LOS ANGELES (AP) — P.F. Sloan, the troubled songwriter behind such classic 1960s tunes as Johnny Rivers’ “Secret Agent Man” and Barry McGuire’s “Eve of Destruction,” has died. He was 70.

Howard Wuelfing, a spokesman for Sloan, said the singer-songwriter died Sunday at his home in Los Angeles after battling pancreatic cancer for several weeks.

Born Philip Gary Schlein in New York City, Sloan signed his first record deal when he was 13 and went on to write songs for such artists as the Turtles, the Grass Roots and the 5th Dimension. He also released several of his own albums and published the memoir “What’s Exactly The Matter With Me?” last year.