A U.S. Air Force veteran convicted of terrorism charges for trying to join the Islamic State group and die a martyr was sentenced Wednesday to 35 years in prison by a judge who called it a "very sad thing" that a onetime soldier would want to join a group seeking to destroy America.

The March 2016 conviction of Tairod Pugh, 49, of Neptune, New Jersey, was the first verdict from more than 70 cases the government brought against Americans accused of trying to support the militant group.

"This isn't about whether you're a Muslim or a Christian or Jewish," U.S. District Judge Nicholas G. Garaufis told Pugh. "This is about whether you're going to stand up for your country."

The Brooklyn judge called Pugh's military service "a long time ago" commendable, but said the defendant squandered his training as an airplane mechanic and all the good things the United States did for him with a decision to betray his country.

"The work of the Islamic State is to destroy our way of life," Garaufis said. He added that he can't imagine a U.S. military veteran trying to join such a group.

"It's a very sad thing," he said.

Prosecutors said Pugh was stopped at a Turkish airport in January 2015 carrying a laptop with information on Turkey-Syria border crossing points, 180 jihadist propaganda videos, including footage of an Islamic State prisoner beheading, and a letter declaring: "I will use the talents and skills given to me by Allah to establish and defend the Islamic States."

At trial, prosecutors showed jurors materials found on Pugh's computer and cited a letter Pugh wrote to his wife saying, in part: "There is only two possible outcomes for me: Victory or martyr."

Prosecutors said he sought a route into Syria to join the Islamic State group. Authorities forced him to turn back. He was arrested soon after his return to New York City.

Pugh was in the Air Force from 1986 to 1990, when he was trained to install and maintain aircraft engines and navigation and weapons systems.

Pugh gave a rambling statement Wednesday, interrupted when he started to cry and when Garaufis cut him off, saying: "I can't listen to this whole thing. I just can't. ... I'm not the psychiatrist. I'm the judge and I'm limited in what I can do."

Before he was interrupted, Pugh was defiant.

"I am innocent," he said.

During closing arguments, defense attorney Eric Creizman said Pugh had no ill intent in Turkey a month after losing his job as an aviation mechanic and telling his supervisor to stop "talking to me like I'm an idiot." He said Pugh had hoped to move to the Middle East with his wife.

He said his client was feeling small and inconsequential when he started researching the rise of the Islamic State group in the summer of 2014, impressed that Muslims somewhere were trying to establish a country and wouldn't "back down from anything."