Berlin Germany’s ruling coalition has backed Foreign Minister Frank-Walter Steinmeier as the country’s next president, party sources said Monday, paving the way for a sharp critic of Donald Trump to become head of state.

Party leaders have been wrangling for months over whom to nominate as a potential successor to President Joachim Gauck, a 76-year-old former pastor from the ex-communist East Germany who is stepping down due to his advanced age.

On Monday, Chancellor Angela Merkel’s Christian Democratic Union (CDU) agreed on Germany’s most popular politician, Steinmeier, whose name had been put forward by his Social Democratic Party (SPD).

The third party in the coalition — the CDU’s Bavarian allies CSU — backed the decision soon after.

“Now it’s official,” a CSU party source told AFP.

The new president — a figure who is meant to transcend party politics and serve as a moral standard bearer for the nation — will be elected on February 12 by a special assembly of MPs, delegates from Germany’s 16 federal states and other notables.

Steinmeier, 60, has emerged in recent months as the German government’s most strident detractor of US president-elect Donald Trump.

He warned a day after Trump’s shock election that transatlantic relations would become “more difficult”.

“I think we must expect that American foreign policy will become less predictable for us and we must expect that the United States will be more inclined to make decisions on its own,” he said.

During the US campaign, Steinmeier was even more outspoken, saying the prospect of a Trump presidency was a “frightening” prospect for the world.

He also compared Trump to a “hate preacher”, saying he had much in common with “fear-mongers” in Germany’s right-wing populist AfD party as well as advocates of Britain’s exit from the EU.

A veteran of the German political system and a familiar face in world capitals, Steinmeier served as Merkel’s vice-chancellor and chief diplomat during her first “grand coalition” government in 2005-2009.

In his second stint as foreign minister beginning in 2013, he has at times drawn fire for attempting to keep the lines of communications open with Russia despite deteriorating relations over Ukraine.

While his Social Democrats have praised his approach as in keeping with their long tradition of Ostpolitik, critics have accused him of being a “Russlandversteher” or Russia apologist.

Even allies raised eyebrows in June this year when he warned Nato against “sabre-rattling and warmongering” after it conducted military exercises in eastern Europe in response to the perceived threat posed by Russia.

Steinmeier has also been frank in expressing Germany’s disapproval of Turkey’s widening crackdown following a failed military coup in July, saying it should not be used as an excuse to muzzle the opposition.

The choice of a nominee for president threatened to become a distraction for Merkel as she prepares for what is widely expected to be a decision in the coming weeks to seek a fourth term as chancellor next year.

This week she will welcome outgoing US President Barack Obama, with whom she shared an often close working relationship during his eight years in power.

Merkel — arguably the world’s second most powerful democratic leader — is expected to chart a pragmatic course with Trump even as she has insisted she will hold him to basic democratic principles and values.