summaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
authorjorton <jorton@13f79535-47bb-0310-9956-ffa450edef68>2005-02-15 12:01:00 +0000
committerjorton <jorton@13f79535-47bb-0310-9956-ffa450edef68>2005-02-15 12:01:00 +0000
commitc5820007158413de6ba666eb49e3007f22f3e82b (patch)
tree5b49691b82af60f8e8ef7d6e5a2a87e52184617b /build
parent3593495faddac3c636d04a07f07d54504349a137 (diff)
downloadlibapr-c5820007158413de6ba666eb49e3007f22f3e82b.tar.gz
Fix HP-UX 11.00 build, where the IP multicast interfaces are not
declared if _XOPEN_SOURCE_EXTENDED is defined (which apr_hints.m4 does): * build/apr_network.m4 (APR_CHECK_MCAST): New macro. * configure.in: Use APR_CHECK_MCAST. * network_io/unix/multicast.c: Make implementation conditional on HAVE_STRUCT_IPMREQ. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@153932 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'build')
-rw-r--r--build/apr_network.m416
1 files changed, 16 insertions, 0 deletions
diff --git a/build/apr_network.m4 b/build/apr_network.m4
index a16cf7930..0e1b09614 100644
--- a/build/apr_network.m4
+++ b/build/apr_network.m4
@@ -667,6 +667,22 @@ else
fi
])
+dnl APR_CHECK_MCAST: check for multicast interfaces
+AC_DEFUN([APR_CHECK_MCAST], [
+AC_CACHE_CHECK([for struct ip_mreq], [apr_cv_struct_ipmreq], [
+AC_TRY_COMPILE([
+#include <sys/types.h>
+#include <netinet/in.h>
+], [
+ struct ip_mreq mip;
+ mip.imr_interface.s_addr = INADDR_ANY;
+], [apr_cv_struct_ipmreq=yes], [apr_cv_struct_ipmreq=no], [apr_cv_struct_ipmreq=yes])])
+
+if test $apr_cv_struct_ipmreq = yes; then
+ AC_DEFINE([HAVE_STRUCT_IPMREQ], 1, [Define if struct impreq was found])
+fi
+])
+
dnl
dnl APR_CHECK_H_ERRNO_FLAG
dnl