At least five people were killed and at least two others were injured during a shooting described as "a targeted attack on The Capital Gazette" newspaper in Annapolis, Md., Thursday afternoon, local officials said, in one of the deadliest attacks involving journalists in U.S. history.

Jarrod W. Ramos was identified as the suspect, the Associated Press reported, citing an unidentified law enforcement official.

Police identified the five victims late Thursday as Rob Hiaasen, Wendi Winters, John McNamara, Rebecca Smith and Gerald Fischman.

During an evening news conference, Deputy Chief William Krampf of the Anne Arundel County police said one person -- a male in his late 30s who lives in Maryland -- was in custody and being interviewed by investigators.

Krampf said the suspect "entered the building" on Bestgate Road "with a shotgun and he looked for his victims as he walked through the lower level."

The wounded individuals' injuries are "superficial" and "possibly from glass from the shotgun blast."

Law enforcement was called to the scene around 2:40 p.m. following word of an active shooter, Anne Arundel County police Lt. Ryan Frashure previously told reporters. An investigation was underway but "at this point we believe that it is one suspect," he said at the time.

Authorities said earlier that they found what they believed "may have been an explosive device," which they said "has been taken care of" and they didn't expect to find any others.

They added the building had been deemed "tactically secure," and said "there was no gunfire exchanged between officers and the suspect."

An official told the Associated Press the shooting suspect was not cooperating with investigators.

Of the explosive device, Krampf said it was "canisters of smoke grenades that he used inside of the building when he entered the establishment."

"So this person was prepared today to come in," he continued. "This person was prepared to shoot people. His intent was to cause harm."

Law enforcement initially had a problem identifying the suspect because he had mutilated fingers, Fox News has learned. However, an Anne Arundel County Police Department spokesperson told Fox News on Friday that it wasn't true that the suspect had mutilated fingers and they weren't sure how the rumor started.

A U.S. official told the Associated Press that the suspect was identified with the use of facial recognition technology.

Krampf also said "that there were threats sent to the Gazette through social media," although authorities were still working to confirm the account and who actually sent them.

Police earlier confirmed on Twitter an "active shooter" situation and that the building had been "evacuated."

"Officers continuing to search building," the tweet continued.

The Baltimore Sun, which owns the Annapolis newspaper, said a Gazette reporter told them of the shooting.

Phil Davis, who said he's a reporter for the newspaper, tweeted that "a single shooter shot multiple people at my office, some of whom are dead."

"Gunman shot through the glass door to the office and opened fire on multiple employees," he wrote. "There is nothing more terrifying than hearing multiple people get shot while you're under your desk and then hear the gunman reload."

The Bureau of Alcohol, Tobacco, Firearms and Explosives (ATF) Baltimore tweeted that it was responding to the scene.

Video shared by Fox 5 DC showed a line of people with their hands in the air being evacuated from the area.

President Donald Trump, as well as first lady Melania trump, were briefed on the shooting, White House officials confirmed. White House deputy press secretary Lindsay Walters said "our thoughts and prayers are with all that are affected."

Trump later tweeted, "Prior to departing Wisconsin, I was briefed on the shooting at Capital Gazette in Annapolis, Maryland. My thoughts and prayers are with the victims and their families. Thank you to all of the First Responders who are currently on scene."

Maryland Gov. Larry Hogan tweeted that he was "absolutely devastated to learn of this tragedy in Annapolis."

"I am in contact with County Executive Steve Schuh, and @MDSP is on the scene assisting @AACOPD," he continued. "Please, heed all warnings and stay away from the area. Praying for those at the scene and for our community."

A fellow journalist, Bloomberg government reporter Madi Alexander, set up a GoFundMe account that raised more than $20,000 in just hours. The account urged people to give what they could to help the newspaper's journalists pay for medical bills, funeral costs, newsroom repairs and other expenses.

Anthony Messenger, who said he is an intern at the paper, earlier tweeted, "Active shooter 888 Bestgate please help us."

Fox News' Jason Donner, Chad Pergram, Brooke Singman and the Associated Press contributed to this report.