--- rxvt-unicode/autoconf/configure.in 2006/01/11 00:59:58 1.66 +++ rxvt-unicode/autoconf/configure.in 2006/01/16 14:23:26 1.71 @@ -99,7 +99,6 @@ MALLOC_TYPE=S -support_addstrings=no support_frills=yes support_inheritpixmap=yes support_tinting=yes @@ -390,12 +389,6 @@ RXVTNAME=`echo "$RXVTNAME"|sed "$program_transform_name"` AC_SUBST(RXVTNAME) -AC_ARG_ENABLE(strings, - [ --enable-strings enable some replacement system functions], - [if test x$enableval = xyes -o x$enableval = xno; then - support_addstrings=$enableval - fi]) - AC_ARG_ENABLE(swapscreen, [ --disable-swapscreen disable swap screen support], [if test x$enableval = xno; then @@ -741,8 +734,8 @@ setsid \ setpgrp \ setpgid \ - openpty \ _getpty \ + posix_openpt \ grantpt \ unlockpt \ isastream \ @@ -752,7 +745,6 @@ updwtmpx \ ttyslot \ ) -dnl# Note: On NetBSD, openpty() exists in libutil. Don't pull it in dnl# -------------------------------------------------------------------------- dnl# DO ALL UTMP AND WTMP CHECKING @@ -1182,27 +1174,22 @@ AC_DEFINE(XIMCB_PROTO_BROKEN, 1, Define if your XIMCallback specifies XIC as first type.) fi -AC_CACHE_CHECK(for getpt, rxvt_cv_func_getpt, -[AC_LINK_IFELSE([AC_LANG_PROGRAM([[#define _GNU_SOURCE -#ifdef HAVE_STDLIB_H -# include -#endif]], [[(void)getpt();]])],[rxvt_cv_func_getpt=yes],[rxvt_cv_func_getpt=no])]) -if test x$rxvt_cv_func_getpt = xyes; then - AC_DEFINE(HAVE_GETPT, 1, Define if you have _GNU_SOURCE getpt() ) +if test x$ac_cv_func_posix_openpt = xno; then + AC_CHECK_FUNC(openpty, [], [AC_CHECK_LIB(util, openpty, [LIBS="$LIBS -lutil"])]) fi dnl# if we don't guess right then it's up to the user AC_CACHE_CHECK(for pty/tty type, rxvt_cv_ptys, -[if test x$ac_cv_func_openpty = xyes; then +[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_posix_openpt = xyes; then + rxvt_cv_ptys=POSIX else if test x$ac_cv_func__getpty = xyes; then rxvt_cv_ptys=SGI4 else if test -c /dev/ttyp20; then rxvt_cv_ptys=SCO else if test -c /dev/ptym/clone; then rxvt_cv_ptys=HPUX - else if test x$rxvt_cv_func_getpt = xyes; then - rxvt_cv_ptys=GLIBC else if test -c /dev/ptc -a -c /dev/pts; then rxvt_cv_ptys=PTC else if test -c /dev/ptc -a -d /dev/pts; then @@ -1225,6 +1212,9 @@ fi ]) +if test x$rxvt_cv_ptys = xPOSIX; then + AC_DEFINE(PTYS_ARE_POSIX, 1, Define for this pty type) +fi if test x$rxvt_cv_ptys = xOPENPTY; then AC_DEFINE(PTYS_ARE_OPENPTY, 1, Define for this pty type) fi @@ -1240,16 +1230,10 @@ if test x$rxvt_cv_ptys = xSGI4; then AC_DEFINE(PTYS_ARE__GETPTY, 1, Define for this pty type) fi -if test x$rxvt_cv_ptys = xCONVEX; then - AC_DEFINE(PTYS_ARE_GETPTY, 1, Define for this pty type) -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 = xHPUX; then AC_DEFINE(PTYS_ARE_CLONE, 1, Define for this pty type) fi -if test x$rxvt_cv_ptys = xBSD -o x$rxvt_cv_ptys = xHPUX -o x$rxvt_cv_ptys = xGLIBC; then +if test x$rxvt_cv_ptys = xBSD -o x$rxvt_cv_ptys = xHPUX -o x$rxvt_cv_ptys = xPOSIX; then AC_DEFINE(PTYS_ARE_SEARCHED, 1, Define for this pty type) fi @@ -1424,7 +1408,7 @@ AC_SUBST(IF_PERL) AC_SUBST(PERL_O) -if text x$support_perl = xyes; then +if test x$support_perl = xyes; then support_frills=yes fi @@ -1454,10 +1438,6 @@ AC_SUBST(X_LIBS) AC_SUBST(X_EXTRA_LIBS) -if test x$support_addstrings = xno; then - AC_DEFINE(NO_STRINGS, 1, Define if you don't need to use our replacement string functions) -fi - dnl# common parts of the Makefile MCOMMON=./autoconf/Make.common AC_SUBST_FILE(MCOMMON)