diff options
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 47 |
1 files changed, 36 insertions, 11 deletions
diff --git a/configure.in b/configure.in index b5ffee79e..7bb96270a 100644 --- a/configure.in +++ b/configure.in | |||
@@ -9,10 +9,25 @@ AC_PROG_CPP | |||
9 | AC_PROG_RANLIB | 9 | AC_PROG_RANLIB |
10 | AC_PROG_INSTALL | 10 | AC_PROG_INSTALL |
11 | AC_CHECK_PROG(AR, ar, ar) | 11 | AC_CHECK_PROG(AR, ar, ar) |
12 | |||
13 | dnl Check for the path to xauth | ||
14 | AC_PATH_PROG(xauth_path, xauth) | 12 | AC_PATH_PROG(xauth_path, xauth) |
15 | AC_DEFINE_UNQUOTED(XAUTH_PATH, "$xauth_path") | 13 | |
14 | dnl Use ip address instead of hostname in $DISPLAY | ||
15 | AC_ARG_WITH(rsh, | ||
16 | [ --with-rsh=PATH Specify path to remote shell program ], | ||
17 | [ | ||
18 | AC_DEFINE_UNQUOTED(RSH_PATH, "$withval") | ||
19 | ], | ||
20 | [ | ||
21 | AC_PATH_PROG(rsh_path, rsh) | ||
22 | ] | ||
23 | ) | ||
24 | |||
25 | if test ! -z "$xauth_path" ; then | ||
26 | AC_DEFINE_UNQUOTED(XAUTH_PATH, "$xauth_path") | ||
27 | fi | ||
28 | if test ! -z "$rsh_path" ; then | ||
29 | AC_DEFINE_UNQUOTED(RSH_PATH, "$rsh_path") | ||
30 | fi | ||
16 | 31 | ||
17 | dnl Checks for compiler characteristics | 32 | dnl Checks for compiler characteristics |
18 | if test "$GCC" = "yes"; then CFLAGS="$CFLAGS -Wall"; fi | 33 | if test "$GCC" = "yes"; then CFLAGS="$CFLAGS -Wall"; fi |
@@ -27,6 +42,7 @@ case "$host" in | |||
27 | fi | 42 | fi |
28 | CFLAGS="$CFLAGS -D_HPUX_SOURCE" | 43 | CFLAGS="$CFLAGS -D_HPUX_SOURCE" |
29 | AC_DEFINE(IPADDR_IN_DISPLAY) | 44 | AC_DEFINE(IPADDR_IN_DISPLAY) |
45 | AC_DEFINE(USE_UTMPX) | ||
30 | AC_MSG_CHECKING(for HPUX trusted system password database) | 46 | AC_MSG_CHECKING(for HPUX trusted system password database) |
31 | if test -f /tcb/files/auth/system/default; then | 47 | if test -f /tcb/files/auth/system/default; then |
32 | AC_MSG_RESULT(yes) | 48 | AC_MSG_RESULT(yes) |
@@ -80,15 +96,22 @@ AC_CHECK_LIB(util, login, AC_DEFINE(HAVE_LIBUTIL_LOGIN) LIBS="$LIBS -lutil") | |||
80 | AC_CHECK_LIB(nsl, yp_match, , ) | 96 | AC_CHECK_LIB(nsl, yp_match, , ) |
81 | AC_CHECK_LIB(socket, main, , ) | 97 | AC_CHECK_LIB(socket, main, , ) |
82 | 98 | ||
83 | dnl libdl is needed by PAM on Redhat systems | 99 | dnl Use ip address instead of hostname in $DISPLAY |
84 | AC_CHECK_LIB(dl, dlopen, , ) | 100 | AC_ARG_WITH(pam, |
85 | AC_CHECK_LIB(pam, pam_authenticate, , ) | 101 | [ --without-pam Disable PAM support ], |
102 | [ | ||
103 | if test "x$withval" != "xno" ; then | ||
104 | AC_CHECK_LIB(dl, dlopen, , ) | ||
105 | AC_CHECK_LIB(pam, pam_authenticate, , ) | ||
106 | fi | ||
107 | ] | ||
108 | ) | ||
86 | 109 | ||
87 | dnl Checks for header files. | 110 | dnl Checks for header files. |
88 | AC_CHECK_HEADERS(endian.h lastlog.h login.h maillock.h netgroup.h paths.h poll.h pty.h shadow_h util.h utmp.h utmpx.h sys/bsdtty.h sys/poll.h sys/select.h sys/stropts.h sys/time.h) | 111 | AC_CHECK_HEADERS(endian.h lastlog.h login.h maillock.h netgroup.h paths.h poll.h pty.h shadow.h util.h utmp.h utmpx.h sys/bsdtty.h sys/poll.h sys/select.h sys/stropts.h sys/time.h sys/ttcompat.h) |
89 | 112 | ||
90 | dnl Checks for library functions. | 113 | dnl Checks for library functions. |
91 | AC_CHECK_FUNCS(arc4random mkdtemp openpty _getpty setenv seteuid setlogin setproctitle setreuid snprintf strlcat strlcpy vsnprintf) | 114 | AC_CHECK_FUNCS(arc4random updwtmpx mkdtemp openpty _getpty innetgr setenv seteuid setlogin setproctitle setreuid snprintf strlcat strlcpy vsnprintf) |
92 | 115 | ||
93 | AC_CHECK_FUNC(login, | 116 | AC_CHECK_FUNC(login, |
94 | [AC_DEFINE(HAVE_LOGIN)], | 117 | [AC_DEFINE(HAVE_LOGIN)], |
@@ -220,19 +243,21 @@ if test -z "$RANDOM_POOL" -a -z "$EGD_POOL"; then | |||
220 | AC_MSG_ERROR([No random device found, and no EGD random pool specified]) | 243 | AC_MSG_ERROR([No random device found, and no EGD random pool specified]) |
221 | fi | 244 | fi |
222 | 245 | ||
223 | dnl Check for ut_host field in utmp | ||
224 | AC_MSG_CHECKING([whether utmp.h has ut_host field]) | 246 | AC_MSG_CHECKING([whether utmp.h has ut_host field]) |
225 | AC_EGREP_HEADER(ut_host, utmp.h, | 247 | AC_EGREP_HEADER(ut_host, utmp.h, |
226 | [AC_DEFINE(HAVE_HOST_IN_UTMP) AC_MSG_RESULT(yes); ], | 248 | [AC_DEFINE(HAVE_HOST_IN_UTMP) AC_MSG_RESULT(yes); ], |
227 | [AC_MSG_RESULT(no)] | 249 | [AC_MSG_RESULT(no)] |
228 | ) | 250 | ) |
229 | |||
230 | dnl Check for ut_host field in utmpx | ||
231 | AC_MSG_CHECKING([whether utmpx.h has ut_host field]) | 251 | AC_MSG_CHECKING([whether utmpx.h has ut_host field]) |
232 | AC_EGREP_HEADER(ut_host, utmpx.h, | 252 | AC_EGREP_HEADER(ut_host, utmpx.h, |
233 | [AC_DEFINE(HAVE_HOST_IN_UTMPX) AC_MSG_RESULT(yes); ], | 253 | [AC_DEFINE(HAVE_HOST_IN_UTMPX) AC_MSG_RESULT(yes); ], |
234 | [AC_MSG_RESULT(no)] | 254 | [AC_MSG_RESULT(no)] |
235 | ) | 255 | ) |
256 | AC_MSG_CHECKING([whether utmpx.h has syslen field]) | ||
257 | AC_EGREP_HEADER(syslen, utmpx.h, | ||
258 | [AC_DEFINE(HAVE_SYSLEN_IN_UTMPX) AC_MSG_RESULT(yes); ], | ||
259 | [AC_MSG_RESULT(no)] | ||
260 | ) | ||
236 | 261 | ||
237 | dnl Look for lastlog location | 262 | dnl Look for lastlog location |
238 | AC_ARG_WITH(lastlog, | 263 | AC_ARG_WITH(lastlog, |