dnl along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
AC_PREREQ(2.65)
-AC_INIT(emacs, 24.0.92)
+AC_INIT(emacs, 24.0.96)
AC_CONFIG_HEADER(src/config.h:src/config.in)
AC_CONFIG_SRCDIR(src/lisp.h)
AC_CONFIG_AUX_DIR(build-aux)
NS_OBJ=
NS_OBJC_OBJ=
if test "${HAVE_NS}" = yes; then
+ if test "$with_toolkit_scroll_bars" = "no"; then
+ AC_MSG_ERROR([Non-toolkit scroll bars are not implemented for Nextstep.])
+ fi
+
window_system=nextstep
with_xft=no
# set up packaging dirs
CPPFLAGS=$OLD_CPPFLAGS
fi
fi
+ AC_CHECK_HEADER([Xm/BulletinB.h], [],
+ [AC_MSG_ERROR([Motif toolkit requested but requirements not found.])])
fi
dnl Use toolkit scroll bars if configured for GTK or X toolkit and either
AC_DEFINE(USE_TOOLKIT_SCROLL_BARS)
HAVE_XAW3D=no
USE_TOOLKIT_SCROLL_BARS=yes
- elif test "${HAVE_XAW3D}" = "yes"; then
+ elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
AC_DEFINE(USE_TOOLKIT_SCROLL_BARS)
USE_TOOLKIT_SCROLL_BARS=yes
fi
# It's better to believe a function is not available
# than to expect to find it in ncurses.
# Also we need tputs and friends to be able to build at all.
-have_tputs_et_al=true
+AC_MSG_CHECKING([for library containing tputs])
+# Run a test program that contains a call to tputs, a call that is
+# never executed. This tests whether a pre-'main' dynamic linker
+# works with the library. It's too much trouble to actually call
+# tputs in the test program, due to portability hassles. When
+# cross-compiling, assume the test program will run if it links.
+AC_DEFUN([tputs_link_source], [
+ AC_LANG_SOURCE(
+ [[extern void tputs (const char *, int, int (*)(int));
+ int main (int argc, char **argv)
+ {
+ if (argc == 10000)
+ tputs (argv[0], 0, 0);
+ return 0;
+ }]])
+])
# Maybe curses should be tried earlier?
# See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
-AC_SEARCH_LIBS(tputs, [ncurses terminfo termcap curses], , have_tputs_et_al=false)
-if test "$have_tputs_et_al" != true; then
+for tputs_library in '' ncurses terminfo termcap curses; do
+ OLIBS=$LIBS
+ if test -z "$tputs_library"; then
+ LIBS_TERMCAP=
+ msg='none required'
+ else
+ LIBS_TERMCAP=-l$tputs_library
+ msg=$LIBS_TERMCAP
+ LIBS="$LIBS_TERMCAP $LIBS"
+ fi
+ AC_RUN_IFELSE([tputs_link_source], [], [msg=no],
+ [AC_LINK_IFELSE([tputs_link_source], [], [msg=no])])
+ LIBS=$OLIBS
+ if test "X$msg" != Xno; then
+ break
+ fi
+done
+AC_MSG_RESULT([$msg])
+if test "X$msg" = Xno; then
AC_MSG_ERROR([The required function `tputs' was not found in any library.
These libraries were tried: libncurses, libterminfo, libtermcap, libcurses.
Please try installing whichever of these libraries is most appropriate
## freebsd < 40000, ms-w32, msdos, netbsd < 599002500, and
## darwin|gnu without ncurses.
TERMINFO=no
-LIBS_TERMCAP=
case "$opsys" in
## cygwin: Fewer environment variables to go wrong, more terminal types.
## hpux10-20: Use the system provided termcap(3) library.
;;
netbsd)
- if test $ac_cv_search_tputs = -lterminfo; then
+ if test "x$LIBS_TERMCAP" = "x-lterminfo"; then
TERMINFO=yes
- LIBS_TERMCAP="-lterminfo"
else
LIBS_TERMCAP="-ltermcap"
fi
TERMCAP_OBJ=tparam.o
if test $TERMINFO = yes; then
AC_DEFINE(TERMINFO, 1, [Define to 1 if you use terminfo instead of termcap.])
-
- ## Default used to be -ltermcap. Add a case above if need something else.
- test "x$LIBS_TERMCAP" = "x" && LIBS_TERMCAP="-lcurses"
-
TERMCAP_OBJ=terminfo.o
fi
AC_SUBST(LIBS_TERMCAP)
## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
## had different values in configure (in ac_link) and src/Makefile.in.
## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
- gnu-linux) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_AUX)" ;;
+ gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_AUX_RPATH)" ;;
*) LD_SWITCH_SYSTEM_TEMACS= ;;
esac