1 | AC_INIT(gnome-pty.h) |
---|
2 | |
---|
3 | AM_INIT_AUTOMAKE(gnome-pty-helper,1.95.0) |
---|
4 | |
---|
5 | AC_ISC_POSIX |
---|
6 | AC_PROG_CC |
---|
7 | AC_STDC_HEADERS |
---|
8 | AM_PROG_CC_STDC |
---|
9 | |
---|
10 | AM_MAINTAINER_MODE |
---|
11 | |
---|
12 | PKG_CHECK_MODULES(GLIB,glib-2.0) |
---|
13 | AC_CHECK_HEADERS(sys/syslimits.h sys/time.h sys/types.h sys/un.h alloca.h lastlog.h libutil.h paths.h pty.h stropts.h termios.h ttyent.h util.h utmp.h utmpx.h pty.h util.h libutil.h ttyent.h) |
---|
14 | have_openpty=0 |
---|
15 | AC_CHECK_LIB(c,grantpt,true,[AC_CHECK_LIB(pt,grantpt)]) |
---|
16 | AC_CHECK_LIB(c,openpty,true,[AC_CHECK_LIB(util,openpty)]) |
---|
17 | AC_CHECK_LIB(c,sendmsg,true,[AC_CHECK_LIB(socket,sendmsg,LIBS="$LIBS -lsocket -lnsl",,-lnsl)]) |
---|
18 | AC_CHECK_FUNCS(endutent fcntl forkpty getttyent getutent getutmpx grantpt flock login_tty openpty revoke sendmsg seteuid setreuid setutent strrchr updwtmp updwtmpx utmpname utmpxname) |
---|
19 | GPH_CHECK_UTMP |
---|
20 | |
---|
21 | AC_CHECK_HEADERS(stropts.h) |
---|
22 | |
---|
23 | # Use all available features under glibc, and disable accidental use of |
---|
24 | # deprecated functionality. |
---|
25 | AC_EGREP_CPP(glibc, |
---|
26 | [ |
---|
27 | #include <stdio.h> |
---|
28 | #ifdef __GLIBC__ |
---|
29 | glibc |
---|
30 | #endif |
---|
31 | ], |
---|
32 | AC_DEFINE(_GNU_SOURCE,1,[Use all glibc features.])) |
---|
33 | AC_DEFINE(_XOPEN_SOURCE_EXTENDED,1,[Needed to get declarations for msg_control and msg_controllen on Solaris]) |
---|
34 | AC_DEFINE(_XOPEN_SOURCE,1,[Needed to get declarations for msg_control and msg_controllen on Solaris]) |
---|
35 | AC_DEFINE(__EXTENSIONS__,1,[Needed to get declarations for msg_control and msg_controllen on Solaris]) |
---|
36 | |
---|
37 | AM_CONFIG_HEADER(config.h) |
---|
38 | |
---|
39 | AC_OUTPUT(Makefile) |
---|