Al-Qaida-linked militants are battling an Islamic State affiliate in eastern Libya after one of their leaders was shot dead by masked gunmen.

Nasr Akr, an al-Qaida-inspired militant once jailed in the U.K. on terrorism charges, was assassinated along with his aide in the eastern town of Darna, home to many of Libya's veteran jihadists.

Akr's group, known as the Shura Council of Darna's Jihadists, announced his killing in a statement on Wednesday, blaming it on Islamic State militants and vowing retaliation.

Akr's killing sparked heavy fighting, leaving at least nine IS militants dead, witnesses said.

IS seized control of Darna last year. The IS group began as an al-Qaida affiliate but later had a bitter falling out with the global jihadist network. The two groups have also clashed in Syria.