The state funeral of Chad’s long-serving President Idriss Déby is being held after he was killed by rebels.

Among the foreign leaders is France’s President Emmanuel Macron, for whom Chad is a key ally in the fight against jihadists in region.

Friday’s ceremony saw a military march-past and a speech by his son, Gen Mahamat “Kaka” Déby Itno, who the army has named as the country’s new leader.

He vowed to “stay loyal to the memory” of his father.

Gen Déby also said he and his family would continue the legacy of “dialogue, forgiveness, peace, unity” that the late president was “admired for”.

After the ceremony in N’Djamena, Déby will be buried in his native region.

The late president’s son, Gen Mahamat Déby Itno, has been appointed Chad’s new leader

The army says President Déby died in a battle with a dissident army rebel group, called Fact, in the country’s north on Tuesday.

Other visiting heads of state include the leaders of Guinea, Mali, Mauritania and Nigeria – who have all ignored warnings from the rebels that they should not attend for security reasons.

After the military honours and various speeches, a prayer will be said at the Grand Mosque of N’Djamena.

Then, in the early afternoon, Mr Déby’s remains will be flown to Amdjarass, a small village next to his hometown of Berdoba, more than 1,000 km (600 miles) from the capital, near the Sudanese border.

On Thursday, leaders including the presidents of Niger (L), France and Mauritania met in the capital

News of his shock death on Tuesday was met with tributes from numerous presidents – France’s Emmanuel Macron called him a “brave friend”, Cameroon’s Paul Biya said he served “tirelessly”, DR Congo’s Felix Tshisikedi called it a “a great loss for Chad and for all of Africa”, Mali’s President Bah Ndaw lamented his “brutal” death and South Africa’s Cyril Ramaphosa called it “disturbing”.

President Déby was a key player in security strategy in the Sahel region – and Chad is reputed for having one of the best-trained and best-equipped armies in West Africa, which is battling militants link to both al-Qaeda and the Islamic State group.

Chadian military officials watch from the stands in N’Djamena

A military council led by his son, Gen Mahamat Déby Itno took power after his death.

The BBC’s Lalla Sy says he only has partial support of the army, however he is backed by former colonial ruler France, which has a large military base in N’Djamena.

On Thursday French Foreign Minister Jean-Yves Le Drian appeared to back the military takeover, by saying the immediate priority in Chad was to ensure the country’s stability amid “exceptional circumstances”.

People have gathered outside the venue in the capital

Fact rebels also reject it but have called a temporary ceasefire while Friday’s funeral takes place.

In a statement on Friday, the rebels said their command centre had been bombed two days earlier in an attempt to kill their leader. Its location, and details of any casualties, were not specified.