The man who shot Pope John Paul II in 1981 was released from prison Thursday after serving more than 25 years in Italy and Turkey for the plot against the pontiff and the slaying of a Turkish journalist.

To the cheers of nationalist supporters, a white sedan whisked Mehmet Ali Agca — whose attempt to assassinate the pope gained notoriety for himself and shame for his homeland — through the gates of the high-security Kartal Prison as dozens of police officers stood guard. His supporters showered the car with red and yellow flowers.

Agca, 48, wearing a blue sweater and jeans, was freed five years after he was pardoned by Italy and extradited to Turkey. He had served 20 years in prison in Italy, where John Paul forgave him in a visit to his cell in 1983.

"We are happy. We endlessly thank the Turkish state," said his brother, Adnan.

He said one of the first things Agca wanted to do was order a typical Turkish meal of beans and rice at a restaurant overlooking the Bosporus Strait, the narrow waterway that bisects Istanbul and joins the European and Asian continents.

Immediately after his release, Agca reported to a military recruitment center and a hospital, both routine procedures, said his lawyer Mustafa Demirbag.

Agca shot the pope as he rode in an open car in St. Peter's Square in Rome on May 13, 1981, and was captured immediately afterward. John Paul was hit in the abdomen, left hand and right arm but recovered because the bullets missed vital organs. Two years after the shooting, the pope met with Agca in prison and forgave him.

Agca's motive remains unclear.

After Agca was extradited back to Turkey, he was convicted of the killing of a left-wing columnist, Abdi Ipekci, in 1979. A court last week decided to release Agca on parole based on credit for time served and recent Turkish penal reforms, Demirbag said.

Many Turks expressed surprise and outrage at the court's ruling, including Ipekci's family.

"Agca is not just the murderer of my father, Abdi Ipekci. I see him as our national assassin," his daughter, Nukhet Ipekci, said Wednesday in a letter on the front page of her father's former newspaper, Milliyet.

Added Deniz Ergin, a 23-year-old university student: "A murderer like him who has stained Turkey's image should not be released."

But hundreds of Agca's supporters came to Istanbul to celebrate his release.

"He is a family friend. We love him," Mustafa Akmercan, one of two Turks who hijacked an Air Malta jetliner in 1997 to demand Agca's release, told The Associated Press outside the prison. "We're very happy."

The pair had forced their way into the Boeing 737's cockpit on June 9, 1997, with a package they claimed was a bomb, and ordered the pilot on a flight from Malta to Istanbul to fly to Cologne, Germany. Akmercan later served four years in prison.

"For us, Mehmet Ali Agca is a role model for every one who loves the Turkish nation," said another supporter, Seyfi Yilmaz.

Agca, known in the past for frequent outbursts and claims that he was the Messiah, has never undergone a thorough psychological evaluation, although he met briefly with a psychiatrist who declared him sane enough to stand trial for shooting the pope.

The issue is important because Agca, a draft-dodger who also escaped from a military prison in 1979, faces the possibility of being enlisted in the army if he is pronounced fit to serve, although the military generally accepts conscripts under age 41.

It was unclear whether Agca was screened for military service Thursday or whether he would face any criminal charges for evading the military and escaping. Agca's lawyer said his client had applied previously to serve a shortened term in the military.

As he left the recruitment center, he handed a journalist a photocopy of a Time magazine cover showing him in his prison cell with the pope and the headline: "Why forgive?"

Demirbag said Wednesday that Agca is sane and wants to work for democracy following his release. "He says, 'I want to extend the hand of peace and friendship to everyone. I want to engage a struggle for democracy and culture,"' Demirbag said.