summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2004-09-29 20:13:05 +0000
committerLennart Poettering <lennart@poettering.net>2004-09-29 20:13:05 +0000
commit66999e5adaf54256718c638c3ad53acb0d74937b (patch)
treeb7890cf9f86d4e4b6b5d884e3f27136d3c2f0121 /configure.ac
parentd09240118ce0170c2fc5f504589646746902eb96 (diff)
Add support for libwrap
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@250 fefdeb5f-60dc-0310-8127-8f9354f1896f
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac19
1 files changed, 19 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index af766847..68df5b85 100644
--- a/configure.ac
+++ b/configure.ac
@@ -111,6 +111,25 @@ AC_SUBST(GLIB12_LIBS)
AC_SUBST(HAVE_GLIB12)
AM_CONDITIONAL([HAVE_GLIB12], [test "x$HAVE_GLIB12" = x1])
+AC_MSG_CHECKING([for tcpwrap library and headers])
+LIBWRAP_LIBS=
+saved_LIBS="$LIBS"
+LIBS="$LIBS -lwrap"
+AC_LINK_IFELSE(
+AC_LANG_PROGRAM(
+[#include <tcpd.h>
+#include <syslog.h>
+int allow_severity = LOG_INFO;
+int deny_severity = LOG_WARNING;],
+[struct request_info *req;
+return hosts_access (req);]),
+[AC_DEFINE(HAVE_LIBWRAP, [], [Have tcpwrap?])
+LIBWRAP_LIBS="-lwrap"
+AC_MSG_RESULT(yes)],
+[AC_MSG_RESULT(no)])
+AC_SUBST(LIBWRAP_LIBS)
+LIBS="$saved_LIBS"
+
# If using GCC specify some additional parameters
if test "x$GCC" = "xyes" ; then
CFLAGS="$CFLAGS -pipe -W -Wall -pedantic"