The disgruntled employee behind Friday’s deadly shooting at a suburban Chicago warehouse opened fire at a meeting at which he was being fired, police said Saturday.

Three of employee Gary Martin’s victims were gunned down in the room where the meeting was being held, said Aurora Police Chief Kristen Ziman. One of the victims was Trevor Wehner, a 21-year-old human resources intern and student at Northern Illinois University who there for his first day on the job, according to The Chicago Sun-Times.

"Each and every one of us have had a 'First Day' on the job, his should have never ended this way," read a Facebook post on Saturday from Cynthia Rose Cascarano, of Oak Lawn, Illinois, who said Wehner and his brother were like sons to her.

He loved his family and girlfriend, "always wore a smile and his legacy will live on forever," she added.

Two other employees who were also killed at the Henry Pratt warehouse in Aurora happened to be nearby when they were shot, she said. A sixth was wounded, as were several police officers.

“He was called in,” Ziman said of Martin, 45, of Aurora. “He did report for a meeting where he was terminated.” She said because he had a gun with him, it was likely he knew he was going to be let go.

The chief said police were still trying to learn from bosses at Henry Pratt the reason for the firing. Martin worked at the warehouse for 15 years.

Henry Pratt makes industrial water valves.

Cops killed Martin after a brief gunfight, officials said.

AURORA WORKPLACE SHOOTER WAS SET TO BE FIRED BY COMPANY, POLICE CHIEF SAYS

Five officers who responded to reports of an active shooter were shot by Martin when they attempted to enter the building.

Ziman said none of the wounded officers suffered life-threatening injuries. They ranged in age from 24 to 59.

Two of the officers were in listed as being in stable condition on Saturday. The other three were treated and released.

Police on Saturday released the names of the five employees who were killed. Besides Wehner, who was from Dekalb, they were: Clayton Parks, of Elgin, the human resources manager; Josh Pinkard, of Oswego, the plant manager; Russell Beyer of Yorkville, a mold operator; and Vicente Juarez, of Oswego, a stock room attendant and forklift operator.

Parks graduated from Northern Illinois University in 2014.

“Loss like this is devastating and senseless,” University President Lisa Freeman said. “I ask our university community to please keep the Wehner and Parks families, friends and communities in your hearts and offer them caring thoughts.”

Parks' wife said on Facebook, "My husband, my love, my best friend, and the incredible father of our sweet son was taken from us yesterday in the shooting in Aurora, and I am devastated."

Pinkard was an Alabama native, according to WVTM-TV in Birmingham, which obtained a photo from his family.

Aurora police said they had arrested Martin six times on charges that included traffic violations and domestic violence. His last arrest in the city was in 2008.

His most recent arrest was two years ago, when Oswego police picked him up on charges of disorderly conduct and criminal damage to property.

Martin purchased the gun that was used in the shooting in 2014, police said. Ziman said Martin purchased the weapon after being issued a firearm owner's identification card, and after passing the initial background check.

ILLINOIS WORKPLACE SHOOTING LEAVES 5 DEAD, SHOOTER KILLED, OFFICIALS SAY

Five days after taking possession of the weapon, a Smith & Wesson 40-caliber handgun, Martin tried to obtain a concealed carry permit.

But during the fingerprinting and background process it was discovered that he had a felony conviction for assault in Mississippi, police said. The date of conviction was in 1995. Police said the conviction would not necessarily have shown up on the background check for a gun owner's license.

Because of the conviction, Martin's concealed carry permit was rejected and his license to own a weapon was revoked by Illinois State Police, police said.

Ziman said as part of the investigation into the shooting, investigators would try to determine why Martin never surrendered his weapon to police as he should have.

Police said Martin fired off many rounds, and that they lost contact with him in the warehouse for more than an hour.

When they finally found him, he had retreated to the rear of building, police said.

CLICK HERE TO GET THE FOX NEWS APP

It was there, police said, that Martin was killed after exchanging gunfire with officers.