Stonyfield and Dannon yogurts are stacked on a supermarket shelf, on April 4, 2017, in New York. Danone will sell its Stonyfield Farms business to gain approval from the U.S. for a $12.5 billion buyout of Denver’s WhiteWave Foods, doubling the size of the French company’s business in North America.

NEWARK, N.J. — Danone will sell its Stonyfield Farms business to gain approval from the U.S. for a $12.5 billion buyout of Denver’s WhiteWave Foods, doubling the size of the French company’s business in North America.

The Justice Department said it would approve the deal if Stonyfield were sold, citing the potential for reduced competition in the organic milk market. The department had been particularly concerned about a long-term strategic partnership and supply and licensing deals between Danone S.A. and CROPP Cooperative, a WhiteWave rival. The Justice Department believed the sale of Stonyfield Farms to an independent buyer would cut the ties between Danone and CROPP and maintain competition.

The sale of Stonyfield will help “ensure competitive marketplaces for both farmers in the northeast that sell raw organic milk and consumers who purchase fluid organic milk in stores nationwide,” the Justice Department said late Monday.

Danone plans to sell Stonyfield in the months after the closure of the WhiteWave deal, first announced over the summer.

Danone is one of the world’s leading food companies, producing several dairy brands, baby foods and Evian water. WhiteWave, which went public in 2012, makes Horizon brand organic dairy products, coffee creamers and plant-based dairy alternatives such as Silk brand soy and almond milk.

Shares of WhiteWave opened near all-time highs Tuesday on the New York Stock Exchange.

A White House advisory council on infrastructure Thursday became the latest casualty of the pique of business leaders over President Donald Trump’s response to the hate-fueled violence in Charlottesville, Virginia.