1diff --git a/ext/gettext/config.m4 b/ext/gettext/config.m4
2index e46acf0928..ee8e5a88f8 100644
3--- a/ext/gettext/config.m4
4+++ b/ext/gettext/config.m4
5@@ -4,9 +4,7 @@ PHP_ARG_WITH([gettext],
6 [Include GNU gettext support])])
7
8 if test "$PHP_GETTEXT" != "no"; then
9- for i in $PHP_GETTEXT /usr/local /usr; do
10- AS_IF([test -r $i/include/libintl.h], [GETTEXT_DIR=$i; break;])
11- done
12+ GETTEXT_DIR=$PHP_GETTEXT
13
14 AS_VAR_IF([GETTEXT_DIR],,
15 [AC_MSG_ERROR([Cannot locate header file libintl.h])])
16diff --git a/sapi/apache2handler/config.m4 b/sapi/apache2handler/config.m4
17index e335721f19..a5087e1320 100644
18--- a/sapi/apache2handler/config.m4
19+++ b/sapi/apache2handler/config.m4
20@@ -68,7 +68,7 @@ if test "$PHP_APXS2" != "no"; then
21 AS_VERSION_COMPARE([$APACHE_VERSION], [2.4.0],
22 [AC_MSG_ERROR([Please note that Apache version >= 2.4 is required])])
23
24- APXS_LIBEXECDIR='$(INSTALL_ROOT)'$($APXS -q LIBEXECDIR)
25+ APXS_LIBEXECDIR="$prefix/modules"
26 if test -z $($APXS -q SYSCONFDIR); then
27 INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
28 $APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \