ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/libptytty/ptytty.m4
(Generate patch)

Comparing libptytty/ptytty.m4 (file contents):
Revision 1.27 by sf-exg, Wed Jul 6 10:04:02 2011 UTC vs.
Revision 1.28 by sf-exg, Thu Nov 10 16:30:16 2011 UTC

53 seteuid \ 53 seteuid \
54 setreuid \ 54 setreuid \
55 setresuid \ 55 setresuid \
56) 56)
57 57
58have_clone=no
59
60AC_MSG_CHECKING(for /dev/ptc)
61if test -e /dev/ptc; then
62 AC_MSG_RESULT(yes)
63 AC_DEFINE(CLONE_DEVICE, "/dev/ptc", [clone device filename])
64 have_clone=yes
65else
66 AC_MSG_RESULT(no)
67fi
68
69case $host in
70 *-*-cygwin*)
71 have_clone=yes
72 AC_DEFINE(CLONE_DEVICE, "/dev/ptmx", [clone device filename])
73 ;;
74 *)
75 AC_MSG_CHECKING(for /dev/ptmx)
76 if test -e /dev/ptmx; then
77 AC_MSG_RESULT(yes)
78 AC_DEFINE(HAVE_DEV_PTMX, 1, [Define to 1 if you have /dev/ptmx])
79 AC_DEFINE(CLONE_DEVICE, "/dev/ptmx", [clone device filename])
80 have_clone=yes
81 else
82 AC_MSG_RESULT(no)
83 fi
84 ;;
85esac
86
87if test x$ac_cv_func_getpt = xyes -o x$ac_cv_func_posix_openpt = xyes -o x$have_clone = xyes; then
88 AC_MSG_CHECKING(for UNIX98 ptys) 58 AC_MSG_CHECKING(for UNIX98 ptys)
89 AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <stdlib.h>]], 59 AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <stdlib.h>]],
90 [[grantpt(0);unlockpt(0);ptsname(0);]])], 60 [[grantpt(0);unlockpt(0);ptsname(0);]])],
91 [unix98_pty=yes 61 [unix98_pty=yes
92 AC_DEFINE(UNIX98_PTY, 1, "") 62 AC_DEFINE(UNIX98_PTY, 1, "")
93 AC_MSG_RESULT(yes)], 63 AC_MSG_RESULT(yes)],
94 [AC_MSG_RESULT(no)]) 64 [AC_MSG_RESULT(no)])
95fi
96 65
97if test -z "$unix98_pty"; then 66if test -z "$unix98_pty"; then
98 AC_SEARCH_LIBS(openpty, util, AC_DEFINE(HAVE_OPENPTY, 1, "")) 67 AC_SEARCH_LIBS(openpty, util, AC_DEFINE(HAVE_OPENPTY, 1, ""))
99fi 68fi
100]) 69])

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines