Philippine President Rodrigo Duterte has appealed to Muslim separatists and Maoist-led rebels to join his government's fight against Daesh-linked militants.
With fears growing that Daesh is seeking a presence in the country, Duterte offered to pay and even house fighters from groups that have long opposed the Philippine state if they would work to defeat a common enemy, the Maute group.
Duterte said the idea of militias and soldiers fighting together had come from the leader of one of the separatist groups.
Maute militants have pledged allegiance to Daesh and have been battling government troops since laying siege to a southern city six days ago.
During a visit on Saturday to an army base on Jolo island, where Philippine forces are fighting another extremist group, the Abu Sayyaf, Duterte said he would treat communist and separatist guerrillas the same as government troops if they join his fight.
"I will hire you as soldiers - same pay, same privileges, and I will build houses for you in some areas," Duterte said, according to a video of his speech made available on Sunday.
He made the unconventional offer to the Moro Islamic Liberation Front and the Moro National Liberation Front. He also asked the communist New People's Army (NPA) to abandon its protracted guerrilla war and work with his government.
The military was using attack helicopters, artillery and ground troops on Sunday to try to take back Marawi City on Mindanao island, where Maute militants are putting up heavy resistance.
Sixty one rebels, 15 security forces and nine civilians have been killed in the violence, while tens of thousands of people have been displaced.
The MILF and MNLF have waged a separatist rebellion since the late 1960s and have signed separate peace deals with the government, but those agreements have yet to be fully implemented.
Duterte's offer to the Maoists comes after his government cancelled the latest round of peace talks with the NPA's political arm, accusing the rebels of planning more attacks.
"If this drags on, and you want to join, take your chance with the Republic," Duterte said.
There were no immediate reaction from leaders of the groups to Duterte's offer.
Duterte said the founder and leader of the MNLF, Nur Misuari, had sent him a letter volunteering his men to join the battle in Marawi and other parts of Lanao del Sur province.
The president said he could create a new army division to accommodate the Muslim and Maoist rebels, which he said had battle experience and mastery of the local terrain.