A second hostage has been released from a Toulouse bank by a gunman who claims to work for al-Qaeda.

The second hostage was freed from the besieged bank a few hours after the first, police sources said. The gunman, who has been holding four people hostage for much of the day, freed the first - a woman - after negotiations with a specialist police team.

The bank director was believed to be one of the hostages.

Prosecutors told AP that the gunman was holding hostages out of "religious conviction".

The man entered a branch of the CIC bank in the southwestern city between 10am and 11am. He demanded money but took hostages after his demand was refused, it was reported.

Police said a shot was fired but no one was injured.

They said that negotiations between the man and the the Groupe d'intervention de la police nationale (GIPN) were continuing.

The area around the bank has been cordoned off and two nearby schools have been closed.

"We're taking measures so we can start a dialogue," said public prosecutor Michel Valet, who was at the scene.