Three men have been charged with felonies in connection with this week's gunfire in north Minneapolis that passed near police officers outside Fourth Precinct headquarters, with one bullet piercing the building's window.

Davion L. Gaines, 20, of Minneapolis, was charged with second-degree riot with a dangerous weapon, reckless discharge of a gun within a municipality and possession of a prohibited firearm. Makeiyen L. Thompson, 21, of Minneapolis, was charged with second-degree riot with a dangerous weapon and reckless discharge of a gun within a municipality. Troy Teasley, 29, of St. Paul, was charged with second-degree riot with a dangerous weapon and fleeing police in a vehicle.

All three remain jailed after appearing Thursday afternoon in Hennepin County District Court. Legal counsel for all three was not immediately available to respond to allegations.

No injuries were reported among any civilians or the officers, who did not return fire, said officer Garrett Parten, a police spokesman. Residential buildings nearby were also hit by the gunfire. The officers "heard gunfire and the sound of bullets passing by them," Parten said in a statement released later Tuesday.

"Reckless gun use will not be tolerated," read a statement issued Thursday by County Attorney Mike Freeman. "Random shootings endanger the community and put innocent people at risk of injury and death. Individuals who engage in this dangerous behavior, near a police precinct no less, will be prosecuted to the full extent of the law."

According to the charges against Gaines:

Officers spotted the shooter, later determined to be Gaines, get in a car driven by Teasley. The car stopped, Teasley was arrested, but Gaines ran to another vehicle parked in an alley.

The officers momentarily lost their view of Gaines. When he reappeared, he held his hands above his head and was arrested. Police recovered a handgun, a magazine and a "switch" attached to the gun that allows it to be fully automatic when fired.

Police located Thompson while searching the area around the precinct. He was facedown on the ground between a fence and a house. Near him was a handgun and an extended magazine.

Parten's statement said, "Preliminary information indicates that an exchange of gunfire occurred between an unknown number of individuals. It is unclear if the 4th Precinct was targeted."