]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
We always want IPv6
authorOndřej Surý <ondrej@sury.org>
Tue, 21 Aug 2018 09:28:24 +0000 (11:28 +0200)
committerOndřej Surý <ondrej@sury.org>
Tue, 28 Aug 2018 08:31:47 +0000 (10:31 +0200)
acconfig.h
bin/tests/system/conf.sh.in
bin/tests/system/conf.sh.win32
config.h.in
config.h.win32
configure
configure.in
lib/isc/tests/socket_test.c
lib/isc/unix/net.c
lib/isc/win32/net.c
lib/ns/interfacemgr.c

index d0b557693ad1bff85ebbdbc774ea873a9b478cee..2be46d28783e58036813ea4009bfbcf1eb876771 100644 (file)
@@ -65,9 +65,6 @@
  */
 #undef CALL_PTHREAD_SETCONCURRENCY
 
-/** define if IPv6 is not disabled */
-#undef WANT_IPV6
-
 /** define if flockfile() is available */
 #undef HAVE_FLOCKFILE
 
index d3837db9a3c0ebab1c204cd0509d338f054d5989..6c77ce7e5884d0ac362701743e7820186337d165 100644 (file)
@@ -138,11 +138,7 @@ else
        TESTSOCK6=false
 fi
 
-if grep "^#define WANT_IPV6 1" $TOP/config.h > /dev/null 2>&1 ; then
-        TESTSOCK6="$TESTSOCK6"
-else
-        TESTSOCK6=false
-fi
+TESTSOCK6="$TESTSOCK6"
 
 # Windows process management leave empty
 PSSUSPEND=
index 6b5c8639b7d1bb9c338cbe63a34979711e7b5baf..4335cd60a7c597dd2f980c5c5dce22c6ed87254f 100644 (file)
@@ -107,7 +107,7 @@ PARALLELDIRS="allow_query catz rpzrecurse serve-stale"
 SUBDIRS="$SEQUENTIALDIRS $PARALLELDIRS"
 
 # missing: chain integrity
-# extra: dname ednscompliance forward 
+# extra: dname ednscompliance forward
 
 #Things that are different on Windows
 KILL="/bin/kill -f"
@@ -117,7 +117,7 @@ DOS2UNIX=dos2unix
 TP=
 
 # Configure is launched from native environment, but tests are run in Cygwin -
-# so any detection is unreliable. 
+# so any detection is unreliable.
 SHELL="/bin/bash -o igncr"
 CURL=/usr/bin/curl
 XMLLINT=/usr/bin/xmllint
@@ -135,11 +135,7 @@ else
        TESTSOCK6=false
 fi
 
-if grep "^#define WANT_IPV6 1" $TOP/config.h > /dev/null 2>&1 ; then
-        TESTSOCK6="$TESTSOCK6"
-else
-        TESTSOCK6=false
-fi
+TESTSOCK6="$TESTSOCK6"
 
 #
 # PsSuspend is part of PSTools and can be downloaded from
index 8823a42ddc060ff350b19a0242dd301eb55206f3..f94ef6ea3b888d665b3a2c738ede8ba6a5a67f65 100644 (file)
@@ -65,9 +65,6 @@
  */
 #undef CALL_PTHREAD_SETCONCURRENCY
 
-/** define if IPv6 is not disabled */
-#undef WANT_IPV6
-
 /** define if flockfile() is available */
 #undef HAVE_FLOCKFILE
 
index a907da5a0c9f88cf49b681511f42100b3d2e1c6f..85510eeb0d456682f8559b5e5ee39d582e88b976 100644 (file)
@@ -141,8 +141,6 @@ char *getpassphrase(const char *);
  */
 #define ISC_DLZ_DLOPEN 1
 
-#define WANT_IPV6
-
 #define S_IFMT   _S_IFMT         /* file type mask */
 #define S_IFDIR  _S_IFDIR        /* directory */
 #define S_IFCHR  _S_IFCHR        /* character special */
index 6f2d3ea112a241f74feffba47a9ce9f65d7a0d88..cd89b5726c4b515d9479462332c010f8c9e28c88 100755 (executable)
--- a/configure
+++ b/configure
@@ -968,7 +968,6 @@ with_purify
 with_gperftools_profiler
 enable_backtrace
 enable_symtable
-enable_ipv6
 with_kame
 enable_tcp_fastopen
 enable_getifaddrs
