diff options
author | Fred Drake <fdrake@acm.org> | 2000-06-28 16:40:38 (GMT) |
---|---|---|
committer | Fred Drake <fdrake@acm.org> | 2000-06-28 16:40:38 (GMT) |
commit | 8cef4cf737878bd8eec648426eebe9b9019b18be (patch) | |
tree | 2fe93f0a2d3c9e22ad836a45bc7a526416c11c61 /configure.in | |
parent | 57823862683db7a463a134dbdf259d2e027619f6 (diff) | |
download | cpython-8cef4cf737878bd8eec648426eebe9b9019b18be.zip cpython-8cef4cf737878bd8eec648426eebe9b9019b18be.tar.gz cpython-8cef4cf737878bd8eec648426eebe9b9019b18be.tar.bz2 |
Thomas Wouters <thomas@xs4all.net>:
This patch adds the openpty() and forkpty() library calls to posixmodule.c,
when they are available on the target
system. (glibc-2.1-based Linux systems, FreeBSD and BSDI at least, probably
the other BSD-based systems as well.)
Lib/pty.py is also rewritten to use openpty when available, but falls
back to the old SGI method or the "manual" BSD open-a-pty
code. Openpty() is necessary to use the Unix98 ptys under Linux 2.2,
or when using non-standard tty names under (at least) BSDI, which is
why I needed it, myself ;-) forkpty() is included for symmetry.
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/configure.in b/configure.in index 6735b69..4944ec4 100644 --- a/configure.in +++ b/configure.in @@ -357,7 +357,7 @@ AC_CHECK_HEADERS(dlfcn.h fcntl.h limits.h locale.h ncurses.h pthread.h \ signal.h stdarg.h stddef.h stdlib.h thread.h unistd.h utime.h \ sys/audioio.h sys/file.h sys/lock.h \ sys/param.h sys/select.h sys/socket.h sys/time.h sys/times.h \ -sys/un.h sys/utsname.h sys/wait.h) +sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h) AC_HEADER_DIRENT # checks for typedefs @@ -771,6 +771,11 @@ AC_CHECK_FUNCS(alarm chown clock confstr ctermid ctermid_r dlopen execv \ tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ truncate uname waitpid) +# check for openpty and forkpty + +AC_CHECK_FUNCS(openpty,, AC_CHECK_LIB(util,openpty, [AC_DEFINE(HAVE_OPENPTY)] [LIBS="$LIBS -lutil"])) +AC_CHECK_FUNCS(forkpty,, AC_CHECK_LIB(util,forkpty, [AC_DEFINE(HAVE_FORKPTY)] [LIBS="$LIBS -lutil"])) + # check for long file support functions AC_CHECK_FUNCS(fseek64 fseeko fstatvfs ftell64 ftello statvfs) |