A man who served 34 years in prison for the rape and murder of a teenager in Pennsylvania has been freed after new DNA analysis led a judge to vacate his murder conviction.

The man, Lewis Fogle, was released from prison on bond Thursday after lawyers for the Innocence Project obtained consent to retest physical evidence from the autopsy of the murdered teenager, Deann Katherine Long, 15, who was raped and killed with a single gunshot in 1976.

In a statement after Mr. Fogle’s release, the Innocence Project, which works to clear the wrongfully convicted, said the authorities had relied on jailhouse informants who said Mr. Fogle had confessed to them. At his trial in 1982, no physical evidence was presented linking Mr. Fogle to the crime, the Innocence Project said.

The new DNA results came from a semen sample that was collected from Ms. Long’s body using new technology.