The signing was met by a wave of applause in the hall as representatives from both sides shook hands
Sudan's army rulers and protest leaders Sunday signed a hard-won constitutional declaration that paves the way for a promised transition to civilian rule following more than seven months of often deadly street rallies.
The agreement, signed at a ceremony in Khartoum, builds on a landmark July 17 power-sharing deal and provides for a joint civilian-military ruling body to oversee the formation of a transitional civilian government and parliament to govern for a three-year transition period.
Protest movement leader Ahmed Rabie and the deputy head of the ruling military council, General Mohamed Hamdan Daglo, signed the declaration at the ceremony attended by African Union and Ethiopian mediators.
"We turned a tough page of Sudan's history by signing this agreement," Daglo, who flashed a victory sign after making a short speech, told reporters.
The signing was met by a wave of applause in the hall as representatives from both sides shook hands.
Overnight, thousands of jubilant Sudanese already took to the streets of the capital to celebrate when the deal was announced before dawn.
A formal signing in front of foreign dignitaries is due to take place on August 17 - the date on which ousted president Omar al-Bashir is due to go on trial on corruption charges - another protest leader, Monzer Abu al-Maali, told AFP.
The next day, the generals and protest leaders are expected to announce the composition of the new transitional civilian-majority ruling council, he said.
"Members of the ruling sovereign council will be announced on August 18, the prime minister will be named on August 20 and cabinet members on August 28," Abu al-Maali told AFP.
Sunday's accord was the result of difficult negotiations between the leaders of mass protests which erupted last December against Bashir's three-decade rule and the generals who eventually ousted him in April.
Demonstrators hail 'victory'
The talks had been repeatedly interrupted by deadly violence against demonstrators who have kept up rallies to press for civilian rule.
They were suspended for weeks after men in military uniform broke up a long-running protest camp outside army headquarters in Khartoum on June 3, killing at least 127 people according to doctors close to the protest movement.
They were briefly suspended again earlier this week when paramilitaries shot dead six demonstrators in the city of Al-Obeid, four of them schoolchildren.
On Saturday, the Arab League welcomed the agreement saying the signing of the constitutional declaration "would launch a new and important phase in line with the Sudanese people's aspirations".
Sudan's army ruler Abdel Fattah al-Burhan lauded the "long-awaited deal" in an interview on Saudi broadcaster Al-Hadath.
Demonstrators among the crowds that took to the streets in the early hours hailed victory in their struggle for a new Sudan.
"For us, the revolution succeeded now and our country set foot on the road towards civilian rule," said 25-year-old Ahmed Ibrahim as he joined the cavalcade of vehicles that criss-crossed the streets of Khartoum, horns blazing.
Fellow protester Somaiya Sadeq said she hoped there would now be justice for those who had given their lives.
"We have been waiting for a civilian state to seek fair retribution from the murderers of our sons," she told AFP.
Doctors linked to the protest umbrella group, the Alliance for Freedom and Change, say a total of more than 250 people have been killed in protest-related violence since December.
Protest leaders have blamed much of the violence on the feared paramilitaries of the Rapid Support Forces, who sprang out of the Janjaweed militia notorious for alleged war crimes during the conflict in Darfur.
The military announced on Friday that nine of them had been dismissed and arrested on suspicion of involvement in this week's fatal shootings in Al-Obeid.
Protest leaders said they had won the military's agreement that the RSF irregulars would be integrated in the army chain of command.