Dozens of widowed and divorced Libyan women are learning to eke out a living in the war-scarred port city of Benghazi by making clothes, with the help of a local charity.

Benghazi was a battlefield from 2014 to 2017 when forces linked to a government based in eastern Libya fought Islamist fighters, some linked to Islamic State, devastating whole districts of the city.

Many women were widowed when their husbands were killed in the violence. They struggle to make a living due to a closure of local banks and a lack of banknotes caused by supply problems in a country with two rival administrations.

A local foundation called Amal, which means "hope" in Arabic, has set up a workshop where it is training some 40 to 50 women who receive no financial help from the state to become seamstresses.

"I heard of this idea and I came for work to earn money," said one woman who gave only her family name, Mohammed, while she was getting trained at a sewing machine.

Benefactors both inside and outside Libya have donated some 50 sewing machines to the charity, said Jamal Mosrati, one of the Amal founders.

Libya, once the wealthiest country in North Africa, has slipped into a spiral of violence since the toppling of veteran ruler Moammar Gadhafi in 2011.

Tripoli and western Libya are run by a U.N.-backed government, while the east is controlled by a rival administration.

A total of 1.1 million Libyans — in a country with a total population of about 6.5 million — are in need of humanitarian assistance, the United Nations says, amid continuing conflict between rival armed groups in several regions.

Security in Benghazi has improved since 2017, but two mosque bombings earlier this year killed at least 35 people.