From: Francis Dupont Date: Mon, 4 Feb 2019 14:50:01 +0000 (+0100) Subject: [340-make-perfdhcp-build-optional] Made perfdhcp optional (default=no) X-Git-Tag: 448-update-cb-cmds-to-handle-parameter-types_base~5 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=8ee2c24be1383819fe1d79a5c75e993cbbc5e243;p=thirdparty%2Fkea.git [340-make-perfdhcp-build-optional] Made perfdhcp optional (default=no) --- diff --git a/Makefile.am b/Makefile.am index 95283b43a4..97f2da8c75 100644 --- a/Makefile.am +++ b/Makefile.am @@ -13,6 +13,7 @@ DISTCHECK_GTEST_CONFIGURE_FLAG=@DISTCHECK_GTEST_CONFIGURE_FLAG@ DISTCHECK_CRYPTO_CONFIGURE_FLAG=@DISTCHECK_CRYPTO_CONFIGURE_FLAG@ DISTCHECK_BOOST_CONFIGURE_FLAG=@DISTCHECK_BOOST_CONFIGURE_FLAG@ DISTCHECK_LOG4CPLUS_CONFIGURE_FLAG=@DISTCHECK_LOG4CPLUS_CONFIGURE_FLAG@ +DISTCHECK_PERFDHCP_CONFIGURE_FLAG=@DISTCHECK_PERFDHCP_CONFIGURE_FLAG@a DISTCHECK_KEA_SHELL_CONFIGURE_FLAG=@DISTCHECK_KEA_SHELL_CONFIGURE_FLAG@ DISTCHECK_PREMIUM_CONFIGURE_FLAG=@DISTCHECK_PREMIUM_CONFIGURE_FLAG@ DISTCHECK_CONTRIB_CONFIGURE_FLAG=@DISTCHECK_CONTRIB_CONFIGURE_FLAG@ @@ -37,6 +38,9 @@ DISTCHECK_CONFIGURE_FLAGS += $(DISTCHECK_BOOST_CONFIGURE_FLAG) # Keep the log4cplus path too DISTCHECK_CONFIGURE_FLAGS += $(DISTCHECK_LOG4CPLUS_CONFIGURE_FLAG) +# Keep perfdhcp if enabled +DISTCHECK_CONFIGURE_FLAGS += $(DISTCHECK_PERFDHCP_CONFIGURE_FLAG) + # Keep kea-shell if enabled DISTCHECK_CONFIGURE_FLAGS += $(DISTCHECK_KEA_SHELL_CONFIGURE_FLAG) diff --git a/configure.ac b/configure.ac index 126d9c6d08..91a006b50b 100644 --- a/configure.ac +++ b/configure.ac @@ -436,6 +436,20 @@ case "$host" in ;; esac +# Made perfdhcp optional. +AC_ARG_ENABLE(perfdhcp, [AC_HELP_STRING([--enable-perfdhcp], + [enable perfdhcp, a DHCP benchmarking tool [defaulno]])], + enable_perfdhcp=$enableval, enable_perfdhcp=no) + +DISTCHECK_KEA_PERFDHCP_CONFIGURE_FLAG= +if test "x$enable_perfdhcp" != xno ; then + DISTCHECK_KEA_PERFDHCP_CONFIGURE_FLAG="--enable-perfdhcp" +fi + +# Export to makefiles the info whether we have perfdhcp enabled or not +AM_CONDITIONAL(PERFDHCP, test x$enable_perfdhcp != xno) +AC_SUBST(DISTCHECK_KEA_PERFDHCP_CONFIGURE_FLAG) + # Kea-shell is written in python. It can work with python 2.7 or any 3.x. # It may likely work with earlier versions, but 2.7 was the oldest one we tested # it with. We require python only if kea-shell was enabled. It is disabled @@ -1932,6 +1946,7 @@ Developer: Logger checks: $enable_logger_checks Generate Documentation: $enable_generate_docs Parser Generation: $enable_generate_parser + Perfdhcp: $enable_perfdhcp Kea-shell: $enable_shell END diff --git a/src/bin/Makefile.am b/src/bin/Makefile.am index 4f58d81903..d93cbf452f 100644 --- a/src/bin/Makefile.am +++ b/src/bin/Makefile.am @@ -1,5 +1,9 @@ # The following build order must be maintained. -SUBDIRS = dhcp4 dhcp6 d2 agent perfdhcp admin lfc keactrl +SUBDIRS = dhcp4 dhcp6 d2 agent admin lfc keactrl + +if PERFDHCP +SUBDIRS += perfdhcp +endif if KEA_SHELL SUBDIRS += shell