From: Jani Taskinen Date: Mon, 6 Aug 2007 14:33:06 +0000 (+0000) Subject: - Fixed bug #42195 (C++ compiler required always) X-Git-Tag: RELEASE_1_2_1~128 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=99139b574ddc2b48c452a17c3c5bc1d1722b0272;p=php - Fixed bug #42195 (C++ compiler required always) --- diff --git a/configure.in b/configure.in index 02c6f28c9c..64abaac54e 100644 --- a/configure.in +++ b/configure.in @@ -1156,7 +1156,13 @@ PHP_HELP_SEPARATOR([Libtool:]) PHP_CONFIGURE_PART(Configuring libtool) LDFLAGS="$LDFLAGS $PHP_AIX_LDFLAGS" + +dnl Only allow AC_PROG_CXX if it's explicitly called (by PHP_REQUIRE_CXX) +dnl otherwise AC_PROG_LIBTOOL fails if there is no working C++ compiler +AC_PROVIDE_IFELSE([PHP_REQUIRE_CXX], [AC_PROG_CXX], [undefine([AC_PROG_CXX]) +AC_DEFUN([AC_PROG_CXX], [])]) AC_PROG_LIBTOOL + if test "$enable_debug" != "yes"; then PHP_SET_LIBTOOL_VARIABLE([--silent]) fi diff --git a/scripts/phpize.m4 b/scripts/phpize.m4 index 28f6913b84..a46dc8bc85 100644 --- a/scripts/phpize.m4 +++ b/scripts/phpize.m4 @@ -68,6 +68,10 @@ sinclude(config.m4) enable_static=no enable_shared=yes +dnl Only allow AC_PROG_CXX if it's explicitly called (by PHP_REQUIRE_CXX) +dnl otherwise AC_PROG_LIBTOOL fails if there is no working C++ compiler +AC_PROVIDE_IFELSE([PHP_REQUIRE_CXX], [AC_PROG_CXX], [undefine([AC_PROG_CXX]) +AC_DEFUN([AC_PROG_CXX], [])]) AC_PROG_LIBTOOL all_targets='$(PHP_MODULES)'