Fix PostGIS installation for older versions of PostGIS.