An unusually cozy relationship between white-shoe law firm Weil Gotshal & Manges and one of its longtime clients has soured — and cafeteria privileges have been revoked.

“Weil informed us late yesterday that it has revoked our cafeteria privileges,” Andrew Purdy, executive director at prestigious investment bank Perella Weinberg, told employees in an Aug. 30 memo obtained by The Post.

“It is unfortunate that Weil has taken this action. We recognize that this is short notice and causes inconvenience to many of you,” Purdy added.

Perella Weinberg — which has advised AT&T, Occidental Petroleum and the swanky luxury retailer Barneys — has been the only Weil client that’s enjoyed independent access to Weil’s cafeteria, sources said.

That’s partly because Perella Weinberg’s offices, like Weil’s, are located in the GM Building, the Fifth Avenue landmark that stands across from the Plaza Hotel and whose basement houses Apple’s famous “Cube” flagship store.

Located on the 26th floor, Weil’s cafeteria commands dramatic views of Central Park.

The lunchtime lockout comes amid a legal dispute between Weil and Perella Weinberg over two ex-bankers’ pay packages that was exclusively reported on by The Post.

Last month, Peter Weinberg, one of the investment bank’s founders, and partner Robert Steele told Weil that it could be fired, according to a person briefed on the conversation.

The “not-so-veiled threat” came after The Post revealed that partners at Weil had botched the pay packages for two former Perella bankers, and had kept the bank in the dark about the mistake for years.

The error could lead to millions of dollars in back taxes, penalties and interest — and finger-pointing about who is responsible for covering the bill.

It’s a bitter turn for a relationship that had been unusually friendly for years. Perella, sources say, was essentially founded in Weil’s conference room in late 2005, with investment bankers Peter Weinberg, Joe Perella, Taruk Abdel-Meguid and others getting advice from top Weil lawyers.

While Perella principally operates out of the GM Building’s 10th floor, its bankers had grown accustomed to taking the elevator up to the cafeteria. Weil’s offices occupy the 26th through 32nd floors.

The cozy arrangement has raised eyebrows.

“It’s weird for a law firm to let people be in private spaces unaccompanied, because you have private and confidential concerns,” one former Weil lawyer told The Post. “Especially investment bankers, who know of deals people are on and are competing with.”

Spokespeople for Weil didn’t return requests for comment. A spokeswoman for Perella declined to comment.