By Philip Pullella and Mustafa Abu Ganeyeh
BETHLEHEM, West Bank (Reuters) - Pope Benedict spoke in the shadow of the fortified Israeli wall dividing Bethlehem from Jerusalem on Wednesday, calling it a tragic symbol of deadlock in the struggle for peace in the Middle East.
"Towering over us ... is a stark reminder of the stalemate that relations between Palestinians and Israelis seemed to have reached -- the wall," the pontiff said in a speech at a U.N. school in Aida refugee camp, just metres (yards) from the wall.
In a world of borders opening to travel, trade and culture, he said, "it is tragic to see walls still being erected."
"How earnestly we pray for an end to the hostilities that have caused this wall to be built," said Benedict, the first pope to see the wall.
It did not exist when his predecessor John Paul II visited the Holy Land in 2000. Israel began raising a barrier of fences and concrete through and around the West Bank in 2002, in what it said was a move to stop deadly Palestinian bombings.
Palestinians, backed by the World Court, say it is an illegal construction which steals and divides their land.
The papal convoy drove the few miles south from Jerusalem, passing slowly through steel gates in the fortified barrier of towering concrete slabs and watchtowers, to reach the town that Christians believe is the birthplace of Jesus.
Cheers of "Long Live the Pope, Long Live Palestine" greeted his black limousine along the steep, ancient streets, from Palestinians gathered to hear the leader of the world's 1.1 billion Catholics back their independence aspirations.
"The oppressed have become oppressors," said one graffiti slogan on the grey concrete barrier that formed a dramatic backdrop to the pope's speech at the Basic Boys' School.
"Bridges, not walls!" said another.
"It is understandable that you often feel frustrated," the pope said. "Your legitimate aspirations for permanent homes, for an independent Palestinian state, remain unfulfilled. Instead you find yourselves trapped ... in a spiral of violence."
It was imagery and language that Palestinians had hoped for from the one-day visit. But the German-born pope, criticised in Israel for what Jews saw as a lack of emotion in condemnation of the Holocaust, stressed there were two sides to the conflict.
Repeating a message he has delivered since the start of his first Middle East tour on Friday, the pope said on arrival in Bethlehem that the Vatican "supports the right of your people to a sovereign Palestinian homeland in the land of your forefathers, secure and at peace with your neighbours."
The two-state solution is backed by Palestinian President Mahmoud Abbas, by Arab nations and the West. Israel's new prime minister, Benjamin Netanyahu, has declined so far to endorse it.
Welcoming the pontiff, Abbas denounced Israel's "apartheid wall" as part of an effort by the Jewish state to drive Palestinian Christians and Muslims from the Holy Land.
He spoke of "oppression, tyranny and land expropriation" and said Palestinians wanted a future with "no occupation, no checkpoints, no walls, no prisoners, no refugees."
A large Palestinian flag hung before the pope as he said Mass for about 5,000 people in Manger Square, next to the Church of the Nativity that marks the spot where Christians believe Jesus was born in a stable.
Applause broke out when he spoke of Palestinians in the Hamas Islamist-ruled Gaza Strip, where up to 1,400 were killed in a 3-week Israeli offensive in January. He said he was praying that Israel's embargo on Gaza "will soon be lifted."
It was strange, Pope Benedict said, that Bethlehem is associated with the joy of Jesus's birth "yet here in our midst, how far this magnificent promise seems from being realised."
Thousands of Christians have left Bethlehem since a Palestinian uprising erupted in 2000. It was met with an Israeli security clampdown and the construction of the barrier.
"There are fewer and fewer of us Palestinian Christians but we have strength," said Kandra Zreineh, a 45-year-old mother of four from a village near Bethlehem. "We are proud to have this visit because we are small and I believe he may be able to make a difference for us. I still believe in miracles."
On his arrival, Benedict acknowledged Israel's security concerns, and urged people not to "resort to acts of violence or terrorism" but to seek a genuine peace with their neighbours.
"On both sides of the wall, great courage is needed if fear and mistrust is to be overcome."
(Additional reporting by Jerusalem and Bethlehem staff)
(Writing by Douglas Hamilton; editing by Alastair Macdonald)