But the German chancellor has pledged her full support for the former Luxembourg prime minister Jean-Claude Juncker to be the next head of the European commission in Brussels, despite vehement opposition from David Cameron.

Addressing parliament in Berlin, Merkel also appeared to confirm German press reports that the issue of the top commission post could propel Britain to exit the EU.

Merkel's tricky balancing act – keen to keep the UK as an EU ally while under mounting domestic pressure to throw her weight behind Juncker – came as she and Cameron met in Brussels on Wednesday evening for a G7 summit with the leaders of France, Italy, the US, Japan and Canada.

At an EU summit last week in Brussels to deal with the fallout of the European elections, Cameron made it absolutely clear that he views Juncker as a "face from the past" who was not fit to lead the EU executive for the next five years. Merkel, however, pledged her support for the Luxembourger at the congress of European Christian Democratic parties in Dublin in March and is under strong pressure at home to redeem that pledge.

Cameron's Tories, under siege at home from Ukip, see Junker as an EU federalist, incapable of implementing the European reform agenda that the prime minister says is necessary to keep Britain in the EU.

Herman Van Rompuy, the president of the European Council who has been charged with seeking a way out of the incendiary dispute over top Brussels posts, confirmed he was likely to tackle the issue on the fringes of the summit.

"It's not excluded that we discuss this upcoming nomination," he told reporters in Brussels.

With an Anglo-German media war brewing over the fate of Juncker, Van Rompuy played down suggestions he was livid after The Sun branded the Luxembourger "the most dangerous man in Europe". But senior officials said privately that Van Rompuy, the EU's fixer-in-chief, was incensed.

With the dispute threatening to veer out of control, Merkel sought to turn down the volume after German pundits and senior politicians this week exploded in exasperation with British blocking tactics in the EU – and told London to put up or shut up on the Juncker issue. She said she was aware of British opposition to Juncker becoming the next president of the European Commission back in October. "I don't share these reservations," she said. "I am also trying to ensure that the lead candidate of the European People's Party, Jean-Claude Juncker, receives the qualified majority he needs to become the next president of the European Commission. The entire German government is pushing for this."

Officials and diplomats in Brussels say Cameron and Merkel have boxed themselves into a corner, with the chancellor under intense pressure at home to engineer Juncker's appointment and Cameron facing possible humiliation should that come to pass.

"We need time. It's going to take a while," said an EU official. "There is a need for de-mining on both sides. But Cameron has been a lot less confrontational in private than is being reported." Germany's bestselling Bildzeitung and the influential weekly Der Spiegel have been spearheading the criticism of Britain in Europe this week, while the German media generally have been highly critical of Merkel's to-ing and fro-ing on the issue.

When she distanced herself from Juncker's prospects at an EU summit last week, she encountered unusually hostile questioning from the German media and performed a U-turn to back the Luxembourger.

Reports from Paris on Tuesday that she had suggested France's Christine Lagarde, head of the International Monetary Fund, for the post were dismissed in Brussels as French spin, although Lagarde's name, as well as several others, has been in the frame for the post for months. However, France's president, François Hollande, is said to oppose Lagarde.

Van Rompuy has been in telephone contact with several EU leaders in recent days, including Cameron, officials said. They added that privately Cameron felt betrayed by Merkel because of her volte face in favour of Juncker.

In Berlin on Wednesday, Merkel paid effusive tribute to Britain and criticised the anti-British comment in Germany.

"What would have come of Europe had the British people not found the strength to put its existence at risk to save Europe," she said ahead of the D-day landings anniversary.

Britain and Germany shared common interests and values, she stressed, while complaining that Britain was "no pleasant partner" in the EU.

There were many in Germany who were "casually or even indifferently" disposed towards Britain quitting the EU, she noted. This was "negligent, in fact unacceptable".

The five main groupings in the newly elected European Parliament are demanding that Juncker be allowed to try to build a majority to become next head of the commission.

They include Merkel's group, the European People's Party, which won the election. One of her christian democrats, Manfred Weber, on Wednesday became the new floor leader of the EPP and promptly demanded Juncker's coronation at the commission.

"It will be good to elect a president in July and his name should be Juncker," said Weber. "That will be a signal of stability and Europe needs stability."

The outgoing head of the EPP, Joseph Daul of France, said: "Mr Cameron can speak and he's a good negotiator. But he needs a majority."

Cameron's intense opposition to Juncker is shared by the Hungarian and Swedish prime ministers while the Danish and Dutch leaders also have reservations.National leaders decide by a qualified majority on who to propose for the post and the nominee then has to be endorsed by an absolute parliamentary majority of 376. So far, Cameron lacks enough support to block Juncker, although it would be highly unusual for the leaders to name someone against the wishes of several EU government chiefs.

While the leaders wrestle over who to proposed for the job, the underlying power struggle is between the national leaders and the parliament over who ultimately decides who heads the EU executive. Until now the job has been in the gift of the national leaders, but the parliament is flexing is flexing its muscles under new powers it gained in the Lisbon Treaty.Juncker said: "I am more confident than ever that I will be the next European Commission president." Merkel and Cameron were expected to meet one-on-one late on Thursday night or early Friday after the summit dinner.