The deal will see AmerisourceBergen pay $2.56bn (€2.2bn) for the Lake Forest, Illinois-based compounder, which makes sterile drug preparations for around 3,000 hospitals in the US.
Amerisource CEO Steven H. Collis described PharMEDium as "the undisputed leader in an important growth area of the US healthcare market."
Ross Muken from Evercore ISI told investors the deal "comes as a modest surprise from a diversification perspective given the recent controversies surrounding drug compounding pharmacies.
However, he added that: "Given ABC's earnings per share growth slowdown from the mid 20% range over the past two years to "low teens" in FY16, today's acquisition makes sense as it would accelerate the company's EPS growth."
The pharmaceutical compounding sector has changed a lot in the past few years following a number of contamination and quality-related problems with drug products.
In the 1990s the FDA could identify drugs for which compounding posed a threat to efficacy or safety. However, in 2001 it was stripped of these powers after they the US Supreme Court ruled them unconstitutional.
In the years that followed the ruling – which prompted the dissolution of the FDA's Pharmacy Compounding Advisory Committee – regulatory monitoring of compounders was been sketchy at best with the FDA becoming involved in various legal battles with firms it tried to regulate.
The situation changed dramatically in 2012 when an outbreak of fungal meningitis was linked to a compounding pharmacy that resulted – in 2013 – in the FDA being granted powers to inspect pharmacies and facilities that register as outsourcing sites.
Since then a number of compounders have been issued with warnings by the US FDA.
These warnings have created a gap in the market and AmerisourceBergen is not the only firm to have noticed.
In August, a newly founded pharmacy called QuVa announced it was acquiring a compounding facility operated by Healix.
At the time a QuVa spokesman told us "We believe there is a market need and opportunity for one more scale national player to meet marketplace demand, particularly one that is focused on manufacturing high-quality products and delivering responsive customer service."