By Ghaith Shennib and Marie-Louise Gumuchian
TRIPOLI (Reuters) - Libya's prime minister said he would reshuffle the cabinet and reorganize the government to cope with the "urgent" situation in the country following killings in the eastern city of Benghazi that sparked violent demonstrations.
Hundreds took to the streets overnight to denounce the assassination of a prominent political activist and critic of the Muslim Brotherhood, Abdelsalam al-Mosmary, who was shot dead on Friday after leaving a mosque in Benghazi.
The demonstrations turned violent, and on Saturday protesters attacked the Benghazi and Tripoli offices of the Muslim Brotherhood's political party and the headquarters of a liberal political coalition in the capital.
Mosmary, one of the first activists to take to the streets in Libya's February 2011 uprising, was an outspoken opponent of the Brotherhood, whose Islamist political wing is the second biggest party in Libya's General National Congress (GNC). Two military officials were also killed in Benghazi on Friday.
Libya's government is struggling to assert its authority over armed groups that helped topple veteran leader Muammar Gaddafi in 2011, part of the wave of Arab Spring uprisings that also felled autocrats in Tunisia, Egypt and Yemen.
"We are about to make a cabinet reshuffle and decrease the number of ministries to ensure a better performance to face the urgent situation," Ali Zeidan told a news conference, without giving details. "What is happening is an attempt to obstruct the state's progression."
Zeidan referred to the assassinations in Benghazi but made no reference to the storming of the parties' offices.
Libya's border with Egypt was closed to prevent Mosmary's killers from fleeing, he said, with only cargo trucks allowed to pass.
Earlier on Saturday, protesters in Benghazi invaded and set fire to a building housing the Muslim Brotherhood's political wing, the Justice and Construction Party (JCP), witnesses said.
"They shouted 'Gather your belongings. Benghazi wants you out'," Benghazi resident Rami al-Shahibi said.
Hundreds gathered outside Benghazi's Tibesti hotel, one of the main squares in the city for demonstrations, for funeral prayers for Mosmary before heading to a cemetery. They continued to shout anti-Brotherhood slogans.
In Tripoli, a crowd stormed JCP headquarters before heading on to ransack the headquarters of the liberal National Forces Alliance (NFA), the country's biggest political party founded by wartime rebel prime minister Mahmoud Jibril.
There has been rising opposition in Libya to the influence of the Muslim Brotherhood, which has links to several government ministers. The movement has struggled to convince Libyans wary of foreign interference that it has no financial or administrative links to its namesake in Egypt, whose Islamist president Mohamed Mursi was overthrown by the army on July 3.
Tensions are also high between secularists and the ruling Islamists in Tunisia, where the funeral of an assassinated secular politician took place on Saturday.
"THE STATE HAS FAILED"
Many of the protesters accused the Brotherhood of being behind the killings in Benghazi, cradle of the 2011 revolution and now a hotspot for violence - a charge rejected by Abdulrahman al-Dibani, a JCP member in congress.
"We have strongly condemned the assassination of Mosmary and all the Libyan people should hear this and not openly blame us," he said. Reached by phone, Bashir el-Kubti, head of the Muslim Brotherhood in Libya, declined to comment on the attacks.
Libyans are growing increasingly frustrated as they witness continuous political squabbling and lawlessness across the North African country, a major oil producer. The GNC passed a law this month for the election of a 60-member committee that will draft the country's new constitution after months of infighting.
On Saturday, hundreds of prisoners broke out of a Benghazi jail following a riot, security officials said, in another example of the breakdown in security. One official said the freed prisoners numbered at more than 1,000 but this could not immediately be verified.
"The people were in the streets because they are fed up of all political parties and how the state has failed," said Hisham Idris, who had demonstrated in Tripoli's Martyrs Square.
"Maybe the growing opposition to the Muslim Brotherhood is because they are trying to achieve their political ambitions using religion as a cover for their agenda."
Officials for the NFA were not immediately reachable for comment. A party source said the alliance was scheduled to meet on Sunday to discuss its next move, potentially even looking at pulling out of the GNC. The NFA, which has just under 40 seats, has already boycotted sessions in the past.
(Additional reporting by Feras Bosalum and Reuters Television; Writing by Marie-Louise Gumuchian; Editing by Sonya Hepinstall)