+20020226
+ - (tim) Bug 12 [configure.ac] add sys/bitypes.h to int64_t tests
+ based on patch by mooney@dogbert.cc.ndsu.nodak.edu (Tim Mooney)
+ Bug 45 [configure.ac] modify skey test to work around conflict with autoconf
+ reported by nolan@naic.edu (Michael Nolan)
+ patch by Pekka Savola <pekkas@netcore.fi>
+ Bug 74 [configure.ac defines.h] add sig_atomic_t test
+ reported by dwd@bell-labs.com (Dave Dykstra)
+ Bug 102 [defines.h] UNICOS fixes. patch by wendyp@cray.com
+ [configure.ac Makefile.in] link libwrap only with sshd
+ based on patch by Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+ Bug 123 link libpam only with sshd
+ reported by peak@argo.troja.mff.cuni.cz (Pavel Kankovsky)
+ [configure.ac defines.h] modify previous SCO3 fix to not break Solaris 7
+ [acconfig.h] remove unused HAVE_REGCOMP
+
20020225
- (bal) Last AIX patch. Moved aix_usrinfo() outside of do_setuserconext()
since we need more session information than provided by that function.
]
)
+# Checks for header files.
+AC_CHECK_HEADERS(bstring.h crypt.h endian.h floatingpoint.h \
+ getopt.h glob.h lastlog.h limits.h login.h \
+ login_cap.h maillock.h netdb.h netgroup.h \
+ netinet/in_systm.h paths.h poll.h pty.h \
+ security/pam_appl.h shadow.h stddef.h stdint.h \
+ strings.h sys/bitypes.h sys/bsdtty.h sys/cdefs.h \
+ sys/poll.h sys/queue.h sys/select.h sys/stat.h \
+ sys/stropts.h sys/sysmacros.h sys/time.h \
+ sys/ttcompat.h sys/un.h time.h ttyent.h usersec.h \
+ util.h utime.h utmp.h utmpx.h)
+
# Checks for libraries.
AC_CHECK_FUNC(yp_match, , AC_CHECK_LIB(nsl, yp_match))
AC_CHECK_FUNC(setsockopt, , AC_CHECK_LIB(socket, setsockopt))
AC_FUNC_STRFTIME
-# Checks for header files.
-AC_CHECK_HEADERS(bstring.h crypt.h endian.h floatingpoint.h \
- getopt.h glob.h lastlog.h limits.h login.h \
- login_cap.h maillock.h netdb.h netgroup.h \
- netinet/in_systm.h paths.h poll.h pty.h \
- rpc/rpc.h \
- security/pam_appl.h shadow.h stddef.h stdint.h \
- strings.h sys/bitypes.h sys/bsdtty.h sys/cdefs.h \
- sys/poll.h sys/queue.h sys/select.h sys/stat.h \
- sys/stropts.h sys/sysmacros.h sys/time.h \
- sys/ttcompat.h sys/un.h time.h ttyent.h usersec.h \
- util.h utime.h utmp.h utmpx.h)
-
# Check for ALTDIRFUNC glob() extension
AC_MSG_CHECKING(for GLOB_ALTDIRFUNC support)
AC_EGREP_CPP(FOUNDIT,
LIBS="-lskey $LIBS"
SKEY_MSG="yes"
- AC_CHECK_FUNC(skey_keyinfo,
- [],
+ AC_MSG_CHECKING([for s/key support])
+ AC_TRY_RUN(
+ [
+#include <stdio.h>
+#include <skey.h>
+int main() { char *ff = skey_keyinfo(""); ff=""; return 0; }
+ ],
+ [AC_MSG_RESULT(yes)],
[
+ AC_MSG_RESULT(no)
AC_MSG_ERROR([** Incomplete or missing s/key libraries.])
])
fi
CPPFLAGS="-I${withval} ${CPPFLAGS}"
fi
fi
- LIBS="-lwrap $LIBS"
+ LIBWRAP="-lwrap"
+ LIBS="$LIBWRAP $LIBS"
AC_MSG_CHECKING(for libwrap)
AC_TRY_LINK(
[
[
AC_MSG_RESULT(yes)
AC_DEFINE(LIBWRAP)
+ AC_SUBST(LIBWRAP)
TCPW_MSG="yes"
],
[
AC_MSG_ERROR([*** libwrap missing])
]
)
+ LIBS="$saved_LIBS"
fi
]
)
PAM_MSG="yes"
AC_DEFINE(USE_PAM)
+ AC_SUBST(LIBPAM, ["-lpam -ldl"])
fi
]
)
PRNGD_SOCKET="$withval"
AC_DEFINE_UNQUOTED(PRNGD_SOCKET, "$PRNGD_SOCKET")
fi
+ ],
+ [
+ # Check for existing socket only if we don't have a random device already
+ if test "$USE_RAND_HELPER" = yes ; then
+ AC_MSG_CHECKING(for PRNGD/EGD socket)
+ # Insert other locations here
+ for sock in /var/run/egd-pool /dev/egd-pool /etc/entropy; do
+ if test -r $sock && $TEST_MINUS_S_SH -c "test -S $sock -o -p $sock" ; then
+ PRNGD_SOCKET="$sock"
+ AC_DEFINE_UNQUOTED(PRNGD_SOCKET, "$PRNGD_SOCKET")
+ break;
+ fi
+ done
+ if test ! -z "$PRNGD_SOCKET" ; then
+ AC_MSG_RESULT($PRNGD_SOCKET)
+ else
+ AC_MSG_RESULT(not found)
+ fi
+ fi
]
)
)
fi
+if test -z "$have_int64_t" ; then
+ AC_MSG_CHECKING([for int64_t type in sys/bitypes.h])
+ AC_TRY_COMPILE(
+ [ #include <sys/bitypes.h> ],
+ [ int64_t a; a = 1],
+ [
+ AC_DEFINE(HAVE_INT64_T)
+ AC_MSG_RESULT(yes)
+ ],
+ [ AC_MSG_RESULT(no) ]
+ )
+fi
+
AC_CACHE_CHECK([for u_intXX_t types], ac_cv_have_u_intxx_t, [
AC_TRY_COMPILE(
[ #include <sys/types.h> ],
have_u_int64_t=1
fi
+if test -z "$have_u_int64_t" ; then
+ AC_MSG_CHECKING([for u_int64_t type in sys/bitypes.h])
+ AC_TRY_COMPILE(
+ [ #include <sys/bitypes.h> ],
+ [ u_int64_t a; a = 1],
+ [
+ AC_DEFINE(HAVE_U_INT64_T)
+ AC_MSG_RESULT(yes)
+ ],
+ [ AC_MSG_RESULT(no) ]
+ )
+fi
+
if test -z "$have_u_intxx_t" ; then
AC_CACHE_CHECK([for uintXX_t types], ac_cv_have_uintxx_t, [
AC_TRY_COMPILE(
TYPE_SOCKLEN_T
+AC_CHECK_TYPES(sig_atomic_t)
+
AC_CACHE_CHECK([for size_t], ac_cv_have_size_t, [
AC_TRY_COMPILE(
[
AC_MSG_WARN([Please check and edit -blibpath in LDFLAGS in Makefile])
fi
+dnl remove pam and dl because they are in $LIBPAM
+if test "$PAM_MSG" = yes ; then
+ LIBS=`echo $LIBS | sed 's/-lpam -ldl //'`
+fi
+
AC_EXEEXT
AC_CONFIG_FILES([Makefile openbsd-compat/Makefile scard/Makefile ssh_prng_cmds])
AC_OUTPUT
echo " Compiler flags: ${CFLAGS}"
echo "Preprocessor flags: ${CPPFLAGS}"
echo " Linker flags: ${LDFLAGS}"
-echo " Libraries: ${LIBS}"
+echo " Libraries: ${LIBWRAP} ${LIBPAM} ${LIBS}"
echo ""
#include <netinet/in_systm.h> /* For typedefs */
#include <netinet/in.h> /* For IPv6 macros */
#include <netinet/ip.h> /* For IPTOS macros */
-#ifdef HAVE_RPC_RPC_H
-# include <rpc/rpc.h> /* For INADDR_LOOPBACK on SCO OSR3 */
-#endif
#ifdef HAVE_SYS_UN_H
# include <sys/un.h> /* For sockaddr_un */
#endif
# define NFDBITS (8 * sizeof(unsigned long))
#endif
+/*
+SCO Open Server 3 has INADDR_LOOPBACK defined in rpc/rpc.h but
+including rpc/rpc.h breaks Solaris 6
+*/
+#ifndef INADDR_LOOPBACK
+#define INADDR_LOOPBACK ((ulong)0x7f000001)
+#endif
+
/* Types */
/* If sys/types.h does not supply intXX_t, supply them ourselves */
typedef short int int16_t;
# else
# ifdef _CRAY
+# if (SIZEOF_SHORT_INT == 4)
+typedef short int16_t;
+# else
typedef long int16_t;
+# endif
# else
# error "16 bit int type not found."
# endif /* _CRAY */
typedef unsigned short int u_int16_t;
# else
# ifdef _CRAY
+# if (SIZEOF_SHORT_INT == 4)
+typedef unsigned short u_int16_t;
+# else
typedef unsigned long u_int16_t;
+# endif
# else
# error "16 bit int type not found."
# endif
# define HAVE_PID_T
#endif /* HAVE_PID_T */
+#ifndef HAVE_SIG_ATOMIC_T
+typedef int sig_atomic_t;
+# define HAVE_SIG_ATOMIC_T
+#endif /* HAVE_SIG_ATOMIC_T */
+
#ifndef HAVE_MODE_T
typedef int mode_t;
# define HAVE_MODE_T