diff --git a/configure.ac b/configure.ac index eee1e3a60fddc..db0d9fa5cb091 100644 --- a/configure.ac +++ b/configure.ac @@ -1847,19 +1847,6 @@ if test -n "\$REDO_ALL"; then echo "creating main/internal_functions_cli.c" AWK="$AWK" sh $srcdir/build/genif.sh $srcdir/main/internal_functions.c.in "$EXT_CLI_STATIC" > main/internal_functions_cli.c - - if test "$PHP_SAPI" = "apache2handler"; then - if test -z "$APACHE_THREADED_MPM"; then -cat </dev/null | grep 'threaded:.*yes') AS_VAR_IF([APACHE_THREADED_MPM],,, [PHP_BUILD_THREAD_SAFE]) + +AC_CONFIG_COMMANDS([apache2handler], [AS_VAR_IF([enable_zts], [yes],, + [AS_VAR_IF([APACHE_THREADED_MPM],, + [AC_MSG_WARN([ ++--------------------------------------------------------------------+ +| *** WARNING *** | +| | +| You have built PHP for Apache's current non-threaded MPM. | +| If you change Apache to use a threaded MPM you must reconfigure | +| PHP with --enable-zts | ++--------------------------------------------------------------------+ + ])])])], + [APACHE_THREADED_MPM=$APACHE_THREADED_MPM; enable_zts=$enable_zts]) fi