1 AC_DEFUN([OPENAFS_LIBRARY_CHECKS],[
2 if test "x${MKAFS_OSTYPE}" = "xIRIX"; then
3 echo Skipping library tests because they confuse Irix.
5 AC_SEARCH_LIBS([socket], [socket inet])
6 AC_SEARCH_LIBS([connect], [nsl])
7 AC_SEARCH_LIBS([gethostbyname], [dns nsl resolv])
9 dnl darwin wants it, aix hates it
10 AC_MSG_CHECKING(for the useability of arpa/nameser_compat.h)
16 #include <sys/types.h>
17 #include <sys/socket.h>
18 #include <netinet/in.h>
19 #include <arpa/inet.h>
20 #include <arpa/nameser.h>
21 #include <arpa/nameser_compat.h>
24 [[static int i; i = 0;]])],
26 AC_DEFINE(HAVE_ARPA_NAMESER_COMPAT_H, 1,
27 [define if arpa/nameser_compat.h exists])],
30 openafs_save_libs="$LIBS"
31 AC_MSG_CHECKING([for res_search])
34 if test "$ac_cv_func_res_search" = no; then
35 for lib in dns nsl resolv; do
36 if test "$ac_cv_func_res_search" != yes; then
39 LIBS="$openafs_save_libs"
42 if test "$ac_cv_func_res_search" = yes; then
44 AC_DEFINE(HAVE_RES_SEARCH, 1, [])
45 AC_MSG_RESULT([yes, in lib$lib])
50 AC_DEFINE(HAVE_RES_SEARCH, 1, [])
55 XLIBS="$LIB_AFSDB $XLIBS"