All buildings, the roofs of which are liable to discharge rain-water over any footway or sidewalk, shall have gutters and drain-pipes installed and maintained by the owner of the building in such a manner and to such an extent as may be necessary to prevent any discharge of rain-water over any footway or sidewalk.