The EU's sweeping new rules on the regulation of medicines has been one of the most bitterly contested pieces of legislation in recent times, with fierce lobbying by the pharma sector - particularly in Ireland - and member states divided on which to prioritise: cheaper medicines for patients, or a regulatory environment that supports indigenous European manufacturers in the face of US dominance.
After two years of deadlock, 26 member states have agreed on a compromise proposal, with only Malta - which has its own small-market medicines challenge - abstaining.
Ironically, it was the Trump administration's hostility to science and medicine regulators that convinced EU member states that the moment to finally agree on a new set of rules was at hand.
"In the US you have a chaotic situation," says one source familiar with negotiations, "between [Health Secretary] Robert Kennedy Jr, who doesn't believe in science or vaccines, and the Trump administration, which has sacked 3,500 people from the Food and Drugs Administration.
"There was a sense in Europe that we should try to get this proposal settled so that we have a stable system in Europe when there's instability elsewhere."
The legislation will now go to the European Parliament, where negotiations between MEPs, the member states and the European Commission, begin on 17 June.
There are hopes that the entire package could be adopted by the end of the year.
The European Commission first proposed overhauling the EU's medicines regime in April 2023, as Europe was emerging from the Covid-19 pandemic.
The EU was reeling from the strain the emergency put on health systems and on the availability of certain kinds of medicines, with a deepening awareness that Europe was overly dependent on China and India for drugs such as antibiotics.
At the same time, digitalisation and the availability of clinical data were opening up new possibilities in how medicines are developed and used.
Despite that, innovative therapies were not reaching patients across Europe at the same speed, while in some member states patients did not have access to medicines they needed due to shortages.
The instinct to reduce health spending further has been given fresh impetus by the expected surge in EU defence expenditure following Russia's invasion of Ukraine.
Overall, the pharma package sought to boost the competitiveness of the sector, reduce the administrative burden - and the over-reliance on India and China - and to tackle the environmental impact of drug manufacture and use.
The central, most divisive issue was around the protection that big European pharma countries would have in holding on to clinical data before generic manufacturers - who could produce cheaper drugs - could access it.
It became a straightforward contest between the competing interests of big pharma, which argued that companies needed the protection in order to invest more in life-saving domestic European research and innovation, and those countries which were more interested in lowering the cost of medicines and making those medicines more accessible to patients.
The legislation was always going to face a stormy passage.
"The difficulty was that the countries that didn't have pharmaceutical industries were very much opposing the regulatory data protection (RDP) element because all they were interested in was making medicines available to citizens," says Fianna Fáil MEP Billy Kelleher, a substitute member of the European Parliament health committee.
"Eastern European countries like Poland, Romania, Bulgaria and others would have been very, very reluctant to support the strong protection of regulatory data, while it was the old West, countries like Ireland, Belgium, Italy, Germany and the Netherlands that have big manufacturing and pharma centres, a lot of research and development, who were pushing for it."

