--- rxvt-unicode/autoconf/configure.in 2006/01/16 14:48:39 1.72 +++ rxvt-unicode/autoconf/configure.in 2006/01/17 11:53:07 1.78 @@ -2,9 +2,9 @@ dnl# dnl# Process this file with autoconf to produce a configure script. dnl# -orig_CXXFLAGS="$CXXFLAGS" AC_INIT +AC_PREREQ(2.50) AC_CONFIG_SRCDIR([src/feature.h]) AC_CONFIG_AUX_DIR(autoconf) AC_CONFIG_HEADER(config.h:autoconf/config.h.in) @@ -25,6 +25,8 @@ echo "configuring for rxvt $VERSION" echo "" +orig_CXXFLAGS="$CXXFLAGS" + dnl# Checks for programs. dnl AC_MAKE_SET @@ -40,9 +42,10 @@ dnl# Supply default CFLAGS, if not specified by `CFLAGS=flags ./configure' dnl# if test -z "$orig_CXXFLAGS"; then - CXXFLAGS='-O' if test x$GCC = xyes && test "x$GXX" = xyes; then CXXFLAGS="-g -O3" + else + CXXFLAGS="-O" fi CFLAGS="$CXXFLAGS" fi @@ -300,11 +303,11 @@ support_scroll_plain=$enableval fi]) -AC_ARG_ENABLE(half-shadow, - [ --enable-half-shadow use half width/height shadow on rxvt scrollbar], - [if test x$enableval = xyes; then - AC_DEFINE(HALFSHADOW, 1, Define if you want the depth of scrollbars and menus to be less) - fi]) +dnl AC_ARG_ENABLE(half-shadow, +dnl [ --enable-half-shadow use half width/height shadow on rxvt scrollbar], +dnl [if test x$enableval = xyes; then +dnl AC_DEFINE(HALFSHADOW, 1, Define if you want the depth of scrollbars and menus to be less) +dnl fi]) AC_ARG_WITH(codesets, [ --with-codesets=NAME,.. compile in additional codesets (jp,jp_ext,kr,zh,zh_ext,all)], @@ -709,23 +712,14 @@ AC_TYPE_SIGNAL dnl> AC_FUNC_VPRINTF -dnl# Note: On Ultrix, setsid() does weirdo stuff, disable it -case "$host_alias" in - *ultrix) ac_cv_func_setsid='no' ;; - *) break;; -esac - AC_CHECK_FUNCS( \ - atexit \ revoke \ unsetenv \ setutent \ seteuid \ setreuid \ - setsid \ - setpgrp \ - setpgid \ _getpty \ + getpt \ posix_openpt \ grantpt \ unlockpt \ @@ -1165,7 +1159,7 @@ AC_DEFINE(XIMCB_PROTO_BROKEN, 1, Define if your XIMCallback specifies XIC as first type.) fi -if test x$ac_cv_func_posix_openpt = xno; then +if test x$ac_cv_func_getpt = xno -a x$ac_cv_func_posix_openpt = xno; then AC_CHECK_FUNC(openpty, [], [AC_CHECK_LIB(util, openpty, [LIBS="$LIBS -lutil"])]) fi @@ -1173,6 +1167,8 @@ AC_CACHE_CHECK(for pty/tty type, rxvt_cv_ptys, [if test x$ac_cv_func_openpty = xyes -o x$ac_cv_lib_util_openpty = xyes; then rxvt_cv_ptys=OPENPTY + else if test x$ac_cv_func_getpt = xyes; then + rxvt_cv_ptys=GLIBC else if test x$ac_cv_func_posix_openpt = xyes; then rxvt_cv_ptys=POSIX else if test x$ac_cv_func__getpty = xyes; then @@ -1201,8 +1197,12 @@ fi fi fi +fi ]) +if test x$rxvt_cv_ptys = xGLIBC; then + AC_DEFINE(PTYS_ARE_GETPT, 1, Define for this pty type) +fi if test x$rxvt_cv_ptys = xPOSIX; then AC_DEFINE(PTYS_ARE_POSIX, 1, Define for this pty type) fi @@ -1426,10 +1426,6 @@ AC_SUBST(X_LIBS) AC_SUBST(X_EXTRA_LIBS) -dnl# common parts of the Makefile -MCOMMON=./autoconf/Make.common -AC_SUBST_FILE(MCOMMON) - AC_ARG_PROGRAM dnl# test for "sun" or "__sun__" before include sys_ioctl @@ -1457,8 +1453,7 @@ RXVT_DEFINE_TO_INCLUDE(include_sys_time_h, sys/time.h, ac_cv_header_sys_time_h, yes, notset, dontmatch) RXVT_DEFINE_TO_INCLUDE(include_time_h, time.h, ac_cv_header_sys_time_h, no, ac_cv_header_time, yes) -AC_CONFIG_FILES([autoconf/Make.common \ -Makefile \ +AC_CONFIG_FILES([Makefile \ doc/Makefile \ src/Makefile \ src/rxvtlib.h \