use AC_SYS_POSIX_TERMIOS instead of rolling our own

This commit is contained in:
Todd C. Miller
2001-12-15 15:57:03 +00:00
parent f3970677ce
commit 313bbae1d3
2 changed files with 6 additions and 4 deletions

View File

@@ -333,9 +333,7 @@
#undef HAVE_TERMIO_H #undef HAVE_TERMIO_H
/* Define if you have the <termios.h> header file and tcgetattr(3). */ /* Define if you have the <termios.h> header file and tcgetattr(3). */
#ifdef HAVE_TCGETATTR
#undef HAVE_TERMIOS_H #undef HAVE_TERMIOS_H
#endif /* HAVE_TCGETATTR */
/* Define if you have the <sys/sockio.h> header file. */ /* Define if you have the <sys/sockio.h> header file. */
#undef HAVE_SYS_SOCKIO_H #undef HAVE_SYS_SOCKIO_H

View File

@@ -1516,8 +1516,12 @@ AC_HEADER_DIRENT
AC_CHECK_HEADERS(malloc.h paths.h utime.h netgroup.h sys/sockio.h sys/bsdtypes.h sys/select.h) AC_CHECK_HEADERS(malloc.h paths.h utime.h netgroup.h sys/sockio.h sys/bsdtypes.h sys/select.h)
dnl ultrix termio/termios are broken dnl ultrix termio/termios are broken
if test "$OS" != "ultrix"; then if test "$OS" != "ultrix"; then
AC_CHECK_HEADERS(termio.h) AC_SYS_POSIX_TERMIOS
AC_CHECK_HEADERS(termios.h, AC_CHECK_FUNCS(tcgetattr)) if test "$ac_cv_sys_posix_termios" = "yes"; then
AC_DEFINE(HAVE_TERMIOS_H)
else
AC_CHECK_HEADERS(termio.h)
fi
fi fi
if test "$with_logincap" = "yes"; then if test "$with_logincap" = "yes"; then
AC_CHECK_HEADERS(login_cap.h) AC_CHECK_HEADERS(login_cap.h)