The new rules would attempt to reconcile the issue of regulatory data protection, which theoretically encourages pharmaceutical companies to invest more in life-saving medicines, with the need to make drugs more affordable.
Under existing EU rules, pharma companies were entitled to keep clinical data for eight years - the so-called regulatory data protection (RDP) before they were obliged to make it accessible.
After the eight years was up, generic producers could file an application to use the data, at which point the patent holder enjoyed a further two - and sometimes three - extra years of protection.
Under the commission's 2023 proposal, there would be a two-year reduction in the baseline RDP to six years, with an extra two years of protection.
However, pharma companies could claw back a further two years of protection - extending RDP to ten years.
The ten-year protection period would be available if the patent holder won approval for significant new innovations (one extra year of protection), if the product addressed an "unmet medical need", ie, where there was product authorised in the EU for a particular disease, or where the disease was associated with a high death-rate (such a situation would merit an extra six months of market protection), or if the manufacturer conducted clinical trials or extended access to all member states (another six months).
Essentially, the commission was attempting to balance the need to reward medicines that meet the greatest clinical need, while speeding up access to generic producers who will make drugs that are cheaper.
However, the new rules were facing hostility from traditional pharma manufacturing countries such as Germany, France, Denmark and the Netherlands, who argued that a shorter clinical data protection period would stymie research.
The Irish Times reported on a full scale lobbying effort by industry, including a claim in a letter to Tánaiste Simon Harris by the Irish Pharmaceutical Healthcare Association (IPHA) that the proposal could lead to a 22% drop in new medicines being developed over the coming decade.
It is understood there were tensions between the IDA and Enterprise Ireland, who shared the concerns of industry, and the Department of Health, which was more concerned with lowering the cost of medicines and making them more accessible.
A number of sources have said that while member states with important pharma sectors went public two years ago, when the commission first proposed reducing clinical data protection from eight years to six, in demanding the status quo of eight years, Ireland remained on the fence, and did so right up until a key meeting of EU ambassadors on 21 May.
On that date, Ireland joined a blocking majority of ten countries - including Belgium, Denmark, the Netherlands and Germany - to oppose the latest Polish proposal that would have essentially increased the RDP by one year to seven, but short of eight.
As a result of that blocking minority, the Poles came back with another compromise text, which is - to all intents and purposes - a return to eight years, with various caveats and conditions designed to make medicines cheaper and more accessible (one part of the text aims to ensure that medicinal products are available in all member states and provides for regulatory action if the marketing authorisation holder does not comply).
Officials say the text provides more reassurance for generic producers, and will cut timelines for authorised medicines to get to market.
There are other measures, including making it easier to have multi-country and multilingual medicine packs, which should reduce production costs and make it easier to move medicines around Europe.
At yesterday morning's meeting of EU ambassadors, the new text received overwhelming support.
The IPHA are understood to be broadly satisfied with the compromise.
In a statement, the organisation said it "believes the [member states] position represents a more balanced approach than had originally been proposed by the Commission.
"As the legislative process enters the final phase, EU decision makers must continue to find solutions that will keep Europe competitive through a predictable and globally competitive environment for research, development and manufacturing, while ensuring fairer access to innovative medicines for patients across the EU."
Support is not uniform. The chief executive of the Confederation of Danish Industry Lars Sandahl Sørensen accused member states of triggering a potential flight of European industry to Trump's America.
"We are de facto making the EU's pharmaceutical industry less competitive and thus European society vulnerable," he said.
The European pharma lobby group EFPIA described yesterday's position by member states as "a missed opportunity to position Europe's life sciences sector at the forefront of global competition".
In a statement, EFPIA said: "The choice to reduce intellectual property protections for pharmaceutical companies makes Europe less attractive, discouraging investment and jeopardising the development of innovative treatments in Europe without addressing the underlying barriers and delays to patient access."
There is some scepticism over the industry's seeming exploitation of Donald Trump's persistence in threatening tariffs on European pharmaceutical exports and reshoring manufacturing to the US.
In April the industry wrote to commission president Ursula von der Leyen, suggesting that €50.6 billion in capital investment and €52.6bn in research and development expenditure were at risk if the EU continued to over-regulate the pharma sector.
"Unless Europe delivers rapid, radical policy change then pharmaceutical research, development and manufacturing is increasingly likely to be directed towards the US," EFPIA warned.
Officials suggest the upcoming Critical Medicines Act (CMA) will further boost access to cheaper medicines.
Drugs such as those for diabetes or HRT have been susceptible to disruption and shortages in recent years because they are often generic and produced outside the EU. The CMA will aim to encourage more manufacturing of such drugs in Europe.
The action now moves to the European Parliament, where so-called trilogues - three way negotiations between member states, the Commission and MEPs - will further shape the legislation.
Last year the parliament adopted its own position, calling for an RDP of seven and a half years with the possibility of some extensions.
The parliament has since moved to the right, following last year's elections, so it remains to be seen if further battles are expected.
EU states adopt new controversial medicine regulations