From: Michael Wallner Date: Tue, 12 Jan 2021 19:03:54 +0000 (+0100) Subject: fix build with libicu-dev not providing icu-config X-Git-Tag: v4.0.0~9 X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-http;a=commitdiff_plain;h=5b02bc7e61e06418cac7871485c89dcabeee42db;hp=89c9a0ff7f1469928cb4c9ff1a114005715449f2 fix build with libicu-dev not providing icu-config --- diff --git a/config9.m4 b/config9.m4 index 6a3c3e8..d653a7c 100644 --- a/config9.m4 +++ b/config9.m4 @@ -87,7 +87,11 @@ if test "$PHP_HTTP" != "no"; then if test "$PHP_HTTP_LIBICU_DIR" != "no"; then AC_PATH_PROG(ICU_CONFIG, icu-config, false, [$PHP_HTTP_LIBICU_DIR/bin:$PATH:/usr/local/bin]) - PECL_CHECK_CONFIG(libicu, [$ICU_CONFIG], [--version], [--cppflags], [--ldflags-searchpath], [--ldflags-libsonly]) + if $ICU_CONFIG --exists >/dev/null 2>/dev/null; then + PECL_CHECK_CONFIG(libicu, [$ICU_CONFIG], [--version], [--cppflags], [--ldflags-searchpath], [--ldflags-libsonly]) + else + PECL_CHECK_PKGCONFIG(icu-i18n, [$PHP_HTTP_LIBICU_DIR]) + fi AC_CACHE_CHECK([for uidna_IDNToASCII], PECL_CACHE_VAR([HAVE_UIDNA_IDNToASCII]), [ if printf "%s" "$CFLAGS" | $EGREP -q "(^|\s)-Werror\b"; then if ! printf "%s" "$CFLAGS" | $EGREP -q "(^|\s)-Wno-error=deprecated-declarations\b"; then