DETROIT -

Detroit police have a gunman in custody after a standoff that lasted hours, including time where the man was on the roof of an apartment complex.

The man was taken into custody around 9:40 a.m. Saturday, Detroit police said.  Police originally responded to the apartment complex on Gladstone near Second Avenue around 4:30 a.m. when there were reports of shots being fired. 

The gunman had fired shots at his girlfriend, police said.  Officers were able to remove the woman from the building, but she punched an officer in the face. The officer suffered minor injuries. The woman who police helped from the building also had minor injuries. It is not clear if those injuries were from bullet fragments or flying glass.

The man was barricaded inside the apartment building, but then went onto the roof the apartment complex. After more than five hours, police cornered the man in the basement of the building and arrested him.

Stay with Local 4 and ClickOnDetroit.com for updates on this developing story.