Libya's parliament on Tuesday approved a constitutional amendment for the direct election of an interim president, a member of parliament said.
The proposal was backed by 141 of the 144 lawmakers present, the MP, Abu Bakr Biira, told AFP.
"A consensus was negotiated among members before the vote," Biira said, adding that the vote "shows the willingness of members of parliament to let the people elect a president directly and without pressure."
The provisional General National Congress (GNC), which the new parliament replaced when it first assembled on August 5, had made no decision about how the president was to be chosen.
Signup to our newsletter and follow us on Facebook and Twitter!
GNC members had expressed fears that allowing lawmakers to elect a president would provoke political horse-trading in a country riddled with divisions, power struggles and violence.
The constitutional amendment foresees the election of a president no more than 40 days after the official adoption of the election method.
However, such deadlines are rarely met in Libya, where militias have held sway since the fall of long-time dictator Moamer Kadhafi in October 2011 after an eight-months uprising.
The current Libyan constitution gives major powers to the president. He appoints the prime minister who, subject to parliamentary approval, selects the head of intelligence and Libya's ambassadors to other countries.
Until the president's election, parliament makes those appointments.