Pope Francis and an admiring throng of thousands enjoyed a little music from the Queen of Soul, Andrea Bocelli and others at the end of his first day in Philadelphia on his first-ever U.S. tour.

Aretha Franklin led an all-star lineup at the Festival of Families, one of the events organized by the Vatican-sponsored World Meeting of Families, which brought Francis to the city after visits in Washington, D.C., and New York.

Francis came to Philadelphia to close out the Vatican-sponsored conference and festival for more than 18,000 people from around the world. He found a city practically under lockdown, with blocked-off streets and checkpoints manned by police, National Guardsmen and border agents.

The festival included song, prayer and testimonials from people from different continents on the joys and challenges of family life, including an Argentine couple celebrating their 60th wedding anniversary. 

After each family spoke, the Pope greeted and spoke with them, and later addressed the crowd at length about the importance of families, urging people to take special care of children and grandparents.

US Pope Francis

Pope Francis waves from the podium during the closing ceremony Saturday for the World Meeting of Families, a Vatican-sponsored conference of more than 18,000 people. He was later honoured with song by Aretha Franklin, Andrea Bocelli and others. (The Associated Press)

"In the family, there are difficulties, but those difficulties are overcome with love," he said through an interpreter. "Love is about celebration, love is joy, love is moving forward."

Folk singer Marie Miller, American rock band the Fray and Colombian pop star Juanes also performed at an event hosted by actor Mark Wahlberg. ​

Franklin, best known for her hit Respect, performed Amazing Grace. The 73-year-old had said earlier she planned to present Francis with a gift: a box set of sermons by her father, civil rights activist and preacher C.L. Franklin. She later came out and performed Nessun Dorma from the opera Turandot, which she intended as a surprise, but the Pope had left by the time of her encore. 

Bocelli, whose rendition of The Lord's Prayer was accompanied by The Philadelphia Orchestra and the Philadelphia Heritage Chorale, has described Francis as "a blessing given to the world." 

"This journey represents for the United States a precious opportunity to embrace this giant, a man of God, a gift from heaven, a point of reference and a providential source of hope for our world," he said. Bocelli also performed another piece after the pontiff left.

Warns religious freedom under threat

Standing at the birthplace of the United States earlier on Saturday, Francis extended a warm and affectionate welcome to recent immigrants and extolled America's founding ideals of liberty and equality, while warning that religious freedom is under threat around the globe.

Francis arrived in the City of Brotherly Love on the final leg of his six-day U.S. trip, and in a moment rich with historical symbolism, he spoke outside Independence Hall, where the Declaration of Independence and the Constitution were signed, and he used the lectern from which Abraham Lincoln delivered the Gettysburg Address.

"It was here that the freedoms which define this country were first proclaimed," Francis told the crowd of about 40,000 after the pope known for his simple tastes and devotion to the poor arrived to the stirring strains of Aaron Copland's Fanfare for the Common Man.

"We remember the great struggles which led to the abolition of slavery, the extension of voting rights, the growth of the labour movement, and the gradual effort to eliminate every kind of racism and prejudice directed at successive waves of new Americans," he said to applause.

"This shows that when a country is determined to remain true to its founding principles, based on respect for human dignity, it is strengthened and renewed."

POPE-USA/PHILADELPHIA

Members of the Pennsylvania National Guard walk to locations to establish a secure perimeter in advance of Pope Francis's arrival in Philadelphia. (Mark Makela/Reuters)

At the same time, the Pope warned that religious freedom is in danger.

"In a world where various forms of modern tyranny seek to suppress religious freedom, or try to reduce it to a subculture without right to a voice in the public square, or to use religion as a pretext for hatred and brutality," he said, "it is imperative that the followers of various religions join their voices in calling for peace, tolerance and respect for the dignity and rights of others."

It may not have been the hard-hitting discussion of religious freedom some conservative American bishops may have wanted to hear. Frances did not mention gay marriage, abortion or government-mandated birth control coverage by name, speaking of threats to religious liberty in broader, more global terms.

Instead, he used the occasion to embrace other causes close to his heart.

Speaking in his native Spanish, Francis encouraged immigrants in the crowd to celebrate their heritage and traditions, and he assured them they are of value to America.

"By contributing your gifts you will not only find your place here, you will help to renew society from within," the first pope from Latin America said.

It remains to be seen if the expected one million people turn out for Francis's final mass in the U.S., an outdoor event Sunday on the Benjamin Franklin Parkway.

APTOPIX US Pope Francis

Pope Francis kisses and blesses Michael Keating, 10, of Elverson, Pa. Keating, who has cerebral palsy, had been waiting for the pontiff to arrive at Philadelphia International Airport. (Joseph Gidjunis/World Meeting of Families via AP)

Earlier in the day, the pontiff arrived from New York at the Philadelphia airport, where a Catholic high school band played the theme song from the Philadelphia-set movie Rocky upon Francis's arrival.

Among those greeting him was Richard Bowes, a former Philadelphia police officer wounded in the line of duty. Francis also kissed the forehead of a 10-year-old boy severely disabled with cerebral palsy.

Then Francis celebrated a mass for about 1,600 people at the downtown Cathedral Basilica of Sts. Peter and Paul, saying in his homily that the future of the Catholic Church in the U.S. requires a much more active role for lay Catholics, especially women.

"It means valuing the immense contribution which women, lay and religious, have made and continue to make to the life of our communities," he said.