Barack Obama destroyed Libya. What he did to Libya is as bad as what George W. Bush did to Iraq and Afghanistan. He doesn’t deserve a historical pass.

When Obama took office in 2009, Libya was under the clutches of longtime dictator Col. Moammar Gadhafi. But things were looking up.

Bush and Gadhafi had cut a deal to lift Western trade sanctions in exchange for Libya acknowledging and paying restitution for its role in the bombing of Pan Am flight 103 over Lockerbie, Scotland.

In a rare triumph for Bush, Libya also agreed to give up its nuclear weapons research program. Libyan and Western analysts anticipated that Gadhafi’s dictatorship would be forced to accept liberal reforms, perhaps even free elections and rival political parties, in order to attract Western investment.

Libya in 2009 was prosperous. As citizens of a major oil- and natural gas-exporting nation, Libyans enjoyed high salaries, low living expenses, generous social benefits, not to mention law and order. It seems like a mirage today.

Looking back, many Libyans miss their former tyrant. “Moammar Gadhafi inherited one of the poorest nations in Africa,” notes Garikai Chengu of the Du Bois Institute for African Research at Harvard University. “However, by the time he was assassinated, Libya was unquestionably Africa’s most prosperous nation. Libya had the highest GDP per capita and life expectancy in Africa and less people lived below the poverty line than in the Netherlands.”

As a dictator, Gadhafi was guilty of horrendous human rights abuses. But life was better then than now. Women enjoyed more rights in Libya than in any other Arab country, particularly after the United States overthrew Saddam Hussein in Iraq. By regional standards, Libya was a relatively sweet place to live.

In February 2011, militant Islamists based in the eastern city of Benghazi launched an armed insurgency against Gadhafi’s central government in the capital of Tripoli. The rebels were linked in the imaginations of American newsmedia and U.S. foreign policy officials to the Arab Spring uprisings in Tunisia and Egypt’s Tahrir Square. But the Benghazi-based rebels, with close ties to al-Qaida, were ideologically closer to the Free Syrian Army fighters who eventually metastasized into the Islamic State group.

Within the CIA and Defense Departments, no one was sure who the insurgents were or what they wanted. Nonetheless, the Obama administration covertly supplied them with at least $1 billion in cash and weapons.

CIA agents and U.S. Special Forces served as “boots on the ground,” training opposition fighters how to use sophisticated new weapons.

Obama threw Gadhafi, whose regime was secular and by all accounts had been cooperative and held up his end of the deals with U.S., under the bus.

U.S. forces jammed Libyan military communications. The U.S. fired missiles to intercept Libyan missiles fired at rebel targets. The U.S. led numerous airstrikes against units loyal to Gadhafi. U.S. intervention turned the tide in favor of the Benghazi-based rebels.

In October 2011, one of Obama’s killer robot drones participated in Gadhafi’s assassination. Game over.

Before invading Iraq, then Secretary of State Colin Powell warned Bush about his “Pottery Barn rule”: if you break it, you own it. Obama has broken the hell out of Libya.

The New York Times describes Libya as “veer[ing] toward complete chaos.”

In 2015, The Guardian reports, Libya is in danger of meeting the official international definition of a failed state: “Libya is wracked by violence, factionalism and political polarization — and by the growing menace of jihadi extremism. Two rival governments, parliaments, prime ministers and military forces claim legitimacy.

“One side is the Islamist-dominated Libya Dawn coalition in Tripoli, the capital. The other camp, Dignity, which is recognized internationally, is based in Tobruk and Bayda. Hundreds of rival militias exist across the country.

“In recent months the homegrown fighters of Ansar al-Sharia have been challenged by Islamic State, which released a video showing the beheading of 21 Egyptian Christians.

“Oil production, the source of most state revenues, has declined massively. Cash is running out and basic services are facing collapse as the financial situation deteriorates. Hopes for change generated by the Arab spring and the demise of Gadhafi’s dictatorship have faded into despair and dysfunction.”

“Libya is falling apart. Politically, financially, the economic situation is disastrous,” says U.N. envoy Bernardino León.

To Obama’s credit, he admits that he screwed up in Libya. Unfortunately he drew the wrong lesson. In 2014, he told an interviewer that a large ground invasion force might have helped Libya’s post-Gadhafi government succeed. Because that worked so well in Iraq and Afghanistan. But if he really believes that, why doesn’t he order in the troops?

Obama’s real mistake was to depose a secular socialist autocrat and allow him to be replaced by a bunch of crazy religious fundamentalist militias whose factionalism ensured they’d never be able to govern.

Bush committed this error in Iraq. Obama made it in Libya. And now he’s doing it again in Syria.

Ted Rall is a writer and political cartoonist. © 2015 Ted Rall