summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastien Estienne <sebastien.estienne@gmail.com>2005-10-17 20:41:59 +0000
committerSebastien Estienne <sebastien.estienne@gmail.com>2005-10-17 20:41:59 +0000
commit55f7dcb690bcbdf6bca6568e0d9aacb2456811a5 (patch)
treebfca70d02d516beca0fda35a2148337e16c32f4d
parent11fdf8612c684b0faf85781ef1b2766bf6ea1f0b (diff)
* autotools magic for PF_ROUTE (not the real thing yet).
git-svn-id: file:///home/lennart/svn/public/avahi/trunk@802 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe
-rw-r--r--avahi-core/Makefile.am5
-rw-r--r--avahi-core/iface.h2
-rw-r--r--configure.ac13
3 files changed, 20 insertions, 0 deletions
diff --git a/avahi-core/Makefile.am b/avahi-core/Makefile.am
index 1a78368..95505b8 100644
--- a/avahi-core/Makefile.am
+++ b/avahi-core/Makefile.am
@@ -80,6 +80,11 @@ if HAVE_NETLINK
libavahi_core_la_SOURCES += \
iface-linux.c iface-linux.h \
netlink.c netlink.h
+else
+if HAVE_PF_ROUTE
+libavahi_core_la_SOURCES += \
+ iface-pfroute.c iface-pfroute.h
+endif
endif
libavahi_core_la_CFLAGS = $(AM_CFLAGS)
diff --git a/avahi-core/iface.h b/avahi-core/iface.h
index 76b3540..14d0195 100644
--- a/avahi-core/iface.h
+++ b/avahi-core/iface.h
@@ -42,6 +42,8 @@ typedef struct AvahiHwInterface AvahiHwInterface;
#ifdef HAVE_NETLINK
#include "iface-linux.h"
+#elif defined(HAVE_PF_ROUTE)
+#include "iface-pfroute.h"
#else
#error "No network configuration notification system available"
#endif
diff --git a/configure.ac b/configure.ac
index 3bcffab..2ed9a8a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -102,6 +102,19 @@ AC_DEFINE([HAVE_NETLINK],[],[Support for Linux netlink])
AM_CONDITIONAL(HAVE_NETLINK, [ test x"$HAVE_NETLINK" = xyes ])
#
+# Check for net/route.h
+#
+AC_CHECK_HEADER(net/route.h,
+HAVE_PF_ROUTE=yes
+AC_DEFINE([HAVE_PF_ROUTE],[],[Support for PF_ROUTE])
+, [], [
+#include <sys/types.h>
+#include <sys/socket.h>
+])
+
+AM_CONDITIONAL(HAVE_PF_ROUTE, [ test x"$HAVE_PF_ROUTE" = xyes ])
+
+#
# Check for struct ip_mreqn
#
AC_MSG_CHECKING(for struct ip_mreqn)