aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog10
-rw-r--r--configure.ac58
2 files changed, 54 insertions, 14 deletions
diff --git a/ChangeLog b/ChangeLog
index 721ab3193b4..52266b07e53 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
12014-06-05 Paul Eggert <eggert@cs.ucla.edu>
2
3 Try harder to find GNU Make when configuring.
4 * configure.ac (AC_PROG_MAKE_SET): Define a dummy.
5 (MAKE): Set it to GNU Make, if one can be found.
6 Search PATH for 'make', 'gmake', 'gnumake'.
7 This works better on platforms like AIX, where GNU Make
8 might be in /opt/freeware/bin/make, and reside
9 behind /usr/bin/make in the PATH.
10
12014-06-05 Dmitry Antipov <dmantipov@yandex.ru> 112014-06-05 Dmitry Antipov <dmantipov@yandex.ru>
2 12
3 * configure.ac (POLL_FOR_INPUT): Define with HAVE_WINDOW_SYSTEM. 13 * configure.ac (POLL_FOR_INPUT): Define with HAVE_WINDOW_SYSTEM.
diff --git a/configure.ac b/configure.ac
index f5485942bd8..0beeedf47ae 100644
--- a/configure.ac
+++ b/configure.ac
@@ -92,7 +92,7 @@ AC_CHECK_PROGS(XCRUN, [xcrun])
92if test -n "$XCRUN"; then 92if test -n "$XCRUN"; then
93 if test -z "$MAKE"; then 93 if test -z "$MAKE"; then
94 dnl Call the variable MAKE_PROG, not MAKE, to avoid confusion with 94 dnl Call the variable MAKE_PROG, not MAKE, to avoid confusion with
95 dnl SET_MAKE and with the usual MAKE variable that 'make' itself uses. 95 dnl the usual MAKE variable that 'make' itself uses.
96 AC_CHECK_PROG([MAKE_PROG], [make], [yes]) 96 AC_CHECK_PROG([MAKE_PROG], [make], [yes])
97 if test -z "$MAKE_PROG"; then 97 if test -z "$MAKE_PROG"; then
98 MAKE="$XCRUN MAKE" 98 MAKE="$XCRUN MAKE"
@@ -102,6 +102,47 @@ if test -n "$XCRUN"; then
102 fi 102 fi
103fi 103fi
104 104
105dnl GNU Make is required, so don't test for its individual features.
106am_cv_make_support_nested_variables=yes
107AC_DEFUN([AC_PROG_MAKE_SET],
108 [SET_MAKE=
109 AC_SUBST([SET_MAKE])])
110
111dnl Check for GNU Make and possibly set MAKE before running AM_INIT_AUTOMAKE.
112AC_CACHE_CHECK([for GNU Make], [ac_cv_path_MAKE],
113 [ac_path_MAKE_found=false
114 if test -n "$MAKE"; then
115 emacs_makeout=`($MAKE --version) 2>/dev/null` &&
116 case $emacs_makeout in
117 'GNU Make '*)
118 ac_path_MAKE_found=:;;
119 esac
120 ac_cv_path_MAKE=$MAKE
121 else
122 emacs_tried_make=false
123 emacs_tried_gmake=false
124 emacs_tried_gnumake=false
125 AC_PATH_PROGS_FEATURE_CHECK([MAKE], [make gmake gnumake],
126 [[emacs_makeout=`($ac_path_MAKE --version) 2>/dev/null` &&
127 case $emacs_makeout in
128 'GNU Make '*)
129 # Use the fully-qualified program name only if the basename
130 # would not resolve to it.
131 if eval \$emacs_tried_$ac_prog; then
132 ac_cv_path_MAKE=$ac_path_MAKE
133 else
134 ac_cv_path_MAKE=$ac_prog
135 fi
136 ac_path_MAKE_found=:;;
137 esac
138 eval emacs_tried_$ac_prog=:]])
139 fi])
140$ac_path_MAKE_found || { AC_MSG_ERROR([[Building Emacs requires GNU Make.
141If you have it installed under another name, configure with 'MAKE=...'.
142For example, run '$0 MAKE=gnu-make'.]])
143}
144MAKE=$ac_cv_path_MAKE
145
105dnl Fairly arbitrary, older versions might work too. 146dnl Fairly arbitrary, older versions might work too.
106AM_INIT_AUTOMAKE(1.11) 147AM_INIT_AUTOMAKE(1.11)
107 148
@@ -659,18 +700,6 @@ Check `etc/MACHINES' for recognized configuration names.])
659fi 700fi
660 701
661 702
662AC_MSG_CHECKING([whether we are using GNU Make])
663testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
664if test "x$testval" != x; then
665 AC_MSG_RESULT([yes])
666else
667 AC_MSG_RESULT([no])
668 AC_MSG_ERROR([Building Emacs requires GNU make.
669If you have it installed under another name, configure with 'MAKE=...'.
670For example, run './configure MAKE=gmake'.])
671fi
672
673
674#### Choose a compiler. 703#### Choose a compiler.
675 704
676dnl Don't bother to test for C89. 705dnl Don't bother to test for C89.
@@ -1531,7 +1560,6 @@ dnl Check for endianness.
1531dnl AC_C_BIGENDIAN is done by gnulib. 1560dnl AC_C_BIGENDIAN is done by gnulib.
1532 1561
1533dnl check for Make feature 1562dnl check for Make feature
1534dnl AC_PROG_MAKE_SET is done by Automake.
1535 1563
1536DEPFLAGS= 1564DEPFLAGS=
1537MKDEPDIR=":" 1565MKDEPDIR=":"
@@ -5090,3 +5118,5 @@ fi
5090]) 5118])
5091 5119
5092AC_OUTPUT 5120AC_OUTPUT
5121
5122test "$MAKE" = make || AC_MSG_NOTICE([Now you can run '$MAKE'.])