diff --git a/configure b/configure index f270e1f1..8189a88f 100755 --- a/configure +++ b/configure @@ -1811,11 +1811,11 @@ fi pgac_pg_config_version=$($PG_CONFIG --version 2>/dev/null) major_version_num=$(echo "$pgac_pg_config_version"| - $SED -e 's/^PostgreSQL \([0-9]\{1,2\}\).*$/\1/') + $SED -e 's/^[^0-9]\+ \([0-9]\{1,2\}\).*$/\1/') if test "$major_version_num" -lt '10'; then version_num=$(echo "$pgac_pg_config_version"| - $SED -e 's/^PostgreSQL \([0-9]*\)\.\([0-9]*\)\([a-zA-Z0-9.]*\)$/\1.\2/') + $SED -e 's/^[^0-9]\+ \([0-9]*\)\.\([0-9]*\)\([a-zA-Z0-9.]*\)$/\1.\2/') if test -z "$version_num"; then as_fn_error $? "could not detect the PostgreSQL version, wrong or broken pg_config?" "$LINENO" 5 @@ -1829,7 +1829,7 @@ if test "$major_version_num" -lt '10'; then fi else version_num=$(echo "$pgac_pg_config_version"| - $SED -e 's/^PostgreSQL \(.\+\)$/\1/') + $SED -e 's/^[^0-9]\+ \(.\+\)$/\1/') if test -z "$version_num"; then as_fn_error $? "could not detect the PostgreSQL version, wrong or broken pg_config?" "$LINENO" 5 diff --git a/configure.in b/configure.in index 0719cbf4..7b3f206d 100644 --- a/configure.in +++ b/configure.in @@ -19,11 +19,11 @@ fi pgac_pg_config_version=$($PG_CONFIG --version 2>/dev/null) major_version_num=$(echo "$pgac_pg_config_version"| - $SED -e 's/^PostgreSQL \([[0-9]]\{1,2\}\).*$/\1/') + $SED -e 's/^[[^0-9]]\+ \([[0-9]]\{1,2\}\).*$/\1/') if test "$major_version_num" -lt '10'; then version_num=$(echo "$pgac_pg_config_version"| - $SED -e 's/^PostgreSQL \([[0-9]]*\)\.\([[0-9]]*\)\([[a-zA-Z0-9.]]*\)$/\1.\2/') + $SED -e 's/^[[^0-9]]\+ \([[0-9]]*\)\.\([[0-9]]*\)\([[a-zA-Z0-9.]]*\)$/\1.\2/') if test -z "$version_num"; then AC_MSG_ERROR([could not detect the PostgreSQL version, wrong or broken pg_config?]) @@ -37,7 +37,7 @@ if test "$major_version_num" -lt '10'; then fi else version_num=$(echo "$pgac_pg_config_version"| - $SED -e 's/^PostgreSQL \(.\+\)$/\1/') + $SED -e 's/^[[^0-9]]\+ \(.\+\)$/\1/') if test -z "$version_num"; then AC_MSG_ERROR([could not detect the PostgreSQL version, wrong or broken pg_config?])