MECCA, Saudi Arabia (Reuters) - Rival Palestinian factions signed a deal to form a unity government at talks in Saudi Arabia on Thursday, Al Jazeera television reported.
The report said delegations from the Islamist group Hamas, which won the last Palestinian elections, and Palestinian President Mahmoud Abbas's Fatah faction would meet Saudi King Abdullah after the signing.
Earlier Palestinian ambassador to Saudi Arabia Jamal al-Shobaki told Reuters: "We have agreed to form a national unity government. The agreement will be signed very soon."
Hamas and Fatah agreed on the distribution of key cabinet posts.
Abbas, Hamas chief Khaled Meshaal and Hamas Prime Minister Ismail Haniyeh met for the crisis talks after internecine fighting that has killed more than 90 Palestinians since December.
The leaders also want to end an international blockade of the government led by Hamas. Fatah has steered peace talks with Israel since 1993 with U.S. approval.
Israel and the United States say Hamas must renounce violence, recognise Israel and commit itself to existing peace accords signed by the Palestinian Authority before sanctions can be lifted on any government including the Islamist movement.
A large part of the Mecca talks has thus focused on agreeing a formula for the unity government's platform that would satisfy these demands.
Palestinian sources close to the talks said before the announcement of an agreement that Hamas was ready to "respect" the accords with Israel if they "did not contradict Palestinian interests".
But Abbas was seeking a clear statement that it would be "committed" to them, to ensure the sanctions end.
Mediators from Saudi Arabia -- a U.S. ally which is hosting the talks -- have pressed Hamas to agree to the word "committed" to avoid U.S. rejection of a deal, Palestinian sources said.
An explicit recognition of Israel was off the cards, Hamas spokesman Ghazi Hamad told Reuters.
Fatah wanted Hamas to agree to a Fatah deputy prime minister to complement Haniyeh if he retains the premier's post.
The deal on cabinet portfolios envisages former culture minister Ziad Abu Amr being nominated as foreign minister and Salam Fayyad as finance minister, a post he has held before, according to Hamas and Fatah sources.
Hamas is expected to suggest a neutral figure for the interior post.
Fatah would take five minor cabinet portfolios and Hamas would take eight including economy, labour and justice.
Israeli Prime Minister Ehud Olmert said on Tuesday he would meet Abbas and U.S. Secretary of State Condoleezza Rice on Feb. 19, in a bid to restart long-stalled peace talks.
That meeting could be in jeopardy if Hamas does not bend on recognising Israel and past agreements.
Previous efforts to stem the bloodshed between Palestinian factions and find common political ground have resulted in short-lived ceasefires and a threat by Abbas to call a new parliamentary election, a move Hamas has said would be tantamount to a coup.
Abbas and Meshaal vowed on Wednesday at the opening of the Saudi-mediated talks not to leave Mecca without agreement.
(Additional reporting by Wafa Amr in Ramallah, Nidal al-Mughrabi in Gaza and Dominic Evans in Jerusalem)