svn commit: samba r25431 - in branches: SAMBA_3_2/source SAMBA_3_2_0/source

jra at samba.org jra at samba.org
Sat Sep 29 23:43:30 GMT 2007


Author: jra
Date: 2007-09-29 23:43:24 +0000 (Sat, 29 Sep 2007)
New Revision: 25431

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=25431

Log:
Add detection for IPv6 support.
Jeremy.

Modified:
   branches/SAMBA_3_2/source/configure.in
   branches/SAMBA_3_2_0/source/configure.in


Changeset:
Modified: branches/SAMBA_3_2/source/configure.in
===================================================================
--- branches/SAMBA_3_2/source/configure.in	2007-09-29 18:00:19 UTC (rev 25430)
+++ branches/SAMBA_3_2/source/configure.in	2007-09-29 23:43:24 UTC (rev 25431)
@@ -3085,6 +3085,26 @@
 fi
 fi
 
+dnl test for ipv6
+AC_CACHE_CHECK([for ipv6 support],samba_cv_HAVE_IPV6,[
+AC_TRY_COMPILE([
+#include <sys/socket.h>
+#include <sys/types.h>
+#include <netdb.h>],
+[
+struct sockaddr_storage sa_store;
+struct addrinfo *ai = NULL;
+int s = socket(AF_INET6, SOCK_STREAM, 0)
+int ret = getaddrinfo(NULL, NULL, NULL &ai);
+if (ret != 0) {
+	const char *es = gai_strerror(ret);
+}
+freeaddrinfo(ai);
+],
+samba_cv_HAVE_IPV6=yes,samba_cv_HAVE_IPV6=no)])
+if test x"$samba_cv_HAVE_IPV6" = x"yes"; then
+    AC_DEFINE(HAVE_IPV6,1,[Whether the system has IPv6 support])
+fi
 
 ################################################
 # look for a method of setting the effective uid

Modified: branches/SAMBA_3_2_0/source/configure.in
===================================================================
--- branches/SAMBA_3_2_0/source/configure.in	2007-09-29 18:00:19 UTC (rev 25430)
+++ branches/SAMBA_3_2_0/source/configure.in	2007-09-29 23:43:24 UTC (rev 25431)
@@ -2956,6 +2956,26 @@
 fi
 fi
 
+dnl test for ipv6
+AC_CACHE_CHECK([for ipv6 support],samba_cv_HAVE_IPV6,[
+AC_TRY_COMPILE([
+#include <sys/socket.h>
+#include <sys/types.h>
+#include <netdb.h>],
+[
+struct sockaddr_storage sa_store;
+struct addrinfo *ai = NULL;
+int s = socket(AF_INET6, SOCK_STREAM, 0)
+int ret = getaddrinfo(NULL, NULL, NULL &ai);
+if (ret != 0) {
+	const char *es = gai_strerror(ret);
+}
+freeaddrinfo(ai);
+],
+samba_cv_HAVE_IPV6=yes,samba_cv_HAVE_IPV6=no)])
+if test x"$samba_cv_HAVE_IPV6" = x"yes"; then
+    AC_DEFINE(HAVE_IPV6,1,[Whether the system has IPv6 support])
+fi
 
 ################################################
 # look for a method of setting the effective uid



More information about the samba-cvs mailing list