diff --git a/configure b/configure index 3f07bba0..df6f0191 100755 --- a/configure +++ b/configure @@ -18,6 +18,7 @@ # PGPORT=5432 +SQLAPI_PORT=8080 MAPNIK_VERSION= usage() { @@ -26,6 +27,7 @@ usage() { echo "Configuration:" echo " --help display this help and exit" echo " --with-pgport=NUM access PostgreSQL server on TCP port NUM [$PGPORT]" + echo " --with-sqlapi-port=NUM access SQL-API server on TCP port NUM [$SQLAPI_PORT]" echo " --with-mapnik-version=STRING set mapnik version string [$MAPNIK_VERSION]" } @@ -38,6 +40,9 @@ while test -n "$1"; do --with-pgport=*) PGPORT=`echo "$1" | cut -d= -f2` ;; + --with-sqlapi-port=*) + SQLAPI_PORT=`echo "$1" | cut -d= -f2` + ;; --with-mapnik-version=*) MAPNIK_VERSION=`echo "$1" | cut -d= -f2` ;; @@ -60,6 +65,7 @@ for f in config/environments/*.example; do # See http://austinmatzko.com/2008/04/26/sed-multi-line-search-and-replace/ sed -n "1h;1!H;\${;g;s/\(,postgres: {[^}]*port: *'\?\)[^',]*\('\?,\)/\1$PGPORT\2/;p;}" < "$f" \ | sed "s/mapnik_version:.*/mapnik_version: '$MAPNIK_VERSION'/" \ + | sed -n "1h;1!H;\${;g;s/\(,sqlapi: {[^}]*port: *'\?\)[^',]*\('\?,\)/\1$SQLAPI_PORT\2/;p;}" \ > "$o" done