])
AC_SUBST([yangmodelsdir])
+AC_ARG_WITH([vici-socket], [AS_HELP_STRING([--with-vici-socket=PATH], [vici-socket (/var/run/charon.vici)])], [
+ vici_socket="$withval"
+], [
+ vici_socket="/var/run/charon.vici"
+])
+AC_DEFINE_UNQUOTED([VICI_SOCKET], ["$vici_socket"], [StrongSWAN vici socket path])
+
AC_ARG_ENABLE(tcmalloc,
AS_HELP_STRING([--enable-tcmalloc], [Turn on tcmalloc]),
[case "${enableval}" in
AC_SUBST([AC_LDFLAGS])
AM_CONDITIONAL([STATIC_BIN], [test "$enable_static_bin" = "yes"])
+AC_ARG_ENABLE([rpath],
+ [AS_HELP_STRING([--enable-rpath], [set hardcoded rpaths in the executable @<:@default=yes@:>@])],
+ [],
+ [enable_rpath=yes])
+
dnl $AR and $RANLIB are set by LT_INIT above
AC_MSG_CHECKING([whether $AR supports D option])
if $AR crD conftest.a >/dev/null 2>/dev/null; then
AS_HELP_STRING([--enable-grpc], [enable the gRPC northbound plugin]))
AC_ARG_ENABLE([zeromq],
AS_HELP_STRING([--enable-zeromq], [enable ZeroMQ handler (libfrrzmq)]))
+AC_ARG_ENABLE([lttng],
+ AS_HELP_STRING([--enable-lttng], [enable LTTng tracing]))
+AC_ARG_ENABLE([usdt],
+ AS_HELP_STRING([--enable-usdt], [enable USDT probes]))
AC_ARG_WITH([libpam],
AS_HELP_STRING([--with-libpam], [use libpam for PAM support in vtysh]))
AC_ARG_ENABLE([ospfapi],
])
fi
+dnl -----
+dnl LTTng
+dnl -----
+if test "$enable_lttng" = "yes"; then
+ PKG_CHECK_MODULES([UST], [lttng-ust >= 2.12.0], [
+ AC_DEFINE([HAVE_LTTNG], [1], [Enable LTTng support])
+ LTTNG=true
+ ], [
+ AC_MSG_ERROR([configuration specifies --enable-lttng but lttng-ust was not found])
+ ])
+fi
+
+dnl ----
+dnl USDT
+dnl ----
+if test "$enable_usdt" = "yes"; then
+ AC_CHECK_HEADERS([sys/sdt.h], [
+ AC_DEFINE([HAVE_USDT], [1], [Enable USDT probes])
+ USDT=true
+ ], [
+ AC_MSG_ERROR([configuration specifies --enable-usdt but no USDT kernel headers (sys/sdt.h) found])
+ ])
+fi
+
dnl ------
dnl ZeroMQ
dnl ------
AC_CONFIG_FILES([tools/frrinit.sh], [chmod +x tools/frrinit.sh])
AC_CONFIG_FILES([tools/frrcommon.sh])
- AC_CONFIG_COMMANDS([lib/route_types.h], [
- dst="${ac_abs_top_builddir}/lib/route_types.h"
- ${PERL} "${ac_abs_top_srcdir}/lib/route_types.pl" \
- < "${ac_abs_top_srcdir}/lib/route_types.txt" \
- > "${dst}.tmp"
- test -f "$dst" \
- && diff "${dst}.tmp" "${dst}" >/dev/null 2>/dev/null \
- && rm "${dst}.tmp" \
- || mv "${dst}.tmp" "${dst}"
- ], [
- PERL="$PERL"
- ])
-
AS_IF([test "$with_pkg_git_version" = "yes"], [
AC_CONFIG_COMMANDS([lib/gitversion.h], [
dst="${ac_abs_top_builddir}/lib/gitversion.h"
## It's already in CVS until texinfo 4.7 is more common.
AC_OUTPUT
+if test "$enable_rpath" = "yes" ; then
+ true
+else
+ # See https://old-en.opensuse.org/openSUSE:Packaging_Guidelines#Removing_Rpath
+ sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
+ sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
+fi
+
echo "
FRRouting configuration
------------------------------
config file mask : ${enable_configfile_mask}
log file mask : ${enable_logfile_mask}
zebra protobuf enabled : ${enable_protobuf:-no}
+vici socket path : ${vici_socket}
The above user and group must have read/write access to the state file
directory and to the config files in the config file directory."
#
lib_LTLIBRARIES += lib/libfrr.la
lib_libfrr_la_LDFLAGS = -version-info 0:0:0 -Xlinker -e_libfrr_version
-lib_libfrr_la_LIBADD = $(LIBCAP) $(UNWIND_LIBS) $(LIBYANG_LIBS) $(LUA_LIB) $(LIBM)
+lib_libfrr_la_LIBADD = $(LIBCAP) $(UNWIND_LIBS) $(LIBYANG_LIBS) $(LUA_LIB) $(UST_LIBS) $(LIBM)
lib_libfrr_la_SOURCES = \
lib/agg_table.c \
lib/lib_errors.c \
lib/lib_vty.c \
lib/libfrr.c \
+ lib/libfrr_trace.c \
lib/linklist.c \
lib/log.c \
lib/log_filter.c \
yang/frr-nexthop.yang.c \
yang/ietf/ietf-routing-types.yang.c \
yang/ietf/ietf-interfaces.yang.c \
+ yang/ietf/ietf-bgp-types.yang.c \
yang/frr-module-translator.yang.c \
yang/frr-nexthop.yang.c \
# end
lib/lib_errors.h \
lib/lib_vty.h \
lib/libfrr.h \
+ lib/libfrr_trace.h \
lib/libospf.h \
lib/linklist.h \
lib/log.h \
lib/table.h \
lib/termtable.h \
lib/thread.h \
+ lib/trace.h \
lib/typerb.h \
lib/typesafe.h \
lib/vector.h \
lib_clippy_CPPFLAGS = $(AM_CPPFLAGS) -D_GNU_SOURCE -DBUILDING_CLIPPY
lib_clippy_CFLAGS = $(PYTHON_CFLAGS)
-lib_clippy_LDADD = $(PYTHON_LIBS)
+lib_clippy_LDADD = $(PYTHON_LIBS) $(UST_LIBS)
lib_clippy_LDFLAGS = -export-dynamic
lib_clippy_SOURCES = \
lib/clippy.c \
lib/command_py.c \
lib/defun_lex.l \
lib/graph.c \
+ lib/libfrr_trace.c \
lib/memory.c \
lib/vector.c \
# end
lib/lib_clippy-command_lex.$(OBJEXT): lib/command_parse.h
lib/lib_clippy-command_parse.$(OBJEXT): lib/command_lex.h
+ rt_enabled =
+
+ if BABELD
+ rt_enabled += --enabled babeld
+ endif
+ if BFDD
+ rt_enabled += --enabled bfdd
+ endif
+ if BGPD
+ rt_enabled += --enabled bgpd
+ if ENABLE_BGP_VNC
+ rt_enabled += --enabled bgpd-vnc
+ endif
+ endif
+ if EIGRPD
+ rt_enabled += --enabled eigrpd
+ endif
+ if ISISD
+ rt_enabled += --enabled isisd
+ endif
+ if FABRICD
+ rt_enabled += --enabled fabricd
+ endif
+ if LDPD
+ rt_enabled += --enabled ldpd
+ endif
+ if NHRPD
+ rt_enabled += --enabled nhrpd
+ endif
+ if OSPFD
+ rt_enabled += --enabled ospfd
+ endif
+ if OSPF6D
+ rt_enabled += --enabled ospf6d
+ endif
+ if PBRD
+ rt_enabled += --enabled pbrd
+ endif
+ if PIMD
+ rt_enabled += --enabled pimd
+ endif
+ if RIPD
+ rt_enabled += --enabled ripd
+ endif
+ if RIPNGD
+ rt_enabled += --enabled ripngd
+ endif
+ if SHARPD
+ rt_enabled += --enabled sharpd
+ endif
+ if ZEBRA
+ rt_enabled += --enabled zebra
+ endif
+
lib/route_types.h: $(top_srcdir)/lib/route_types.txt $(top_srcdir)/lib/route_types.pl
- $(PERL) $(top_srcdir)/lib/route_types.pl < $(top_srcdir)/lib/route_types.txt > $@
+ $(PERL) $(top_srcdir)/lib/route_types.pl $(rt_enabled) < $(top_srcdir)/lib/route_types.txt > $@
DISTCLEANFILES += lib/route_types.h
if GIT_VERSION