]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[340-make-perfdhcp-build-optional] Made perfdhcp optional (default=no)
authorFrancis Dupont <fdupont@isc.org>
Mon, 4 Feb 2019 14:50:01 +0000 (15:50 +0100)
committerFrancis Dupont <fdupont@isc.org>
Tue, 5 Feb 2019 22:19:03 +0000 (17:19 -0500)
Makefile.am
configure.ac
src/bin/Makefile.am

index 95283b43a40536053338c119f44e160a630d407b..97f2da8c7549962df34cbec3e761d1c8020c6a36 100644 (file)
@@ -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)
 
index 126d9c6d0892aff4d6fd16081e85e15072a79ac9..91a006b50b0ba971fcbf888c33c78201cf628e64 100644 (file)
@@ -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
index 4f58d81903396b5dc55263b493873c80227866f3..d93cbf452fc4a9dac494a2038090b5207862313d 100644 (file)
@@ -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