Squatters who broke into and have been living in a disused prison in Dublin face terms of imprisonment for failing to comply with a High Court order.

Ms Justice Deirdre Murphy granted the State leave on Monday to bring a motion before the court within the next two days seeking to attach and commit to prison the squatters for contempt of court.

Barrister Joseph O’Sullivan told the court that the Department of Expenditure and the Office of Public Works considered the former debtors’ prison between Halston Street and Green Street to be unsafe.

Last week, the State was granted an injunction restraining the squat and directing those in unlawful possession to vacate the property by Sunday.

Mr O’Sullivan said the order of Mr Justice Michael Hanna had not been complied with and he had been instructed to seek to attach and commit a number “of unknown persons” still squatting in the old prison.

John Roche, a man who identified himself as a member of the group, said he had complied with the order and had vacated the property. He told the judge that a week was not allowing the group enough time to leave the debtors’ prison and asked that the time be extended to a month.

Ms Justice Murphy said she did not have jurisdiction to amend Mr Justice Hanna’s order and granted the State bodies leave to bring their motion within 48 hours.

Mr O’Sullivan said a number of the squatters were in court but were unknown to the applicants. They were not identified in court and Ms Justice Murphy granted the State leave to serve notice of the notice of motion on them by attaching it to the prison gate and placing copies in and around the old prison.

Earlier, the court heard there were serious concerns about the safety of the group and anyone visiting them as the old debtors’ prison was in a derelict condition.

Mr Justice Hanna had been told the squatters had recently been ordered by the High Court to leave a squat in Grangegorman and had moved to the old debtors’ prison.

He heard the building was in a dangerous state and had no running water. The State authorities feared that its electrical circuit would not support various appliances which had recently been brought in by the squatters. There were also health concerns in relation to the effect of pigeon droppings on young children.

The motion will be brought before the court on Wednesday.