Entertainment mogul David Geffen was on the verge of marrying Cher – then nearly cracked up when she dumped him for rocker Gregg Allman, according to a new bio.

In fact, the book claims, Geffen was so enraged when the raven-haired pop goddess gave him the boot, he roared: “If you see me walking down the street, you better cross over to the other side!”

The alleged details of the affair are bared in Tom King’s tome, “The Operator: David Geffen Builds, Buys and Sells the New Hollywood,” excerpted in People magazine – an excerpt Geffen reportedly tried to kill by calling editor-in-chief Norman Pearlstine.

The now openly gay Geffen – an owner of DreamWorks SKG with Steven Spielberg and Jeff Katzenberg – was 31 when he first hooked up with 27-year-old Cher in 1973 at the Roxy nightclub in Los Angeles.

He poured his heart out about his confused sexual identity and how he thought a relationship with a woman would “offer him the best chance to find true love,” the book says.

And Cher – in the last stages of her crumbling marriage to Sonny Bono – was touched by his honesty.

“I was the first person to share his bed and to share his life. We were really crazy about each other,” Cher tells the author.

In less than a year, the pair planned to wed and Geffen showered her with gifts including a Rolls-Royce, which he quickly swapped for a diamond necklace when she told him she hated it.

Cher then two-timed Geffen by sleeping with the bass player for the Average White Band, a discovery that “destroyed” him but didn’t stop him from still wanting to walk up the aisle, the book says.

Still, Cher started having second thoughts because Geffen became “controlling” like Sonny had been – and because of his lingering attraction toward men.

After she dumped him, he “tried to transform the relationship into a friendship” and found himself “moping around Cher’s door,” the book says.

When Geffen later saw Cher with Allman, whom she eventually wed, he “blew up, wanted revenge” and demanded his gifts back, the book says.

“You know, you can have some, but there are certain ones I’m not giving back,” Cher said.

“I’ll sue you!” Geffen stormed.

“Go ahead!” Cher shot back, according to the book.

Geffen was “so paralyzed with his post-Cher depression that he could not get out of bed some days” and felt even worse when a mag quoted Cher as saying she’d traded “one short ugly man for another.”

Finally with therapy, Geffen lifted his spirits, called Cher and said he wanted to be friends, according to the book. She accepted, but was flabbergasted to hear Geffen’s next request: “I still want my jewelry back.”