(CNN) -- The son of Gabon's former president was declared the winner of the country's presidential elections on Thursday, sparking violent protests in some parts of the West African nation.
Voters went to the polls Sunday to elect a successor to President Omar Bongo, who died in June after more than four decades in office. Bongo, 73, was Africa's longest-serving ruler.
In a live announcement Thursday on Gabonese television, Interior Minister Jean Francois Ndongou said Ali Bongo received 41.73 percent of the votes in Sunday's election, with former interior minister Andre Mba Obame getting 25.88 percent and main opposition leader Pierre Mamboundou winning 25.22 percent.
Opposition supporters protested the results outside the French consulate in the oil-rich city of Port-Gentil, on the country's coast. A fire broke out at the consulate during the demonstrations, a French official told CNN. The official did not want his name to be used.
Some people were seriously injured in the blaze, the official said.
In his first address to the nation shortly after the results were announced, Ali Bongo, 50, promised to work to improve living conditions for all Gabonese by a redistribution of the country's riches, according to Gabonese media reports.
The country has multiple lucrative natural resources, including oil, timber, minerals and gems.
Before the results were made public, all three candidates had previously claimed victory, with the opposition candidates denouncing what they said was fraud in the election and vote-counting.
Security forces patrolled the streets in the Gabonese capital of Libreville, where violence broke out in some quarters when the results were released, according to French media reports.
Libreville was deserted because residents had fled to villages for fear of post-election violence, Andriankoto Ratozamanana told CNN by phone from the capital.
"The citizens won't accept if Ali Bongo wins, because that will mean the government stole the vote," Ratozamanana said. "They want change. They don't want Bongo, because he is his dad's son."
The younger Bongo, a former defense minister, was one of 23 politicians originally in the ballot. Several candidates pulled out a few days before the vote to support the opposition, said Archippe Yepmou, a media activist.
The elder Bongo took power in 1967, seven years after the country's independence from France.
He imposed one-party rule a year after succeeding the country's first president, who died in office. He allowed multiparty elections after a new constitution in 1991, but his party retained its grip on the government despite that.
The nation of about 1.5 million has a per capita income four times that of most sub-Saharan African nations, according to the CIA World Factbook.
Despite its wealth, which also comes from timber exports, a large percentage of its population lives in poverty because of poor financial management and a huge gap between the rich and the poor.
--CNN's Alanne Orjoux and Umaro Djau contributed to this report.
TM & © 2009 Cable News Network, Inc., a Time Warner Company. All rights reserved.