summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorRenato Westphal <renato@opensourcerouting.org>2016-09-12 14:02:39 +0200
committerDonald Sharp <sharpd@cumulusnetworks.com>2016-09-23 15:31:13 +0200
commitbe0dba358f7cd40ae27f012409734786a13d5ce4 (patch)
tree698d02bc1c5227cb5e43686d94ee19a42203dfd7 /configure.ac
parentmpls: add support for LDP LSPs (diff)
downloadfrr-be0dba358f7cd40ae27f012409734786a13d5ce4.tar.xz
frr-be0dba358f7cd40ae27f012409734786a13d5ce4.zip
mpls: add null driver
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Diffstat (limited to 'configure.ac')
-rwxr-xr-xconfigure.ac25
1 files changed, 25 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index eb1f1de6c..e15f384c2 100755
--- a/configure.ac
+++ b/configure.ac
@@ -309,6 +309,8 @@ AC_ARG_ENABLE(systemd,
AS_HELP_STRING([--enable-systemd], [enable Systemd support]))
AC_ARG_ENABLE(poll,
AS_HELP_STRING([--enable-poll], [enable usage of Poll instead of select]))
+AC_ARG_ENABLE(mpls,
+ AS_HELP_STRING([--enable-mpls], [enable MPLS support - requires compatible kernel]))
AC_ARG_ENABLE(werror,
AS_HELP_STRING([--enable-werror], [enable -Werror (recommended for developers only)]))
AC_ARG_ENABLE(cumulus,
@@ -360,6 +362,29 @@ if test "${enable_poll}" = "yes" ; then
AC_DEFINE(HAVE_POLL,,Compile systemd support in)
fi
+dnl ----------
+dnl MPLS check
+dnl ----------
+MPLS_METHOD=""
+AC_MSG_CHECKING(whether this OS has MPLS stack)
+if test "x${enable_mpls}" = "xyes"; then
+ case "$host" in
+ *-linux*)
+ AC_DEFINE(HAVE_MPLS,,Enable MPLS)
+ MPLS_METHOD="zebra_mpls_netlink.o"
+ AC_MSG_RESULT(Linux MPLS)
+ ;;
+ *)
+ AC_MSG_RESULT(Unsupported kernel)
+ MPLS_METHOD="zebra_mpls_null.o"
+ ;;
+ esac
+else
+ AC_MSG_RESULT(disabled)
+ MPLS_METHOD="zebra_mpls_null.o"
+fi
+AC_SUBST(MPLS_METHOD)
+
if test "${enable_cumulus}" = "yes" ; then
AC_DEFINE(HAVE_CUMULUS,,Compile Special Cumulus Code in)
fi