A friend of the accused gunman in the shooting massacre that killed nine black churchgoers in a South Carolina church was arrested by federal agents on Thursday, local media reported.

Joseph Meek Jr. had given Dylann Roof, 21, a place to stay in the weeks before the killings in June at a historic church in Charleston, according to newspaper reports.

A person with his name was jailed in the Lexington County Detention Center outside Columbia, South Carolina, according a detention officer. Meek, 21, was listed as a federal inmate.

He faced a charge of concealing knowledge of a crime from authorities, the Post and Courier in Charleston reported, citing unnamed officials.

Details of the arrest were originally reported by the Post and Courier as well as the State newspaper in Columbia.

Meek was a "potential target" in a federal investigation into the shootings, the State reported on Tuesday, but he denied committing any crimes.

Roof faces 33 federal hate crime and firearms charges, along with state murder charges. (Writing by Letitia Stein in Tampa, Fla.; Editing by David Adams and Bill Trott)