* PNG rivals end political feud and join forces
* Incumbent PM O'Neill set to form new government
* New hopes for political stability in mineral-rich country
PORT MORESBY, July 25 (Reuters) - Papua New Guinea's rival prime ministers have ended a political feud that left the resource-rich country with two leaders for the most of the past year, joining forces to form a government in a surprise twist to the South Pacific nation's elections.
The peace deal means incumbent Prime Minister Peter O'Neill is most likely to head the new government and form a coalition after a prolonged national election in the often volatile country, with backing from rival Michael Somare.
"I want to take this opportunity to thank our founding father of our country, Grand Chief Sir Michael Somare, for joining us, making sure that we provide a government that is truly deserving for Papua New Guinea with all the stability that it deserves," O'Neill said.
The result, if endorsed by parliament next week, should bring a new level of political stability to the nation of around 6.5 million people after a tumultuous year.
Despite its mineral wealth, successive governments have been unable to deliver infrastructure or services to the people, with around 80 percent of the population living on subsistence village farming and small cash crops.
PNG is the home to a $15.7 billion Exxon Mobil gas export project, and the giant OK Tedi copper mine which began production in 1987, as well as the Frieda River copper project, run by Swiss-based global miner Xstrata.
Exxon's LNG project is expected to start production in 2014 and boost GDP by about 20 percent.
Somare, the elder statesman of South Pacific politics at 76 and the country's first prime minister in 1975 after independence from Australia, re-contested his seat despite being gravely ill for much of 2011.
His ill health sparked the feud. O'Neill was voted in as prime minister after Somare was ruled ineligible due to his prolonged absence from parliament.
While O'Neill had the support of parliament, the Supreme Court twice ruled that Somare was legitimate prime minister, leaving the country with rival leaders.
The election, which dragged on for more than a month, was praised by observers as being "largely peaceful", despite reports of sporadic violence.
Other failings included bribery, widespread delays and anomalies in polling, destruction of ballot boxes, and discrimination against women, the Commonwealth Observer Group said in an interim report into the election earlier this month.
The final makeup of the 111-seat parliament should be clear by Friday, when official results are declared.
More than 3,400 candidates from 46 political parties contested the poll, where around half of the country's lawmakers have so far lost their seats.
To form a government, a leader must cobble together a coalition of at least 56 lawmakers during the post-election horse-trading, with the prime minister directly elected by a vote in parliament, which is due to meet by Aug. 3. (Writing by James Grubel; Editing by Nick Macfie)