X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/c603ccce31f031253351353f4056197684d9ff81..9ab59cdf423777105470235363919018a8cc25bb:/utils/setup.php?ds=sidebyside diff --git a/utils/setup.php b/utils/setup.php index 270c1a49..a5466432 100755 --- a/utils/setup.php +++ b/utils/setup.php @@ -132,6 +132,10 @@ } else { pgsqlRunScript('CREATE EXTENSION postgis'); } + if ($fPostgisVersion < 2.1) { + // Function was renamed in 2.1 and throws an annoying deprecation warning + pgsqlRunScript('ALTER FUNCTION st_line_interpolate_point(geometry, double precision) RENAME TO ST_LineInterpolatePoint'); + } $sVersionString = $oDB->getOne('select postgis_full_version()'); preg_match('#POSTGIS="([0-9]+)[.]([0-9]+)[.]([0-9]+)( r([0-9]+))?"#', $sVersionString, $aMatches); if (CONST_Postgis_Version != $aMatches[1].'.'.$aMatches[2])