From: Donald Sharp Date: Sun, 21 Feb 2016 17:43:50 +0000 (-0500) Subject: debian, config, zebra: Ensure Cumulus Extensions are not auto turned on X-Git-Tag: frr-2.0-rc1~1111 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=000cf1fb358dd7a7ce44e1e4c8bfdc332c335b9a;p=mirror%2Ffrr.git debian, config, zebra: Ensure Cumulus Extensions are not auto turned on There exist cases where Cumulus Code( in this case code surrounding when we want to send Router Advertisements ) should only be turned on for Cumulus Switches. Signed-off-by: Donald Sharp --- diff --git a/configure.ac b/configure.ac index 5a7744a06e..74020ad736 100755 --- a/configure.ac +++ b/configure.ac @@ -302,6 +302,8 @@ AC_ARG_ENABLE(systemd, [ --enable-systemd enable Systemd support]) AC_ARG_ENABLE(werror, AS_HELP_STRING([--enable-werror], [enable -Werror (recommended for developers only)])) +AC_ARG_ENABLE(cumulus, +[ --enable-cumulus enable Cumulus Switch Special Extensions]) if test x"${enable_gcc_ultra_verbose}" = x"yes" ; then CFLAGS="${CFLAGS} -W -Wcast-qual -Wstrict-prototypes" @@ -329,6 +331,10 @@ if test "${enable_systemd}" = "yes" ; then LIBS="$LIBS -lsystemd " fi +if test "${enable_cumulus}" = "yes" ; then + AC_DEFINE(HAVE_CUMULUS,,Compile Special Cumulus Code in) +fi + if test "${enable_shell_access}" = "yes"; then AC_DEFINE(HAVE_SHELL_ACCESS,,Allow user to use ssh/telnet/bash) fi diff --git a/debian/rules b/debian/rules index ff46795499..30220c9208 100755 --- a/debian/rules +++ b/debian/rules @@ -67,6 +67,7 @@ override_dh_auto_configure: --enable-gcc-rdynamic \ --with-libpam \ --enable-systemd=yes \ + --enable-cumulus=yes \ --enable-dependency-tracking; \ fi if ! diff -b -IHAVE_SNMP -IHAVE_NETSNMP -IUCD_COMPAT -IGETIFADDR debian/my/config.h.reference config.h; then \ diff --git a/zebra/rtadv.h b/zebra/rtadv.h index 51b8afe8d3..e8d84f9dee 100644 --- a/zebra/rtadv.h +++ b/zebra/rtadv.h @@ -116,10 +116,12 @@ static inline int interface_ipv6_auto_ra_allowed (struct interface *ifp) { #if defined (HAVE_RTADV) +#if defined (HAVE_CUMULUS) if ((strncmp (ifp->name, "eth", strlen("eth")) == 0) || (strncmp (ifp->name, "lo", strlen("lo")) == 0) || (strncmp (ifp->name, "switch", strlen("switch")) == 0)) return 0; +#endif return 1; #else return 0;