1 dnl ## Check for libraries
3 AC_CHECK_LIB(nsl, gethostname, [
4 AC_ADD_LIBRARY(nsl) ], [])
6 AC_CHECK_LIB(socket, socket, [
7 AC_ADD_LIBRARY(socket) ], [])
9 AC_CHECK_LIB(nsl, gethostbyaddr, [
10 AC_ADD_LIBRARY(nsl) ], [])
12 AC_CHECK_LIB(crypt, crypt, [
14 AC_DEFINE(HAVE_CRYPT)], [])
16 AC_CHECK_LIB(c, crypt, [
17 AC_DEFINE(HAVE_CRYPT)], [])
19 dnl ## Check for header files
31 dnl ## Check for typedefs, structures, and compiler characteristics.
34 AC_CACHE_CHECK([for tm_gmtoff in struct tm], ac_cv_struct_tm_gmtoff,
35 [AC_TRY_COMPILE([#include <sys/types.h>
36 #include <$ac_cv_struct_tm>], [struct tm tm; tm.tm_gmtoff;],
37 ac_cv_struct_tm_gmtoff=yes, ac_cv_struct_tm_gmtoff=no)])
39 if test "$ac_cv_struct_tm_gmtoff" = "yes"; then
40 AC_DEFINE(HAVE_GMTOFF)
43 dnl ## Check for library functions