A Grand Prairie man was sentenced to eight years in federal prison Wednesday after police found him in the woods with a partially 3-D-printed AR-15 and a list of lawmakers' addresses in his backpack.

Eric Gerard McGinnis, 43, was sentenced to eight years in prison. (Grand Prairie Police Department)

Eric Gerard McGinnis, 43, was arrested in July 2017 after reports of someone threatening to harm himself in the woods near Lone Star Park in Grand Prairie, authorities said.

Officers heard gunfire and quickly found McGinnis carrying an unregistered rifle, ammunition and the backpack. He initially claimed to be with the CIA.

McGinnis wasn't allowed to own a firearm at the time because of a protective order stemming from a 2015 altercation with a girlfriend, federal prosecutors said.

Prosecutors said McGinnis attempted to buy a semiautomatic rifle in 2016, and was turned away when the protective order was revealed in a background check. He instead obtained various gun parts and used a 3-D printer to create the firing mechanism for an AR-15 rifle, officials said.

With just a month left on his protective order, he built the hybrid rifle and took the weapon into the woods, prosecutors said.

McGinnis was convicted by a federal jury last summer of possessing an unregistered short-barreled rifle and unlawfully possessing ammunition while having an active protective order.

In addition to the gun and ammunition, officials found a "hit list" that included the home addresses of several federal lawmakers, prosecutors said. The list, labeled "9/11/2001 list of American Terrorists," wasn't used as evidence at trial but was presented at McGinnis' sentencing.

Prosecutors said Wednesday that an analysis of McGinnis' devices suggested he had an interest in James Hodgkinson, the gunman who shot several Republican lawmakers at a congressional baseball practice in Virginia in June 2017.

A photo of the partially 3-D printed gun police said Eric McGinnis unlawfully owned when he was arrested in 2017. (U.S. Attorney's Office of the Northern District of Texas)

McGinnis' list included both Democratic and Republican lawmakers, prosecutors said.

"This case should send a message to prohibited persons contemplating acquiring guns by any method: this office is committed to keeping guns out of the hands of those who violate protective orders for domestic violence, no matter how the guns are obtained," said U.S. Attorney Erin Nealy Cox in a statement.