Egyptians wait in Ras Jdir in Tunisia on Friday ahead of being evacuated to the Djerba airport on the Tunisian-Libyan border. Earlier in the week, IS affiliates in Libya released a video showing beheading of 21 Coptic Christians, most of whom were Egyptian, taken prisoner in the country. That prompted Egypt to bomb jihadist targets in Libya and to threaten further action.
Reuters/Benghazi, Libya
Three car bombs ripped through the eastern Libyan city of Qubbah on Friday, killing 40 people and wounding 70 in what officials described as a revenge attack for Egyptian air strikes on Islamist militant targets.
Parliamentary speaker Aguila Saleh said the bombs appeared to have been in retaliation for Egyptian air raids on nearby Derna, an Islamist hotspot.
On Monday, Egyptian air force jets bombed suspected Islamic State targets in Derna in far eastern Libya, a day after the ultra-radical group released a video showing 21 captive Egyptian Coptic Christian workers being decapitated on a beach.
Four years after rebels overthrew Muammar Gaddafi, the oil-producing North African state is in chaos, with two governments and parliaments allied to armed factions fighting for control, while Islamist groups exploit a power vacuum.
Three bombs exploded shortly before Friday prayers at a petrol station, the local security headquarters and the town council in Qubbah, which is Saleh's hometown, security officials said. His house is close to the town council.
There have been suicide and car bomb attacks mainly in the east of Libya but the targets have tended to be police and army bases rather than civilians, with security officials blaming Islamist groups such as Ansar al-Sharia.
"We are announcing seven days of mourning for the victims of Qubbah," Saleh told Al Arabiya television. "I think this operation was revenge for what happened in Derna," he said without elaborating.
He said he was outside Derna at the time of the attacks.
A security official said the car bombs were probably suicide attacks but no more details were immediately available.
The internationally recognised prime minister, Abdullah al-Thinni, is based in Bayda, some 40 km from Qubbah. Saleh works out of Tobruk, another eastern town now home to the House of Representatives, the elected parliament.
The capital Tripoli in the far west is under the control of a rival government and parliament, set up after a faction called Libya Dawn seized the city in summer, forcing Thinni to flee to the east.
Libya's neighbours and Western powers are alarmed by a spread of militant Islamists in the country. Last month, militants claiming loyalty to Islamic State stormed the Corinthia luxury hotel in Tripoli, killing five foreigners and at least four Libyans.
Supporters of the group, which has seized large areas of Iraq and Syria, have also taken over government and university buildings in Sirte, a central city, according to residents.
IS jihadists claim responsibility
The Islamic State group claimed responsibility on Friday for car bombings in eastern Libya that left dozens dead.
A brief statement by an IS branch in Libya said two suicide bombers targeted the forces of General Khalifa Haftar in Qubbah "in revenge for the blood of our Muslim people in the city of Derna", an apparent reference to air strikes on the eastern jihadist stronghold this week.
Qubbah is controlled by Haftar's forces who are backed by Libya's embattled internationally recognised government.
It lies just 30 kilometres west of Derna, where air strikes were launched against jihadist targets on Monday in retaliation for a gruesome Islamic State group video showing the beheading of 21 Christians.