[SCM] PostGIS branch stable-3.3 updated. 3.3.6-26-gf09a1793b
git at osgeo.org
git at osgeo.org
Fri Jul 5 02:23:04 PDT 2024
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "PostGIS".
The branch, stable-3.3 has been updated
via f09a1793b9b088cde7203a4a2b90f88faa1c990d (commit)
via 0b286e91bea0b177d51fec4f844ef982a052e595 (commit)
from 825755c43b0b53d69bce4bf2ecc57ebcc238bcaf (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit f09a1793b9b088cde7203a4a2b90f88faa1c990d
Author: Regina Obe <lr at pcorp.us>
Date: Fri Jul 5 05:17:46 2024 -0400
Fix regression failures against PG17
Closes #5687 for PostGIS 3.3.7
Closes #5756 for PostGIS 3.3.7
diff --git a/NEWS b/NEWS
index 9f7808021..7f05ebb97 100644
--- a/NEWS
+++ b/NEWS
@@ -1,6 +1,11 @@
PostGIS 3.3.7
xxxx/xx/xx
+This version requires PostgreSQL 11-17, GEOS 3.6 or higher, and Proj 4.9+
+Additional features are enabled if you are running GEOS 3.9+
+(and ST_MakeValid enhancements with 3.10+), Proj 6.1+,
+and PostgreSQL 15+.
+
* Bug Fixes and Enhancements *
- #5709, Fix loose mbr in topology.face on ST_ChangeEdgeGeom (Sandro Santilli)
@@ -16,6 +21,8 @@ xxxx/xx/xx
- #5686, ST_NumInteriorRings and Triangle crash (Paul Ramsey)
- #5671, Bug in ST_Area function with use_spheroid=false
(Paul Ramsey, Regina Obe)
+ - #5687, #5756 Support for PostgreSQL 17, revise postgis_get_full_version_schema()
+ to not rely on search_path
PostGIS 3.3.6
diff --git a/libpgcommon/lwgeom_pg.c b/libpgcommon/lwgeom_pg.c
index 6af4bea39..7c0bff482 100644
--- a/libpgcommon/lwgeom_pg.c
+++ b/libpgcommon/lwgeom_pg.c
@@ -114,22 +114,51 @@ postgis_get_extension_schema(Oid ext_oid)
static Oid
postgis_get_full_version_schema()
{
- const char* proname = "postgis_full_version";
- #if POSTGIS_PGSQL_VERSION < 160
- List* names = stringToQualifiedNameList(proname);
- #else
- List* names = stringToQualifiedNameList(proname, NULL);
- #endif
-
- #if POSTGIS_PGSQL_VERSION < 140
- FuncCandidateList clist = FuncnameGetCandidates(names, -1, NIL, false, false, false);
- #else
- FuncCandidateList clist = FuncnameGetCandidates(names, -1, NIL, false, false, false, false);
- #endif
- if (!clist)
+ const char* query = "SELECT pronamespace "
+ " FROM pg_catalog.pg_proc "
+ " WHERE proname = 'postgis_full_version'";
+ int spi_result;
+ Oid funcNameSpaceOid;
+ if (SPI_OK_CONNECT != SPI_connect())
+ {
+ elog(ERROR, "%s: could not connect to SPI manager", __func__);
return InvalidOid;
+ }
- return get_func_namespace(clist->oid);
+ /* Execute the query, noting the readonly status of this SQL */
+ spi_result = SPI_execute(query, true, 0);
+
+ if (spi_result != SPI_OK_SELECT || SPI_tuptable == NULL){
+ elog(ERROR, "%s: error executing query %d", __func__, spi_result);
+ SPI_finish();
+ return InvalidOid;
+ }
+
+ /* Read back the OID of the function namespace, only if one result returned
+ If more than one, then this install is f..cked.
+ If 0 then postgis is not installed at all */
+ if (SPI_processed == 1)
+ {
+ TupleDesc tupdesc;
+ SPITupleTable *tuptable = SPI_tuptable;
+ HeapTuple tuple;
+
+ tupdesc = SPI_tuptable->tupdesc;
+ tuptable = SPI_tuptable;
+ tuple = tuptable->vals[0];
+ funcNameSpaceOid = atoi(SPI_getvalue(tuple, tupdesc, 1));
+
+ if (SPI_tuptable) SPI_freetuptable(tuptable);
+ SPI_finish();
+ }
+ else
+ {
+ elog(ERROR, "Cannot determine install schema of postgis_full_version function.");
+ SPI_finish();
+ return InvalidOid;
+ }
+
+ return funcNameSpaceOid;
}
commit 0b286e91bea0b177d51fec4f844ef982a052e595
Author: Regina Obe <lr at pcorp.us>
Date: Fri Jul 5 05:16:44 2024 -0400
Streamline winnie build, and update to GEOS 3.12.2
diff --git a/ci/winnie/build_postgis.sh b/ci/winnie/build_postgis.sh
index f7e2d63ee..24efa2044 100644
--- a/ci/winnie/build_postgis.sh
+++ b/ci/winnie/build_postgis.sh
@@ -1,79 +1,6 @@
#!/usr/bin/env bash
-set -e
-if [[ "${OVERRIDE}" == '' ]] ; then
- export GEOS_VER=3.10.2
- export GDAL_VER=3.4.2
- export PROJ_VER=7.2.1
- export SFCGAL_VER=1.4.1
- export CGAL_VER=5.3
- export ICON_VER=1.16
- export ZLIB_VER=1.2.11
- export PROTOBUF_VER=3.2.0
- export PROTOBUFC_VER=1.2.1
- export JSON_VER=0.12
- export PROJSO=libproj-19.dll
-fi;
-export PROTOBUF_VER=3.2.0
-export PROTOBUFC_VER=1.2.1
-if [[ "${JSON_VER}" == '' ]] ; then
- export JSON_VER=0.12
-fi;
-export PCRE_VER=8.33
-
-if [[ "${ICON_VER}" == '' ]] ; then
- export ICON_VER=1.17
-fi;
-
-echo "ICON_VER ${ICON_VER}"
-
-#set to something even if override is on but not set
-if [[ "${ZLIB_VER}" == '' ]] ; then
- export ZLIB_VER=1.2.13
-fi;
-
-
-#set to something even if override is on but not set
-if [[ "${LIBXML_VER}" == '' ]] ; then
- export LIBXML_VER=2.7.8
-fi;
-
-#set to something even if override is on but not set
-if [[ "${CGAL_VER}" == '' ]] ; then
- export CGAL_VER=5.3
-fi;
-
-#export GDAL_VER=2.4.0
-#export PROJ_VER=5.2.0
-
-echo "ZLIB_VER $ZLIB_VER"
-echo "PROJ_VER $PROJ_VER"
-echo "LIBXML_VER $LIBXML_VER"
-echo "CGAL_VER $CGAL_VER"
-export PROJECTS=/projects
-export MINGPROJECTS=/projects
-export PATHOLD=$PATH
-
-if [ "$OS_BUILD" == "64" ] ; then
- export MINGHOST=x86_64-w64-mingw32
-else
- export MINGHOST=i686-w64-mingw32
-fi;
-
-echo PATH AFTER: $PATH
-#export PG_VER=9.2beta2
-export PGWINVER=${PG_VER}edb
-export WORKSPACE=`pwd`
-
-echo PATH BEFORE: $PATH
-
-#export PGHOST=localhost
-#export PGPORT=8442
-export PGUSER=postgres
-#export GEOS_VER=3.4.0dev
-#export GDAL_VER=1.9.1
-export PGPATH=${PROJECTS}/postgresql/rel/pg${PG_VER}w${OS_BUILD}${GCC_TYPE}
-export PGPATHEDB=${PROJECTS}/postgresql/rel/pg${PG_VER}w${OS_BUILD}${GCC_TYPE}edb
+. $(dirname $0)/winnie_common.sh
if [ -n "$SOURCE_FOLDER" ]; then
export POSTGIS_SRC=${PROJECTS}/postgis/$SOURCE_FOLDER
@@ -84,6 +11,7 @@ else
else
#tagged version -- official release
export POSTGIS_SRC=${PROJECTS}/postgis/tags/${POSTGIS_VER}.${POSTGIS_MICRO_VERSION}
+ INCLUDE_MINOR_LIB=0
fi;
fi;
@@ -92,18 +20,8 @@ export POSTGIS_MICRO_VER=${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}.${POS
#export POSTGIS_SRC=${PROJECTS}/postgis/trunk
-export GDAL_DATA="${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/share/gdal"
-
export RELVERDIR=postgis-pg${REL_PGVER}-binaries-${POSTGIS_MICRO_VER}w${OS_BUILD}
-export PATH="${PATHOLD}:${PGPATH}/bin:${PGPATH}/lib"
-export PATH="${PROJECTS}/xsltproc:${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/libxml/rel-libxml2-${LIBXML_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
-export PKG_CONFIG_PATH="${PROJECTS}/sqlite/rel-sqlite3w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/json-c/rel-${JSON_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/pcre/rel-${PCRE_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig::${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/lib/pkgconfig"
-export SHLIB_LINK="-static-libstdc++ -lstdc++ -Wl,-Bdynamic -lm"
-CPPFLAGS="-I${PGPATH}/include -I${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include"
-
-#add protobuf
-export PATH="${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
echo PATH AFTER: $PATH
@@ -124,29 +42,23 @@ cd ${POSTGIS_SRC}
# make distclean
# fi
+git clean -dxf # ensure we start fresh
+git describe --long --all --tags # Report where we are at
+
sh autogen.sh
if [ -n "$PCRE_VER" ]; then
export PATH="${PROJECTS}/pcre/rel-${PCRE_VER}w${OS_BUILD}${GCC_TYPE}/include:${PROJECTS}/pcre/rel-${PCRE_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
fi
-
-
-if [ -n "$SFCGAL_VER" ]; then
- ##hard code versions of cgal etc. for now
- export CGAL_VER=4.11
- BOOST_VER=1.53.0
- #BOOST_VER_WU=1_49_0
- export BOOST_VER_WU=1_53_0
- export PATH="${PROJECTS}/CGAL/rel-cgal-${CGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/CGAL/rel-sfcgal-${SFCGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/boost/rel-${BOOST_VER_WU}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
-
+if [$INCLUDE_MINOR_LIB == "1"]; then
#CPPFLAGS="-I${PGPATH}/include -I${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include" \
#CFLAGS="-Wall -fno-omit-frame-pointer"
#LDFLAGS="-Wl,--enable-auto-import -L${PGPATH}/lib -L${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/lib -L${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib" \
-LDFLAGS="-Wl,--enable-auto-import -L${PGPATH}/lib -L${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib -L${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib" \
+LDFLAGS="-Wl,--enable-auto-import -L${PGPATH}/lib -L${LZ4_PATH}/bin -L${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib -L${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib" \
./configure \
--host=${MINGHOST} --with-xml2config=${PROJECTS}/libxml/rel-libxml2-${LIBXML_VER}w${OS_BUILD}${GCC_TYPE}/bin/xml2-config \
--with-pgconfig=${PGPATH}/bin/pg_config \
@@ -155,21 +67,18 @@ LDFLAGS="-Wl,--enable-auto-import -L${PGPATH}/lib -L${PROJECTS}/rel-libiconv-${I
--with-xsldir=${PROJECTS}/docbook/docbook-xsl-1.76.1 \
--with-gui --with-gettext=no \
--with-sfcgal=${PROJECTS}/CGAL/rel-sfcgal-${SFCGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin/sfcgal-config \
- --without-interrupt-tests \
- --prefix=${PROJECTS}/postgis/liblwgeom-${POSTGIS_VER}w${OS_BUILD}${GCC_TYPE}
+ --prefix=${PROJECTS}/postgis/liblwgeom-${POSTGIS_VER}w${OS_BUILD}${GCC_TYPE} --with-library-minor-version
#exit
else
-CPPFLAGS="-I${PGPATH}/include -I${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include" \
-CFLAGS="-Wall -fno-omit-frame-pointer" \
-LDFLAGS="-L${PGPATH}/lib -L${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/lib -L${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib" ./configure \
- --host=${MINGHOST} --with-xml2config=${PROJECTS}/libxml/rel-libxml2-${LIBXML_VER}w${OS_BUILD}${GCC_TYPE}/bin/xml2-config \
+LDFLAGS="-Wl,--enable-auto-import -L${PGPATH}/lib -L${LZ4_PATH}/bin -L${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib -L${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib" \
+./configure \
+ --host=${MINGHOST} --with-xml2config=${PROJECTS}/libxml/rel-libxml2-${LIBXML_VER}w${OS_BUILD}${GCC_TYPE}/bin/xml2-config \
--with-pgconfig=${PGPATH}/bin/pg_config \
--with-geosconfig=${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}${GCC_TYPE}/bin/geos-config \
- --with-projdir=${MINGPROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE} \
- --with-gui --with-gettext=no \
--with-libiconv=${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE} \
--with-xsldir=${PROJECTS}/docbook/docbook-xsl-1.76.1 \
- --without-interrupt-tests \
+ --with-gui --with-gettext=no \
+ --with-sfcgal=${PROJECTS}/CGAL/rel-sfcgal-${SFCGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin/sfcgal-config \
--prefix=${PROJECTS}/postgis/liblwgeom-${POSTGIS_VER}w${OS_BUILD}${GCC_TYPE}
fi;
diff --git a/ci/winnie/package_postgis.sh b/ci/winnie/package_postgis.sh
index b3e2f7ef3..168e68bb3 100644
--- a/ci/winnie/package_postgis.sh
+++ b/ci/winnie/package_postgis.sh
@@ -3,93 +3,14 @@
## PostgreSQL, OS_BUILD denote the last build to be packaged
## and are passed in by the jenkins job process
###
-#export OS_BUILD=64
-#export PGPORT=8442
-#export OS_BUILD=32
+. $(dirname $0)/winnie_common.sh
-#export GCC_TYPE=
-#if no override is set - use these values
-#otherwise use the ones jenkins passes thru
-#!/usr/bin/env bash
-if [[ "${OVERRIDE}" == '' ]] ; then
- export GEOS_VER=3.10.3
- export GDAL_VER=3.4.2
- export PROJ_VER=7.2.1
- export SFCGAL_VER=1.4.1
- export CGAL_VER=5.3
- export ICON_VER=1.17
- export ZLIB_VER=1.2.13
- export PROTOBUF_VER=3.2.0
- export PROTOBUFC_VER=1.2.1
- export JSON_VER=0.12
- export PROJSO=libproj-19.dll
- export CURL_VER=8.0.1
-fi;
-
-export PROTOBUF_VER=3.2.0
-export PROTOBUFC_VER=1.2.1
-if [[ "${JSON_VER}" == '' ]] ; then
- export JSON_VER=0.12
-fi;
-export PCRE_VER=8.33
-
-if [[ "${ICON_VER}" == '' ]] ; then
- export ICON_VER=1.15
-fi;
-
-echo "ICON_VER ${ICON_VER}"
-
-if [[ "${CURL_VER}" == '' ]] ; then
- export CURL_VER=8.0.1
-fi;
-
-echo "CURL_VER ${CURL_VER}"
-
-#set to something even if override is on but not set
-if [[ "${ZLIB_VER}" == '' ]] ; then
- export ZLIB_VER=1.2.13
-fi;
-
-
-#set to something even if override is on but not set
-if [[ "${LIBXML_VER}" == '' ]] ; then
- export LIBXML_VER=2.9.14
-fi;
-
-#set to something even if override is on but not set
-if [[ "${CGAL_VER}" == '' ]] ; then
- export CGAL_VER=5.3
-fi;
-
-echo "ZLIB_VER $ZLIB_VER"
-echo "PROJ_VER $PROJ_VER"
-echo "LIBXML_VER $LIBXML_VER"
-echo "CGAL_VER $CGAL_VER"
-
-
-export PROJECTS=/projects
-export PROJECTS=/projects
-export PATHOLD=$PATH
-
-
-export PGHOST=localhost
-
-export PGUSER=postgres
-
-export PATHOLD=$PATH
WEB=/home/www/postgis/htdocs
DWN=${WEB}/download
-export PATHOLD="/mingw/bin:/mingw/include:/c/Windows/system32:/c/Windows:.:/bin:/include:/usr/local/bin"
#export PG_VER=9.2beta2
-echo PATH BEFORE: $PATH
-
-export PGPATH=${PROJECTS}/postgresql/rel/pg${PG_VER}w${OS_BUILD}${GCC_TYPE}
-export PGPATHEDB=${PGPATH}edb
-#export PROJSO=libproj-13.dll
-
if [ -n "$SOURCE_FOLDER" ]; then
export POSTGIS_SRC=${PROJECTS}/postgis/$SOURCE_FOLDER
cd $POSTGIS_SRC
@@ -115,14 +36,13 @@ export REL_PGVER=${PG_VER//./} #strip the period
export RELDIR=${PROJECTS}/postgis/builds/${POSTGIS_MINOR_VER}
export RELVERDIR=postgis-pg${REL_PGVER}-binaries-${POSTGIS_MICRO_VER}w${OS_BUILD}${GCC_TYPE}
export PATH="${PATHOLD}:${PGPATH}/bin:${PGPATH}/lib"
-export PCRE_VER=8.33
#PATH="${PGPATH}/bin:${PGPATH}/lib:${PROJECTS}/xsltproc:${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/gtkw${OS_BUILD}/bin:${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include:${PROJECTS}/rel-libiconv-1.13.1w${OS_BUILD}${GCC_TYPE}/bin:${PATH}"
#echo PATH AFTER: $PATH
outdir="${RELDIR}/${RELVERDIR}"
package="${RELDIR}/${RELVERDIR}.zip"
verfile="${RELDIR}/${RELVERDIR}/version.txt"
rm -rf $outdir
-rm $package
+rm -f $package
mkdir -p $outdir
mkdir -p $outdir/share/contrib/postgis-${POSTGIS_MINOR_VER}
mkdir -p $outdir/share/contrib/postgis-${POSTGIS_MINOR_VER}/proj
@@ -161,22 +81,13 @@ cp -r ${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/lib/gtk-2.0 $outdir/bin/postgisgui/
cp -r ${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/lib/*.dll $outdir/bin/postgisgui/lib
cp -r ${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/lib/gdk-pixbuf-2.0 $outdir/bin/postgisgui/lib
-# old proj < 8
-cp ${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/share/proj/* $outdir/share/contrib/postgis-${POSTGIS_MINOR_VER}/proj
-cp ${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin/*.dll $outdir/bin
-
-# new proj >= 8 folder prefixed with proj
-cp ${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/share/proj/* $outdir/share/contrib/postgis-${POSTGIS_MINOR_VER}/proj
-cp ${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin/*.dll $outdir/bin
-#for some reason shp2pgsql-gui has a dependency on proj, so annoying
-cp ${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin/*.dll $outdir/bin/postgisgui
-#start shipping the projsync
-cp ${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin/projsync.exe $outdir/bin
-
+# proj
+cp ${PROJ_LIB}/* $outdir/share/contrib/postgis-${POSTGIS_MINOR_VER}/proj
+cp ${PROJ_PATH}/bin/*.dll $outdir/bin
+cp ${PROJ_PATH}/bin/*.dll $outdir/bin/postgisgui
+# geos
cp -p ${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}${GCC_TYPE}/bin/*.dll $outdir/bin
-
-cp ${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin/*.dll $outdir/bin/postgisgui
cp -p ${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}${GCC_TYPE}/bin/*.dll $outdir/bin/postgisgui
#for protobuf
@@ -205,7 +116,7 @@ if [ -n "$SFCGAL_VER" ]; then
echo "GMP VERSION: ${GMP_VER} https://gmplib.org" >> $verfile
echo "MPFR VERSION: ${MPFR_VER} http://www.mpfr.org" >> $verfile
- cp -p ${PROJECTS}/CGAL/rel-cgal-${CGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin/*.dll $outdir/bin
+ #cp -p ${PROJECTS}/CGAL/rel-cgal-${CGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin/*.dll $outdir/bin
cp -p ${PROJECTS}/CGAL/rel-sfcgal-${SFCGAL_VER}w${OS_BUILD}${GCC_TYPE}/lib/*.dll $outdir/bin
# cp -p ${PROJECTS}/CGAL/rel-cgal-${CGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin/*.dll $outdir/bin/postgisgui
# cp -p ${PROJECTS}/CGAL/rel-sfcgal-${SFCGAL_VER}w${OS_BUILD}${GCC_TYPE}/lib/*.dll $outdir/bin/postgisgui
@@ -221,7 +132,7 @@ cd ${POSTGIS_SRC}
strip postgis/*.dll
strip sfcgal/*.dll
strip raster/rt_pg/*.dll
-strip liblwgeom/.libs/*.dll
+#strip liblwgeom/.libs/*.dll
cp postgis/*.dll ${RELDIR}/${RELVERDIR}/lib
cp sfcgal/*.dll ${RELDIR}/${RELVERDIR}/lib
@@ -233,9 +144,12 @@ cp raster/rt_pg/*.sql ${RELDIR}/${RELVERDIR}/share/contrib/postgis-${POSTGIS_MIN
cp utils/*.pl ${RELDIR}/${RELVERDIR}/utils
cp raster/loader/.libs/raster2pgsql.exe ${RELDIR}/${RELVERDIR}/bin
-cp liblwgeom/.libs/*.dll ${RELDIR}/${RELVERDIR}/bin
+#cp liblwgeom/.libs/*.dll ${RELDIR}/${RELVERDIR}/bin
+cp loader/shp2pgsql.exe ${RELDIR}/${RELVERDIR}/bin
cp loader/.libs/shp2pgsql.exe ${RELDIR}/${RELVERDIR}/bin
+cp loader/pgsql2shp.exe ${RELDIR}/${RELVERDIR}/bin
cp loader/.libs/pgsql2shp.exe ${RELDIR}/${RELVERDIR}/bin
+cp loader/shp2pgsql-gui.exe ${RELDIR}/${RELVERDIR}/bin/postgisgui
cp loader/.libs/shp2pgsql-gui.exe ${RELDIR}/${RELVERDIR}/bin/postgisgui
cp topology/loader/* ${RELDIR}/${RELVERDIR}/bin
@@ -245,12 +159,12 @@ cp topology/loader/* ${RELDIR}/${RELVERDIR}/bin
cp -p ${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}${GCC_TYPE}/bin/*.dll ${RELDIR}/${RELVERDIR}/bin/postgisgui
cp spatial_ref_sys.sql ${RELDIR}/${RELVERDIR}/share/contrib/postgis-${POSTGIS_MINOR_VER}
cp topology/topology.sql ${RELDIR}/${RELVERDIR}/share/contrib/postgis-${POSTGIS_MINOR_VER}
-cp topology/topology_upgrade_*.sql ${RELDIR}/${RELVERDIR}/share/contrib/postgis-${POSTGIS_MINOR_VER}
+#cp topology/topology_upgrade_*.sql ${RELDIR}/${RELVERDIR}/share/contrib/postgis-${POSTGIS_MINOR_VER}
#cp topology/README* ${RELDIR}/${RELVERDIR}/share/contrib/postgis-${POSTGIS_MINOR_VER}
#cp utils/* ${RELDIR}/${RELVERDIR}/utils
#cp extras/* ${RELDIR}/${RELVERDIR}/share/contrib/postgis-${POSTGIS_MINOR_VER}/extras
# in case we ever do MAX ship all the max scripts
-export POSTGIS_MINOR_MAX_VER=${POSTGIS_MINOR_VER}.UPGRADEME
+export POSTGIS_MINOR_MAX_VER="ANY"
#export UPGRADE_VER_FILE="extensions/upgradeable_versions.mk"
value=$(<extensions/upgradeable_versions.mk)
@@ -261,31 +175,21 @@ export UPGRADEABLE_VERSIONS=$value
#echo "Versions are: $UPGRADEABLE_VERSIONS"
export WIN_RELEASED_VERSIONS="2.0.0 2.0.1 2.0.3 2.0.4 2.0.6 2.1.4 2.1.7 2.1.8 2.2.0 2.2.3 2.3.0 2.3.7 2.4.0 2.4.4"
for EXTNAME in postgis postgis_raster postgis_topology postgis_sfcgal postgis_tiger_geocoder address_standardizer; do
- cp extensions/$EXTNAME/sql/$EXTNAME--${POSTGIS_MICRO_VER}.sql ${RELDIR}/${RELVERDIR}/share/extension
- cp extensions/$EXTNAME/sql/*unpackaged*.sql ${RELDIR}/${RELVERDIR}/share/extension
- cp extensions/$EXTNAME/sql/$EXTNAME--ANY--${POSTGIS_MICRO_VER}.sql ${RELDIR}/${RELVERDIR}/share/extension
- cp extensions/$EXTNAME/sql/$EXTNAME--ANY--${POSTGIS_MICRO_VER}.sql ${RELDIR}/${RELVERDIR}/share/extension/$EXTNAME--${POSTGIS_MINOR_MAX_VER}--${POSTGIS_MICRO_VER}.sql
- cp extensions/$EXTNAME/sql/$EXTNAME--ANY--${POSTGIS_MICRO_VER}.sql ${RELDIR}/${RELVERDIR}/share/extension/$EXTNAME--${POSTGIS_MICRO_VER}next--${POSTGIS_MICRO_VER}.sql
- cp extensions/$EXTNAME/sql/$EXTNAME--ANY--${POSTGIS_MICRO_VER}.sql ${RELDIR}/${RELVERDIR}/share/extension/$EXTNAME--${POSTGIS_MICRO_VER}--${POSTGIS_MICRO_VER}next.sql
+ cp extensions/$EXTNAME/sql/* ${RELDIR}/${RELVERDIR}/share/extension
+
+ cp extensions/$EXTNAME/sql/$EXTNAME--ANY--${POSTGIS_MICRO_VER}.sql ${RELDIR}/${RELVERDIR}/share/extension/$EXTNAME--${POSTGIS_MINOR_MAX_VER}--${POSTGIS_MICRO_VER}.sql
- # special cases of ANY and next
- echo "--placeholder" > ${RELDIR}/${RELVERDIR}/share/extension/$EXTNAME--ANY--${POSTGIS_MINOR_MAX_VER}.sql
if test "$EXTNAME" = "address_standardizer"; then #repeat for address_standardizer_data_us
- cp extensions/$EXTNAME/sql/${EXTNAME}_data_us--${POSTGIS_MICRO_VER}.sql ${RELDIR}/${RELVERDIR}/share/extension
- cp extensions/postgis/sql/postgis--ANY--${POSTGIS_MICRO_VER}.sql ${RELDIR}/${RELVERDIR}/share/extension
- cp extensions/$EXTNAME/sql/${EXTNAME}_data_us--ANY--${POSTGIS_MICRO_VER}.sql ${RELDIR}/${RELVERDIR}/share/extension/${EXTNAME}_data_us--${POSTGIS_MINOR_MAX_VER}--${POSTGIS_MICRO_VER}.sql
- cp extensions/$EXTNAME/sql/${EXTNAME}_data_us--ANY--${POSTGIS_MICRO_VER}.sql ${RELDIR}/${RELVERDIR}/share/extension/${EXTNAME}_data_us--${POSTGIS_MICRO_VER}next--${POSTGIS_MICRO_VER}.sql
- echo "--placeholder" > ${RELDIR}/${RELVERDIR}/share/extension//${EXTNAME}_data_us--ANY--${POSTGIS_MINOR_MAX_VER}.sql
- echo "--placeholder" > ${RELDIR}/${RELVERDIR}/share/extension//${EXTNAME}_data_us--${POSTGIS_MICRO_VER}--${POSTGIS_MINOR_MAX_VER}.sql
- echo "--placeholder" > ${RELDIR}/${RELVERDIR}/share/extension//${EXTNAME}_data_us--${POSTGIS_MICRO_VER}next--${POSTGIS_MINOR_MAX_VER}.sql
+ cp extensions/$EXTNAME/sql/${EXTNAME}_data_us--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension
+ cp extensions//$EXTNAME/sql/${EXTNAME}_data_us--ANY--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension
fi
for OLD_VERSION in $UPGRADEABLE_VERSIONS; do \
if [ "$OLD_VERSION" > "2.5" ] || [ "$OLD_VERSION" in $WIN_RELEASED_VERSIONS ]; then
- echo "--placeholder" > ${RELDIR}/${RELVERDIR}/share/extension/$EXTNAME--$OLD_VERSION--${POSTGIS_MINOR_MAX_VER}.sql; \
+ cp extensions/$EXTNAME/sql/$EXTNAME--TEMPLATED--TO--ANY.sql ${RELDIR}/${RELVERDIR}/share/extension/$EXTNAME--$OLD_VERSION--${POSTGIS_MINOR_MAX_VER}.sql; \
if test "$EXTNAME" = "address_standardizer"; then
- echo "--placeholder" > ${RELDIR}/${RELVERDIR}/share/extension/${EXTNAME}_data_us--$OLD_VERSION--${POSTGIS_MINOR_MAX_VER}.sql; \
+ cp extensions/$EXTNAME/sql/$EXTNAME--TEMPLATED--TO--ANY.sql ${RELDIR}/${RELVERDIR}/share/extension/${EXTNAME}_data_us--$OLD_VERSION--${POSTGIS_MINOR_MAX_VER}.sql; \
fi
fi
done
@@ -301,7 +205,7 @@ cp -r extensions/*/*.dll ${RELDIR}/${RELVERDIR}/lib #only address_standardizer i
cp -r ${RELDIR}/packaging_notes/* ${RELDIR}/${RELVERDIR}/
-echo "GEOS VERSION: ${GEOS_VER} https://trac.osgeo.org/geos" >> $verfile
+echo "GEOS VERSION: ${GEOS_VER} https://github.com/libgeos/geos" >> $verfile
echo "GDAL VERSION: ${GDAL_VER} https://gdal.org/download.html#current-releases" >> $verfile
echo "PROJ VERSION: ${PROJ_VER} https://proj.org/download.html#current-release" >> $verfile
@@ -310,13 +214,13 @@ echo "LIBICONV VERSION: ${ICON_VER} http://ftp.gnu.org/gnu/libiconv/libiconv-${I
if [ -n "$SFCGAL_VER" ]; then
echo "CGAL VERSION: ${CGAL_VER} http://www.cgal.org" >> $verfile
echo "BOOST VERSION: ${BOOST_VER} http://www.boost.org" >> $verfile
- echo "SFCGAL VERSION: ${SFCGAL_VER} http://www.sfcgal.org https://github.com/sfcgal/SFCGAL" >> $verfile
+ echo "SFCGAL VERSION: ${SFCGAL_VER} http://www.sfcgal.org https://gitlab.com/sfcgal/SFCGAL" >> $verfile
fi;
if [ -f ${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/gdal_depends.txt ]; then
cat $verfile ${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/gdal_depends.txt > $verfile
fi
-#echo "PAGC ADDRESS STANDARDIZER: http://sourceforge.net/p/pagc/code/HEAD/tree/branches/sew-refactor/postgresql " >> $verfile
+
cd ${RELDIR}
zip -r $package ${RELVERDIR}
md5sum $package > ${package}.md5
diff --git a/ci/winnie/regress_postgis.sh b/ci/winnie/regress_postgis.sh
index 0ef160335..9906d5659 100644
--- a/ci/winnie/regress_postgis.sh
+++ b/ci/winnie/regress_postgis.sh
@@ -1,78 +1,14 @@
#!/usr/bin/env bash
-set -e
-if [[ "${OVERRIDE}" == '' ]] ; then
- export GEOS_VER=3.11.2
- export GDAL_VER=3.4.2
- export PROJ_VER=7.2.1
- export SFCGAL_VER=1.4.1
- export CGAL_VER=5.3
- export ICON_VER=1.16
- export ZLIB_VER=1.2.11
- export PROTOBUF_VER=3.2.0
- export PROTOBUFC_VER=1.2.1
- export JSON_VER=0.12
- export PROJSO=libproj-19.dll
-fi;
-export PROTOBUF_VER=3.2.0
-export PROTOBUFC_VER=1.2.1
-if [[ "${JSON_VER}" == '' ]] ; then
- export JSON_VER=0.12
-fi;
+. $(dirname $0)/winnie_common.sh
-export PCRE_VER=8.33
-
-if [[ "${ICON_VER}" == '' ]] ; then
- export ICON_VER=1.17
-fi;
-
-echo "ICON_VER ${ICON_VER}"
-
-#set to something even if override is on but not set
-if [[ "${ZLIB_VER}" == '' ]] ; then
- export ZLIB_VER=1.2.13
-fi;
-
-
-#set to something even if override is on but not set
-if [[ "${LIBXML_VER}" == '' ]] ; then
- export LIBXML_VER=2.9.14
-fi;
-
-#set to something even if override is on but not set
-if [[ "${CGAL_VER}" == '' ]] ; then
- export CGAL_VER=5.3
-fi;
-
-echo "ZLIB_VER $ZLIB_VER"
-echo "PROJ_VER $PROJ_VER"
-echo "LIBXML_VER $LIBXML_VER"
-echo "CGAL_VER $CGAL_VER"
-echo "ZLIB_VER $ZLIB_VER"
-echo "PROJ_VER $PROJ_VER"
-echo "LIBXML_VER $LIBXML_VER"
-export PROJECTS=/projects
-export MINGPROJECTS=/projects
-export PATHOLD=$PATH
-
-if [ "$OS_BUILD" == "64" ] ; then
- export MINGHOST=x86_64-w64-mingw32
-else
- export MINGHOST=i686-w64-mingw32
-fi;
+echo "MSYS2_ARG_CONV_EXCL=$MSYS2_ARG_CONV_EXCL"
echo PATH AFTER: $PATH
#export PG_VER=9.2beta2
export PGWINVER=${PG_VER}edb
export WORKSPACE=`pwd`
-echo PATH BEFORE: $PATH
-
-#export PGHOST=localhost
-#export PGPORT=8442
-export PGUSER=postgres
-#export GEOS_VER=3.4.0dev
-#export GDAL_VER=1.9.1
export PGPATH=${PROJECTS}/postgresql/rel/pg${PG_VER}w${OS_BUILD}${GCC_TYPE}
export PGPATHEDB=${PROJECTS}/postgresql/rel/pg${PG_VER}w${OS_BUILD}${GCC_TYPE}edb
@@ -101,21 +37,6 @@ export GDAL_DATA="${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/share/
export RELVERDIR=postgis-pg${REL_PGVER}-binaries-${POSTGIS_MICRO_VER}w${OS_BUILD}
-export PATH="${PATHOLD}:${PGPATH}/bin:${PGPATH}/lib"
-export PATH="${PROJECTS}/xsltproc:${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/libxml/rel-libxml2-${LIBXML_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
-export PKG_CONFIG_PATH="${PROJECTS}/sqlite/rel-sqlite3w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/json-c/rel-${JSON_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/pcre/rel-${PCRE_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:/mingw/${MINGHOST}/lib/pkgconfig"
-export SHLIB_LINK="-static-libstdc++ -lstdc++ -Wl,-Bdynamic -lm"
-CPPFLAGS="-I${PGPATH}/include -I${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include"
-
-#needed for proj.db to be found during cunit - for some reason on winnie it doesn't set
-if [ -d "${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/share/proj" ]; then
-export PROJ_LIB=${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/share/proj
-else
-export PROJ_LIB=${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/share/proj
-fi
-
-#add protobuf
-export PATH="${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
echo PATH AFTER: $PATH
@@ -144,21 +65,15 @@ fi
-if [ -n "$SFCGAL_VER" ]; then
- ##hard code versions of cgal etc. for now
- #export CGAL_VER=4.11
- BOOST_VER=1.78.0
- #BOOST_VER_WU=1_49_0
- export BOOST_VER_WU=1_78_0
- export PATH="${PROJECTS}/CGAL/rel-cgal-${CGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/CGAL/rel-sfcgal-${SFCGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/boost/rel-${BOOST_VER_WU}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
-
+if [$INCLUDE_MINOR_LIB == "1"]; then
#CPPFLAGS="-I${PGPATH}/include -I${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include" \
#CFLAGS="-Wall -fno-omit-frame-pointer"
#LDFLAGS="-Wl,--enable-auto-import -L${PGPATH}/lib -L${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/lib -L${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib" \
-LDFLAGS="-Wl,--enable-auto-import -L${PGPATH}/lib -L${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib -L${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib" \
+CPPFLAGS="-I${PGPATH}/include -I${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include" \
+LDFLAGS="-Wl,--enable-auto-import -L${PGPATH}/lib -L${LZ4_PATH}/bin -L${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib -L${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib" \
./configure \
--host=${MINGHOST} --with-xml2config=${PROJECTS}/libxml/rel-libxml2-${LIBXML_VER}w${OS_BUILD}${GCC_TYPE}/bin/xml2-config \
--with-pgconfig=${PGPATH}/bin/pg_config \
@@ -167,18 +82,18 @@ LDFLAGS="-Wl,--enable-auto-import -L${PGPATH}/lib -L${PROJECTS}/rel-libiconv-${I
--with-xsldir=${PROJECTS}/docbook/docbook-xsl-1.76.1 \
--with-gui --with-gettext=no \
--with-sfcgal=${PROJECTS}/CGAL/rel-sfcgal-${SFCGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin/sfcgal-config \
- --prefix=${PROJECTS}/postgis/liblwgeom-${POSTGIS_VER}w${OS_BUILD}${GCC_TYPE}
+ --prefix=${PROJECTS}/postgis/liblwgeom-${POSTGIS_VER}w${OS_BUILD}${GCC_TYPE} --with-library-minor-version
#exit
else
-CPPFLAGS="-I${PGPATH}/include -I${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include" \
-CFLAGS="-Wall -fno-omit-frame-pointer" \
-LDFLAGS="-L${PGPATH}/lib -L${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/lib -L${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib" ./configure \
- --host=${MINGHOST} --with-xml2config=${PROJECTS}/libxml/rel-libxml2-${LIBXML_VER}w${OS_BUILD}${GCC_TYPE}/bin/xml2-config \
+LDFLAGS="-Wl,--enable-auto-import -L${PGPATH}/lib -L${LZ4_PATH}/bin -L${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib -L${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib" \
+./configure \
+ --host=${MINGHOST} --with-xml2config=${PROJECTS}/libxml/rel-libxml2-${LIBXML_VER}w${OS_BUILD}${GCC_TYPE}/bin/xml2-config \
--with-pgconfig=${PGPATH}/bin/pg_config \
--with-geosconfig=${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}${GCC_TYPE}/bin/geos-config \
- --with-gui --with-gettext=no \
--with-libiconv=${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE} \
--with-xsldir=${PROJECTS}/docbook/docbook-xsl-1.76.1 \
+ --with-gui --with-gettext=no \
+ --with-sfcgal=${PROJECTS}/CGAL/rel-sfcgal-${SFCGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin/sfcgal-config \
--prefix=${PROJECTS}/postgis/liblwgeom-${POSTGIS_VER}w${OS_BUILD}${GCC_TYPE}
fi;
@@ -206,7 +121,8 @@ if [ "$MAKE_EXTENSION" == "1" ]; then
cp raster/rt_pg/postgis_raster-*.dll ${PGPATHEDB}/lib
export POSTGIS_MINOR_VER=${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}
-export POSTGIS_MINOR_MAX_VER=${POSTGIS_MINOR_VER}.UPGRADEME
+export POSTGIS_MINOR_MAX_VER="ANY"
+export POSTGIS_MICRO_VER=${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}.${POSTGIS_MICRO_VERSION}
#export UPGRADE_VER_FILE="extensions/upgradeable_versions.mk"
value=$(<extensions/upgradeable_versions.mk)
@@ -214,32 +130,23 @@ export value=${value//\\/}
value=${value//UPGRADEABLE_VERSIONS = /}
#echo $value
export UPGRADEABLE_VERSIONS=$value
+export WIN_RELEASED_VERSIONS="2.0.0 2.0.1 2.0.3 2.0.4 2.0.6 2.1.4 2.1.7 2.1.8 2.2.0 2.2.3 2.3.0 2.3.7 2.4.0 2.4.4"
#echo "Versions are: $UPGRADEABLE_VERSIONS"
for EXTNAME in postgis postgis_raster postgis_topology postgis_sfcgal postgis_tiger_geocoder address_standardizer; do
- cp extensions/$EXTNAME/sql/$EXTNAME--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension
- cp extensions/$EXTNAME/sql/$EXTNAME--ANY--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension
- cp extensions/$EXTNAME/sql/$EXTNAME--ANY--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension/$EXTNAME--${POSTGIS_MINOR_MAX_VER}--${POSTGIS_MICRO_VER}.sql
- cp extensions/$EXTNAME/sql/$EXTNAME--ANY--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension/$EXTNAME--${POSTGIS_MICRO_VER}next--${POSTGIS_MICRO_VER}.sql
- cp extensions/$EXTNAME/sql/$EXTNAME--ANY--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension/$EXTNAME--${POSTGIS_MICRO_VER}--${POSTGIS_MICRO_VER}next.sql
-
- # special cases of ANY and next
- echo "--placeholder" > ${PGPATHEDB}/share/extension/$EXTNAME--ANY--${POSTGIS_MINOR_MAX_VER}.sql
+ cp extensions/$EXTNAME/sql/* ${PGPATHEDB}/share/extension
+ cp extensions/$EXTNAME/sql/$EXTNAME--TEMPLATED--TO--ANY.sql ${PGPATHEDB}/share/extension/$EXTNAME--$POSTGIS_MICRO_VER--${POSTGIS_MINOR_MAX_VER}.sql;
if test "$EXTNAME" = "address_standardizer"; then #repeat for address_standardizer_data_us
cp extensions/$EXTNAME/sql/${EXTNAME}_data_us--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension
- cp extensions/postgis/sql/postgis--ANY--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension
- cp extensions/$EXTNAME/sql/${EXTNAME}_data_us--ANY--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension/${EXTNAME}_data_us--${POSTGIS_MINOR_MAX_VER}--${POSTGIS_MICRO_VER}.sql
- cp extensions/$EXTNAME/sql/${EXTNAME}_data_us--ANY--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension/${EXTNAME}_data_us--${POSTGIS_MICRO_VER}next--${POSTGIS_MICRO_VER}.sql
- echo "--placeholder" > ${PGPATHEDB}/share/extension//${EXTNAME}_data_us--ANY--${POSTGIS_MINOR_MAX_VER}.sql
- echo "--placeholder" > ${PGPATHEDB}/share/extension//${EXTNAME}_data_us--${POSTGIS_MICRO_VER}--${POSTGIS_MINOR_MAX_VER}.sql
- echo "--placeholder" > ${PGPATHEDB}/share/extension//${EXTNAME}_data_us--${POSTGIS_MICRO_VER}next--${POSTGIS_MINOR_MAX_VER}.sql
+ cp extensions//$EXTNAME/sql/${EXTNAME}_data_us--ANY--${POSTGIS_MICRO_VER}.sql ${PGPATHEDB}/share/extension
+ cp extensions/$EXTNAME/sql/${EXTNAME}--TEMPLATED--TO--ANY.sql ${PGPATHEDB}/share/extension/${EXTNAME}_data_us--$POSTGIS_MICRO_VER--ANY.sql;
fi
for OLD_VERSION in $UPGRADEABLE_VERSIONS; do \
- if [ "$OLD_VERSION" > "2.5" ] ; then
- echo "--placeholder" > ${PGPATHEDB}/share/extension/$EXTNAME--$OLD_VERSION--${POSTGIS_MINOR_MAX_VER}.sql; \
+ if [ "$OLD_VERSION" > "2.5" ] || [ "$OLD_VERSION" in $WIN_RELEASED_VERSIONS ]; then
+ cp extensions/$EXTNAME/sql/$EXTNAME--TEMPLATED--TO--ANY.sql ${PGPATHEDB}/share/extension/$EXTNAME--$OLD_VERSION--${POSTGIS_MINOR_MAX_VER}.sql; \
if test "$EXTNAME" = "address_standardizer"; then
- echo "--placeholder" > ${PGPATHEDB}/share/extension/${EXTNAME}_data_us--$OLD_VERSION--${POSTGIS_MINOR_MAX_VER}.sql; \
+ cp extensions/$EXTNAME/sql/$EXTNAME--TEMPLATED--TO--ANY.sql ${PGPATHEDB}/share/extension/${EXTNAME}_data_us--$OLD_VERSION--${POSTGIS_MINOR_MAX_VER}.sql; \
fi
fi
done
@@ -252,12 +159,12 @@ done
make check RUNTESTFLAGS="--extension -v"
- ##test address standardizer
+ #test address standardizer
cd ${POSTGIS_SRC}
cd extensions/address_standardizer
make installcheck
- ##test tiger geocoder
+ #test tiger geocoder
cd ${POSTGIS_SRC}
cd extensions/postgis_tiger_geocoder
make installcheck
@@ -267,7 +174,7 @@ done
fi
if [ "$DUMP_RESTORE" == "1" ]; then
- echo "Dum restore test"
+ echo "Dump restore test"
make install
make check RUNTESTFLAGS="-v --dumprestore"
if [ "$?" != "0" ]; then
diff --git a/ci/winnie/winnie_common.sh b/ci/winnie/winnie_common.sh
new file mode 100644
index 000000000..296712046
--- /dev/null
+++ b/ci/winnie/winnie_common.sh
@@ -0,0 +1,143 @@
+# Common code for all winnie scripts
+#
+# TODO: add more shared code, I guess
+#
+
+set -e
+
+export PROJECTS=/projects
+# Don't convert paths
+# See https://trac.osgeo.org/postgis/ticket/5436#comment:5
+export MSYS2_ARG_CONV_EXCL=/config/tags
+
+if [[ "${OVERRIDE}" == '' ]] ; then
+ export GEOS_VER=3.12.2
+ export GDAL_VER=3.8.5
+ export PROJ_VER=8.2.1
+ export SFCGAL_VER=1.5.1
+ export CGAL_VER=5.6
+ export ICON_VER=1.17
+ export ZLIB_VER=1.2.13
+ export PROTOBUF_VER=3.2.0
+ export PROTOBUFC_VER=1.2.1
+ export JSON_VER=0.12
+ export PROJSO=libproj_8_2.dll
+ export LZ4_VER=1.9.3
+fi;
+
+export PROTOBUF_VER=3.2.0
+export PROTOBUFC_VER=1.2.1
+export JSON_VER=0.12
+export PCRE_VER=8.33
+
+
+#export OS_BUILD=64
+#export PGPORT=8442
+
+#export OS_BUILD=32
+
+#export GCC_TYPE=
+#if no override is set - use these values
+#otherwise use the ones jenkins passes thru
+if [[ "${ICON_VER}" == '' ]] ; then
+ export ICON_VER=1.17
+fi;
+
+echo "ICON_VER ${ICON_VER}"
+
+#set to something even if override is on but not set
+if [[ "${ZLIB_VER}" == '' ]] ; then
+ export ZLIB_VER=1.2.13
+fi;
+
+#set to something even if override is on but not set
+if [[ "${LIBXML_VER}" == '' ]] ; then
+ export LIBXML_VER=2.9.14
+fi;
+
+#set to something even if override is on but not set
+if [[ "${CGAL_VER}" == '' ]] ; then
+ export CGAL_VER=5.6
+fi;
+
+##hard code versions of cgal etc. for now
+export CGAL_VER=5.6
+BOOST_VER=1.84.0
+export BOOST_VER_WU=1_84_0
+
+
+export LZ4_PATH=${PROJECTS}/lz4/rel-lz4-${LZ4_VER}w${OS_BUILD}${GCC_TYPE}
+
+export PATH="${PROJECTS}/CGAL/rel-cgal-${CGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/CGAL/rel-sfcgal-${SFCGAL_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/boost/rel-${BOOST_VER_WU}w${OS_BUILD}${GCC_TYPE}/lib:${LZ4_PATH}/bin:${LZ4_PATH}/lib:${PATH}"
+#export GDAL_VER=2.4.0
+#export PROJ_VER=5.2.0
+
+echo "ZLIB_VER $ZLIB_VER"
+echo "PROJ_VER $PROJ_VER"
+echo "LIBXML_VER $LIBXML_VER"
+echo "CGAL_VER $CGAL_VER"
+export PROJECTS=/projects
+export MINGPROJECTS=/projects
+export PATHOLD=$PATH
+
+if [ "$OS_BUILD" == "64" ] ; then
+ export MINGHOST=x86_64-w64-mingw32
+else
+ export MINGHOST=i686-w64-mingw32
+fi;
+
+#needed for proj.db to be found during cunit - for some reason on winnie it doesn't set
+if [ -d "${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/share/proj" ]; then
+export PROJ_LIB=${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/share/proj
+export PROJ_PATH=${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}
+else
+export PROJ_LIB=${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/share/proj
+export PROJ_PATH=${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}
+fi
+
+#export PG_VER=9.2beta2
+export PGWINVER=${PG_VER}edb
+export WORKSPACE=`pwd`
+
+echo PATH BEFORE: $PATH
+
+#export PGHOST=localhost
+#export PGPORT=8442
+export PGUSER=postgres
+#export GEOS_VER=3.4.0dev
+#export GDAL_VER=1.9.1
+export PGPATH=${PROJECTS}/postgresql/rel/pg${PG_VER}w${OS_BUILD}${GCC_TYPE}
+export PGPATHEDB=${PROJECTS}/postgresql/rel/pg${PG_VER}w${OS_BUILD}${GCC_TYPE}edb
+
+export GDAL_DATA="${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/share/gdal"
+
+export PATH="${PATHOLD}:${PGPATH}/bin:${PGPATH}/lib"
+export PATH="${PROJECTS}/xsltproc:${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJ_PATH}/bin:${PROJECTS}/libxml/rel-libxml2-${LIBXML_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
+export PKG_CONFIG_PATH="${PROJECTS}/sqlite/rel-sqlite3w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/json-c/rel-${JSON_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJ_PATH}/lib/pkgconfig:${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/pcre/rel-${PCRE_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:/mingw/${MINGHOST}/lib/pkgconfig"
+export SHLIB_LINK="-static-libstdc++ -lstdc++ -Wl,-Bdynamic -lm"
+CPPFLAGS="-I${PGPATH}/include -I${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include"
+
+
+
+#add protobuf
+export PATH="${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
+
+export PATH="${PATHOLD}:${PGPATH}/bin:${PGPATH}/lib"
+
+#add lz4
+export PATH="${LZ4_PATH}/bin:${LZ4_PATH}/lib:${PATH}"
+echo $PATH
+
+export PATH="${PROJECTS}/xsltproc:${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include:${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/libxml/rel-libxml2-${LIBXML_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
+export PKG_CONFIG_PATH="${PROJECTS}/sqlite/rel-sqlite3w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/json-c/rel-${JSON_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/proj/rel-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/proj/rel-proj-${PROJ_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/gdal/rel-${GDAL_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/pcre/rel-${PCRE_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/zlib/rel-zlib-${ZLIB_VER}w${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${PROJECTS}/gtkw${OS_BUILD}${GCC_TYPE}/lib/pkgconfig:${LZ4_PATH}/lib/pkgconfig"
+export SHLIB_LINK="-static-libstdc++ -lstdc++ -Wl,-Bdynamic -lm"
+CPPFLAGS="-I${PGPATH}/include -I${PROJECTS}/rel-libiconv-${ICON_VER}w${OS_BUILD}${GCC_TYPE}/include"
+
+#add protobuf
+export PATH="${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/bin:${PROJECTS}/protobuf/rel-${PROTOBUF_VER}w${OS_BUILD}${GCC_TYPE}/lib:${PATH}"
+
+echo "PATH AFTER: $PATH"
+
+if [[ "${INCLUDE_MINOR_LIB}" == "" ]] ; then
+ export INCLUDE_MINOR_LIB=1
+fi;
-----------------------------------------------------------------------
Summary of changes:
NEWS | 7 +++
ci/winnie/build_postgis.sh | 117 ++++------------------------------
ci/winnie/package_postgis.sh | 146 ++++++++-----------------------------------
ci/winnie/regress_postgis.sh | 141 +++++++----------------------------------
ci/winnie/winnie_common.sh | 143 ++++++++++++++++++++++++++++++++++++++++++
libpgcommon/lwgeom_pg.c | 57 ++++++++++++-----
6 files changed, 255 insertions(+), 356 deletions(-)
create mode 100644 ci/winnie/winnie_common.sh
hooks/post-receive
--
PostGIS
More information about the postgis-tickets
mailing list