@@ -1660,7 +1659,6 @@ Optional Features:
   --enable-backtrace      log stack backtrace on abort [default=yes]
   --enable-symtable       use internal symbol table for backtrace
                           [all|minimal(default)|none]
-  --enable-ipv6           use IPv6 [default=autodetect]
   --disable-tcp-fastopen  disable TCP Fast Open support [default=autodetect]
   --enable-getifaddrs     enable the use of getifaddrs() [yes|no].
   --disable-isc-spnego    use SPNEGO from GSSAPI library
@@ -17838,24 +17836,6 @@ BIND9_CO_RULE=".c.$O:"
 # capabilities.  The order of the tests is significant.
 #
 
-#
-# IPv6
-#
-# Check whether --enable-ipv6 was given.
-if test "${enable_ipv6+set}" = set; then :
-  enableval=$enable_ipv6;
-fi
-
-
-case "$enable_ipv6" in
-       yes|''|autodetect)
-               $as_echo "#define WANT_IPV6 1" >>confdefs.h
-
-               ;;
-       no)
-               ;;
-esac
-
 #
 # We do the IPv6 compilation checking after libtool so that we can put
 # the right suffix on the files.
@@ -25469,8 +25449,7 @@ report() {
 
     # these lines are only printed if run with --enable-full-report
     if test "yes" = "$enable_full_report"; then
-       test "no" = "$enable_ipv6" -o "no" = "$found_ipv6" || \
-           echo "    IPv6 support (--enable-ipv6)"
+       test "no" = "$found_ipv6" || echo "    IPv6 support (--enable-ipv6)"
        test "X$PYTHON" = "X" || echo "    Python tools (--with-python)"
        test "X$XMLSTATS" = "X" || echo "    XML statistics (--with-libxml2)"
        test "X$JSONSTATS" = "X" || echo "    JSON statistics (--with-libjson)"
@@ -25521,8 +25500,7 @@ report() {
     echo "-------------------------------------------------------------------------------"
 
     echo "Features disabled or unavailable on this platform:"
-    test "no" = "$enable_ipv6" -o "no" = "$found_ipv6" && \
-           echo "    IPv6 support (--enable-ipv6)"
+    test "no" = "$found_ipv6" && echo "    IPv6 support (--enable-ipv6)"
     test "large" = "$use_tuning" || echo "    Large-system tuning (--with-tuning)"
 
     test "no" = "$use_dnstap" && \
index 5fcc85117cf5a4631269a6ab74df8e3dccab53f2..c77651a57e1d375966be38a4c3ec428c0f6b0407 100644 (file)
@@ -1930,20 +1930,6 @@ AC_SUBST(BIND9_CO_RULE)
 # capabilities.  The order of the tests is significant.
 #
 
-#
-# IPv6
-#
-AC_ARG_ENABLE(ipv6,
-             AS_HELP_STRING([--enable-ipv6], [use IPv6 [default=autodetect]]))
-
-case "$enable_ipv6" in
-       yes|''|autodetect)
-               AC_DEFINE(WANT_IPV6)
-               ;;
-       no)
-               ;;
-esac
-
 #
 # We do the IPv6 compilation checking after libtool so that we can put
 # the right suffix on the files.
