Hey Regina,

postgis-3.5.3:
./configure \
   --with-gdalconfig=/export/path/local/bin/gdal-config \  # gdal 3.11.3
   --with-geosconfig=/bin/geos-config \                    # pkg 3.11.1
   --with-sfcgal=/bin/sfcgal-config \                      # pkg 1.4.1
   --with-pgconfig=/usr/lib/postgresql/15/bin/pg_config

Note: gdal is built from source with sfcgal 2.3.0 and geos 3.14 and installed in non-standard location.

3.5.3, if I use --prefix to install it in a non-standard location, make install ignores it and puts postgis-3.so in /usr/lib/postgresql/15/lib anyways.

Configuring 3.6.0 with --prefix set to non-standard location, I get this interesting message:

------------------------------------------------------------------------
WARNING: You have set the --prefix to '/export/gis/local'. But we mostly
  ignore the --prefix. For your info, using the values determined from
  /usr/lib/postgresql/15/bin/pg_config we will be installing:
    * postgis shared library in /usr/lib/x86_64-linux-gnu
    * postgis SQL files in /usr/share/postgresql/15/contrib/postgis-3.6
------------------------------------------------------------------------



On 9/3/25 14:37, Regina Obe wrote:
On debian 12, PG 15, gdal 3.6.2 is the latest system pkg.

However, I've built PostGIS 3.5.3 with non-system pkg GDAL 3.11.3. That
GDAL version is built with the latest non-system pkg geos 3.14 and sfcgal
2.3.0.

I can build PostGIS with the latest non-system pkg GDAL, but not the latest
non-system pkg geos/sfcgal. Kinda weird.

SELECT postgis_full_version();

POSTGIS="3.5.3 aab5f55" [EXTENSION]
PGSQL="150"
GEOS="3.11.1-CAPI-1.17.1"
SFCGAL="SFCGAL 1.4.1,
CGAL 5.5.1,
BOOST 1.74.0"
PROJ="9.1.1
     NETWORK_ENABLED=OFF
     URL_ENDPOINT=https://cdn.proj.org
     USER_WRITABLE_DIRECTORY=/tmp/proj
     DATABASE_PATH=/usr/share/proj/proj.db" (compiled against PROJ 9.1.1)
GDAL="GDAL 3.11.3 "Eganville", released 2025/07/12"
LIBXML="2.9.14"
LIBJSON="0.16"
LIBPROTOBUF="1.4.1"
WAGYU="0.5.0 (Internal)" TOPOLOGY RASTER



What is your configure statement for building PostGIS.

Are you using the --with-geosconfig=/path/to/geos  
--with-sfcgal=/path/to/sfcgal parameters.

I've been having issues building too when GDAL is installed in system.
I suspect there is some messiness with GDAL depending on GEOS and raster 
depending on both GEOS and GDAL.

This seems to have gotten worse when I tried to build SFCGAL from scratch. But 
in my case I was using system GDAL which
was using an older version of GEOS than what I custom built, so I was bound to 
have issues anyway.


Reply via email to