PORT MORESBY, May 30 (Reuters) - Papua New Guinea's parliament endorsed on Wednesday Peter O'Neill as prime minister for the third time in a bid to resolve a long-running crisis over the leadership of the resource-rich South Pacific nation.
However, a PNG expert said the vote for O'Neill was probably illegal as parliament had already been suspended and writs have been issued for national elections in June.
At a special sitting, O'Neill was elected unopposed as prime minister by 56 of the 109 members of parliament. Prime ministerial rival Michael Somare and his supporters boycotted the vote.
But Australian National University professor Ron May said the parliamentary gathering had no legal standing.
"The parliamentary meeting today was a bit of a circus," May told Australian television.
"The writs for the election have been issued, the parliament has been prorogued, so a meeting of the parliament has no standing."
PNG, an often volatile nation of about 6.5 million people, has been through a prolonged period of political uncertainty.
O'Neill and Somare, a former prime minister, have been jostling for power since last August 2011, when Somare was ruled ineligible to be a member of parliament after a prolonged absence from legislature because of illness.
O'Neill has the clear support of parliament but the Supreme Court has twice ruled that Somare was eligible to sit in parliament and that he remains the legitimate prime minister.
The issue reached a flashpoint on May 24, when police arrested the chief justice and charged him with sedition over a judgement in favour of Somare. A second judge was charged with sedition on Monday.
Adding to the confusion over O'Neill's appointment, Governor-General Michael Ogio left the country on Monday to attend celebrations in London for Queen Elizabeth's 60 years on the throne, leaving it to an acting head of state to swear O'Neill back into office.
PNG has vast mineral resources but struggles to pass on the benefits to its people. U.S. oil giant ExxonMobil is developing a $15.7 billion liquefied natural gas plant, the country's biggest-ever resource project. (Writing by James Grubel; Editing by Robert Birsel)