[postgis-tickets] r17605 - Try to get berrie to use workspace installed pg12 to get around make install installing in wrong folder

Regina Obe lr at pcorp.us
Mon Jul 15 04:14:23 PDT 2019


Author: robe
Date: 2019-07-15 16:14:22 -0700 (Mon, 15 Jul 2019)
New Revision: 17605

Modified:
   trunk/ci/berrie/postgis_regress.sh
Log:
Try to get berrie to use workspace installed pg12 to get around make install installing in wrong folder
References #4456

Modified: trunk/ci/berrie/postgis_regress.sh
===================================================================
--- trunk/ci/berrie/postgis_regress.sh	2019-07-15 12:38:43 UTC (rev 17604)
+++ trunk/ci/berrie/postgis_regress.sh	2019-07-15 23:14:22 UTC (rev 17605)
@@ -1,8 +1,35 @@
 #Berrie is a 32-bit Rasberry Pi managed by Bruce Rindahl
 #BRANCH is passed in via jenkins which is set via gitea web hook
-mkdir -p tmp
+export WORKSPACE=~/workspace
+export OS_BUILD=32
+export PG_VER=12
+export PGPATH=${WORKSPACE}/postgresql/rel/pg${PG_VER}w${OS_BUILD}
+export PATH=${PATH}:${PGPATH}/bin:${PGPATH}/lib
+export PGPORT=55432
+export PGDATA=${WORKSPACE}/postgresql/rel/pg${PG_VER}w${OS_BUILD}/data_${PGPORT}
+# What to use to start up the postmaster (we do NOT use pg_ctl for this,
+# as it adds no value and can cause the postmaster to misrecognize a stale
+# lock file)
+DAEMON="$PGPATH/bin/postmaster"
+
+# What to use to shut down the postmaster
+PGCTL="$PDPATH/bin/pg_ctl"
+
+# remove cluster if exists
+if [ -d $PGDATA ] ; then
+    rm $PGDATA
+fi;
+
+#initialize cluster
+$PGPATH/bin/initdb
+
+echo -n "Starting PostgreSQL: "
+$DAEMON
+sleep 5
+echo "ok"
+
 sh autogen.sh
-./configure
+./configure --with-pgconfig=${PGPATH}/bin/pg_config
 make clean
 make
 export PGUSER=postgres
@@ -9,5 +36,10 @@
 #export PGIS_REG_TMPDIR=tmp
 psql -c "DROP DATABASE IF EXISTS postgis_reg;"
 make check RUNTESTFLAGS="-v"
-sudo make install
-make check RUNTESTFLAGS="-v --extension"
\ No newline at end of file
+make install
+make check RUNTESTFLAGS="-v --extension"
+
+echo -n "Stopping PostgreSQL: "
+$PGCTL stop -D $PGDATA -s -m fast
+echo "ok"
+;;
\ No newline at end of file



More information about the postgis-tickets mailing list