@@ -4035,8 +4021,7 @@ report() {
 
     # these lines are only printed if run with --enable-full-report 
     if test "yes" = "$enable_full_report"; then
-       test "no" = "$enable_ipv6" -o "no" = "$found_ipv6" || \
-           echo "    IPv6 support (--enable-ipv6)"
+       test "no" = "$found_ipv6" || echo "    IPv6 support (--enable-ipv6)"
        test "X$PYTHON" = "X" || echo "    Python tools (--with-python)"
        test "X$XMLSTATS" = "X" || echo "    XML statistics (--with-libxml2)"
        test "X$JSONSTATS" = "X" || echo "    JSON statistics (--with-libjson)"
@@ -4087,8 +4072,7 @@ report() {
     echo "-------------------------------------------------------------------------------"
 
     echo "Features disabled or unavailable on this platform:"
-    test "no" = "$enable_ipv6" -o "no" = "$found_ipv6" && \
-           echo "    IPv6 support (--enable-ipv6)"
+    test "no" = "$found_ipv6" && echo "    IPv6 support (--enable-ipv6)"
     test "large" = "$use_tuning" || echo "    Large-system tuning (--with-tuning)"
 
     test "no" = "$use_dnstap" && \
index 84627a143e2a9940e202bd0e974950c648e45bb3..679c47cda47068410d660790b676637bf023f959 100644 (file)
@@ -412,7 +412,7 @@ ATF_TC_HEAD(udp_dscp_v6, tc) {
        atf_tc_set_md_var(tc, "descr", "udp dscp ipv6");
 }
 ATF_TC_BODY(udp_dscp_v6, tc) {
-#if defined(ISC_PLATFORM_HAVEIPV6) && defined(WANT_IPV6)
+#if defined(ISC_PLATFORM_HAVEIPV6)
        isc_result_t result;
        isc_sockaddr_t addr1, addr2;
        struct in6_addr in6;
index 0064f1a2193cb12b10a5a49d777e2387c7845514..ed4eb0518097c6a7ed20435ff0ca69347d705ca7 100644 (file)
@@ -102,13 +102,11 @@ const struct in6_addr isc_net_in6addrany = IN6ADDR_ANY_INIT;
 const struct in6_addr isc_net_in6addrloop = IN6ADDR_LOOPBACK_INIT;
 # endif
 
-# if defined(WANT_IPV6)
 static isc_once_t      once_ipv6only = ISC_ONCE_INIT;
 
 #  if defined(ISC_PLATFORM_HAVEIN6PKTINFO)
 static isc_once_t      once_ipv6pktinfo = ISC_ONCE_INIT;
 #  endif
-# endif /* WANT_IPV6 */
 #endif /* ISC_PLATFORM_HAVEIPV6 */
 
 #ifndef ISC_CMSG_IP_TOS
@@ -165,7 +163,6 @@ try_proto(int domain) {
        }
 
 #ifdef ISC_PLATFORM_HAVEIPV6
-#ifdef WANT_IPV6
 #ifdef ISC_PLATFORM_HAVEIN6PKTINFO
        if (domain == PF_INET6) {
                struct sockaddr_in6 sin6;
@@ -205,7 +202,6 @@ try_proto(int domain) {
                }
        }
 #endif
-#endif
 #endif
 
        (void)close(s);
@@ -217,12 +213,10 @@ static void
 initialize_action(void) {
        ipv4_result = try_proto(PF_INET);
 #ifdef ISC_PLATFORM_HAVEIPV6
-#ifdef WANT_IPV6
 #ifdef ISC_PLATFORM_HAVEIN6PKTINFO
        ipv6_result = try_proto(PF_INET6);
 #endif
 #endif
-#endif
 #ifdef ISC_PLATFORM_HAVESYSUNH
        unix_result = try_proto(PF_UNIX);
 #endif
@@ -252,7 +246,6 @@ isc_net_probeunix(void) {
 }
 
 #ifdef ISC_PLATFORM_HAVEIPV6
-#ifdef WANT_IPV6
 static void
 try_ipv6only(void) {
 #ifdef IPV6_V6ONLY
@@ -328,10 +321,8 @@ initialize_ipv6only(void) {
        RUNTIME_CHECK(isc_once_do(&once_ipv6only,
                                  try_ipv6only) == ISC_R_SUCCESS);
 }
-#endif /* WANT_IPV6 */
 
 #ifdef ISC_PLATFORM_HAVEIN6PKTINFO
-#ifdef WANT_IPV6
 static void
 try_ipv6pktinfo(void) {
        int s, on;
@@ -383,18 +374,13 @@ initialize_ipv6pktinfo(void) {
        RUNTIME_CHECK(isc_once_do(&once_ipv6pktinfo,
                                  try_ipv6pktinfo) == ISC_R_SUCCESS);
 }
-#endif /* WANT_IPV6 */
 #endif /* ISC_PLATFORM_HAVEIN6PKTINFO */
 #endif /* ISC_PLATFORM_HAVEIPV6 */
 
 isc_result_t
 isc_net_probe_ipv6only(void) {
 #ifdef ISC_PLATFORM_HAVEIPV6
-#ifdef WANT_IPV6
        initialize_ipv6only();
-#else
-       ipv6only_result = ISC_R_NOTFOUND;
-#endif
 #endif
        return (ipv6only_result);
 }
@@ -403,18 +389,14 @@ isc_result_t
 isc_net_probe_ipv6pktinfo(void) {
 #ifdef ISC_PLATFORM_HAVEIPV6
 #ifdef ISC_PLATFORM_HAVEIN6PKTINFO
-#ifdef WANT_IPV6
        initialize_ipv6pktinfo();
-#else
-       ipv6pktinfo_result = ISC_R_NOTFOUND;
-#endif
 #endif
 #endif
        return (ipv6pktinfo_result);
 }
 
 #if ISC_CMSG_IP_TOS || \
-    defined(ISC_NET_BSD44MSGHDR) && defined(IPV6_TCLASS) && defined(WANT_IPV6)
+    defined(ISC_NET_BSD44MSGHDR) && defined(IPV6_TCLASS)
 
 static inline ISC_SOCKADDR_LEN_T
 cmsg_len(ISC_SOCKADDR_LEN_T len) {
@@ -691,7 +673,6 @@ try_dscp_v4(void) {
 static void
 try_dscp_v6(void) {
 #ifdef ISC_PLATFORM_HAVEIPV6
-#ifdef WANT_IPV6
 #ifdef IPV6_TCLASS
        char strbuf[ISC_STRERRORSIZE];
        struct addrinfo hints, *res0;
@@ -745,7 +726,6 @@ try_dscp_v6(void) {
        close(s);
 
 #endif /* IPV6_TCLASS */
-#endif /* WANT_IPV6 */
 #endif /* ISC_PLATFORM_HAVEIPV6 */
 }
 
index c49bb6bedd863897d77fc537944e0431305cd283..1a6f0864371b23945761d048de40652602e478fb 100644 (file)
@@ -91,12 +91,10 @@ initialize_action(void) {
        InitSockets();
        ipv4_result = try_proto(PF_INET);
 #ifdef ISC_PLATFORM_HAVEIPV6
-#ifdef WANT_IPV6
 #ifdef ISC_PLATFORM_HAVEIN6PKTINFO
        ipv6_result = try_proto(PF_INET6);
 #endif
 #endif
-#endif
 }
 
 static void
@@ -122,7 +120,6 @@ isc_net_probeunix(void) {
 }
 
 #ifdef ISC_PLATFORM_HAVEIPV6
-#ifdef WANT_IPV6
 static void
 try_ipv6only(void) {
 #ifdef IPV6_V6ONLY
@@ -262,17 +259,12 @@ initialize_ipv6pktinfo(void) {
                                  try_ipv6pktinfo) == ISC_R_SUCCESS);
 }
 #endif /* __notyet__ */
-#endif /* WANT_IPV6 */
 #endif /* ISC_PLATFORM_HAVEIPV6 */
 
 isc_result_t
 isc_net_probe_ipv6only(void) {
 #ifdef ISC_PLATFORM_HAVEIPV6
-#ifdef WANT_IPV6
        initialize_ipv6only();
-#else
-       ipv6only_result = ISC_R_NOTFOUND;
-#endif
 #endif
        return (ipv6only_result);
 }
@@ -281,11 +273,7 @@ isc_result_t
 isc_net_probe_ipv6pktinfo(void) {
 #ifdef __notyet__
 #ifdef ISC_PLATFORM_HAVEIPV6
-#ifdef WANT_IPV6
        initialize_ipv6pktinfo();
-#else
-       ipv6pktinfo_result = ISC_R_NOTFOUND;
-#endif
 #endif
 #endif /* __notyet__ */
        return (ipv6pktinfo_result);
index 3bc582ef71bfbb8ca058ff8411261957e525cabb..6f1b0d591a6507db253c12bcfd8cc426be9bbd06 100644 (file)
@@ -862,12 +862,10 @@ do_scan(ns_interfacemgr_t *mgr, ns_listenlist_t *ext_listen,
 
        if (isc_net_probeipv6() == ISC_R_SUCCESS)
                scan_ipv6 = true;
-#ifdef WANT_IPV6
        else if ((mgr->sctx->options & NS_SERVER_DISABLE6) == 0)
                isc_log_write(IFMGR_COMMON_LOGARGS,
                              verbose ? ISC_LOG_INFO : ISC_LOG_DEBUG(1),
                              "no IPv6 interfaces found");
-#endif
 
        if (isc_net_probeipv4() == ISC_R_SUCCESS)
                scan_ipv4 = true;