Pope Benedict XVI prayed on Sunday that Middle East leaders work toward peace and reconciliation in his homily at an open-air mass on Beirut's seafront.
"In a world where violence constantly leaves behind its grim trail of death and destruction, to serve justice and peace is urgently necessary," the pope said at the end of mass on the final day of his trip to Lebanon.
"I pray in particular that the Lord will grant to this region of the Middle East servants of peace and reconciliation, so that all people can live in peace and with dignity," he added.
He also appealed to the international community and to Arab countries, in particular, that "as brothers, they might propose workable solutions respecting the dignity, the rights and the religion of every human person."
"You know all too well the tragedy of the conflicts and the violence which generates so much suffering. Sadly, the din of weapons continues to make itself heard, along with the cry of the widow and the orphan.
"Violence and hatred invade people's lives, and the first victims are women and children. Why so much horror? Why so many dead?" the pope asked.
An estimated 350,000 people had gathered under a bright warm sun to join the pontiff as he celebrated a solemn mass in Beirut.
On Saturday the pontiff met Lebanese political leaders at the presidential palace near Beirut.
Later, he travelled to the town of Bkerke to address a gathering of thousands of young people.
In his speeches on Saturday, the Pope urged Christians and Muslims to forge a harmonious, pluralistic society in which the dignity of each person is respected and the right to worship in peace is guaranteed.
The pope came with a message of peace and reconciliation both to Lebanon and to the wider Middle East.
He will have lunch in the mountain village of Harissa, where he has been staying, and then attend a late afternoon ecumenical meeting.
He was scheduled to leave for Rome at 7:00 pm (1600 GMT) after addressing some final words to his hosts at Beirut International Airport.