A flurry of lawsuits over 509 Fifth Ave. may become moot now that sources say Rabbi Joshua Metzger has signed a contract to pay $40 million for the nondescript building partially occupied by his nonprofit Chai Foundation and Chabad Lubavitch of Midtown.

The rabbi, who blessed Knick Amar’e Stoudemire after he went to Israel to search for his Jewish roots, would be buying a 12-story, 60,000-square-foot building that is sandwiched between two larger buildings and sits mid-block between East 42nd and 43rd streets.

The New York State Supreme Court complaint filed by the Chai Foundation claims that back in 2010, Metzger discussed his desire to buy the building with real-estate investors David Werner and Amram Kass.

The complaint says Metzger provided “confidential” information about the building where Chai was occupying two floors before being cut out of its subsequent purchase.

The complaint asks for at least $30 million in damages from Werner and Kass, who have countered that they are not part of the ownership group.

The suit was also filed against the current owners, 509 Fifth Avenue Associates Owner, which includes Norman Sturner of Murray Hill Properties.

In June 2010, we told you that Werner had acted as the matchmaker between seller Joseph Moinian and Sturner, who closed on his purchase of 509 Fifth Ave. at the end of Oct. 2010 for $32 million.

Since then, sources say, Metzger has been a thorn in Sturner’s plans to create floors of office condominiums and sell them.

A suit filed in January by Sturner’s ownership group asks for over $9 million in damages against a Braintree, Mass., company, along with the Chai Foundation and Metzger.

The suit alleges the rabbi no longer has a lease, has not paid any rent and was in the process of being evicted when the Braintree firm signed a contract to buy the building last year for $39 million.

While the company deposited $1.95 million, it never closed on what was to be a December 2011 purchase. The suit alleges the rabbi interfered with the purchase and even tried to take over the contract.

When Sturner recently hired Eastern Consolidated’s Peter Hauspurg and Brian Ezratty to market the building, Metzger apparently sprang into action, putting down a deposit last Thursday before everyone left for the holiday weekend.

All the parties involved either wouldn’t comment or could not be reached.

It is possible, however, that to help pay for the purchase, the rabbi will carry through with Sturner’s original plans to sell off the retail — now occupied by Steve Madden — as well as other floors of the building.

“In the event that 509 Fifth Ave. was to be converted to office condominiums, I am working with buyers that would pay between $750 and $850 per foot for the approximately 5,000 square- foot floors,” said Michael Rudder of the Rudder Property Group, who specializes in selling office condominiums.

*

For its flagship first US location Armani Junior has just leased a store in the base of the cooperative building at 1223 Madison Ave. on the northeast corner of 88th Street.

The asking rent for the 1,480 square-foot store was $300 a foot — a far cry from the rents just a dozen blocks south. The shop, occupied until the end of January by Boutique Mirabelle, includes a 376-square-foot storage basement.

Nick Cowen of Isaacs and Co. represented the retailer in the 10- year deal.

Faith Hope Consolo and Joseph Aquino of Prudential Douglas Elliman Retail represented the building board.

*

Duryea’s Lobster Deck in Montauk is going up for grabs.

The two acres of land with 650 feet of shoreline on Fort Pond Bay has an additional six acres of underwater rights as well as a 200 foot-long, deep-water dock with approvals for a desperately needed renovation.

“You can create moorings and have a nice lunch while you park your yacht,” said Corcoran’s Helen Stubmann of the $5.9 million listing.

The complex also includes 8,000 square feet across three stores (with one leased to an art gallery), a garage for trucks, a retail fish market with a dining dock, and a beach cottage that housed summer help and was often used for fashion shoots.

[email protected]