Hesitant at first to dump one-time friend Muammar Gaddafi and to back NATO operations, Turkey is taking a lead role in efforts to rebuild Libya now the Libyan leader is on the run, eyeing billion dollar deals and hoping to extend its influence in north Africa.
Turkey, a rising diplomatic and political power in the Middle East and in North Africa, had close political ties with Gaddafi and Turkish companies had projects worth more than $15 billion in the oil producing nation last year.
Prime Minister Tayyip Erdogan, who in February said NATO intervention in Libya was "out of the question," once received the Gaddafi International peace prize from Gaddafi himself.
But as the revolt spread, forcing the evacuation of thousands of Turks and leaving unfinished projects behind, and as Gaddafi grew more isolated internationally, Ankara shifted its position.
It reluctantly backed NATO operations, called on Gaddafi to step down and recognized the rebels as Libya's legitimate government. Ankara has provided the rebel National Transitional Council, the new masters of much of Libya, with $300 million in cash, loans and other aid.
Speaking at a Libya Contact Group meeting of senior diplomats in Istanbul Thursday, Turkish Foreign Minister Ahmet Davutoglu urged the United Nations to unfreeze Libyan assets and pledged full international support for a stable, prosperous and democratic Libya.
Analysts say Turkey's approach has highlighted the challenges Ankara faces as it throws itself to the forefront of diplomacy in the Middle East and Africa and beyond while trying to look after its interests in the wake of Arab Spring revolts.
"Turkey is taking the lead in post-Gaddafi Libya to secure its extensive commercial interests and it wants to demonstrate it is an indispensable player in the Middle East and in Africa," said Fadi Hakura, a Turkey expert from the London-based Chatham House think- tank.
"Libya will become a theater for competing economic interests. The U.S., France, Italy and Britain have the leg up in securing their interests for taking the lead in assisting in the removal of Gaddafi. But commercial opportunities are big enough to accommodate many countries, including Turkey."
Davutoglu was the first international dignitary to visit Benghazi Tuesday after rebels fighting to end Gaddafi's 42-year-old rule, backed by NATO air strikes, entered Tripoli.
Aref al-Nayed, Libyan ambassador to the United Arab Emirates, was quick to praise Turkey, which is the current term president of the Libya Contact Group made up of the nations that opposed Gaddafi's campaign to crush the rebellion.
"We expect the world community to follow the wonderful support of Turkey, its leading role and effort. Turkey has done an amazing job," Nayed told reporters at the Istanbul meeting.
FRIENDS AND BUSINESS
Helped by a foreign policy aimed at winning friends and business, Turkish firms have gone aggressively into the Middle East and Africa, particularly North Africa.
This drive, which has helped European Union candidate and long-time NATO member Turkey become one of the fastest growing economies in the world, has come as Ankara pursued a "zero problems with neighbors" policy.
In Libya, which had been part of the Ottoman Empire until it lost the province to Italy in the early 20th Century, Turkish companies had projects worth $15.3 billion.
While Ankara courts Libya's government-in-waiting, businessmen are waiting for the situation to calm before they can return and expect the National Transition Council to use unfrozen assets to honor pending payments to Turkish companies.
"Turkey will be taking an active role in the country," Riza Nur Meral, chairman of the Confederation of Businessmen and Industrialists of Turkey told Turkish media.
"The chance that Turkish firms will return to the war-stricken country is very high."
At the same time, Turkish Energy Minister Taner Yildiz said he wanted state-owned oil and gas exploration company TPAO to resume oil exploration and production work in Libya if security is established.
Turkey's policy of championing democracy and Arab Spring aspirations while befriending the region's autocratic leaders will face a further test in Syria, analysts said.
Turkey, which has forged close political and economic ties with neighbor Syria, is bitterly frustrated at President Bashar al-Assad's crackdown on demonstrators demanding an end to his 11 years in power.
"Libya and Syria have underlined the soft belly of Turkey's zero problems with neighbors because zero problems with neighbors means zero problems with regimes," said Sinan Ulgen, from the Istanbul-based Center for Economics and Foreign Policy Studies.
"Turkey's foreign policy has become subservient to its economic interests in the region but in Syria it will also be forced to take the right side of history."
Ulgen predicted Turkey-Syria relations will eventually come to a head if Assad keeps ignoring international calls to end his crackdown. Davutoglu, who met Assad in Damascus earlier this month, said Turkey had issued its "final word."
Senior Turkish officials admit Syria -- an ally of Shi'ite Iran with a volatile ethnic and religious mix lying in a web of regional conflicts -- will be a particularly challenging case.
Unlike the United States and the European Union, Turkey has not called on Assad to step down. If Turkey sides with the West on Syria, Tehran might regard Ankara's move as treason. Turkey and Iran have also forged closer ties in recent years.
Almost all governments had abandoned Gaddafi, except Venezuela's Hugo Chavez, so cutting ties with him was relatively easy.
"Libya was one thing but Syria is another. The Iranians are not going to let Syria go that easy," a Turkish official said.