• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1AC_DEFUN([ACX_LIBWRAP], [
2LIBWRAP_LIBS=
3saved_LIBS="$LIBS"
4LIBS="$LIBS -lwrap"
5AC_MSG_CHECKING([for tcpwrap library and headers])
6AC_LINK_IFELSE(
7[AC_LANG_PROGRAM(
8[#include <tcpd.h>
9#include <syslog.h>
10int allow_severity = LOG_INFO;
11int deny_severity = LOG_WARNING;],
12[struct request_info *req;
13return hosts_access (req);])],
14[AC_DEFINE(HAVE_LIBWRAP, [], [Have tcpwrap?])
15LIBWRAP_LIBS="-lwrap"
16AC_MSG_RESULT(yes)],
17[AC_MSG_RESULT(no)])
18LIBS="$saved_LIBS"
19])
20