build: remove --disable-ipv6

Building with IPv6 disabled tends to break rather often and sprinkles
ugly #ifdefs around the code.  All that only to support systems where
the C library doesn't have IPv6 capability.

The year now being 2015, if this is a problem the thing to fix is the C
library.

The implication of this patch is that future patches need not care about
HAVE_IPV6 = 0 and may remove ifdefs gratuitously.  This patch doesn't
remove these ifdefs to not create unneccessary churn.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Acked-by: Paul Jakma <paul@jakma.org>
diff --git a/buildtest.sh b/buildtest.sh
index 4859bf4..3bc25f2 100755
--- a/buildtest.sh
+++ b/buildtest.sh
@@ -4,22 +4,16 @@
 # builds some git commit of Quagga in some different configurations
 # usage: buildtest.sh [commit [configurations...]]
 
-basecfg="--prefix=/usr --enable-user=quagga --enable-group=quagga --enable-vty-group=quagga --enable-configfile-mask=0660 --enable-logfile-mask=0640 --enable-vtysh --sysconfdir=/etc/quagga --enable-exampledir=/etc/quagga/samples --localstatedir=/var/run/quagga --libdir=/usr/lib64/quagga --enable-ipv6 --enable-ripngd --enable-ospf6d --enable-rtadv --disable-static --enable-isisd --enable-multipath=0 --enable-babeld --enable-pimd"
+basecfg="--prefix=/usr --enable-user=quagga --enable-group=quagga --enable-vty-group=quagga --enable-configfile-mask=0660 --enable-logfile-mask=0640 --enable-vtysh --sysconfdir=/etc/quagga --enable-exampledir=/etc/quagga/samples --localstatedir=/var/run/quagga --libdir=/usr/lib64/quagga --enable-rtadv --disable-static --enable-isisd --enable-multipath=0 --enable-babeld --enable-pimd"
 
 configs_base="gcc|$basecfg"
 
-configs_nov6="gcc|$basecfg"
-configs_nov6="${configs_nov6/enable-ipv6/disable-ipv6}"
-configs_nov6="${configs_nov6/enable-ospf6d/disable-ospf6d}"
-configs_nov6="${configs_nov6/enable-ripngd/disable-ripngd}"
-configs_nov6="${configs_nov6/enable-babeld/disable-babeld}"
-
 configs_ext="gcc|$basecfg --enable-opaque-lsa --enable-ospf-te --enable-ospfclient --enable-isis-topology"
 configs_snmp="gcc|$basecfg --enable-opaque-lsa --enable-ospf-te --enable-ospfclient --enable-isis-topology --enable-snmp"
 configs_clang="clang|$basecfg --enable-opaque-lsa --enable-ospf-te --enable-ospfclient --enable-isis-topology"
 configs_icc="icc|$basecfg --enable-opaque-lsa --enable-ospf-te --enable-ospfclient --enable-isis-topology"
 
-defconfigs="base nov6 ext"
+defconfigs="base ext"
 net-snmp-config --version	&> /dev/null && defconfigs="$defconfigs snmp"
 clang --version			&> /dev/null && defconfigs="$defconfigs clang"
 icc --version			&> /dev/null && defconfigs="$defconfigs icc"
diff --git a/configure.ac b/configure.ac
index 715f35d..33a1cd0 100755
--- a/configure.ac
+++ b/configure.ac
@@ -198,8 +198,6 @@
 	[ test "x$withval" != "xno" && with_pkg_git_version="yes" ])
 AC_ARG_ENABLE(vtysh,
   AS_HELP_STRING([--enable-vtysh], [include integrated vty shell for Quagga]))
-AC_ARG_ENABLE(ipv6,
-  AS_HELP_STRING([--disable-ipv6], [turn off IPv6 related features and daemons]))
 AC_ARG_ENABLE(doc,
   AS_HELP_STRING([--disable-doc], [do not build docs]))
 AC_ARG_ENABLE(zebra,
@@ -1026,51 +1024,37 @@
 dnl IPv6 check
 dnl ----------
 AC_MSG_CHECKING(whether does this OS have IPv6 stack)
-if test "${enable_ipv6}" = "no"; then
-  AC_MSG_RESULT(disabled)
-else
 dnl ---------
 dnl KAME IPv6
 dnl ---------
   if grep WIDE /usr/include/netinet6/in6.h >/dev/null 2>&1; then
-    zebra_cv_ipv6=yes
     AC_DEFINE(KAME,1,KAME IPv6)
     AC_MSG_RESULT(KAME)
 dnl ------------------------------------
 dnl Solaris 9, 10 and potentially higher
 dnl ------------------------------------
   elif test x"$opsys" = x"sol8"; then
-    zebra_cv_ipv6=yes;
     AC_DEFINE(SOLARIS_IPV6, 1, Solaris IPv6)
     AC_MSG_RESULT(Solaris IPv6)
 dnl ----------
 dnl Linux IPv6
 dnl ----------
   elif test x"$opsys" = x"gnu-linux"; then
-    zebra_cv_ipv6=yes
     AC_DEFINE(LINUX_IPV6,1,Linux IPv6 stack)
     AC_MSG_RESULT(Linux IPv6)
   else
-    AC_MSG_RESULT(Unknown OS)
+    AC_MSG_ERROR([Failed to detect IPv6 stack])
   fi
-fi
 
-if test x"$zebra_cv_ipv6" = x"yes"; then
-  AC_DEFINE(HAVE_IPV6,1,IPv6)
-  RIPNGD="ripngd"
-  OSPF6D="ospf6d"
-elif test x"${enable_ipv6}" = x"yes"; then
-  AC_MSG_ERROR([--enable-ipv6 given but IPv6 stack unknown])
-fi
+dnl this is unconditial, for compatibility
+AC_DEFINE(HAVE_IPV6,1,IPv6)
 
 dnl ------------------
 dnl IPv6 header checks
 dnl ------------------
-if test "x${zebra_cv_ipv6}" = "xyes"; then
 AC_CHECK_HEADERS([netinet6/in6.h netinet/in6_var.h netinet/icmp6.h \
 	netinet6/in6_var.h netinet6/nd6.h], [], [],
 	QUAGGA_INCLUDES)
-fi
 
 m4_define([QUAGGA_INCLUDES],dnl
 QUAGGA_INCLUDES
@@ -1157,16 +1141,14 @@
 AM_CONDITIONAL(OSPFCLIENT, test "x$OSPFCLIENT" = "xospfclient")
 
 case "${enable_ripngd}" in
-  "yes") RIPNGD="ripngd";;
   "no" ) RIPNGD="";;
-  *    ) ;;
+  *    ) RIPNGD="ripngd";;
 esac
 AM_CONDITIONAL(RIPNGD, test "x$RIPNGD" = "xripngd")
 
 case "${enable_ospf6d}" in
-  "yes") OSPF6D="ospf6d";;
   "no" ) OSPF6D="";;
-  *    ) ;;
+  *    ) OSPF6D="ospf6d";;
 esac
 AM_CONDITIONAL(OSPF6D, test "x$OSPF6D" = "xospf6d")