From: Sandro Santilli Date: Fri, 4 Nov 2011 08:15:53 +0000 (+0000) Subject: Fix builds againts GEOS < 3.3 X-Git-Tag: 2.0.0alpha1~771 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=174a4e7ac58adb039d756a4611f0e9edcbb42e62;p=postgis Fix builds againts GEOS < 3.3 git-svn-id: http://svn.osgeo.org/postgis/trunk@8089 b70326c6-7e19-0410-871a-916f4a2858ee --- diff --git a/liblwgeom/lwgeom_geos_node.c b/liblwgeom/lwgeom_geos_node.c index 594d6b0d5..02ac299af 100644 --- a/liblwgeom/lwgeom_geos_node.c +++ b/liblwgeom/lwgeom_geos_node.c @@ -85,6 +85,13 @@ lwgeom_extract_endpoints(const LWGEOM* lwg) static LWGEOM* lwgeom_extract_unique_endpoints(const LWGEOM* lwg) { +#if POSTGIS_GEOS_VERSION < 33 + lwerror("The GEOS version this postgis binary " + "was compiled against (%d) doesn't support " + "'GEOSUnaryUnion' function (3.3.0+ required)", + POSTGIS_GEOS_VERSION); + return NULL; +#else /* POSTGIS_GEOS_VERSION >= 33 */ LWGEOM* ret; GEOSGeometry *gepu; LWMPOINT *epall = lwgeom_extract_endpoints(lwg); @@ -114,6 +121,7 @@ lwgeom_extract_unique_endpoints(const LWGEOM* lwg) } return ret; +#endif /* POSTGIS_GEOS_VERSION >= 33 */ } /* exported */