Speaking in Istanbul on Friday after talks with German Chancellor Angela Merkel, Erdogan also said countries which attended a Libya summit in Berlin on Sunday should not favour al-Sarraj’s opponent, Khalifa Haftar, after he left the meeting without signing a ceasefire deal.
Earlier on Friday, the Turkish president warned of chaos in Libya unless peace is quickly established, as he hosted Merkel.
The two leaders inaugurated a new Turkish-German University in Istanbul, where Erdogan expressed his concerns about the Libyan conflict.
“If calm is not established as soon as possible, the atmosphere of chaos in Libya will affect all the Mediterranean basin,” he said in a speech
Missile attacks this week on Tripoli’s Mitiga airport, blamed on Haftar’s forces, show “who is in favour of peace and who is in favour of bloodshed and tears,” Erdogan said.
“We hope the international community will not make the mistakes it made in Syria,” he said.
Haftar’s forces, which are aligned with an eastern-based rival administration and control the east and much of southern Libya, receive support from the United Arab Emirates (UAE) and Egypt.
In addition to the conflict in Libya, talks between Erdogan and Merkel were expected to also focus on the future of a migration deal between Turkey and the European Union that helped decrease refugee flows to Europe.
The number of refugees and migrants entering Europe from Turkey rose significantly last year as people fleeing conflict in Syria and Afghanistan arrived in Greece, leading to deteriorating conditions in overcrowded camps on the eastern Aegean islands.
Spearheaded by Germany, the EU agreed in 2016 to grant Turkey up to six billion euros ($6.6bn) in Syrian refugee aid money and other incentives to persuade the government in Ankara to stop migrants departing for Greece.
Erdogan frequently accuses the EU of not fulfilling its side of the deal and has in the past threatened to “open the gates” for refugees and migrants to head to Europe.
He says his country cannot be expected to shoulder the burden of hosting more than 3.6 million Syrian refugees and wants European support to settle some of them in a so-called “safe zone” in northern Syria. European nations are reluctant to back such a proposal.
The timing of Merkel’s visit also comes amid rising tensions with the EU over Turkey’s attempts to drill for natural gas in waters in the eastern Mediterranean where EU-member Cyprus says it has exclusive economic rights. Cyprus last week denounced Turkey as a “pirate” state that flouts international law.
Turkey insists it is protecting its rights and interests, and those of breakaway Turkish Cypriots, to the region’s energy resources. It says it is carrying out drilling activities as part of an agreement with the Turkish Cypriots.