Several shells have hit the terminal of Libya's main airport as rival armed groups fought in Tripoli for a fifth straight day, and gunmen assassinated a female politician in the country’s east.

In another sign of growing turmoil, air controllers on Thursday halted work in Tripoli, shutting off much of the oil-producing country from international traffic.

Tripoli International Airport has been a battlefield since fighters attacked it with heavy guns on Sunday to wrest control from a rival militia which has been based there since the fall of Libya's late ruler Muammar Gaddafi in 2011.

The conflict is fuelling worries that Libya is on the point of turning into a failed state where a weak central government is powerless to control the militias which helped oust Gaddafi in 2011.

The airport fighting pits brigades from Misrata, a western coastal town, against rival fighters from Zintan in the northwest.

On Thursday, several shells hit the airport terminal where the Zintanis are holding out, striking the main building for the first time, witnesses said.

A Reuters news agency reporter at the airport saw holes in the roof and smashed windows at the terminal building and in airline offices, including one belonging to British Airways, with a shell lying on the floor.

Air controllers refused to go to work at the control tower in Tripoli, which regulates traffic for all of western Libya, a spokesman for the transport ministry said.

Politician assassinated

On Wednesday, Libya reopened the western Misrata airport, which had been closed with Tripoli after the weekend attack, but it will have to shut again because Tripoli air controllers are also responsible for Misrata.

Many Libyans who had been planning to come home for the Muslim fasting month of Ramadan have been trapped abroad.

Expatriates trying to leave the country have been travelling by taxi to Tunisia, in scenes reminiscent of the 2011 NATO-backed uprising.

In the eastern city of Derna, gunmen shot dead Fariha al-Barkawi, a former member of parliament, officials said.

She is the second prominent woman to be assassinated, following the killing of Benghazi human rights activist Salwa Bugaighis last month.