diff options
author | Jeff Davis <jdavis@postgresql.org> | 2024-08-20 11:24:00 -0700 |
---|---|---|
committer | Jeff Davis <jdavis@postgresql.org> | 2024-08-20 12:25:06 -0700 |
commit | 0fb0f689331cb0c00348aab752dced30493a6672 (patch) | |
tree | cb0a47cfc1f86c36f9bda4378335b82118ce7359 /configure | |
parent | 5ff9b6b4d981a59236a89d33dea8bc253257ce2a (diff) | |
download | postgresql-0fb0f689331cb0c00348aab752dced30493a6672.tar.gz postgresql-0fb0f689331cb0c00348aab752dced30493a6672.zip |
Improve configure error for ICU libraries if pkg-config is absent.
If pkg-config is not installed, the ICU libraries cannot be found, but
the custom configure error message did not mention this. This might
lead to confusion about the actual problem. To improve this, remove
the explicit error message and rely on PKG_CHECK_MODULES' generic
error message.
Author: Michael Banck
Reported-by: Holger Jakobs
Discussion: https://postgr.es/m/ccd579ed-4949-d3de-ab13-9e6456fd2caf%40jakobs.com
Discussion: https://postgr.es/m/66b5d05c.050a0220.7c8ce.a951@mx.google.com
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 30 |
1 files changed, 22 insertions, 8 deletions
diff --git a/configure b/configure index 2abbeb27944..537366945c0 100755 --- a/configure +++ b/configure @@ -8153,17 +8153,31 @@ fi # Put the nasty error message in config.log where it belongs echo "$ICU_PKG_ERRORS" >&5 - as_fn_error $? "ICU library not found -If you have ICU already installed, see config.log for details on the -failure. It is possible the compiler isn't looking in the proper directory. -Use --without-icu to disable ICU support." "$LINENO" 5 + as_fn_error $? "Package requirements (icu-uc icu-i18n) were not met: + +$ICU_PKG_ERRORS + +Consider adjusting the PKG_CONFIG_PATH environment variable if you +installed software in a non-standard prefix. + +Alternatively, you may set the environment variables ICU_CFLAGS +and ICU_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } - as_fn_error $? "ICU library not found -If you have ICU already installed, see config.log for details on the -failure. It is possible the compiler isn't looking in the proper directory. -Use --without-icu to disable ICU support." "$LINENO" 5 + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it +is in your PATH or set the PKG_CONFIG environment variable to the full +path to pkg-config. + +Alternatively, you may set the environment variables ICU_CFLAGS +and ICU_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. + +To get pkg-config, see <http://pkg-config.freedesktop.org/>. +See \`config.log' for more details" "$LINENO" 5; } else ICU_CFLAGS=$pkg_cv_ICU_CFLAGS ICU_LIBS=$pkg_cv_ICU_LIBS |