Selcan Hacaoglu| Bloomberg
Turkey’s support for Libya’s internationally backed government aims to salvage billions of dollars of business contracts thrown into limbo by the conflict and secure more leverage in the scramble for oil and gas in the Mediterranean, according to two Turkish officials. Turkey evacuated 25,000 workers during the NATO-backed uprising that ended Moammar Gadhafi’s four-decade rule in 2011. Libya has been in turmoil ever since, with rival governments in the east and west and dozens of militias vying for control of a country that’s home to Africa’s largest proven oil reserves.

Eight years on, Ankara has thrown its support behind the Tripoli government, which is fending off a campaign by eastern-based military commander Khalifa Haftar to capture Tripoli and wrest full control of the OPEC member.

The recent capture of six Turks by forces loyal to Haftar threatened to drag Turkey deeper into what’s morphing into the Middle East’s latest proxy war. The captives were freed only after Turkey threatened to take military action against Haftar, who is backed by several countries including its regional rivals the United Arab Emirates and Egypt.

Turkey’s main goal in backing the Tripoli-based government of Fayez al-Sarraj is to ensure it will eventually be able to resume construction projects worth about $18 billion, said the two officials, who spoke on condition of anonymity.

Restoring calm and keeping Sarraj’s government in place would also make it easier to demarcate maritime borders, helping Turkey expand its exclusive economic zones and strengthen its hand in the competition for control of energy resources and supply routes in the eastern Mediterranean, they said.

Turkey is vying with Cyprus for control of potential offshore energy finds and wants to become the main conduit to Europe for natural gas supplies from the Mediterranean.

Turkey’s friendship with Libya was forged when Gadhafi gave it spare parts to operate its American-made jets during a U.S. arms embargo over the Turkish military’s seizure of northern Cyprus in 1974.

Turkish builders soon became a mainstay of foreign business in Libya, despite a subsequent influx by Chinese, Russians and others.

President Recep Tayyip Erdogan received a human rights award named after Gadhafi in 2010.

Sarraj’s government has boasted of the backing it has received from Ankara, releasing images of Turkish-made armored cars, several weeks after disclosing that the Turks would be arming its forces.

In early May, video footage published on social media showed the vehicles passing through the streets of Tripoli to the cheers of locals.

Responding to questions about reported arms shipments, Erdogan told journalists on June 20 that “we are providing some support in line with their requests.”

However, Erdogan’s special Libya envoy Emrullah Isler denied that Turkish armored personnel carriers and drones had been delivered to the Tripoli government, which would be a violation of a United Nations arms embargo. Isler also said Turkey had not provided support to Libyan government fighters and affiliated militias who seized a strategic city south of Tripoli from Haftar last week.

Both sides have traded accusations over the supply of arms.

Sarraj’s government said last week it had seized sophisticated U.S.-made missiles originally sold to the UAE and apparently left behind when Haftar’s forces withdrew from Gharyan. The UAE and Haftar denied the claim.