BIND 10 trac2367, updated. b128644f4e6d6af175c93f8fec5e61cf80482f90 [2367] introduce ./configure --enable-components option

BIND 10 source code commits bind10-changes at lists.isc.org
Wed Aug 21 16:51:02 UTC 2013


The branch, trac2367 has been updated
       via  b128644f4e6d6af175c93f8fec5e61cf80482f90 (commit)
       via  692c01abc37ba7d2b1c2bd1a9ce91f60b47c8fb2 (commit)
       via  b02e95f60e6f4429802f985897ba0c4a6661aabb (commit)
      from  9a1036278055840ef554c42d398478430c8ba188 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit b128644f4e6d6af175c93f8fec5e61cf80482f90
Author: Jeremy C. Reed <jreed at isc.org>
Date:   Wed Aug 21 11:49:29 2013 -0500

    [2367] introduce ./configure --enable-components option
    
    add support for dhcp, libdhcp, and resolver for it.
    change experimental resolver builtin conditionals at this time also

commit 692c01abc37ba7d2b1c2bd1a9ce91f60b47c8fb2
Author: Jeremy C. Reed <jreed at isc.org>
Date:   Wed Aug 21 11:48:32 2013 -0500

    [2367] output the list of selected components to config.report

commit b02e95f60e6f4429802f985897ba0c4a6661aabb
Author: Jeremy C. Reed <jreed at isc.org>
Date:   Wed Aug 21 09:27:30 2013 -0500

    [2367] move the --enable-experimental-resolver macro to a new file
    
    This is the start of adding the configure switches to enable/disable
    components.

-----------------------------------------------------------------------

Summary of changes:
 configure.ac                     |   24 ++++++--------
 m4macros/Makefile.am             |    3 +-
 m4macros/ax_bind10_components.m4 |   68 ++++++++++++++++++++++++++++++++++++++
 src/bin/Makefile.am              |   16 +++++----
 src/lib/Makefile.am              |   15 +++++----
 5 files changed, 100 insertions(+), 26 deletions(-)
 create mode 100644 m4macros/ax_bind10_components.m4

-----------------------------------------------------------------------
diff --git a/configure.ac b/configure.ac
index e01f5cf..6a36bff 100644
--- a/configure.ac
+++ b/configure.ac
@@ -32,6 +32,11 @@ AC_ARG_ENABLE([debug],
 AM_CONDITIONAL([DEBUG_ENABLED], [test x$debug_enabled = xyes])
 AM_COND_IF([DEBUG_ENABLED], [AC_DEFINE([ENABLE_DEBUG], [1], [Enable low-performing debugging facilities?])])
 
+#
+# Enable/disable BIND10 components
+#
+AX_BIND10_COMPONENTS
+
 # Libtool configuration
 #
 
@@ -898,19 +903,6 @@ if test "$BOOST_NUMERIC_CAST_WOULDFAIL" = "yes" -a X"$werror_ok" = X1 -a $CLANGP
     AC_MSG_ERROR([Failed to compile a required header file.  If you are using FreeBSD and Boost installed via ports, retry with specifying --without-werror.  See the ChangeLog entry for Trac no. 1991 for more details.])
 fi
 
-build_experimental_resolver=no
-AC_ARG_ENABLE(experimental-resolver,
-  [AC_HELP_STRING([--enable-experimental-resolver],
-  [enable building of the experimental resolver [default=no]])],
-  [build_experimental_resolver=$enableval])
-AM_CONDITIONAL([BUILD_EXPERIMENTAL_RESOLVER], [test "$build_experimental_resolver" = "yes"])
-if test "$build_experimental_resolver" = "yes"; then
-   BUILD_EXPERIMENTAL_RESOLVER=yes
-else
-   BUILD_EXPERIMENTAL_RESOLVER=no
-fi
-AC_SUBST(BUILD_EXPERIMENTAL_RESOLVER)
-
 use_shared_memory=yes
 AC_ARG_WITH(shared-memory,
     AC_HELP_STRING([--with-shared-memory],
@@ -1571,6 +1563,12 @@ cat >> config.report << END
 END
 fi
 
+echo >> config.report
+echo Components: >> config.report
+for i in $components_list; do
+  echo "  $i"
+done >> config.report
+
 cat >> config.report << END
 
 Features:
diff --git a/m4macros/Makefile.am b/m4macros/Makefile.am
index eeae7f9..daa0494 100644
--- a/m4macros/Makefile.am
+++ b/m4macros/Makefile.am
@@ -1,2 +1,3 @@
-EXTRA_DIST  = ax_boost_for_bind10.m4
+EXTRA_DIST  = ax_bind10_components.m4
+EXTRA_DIST += ax_boost_for_bind10.m4
 EXTRA_DIST += ax_sqlite3_for_bind10.m4
diff --git a/m4macros/ax_bind10_components.m4 b/m4macros/ax_bind10_components.m4
new file mode 100644
index 0000000..b581d35
--- /dev/null
+++ b/m4macros/ax_bind10_components.m4
@@ -0,0 +1,68 @@
+dnl @synopsis AX_BIND10_COMPONENTS
+dnl
+dnl Select what BIND10 components to build and install.
+dnl
+dnl reallyall includes experimental components
+
+AC_DEFUN([AX_BIND10_COMPONENTS], [
+
+AC_ARG_ENABLE(components,
+  AC_HELP_STRING(--enable-components=FEATURES-LIST,Space-separated
+list of components to enable | "all" | "reallyall"),[
+    for i in $enableval; do
+      if test "$i" = "all" -o "$i" = "reallyall" ; then
+        components_selection=$i
+      else
+        i=`echo $i | sed 's/-/_/g'`
+        eval "enable_$i=yes"
+      fi
+    done
+  ])
+
+AC_ARG_ENABLE(dhcp,
+ AC_HELP_STRING(--enable-dhcp,Build and install the DHCP components),
+  [enable_dhcp=$enableval], [
+   if test "$components_selection" = "all" -o \
+            "$components_selection" = "reallyall" ; then
+     enable_dhcp=yes
+     enable_libdhcp=yes
+   fi
+])
+
+AM_CONDITIONAL(ENABLE_DHCP, [test "$enable_dhcp" = "yes"])
+AC_SUBST(ENABLE_DHCP)
+if test "x$enable_dhcp" = "xyes" ; then
+  enable_libdhcp=yes
+  components_list="$components_list dhcp"
+fi
+
+AC_ARG_ENABLE(libdhcp,
+ AC_HELP_STRING(--enable-libdhcp,Build and install the dhcp libraries),
+  [enable_libdhcp=$enableval], [
+   if test "$components_selection" = "all" -o \
+            "$components_selection" = "reallyall" ; then
+     enable_libdhcp=yes
+   fi
+])
+AM_CONDITIONAL(ENABLE_LIBDHCP, [test "$enable_libdhcp" = "yes"])
+AC_SUBST(ENABLE_LIBDHCP)
+if test "x$enable_libdhcp" = "xyes" ; then
+  components_list="$components_list libdhcp"
+fi
+
+AC_ARG_ENABLE(resolver,
+  [AC_HELP_STRING([--enable-experimental-resolver],
+  [Build and install the experimental resolver [default=no]])],
+  [enable_resolver=$enableval], [
+   if test "$components_selection" = "reallyall" ; then
+     enable_resolver=yes
+   fi
+])
+
+AM_CONDITIONAL([ENABLE_RESOLVER], [test "$enable_resolver" = "yes"])
+AC_SUBST(ENABLE_RESOLVER)
+if test "x$enable_resolver" = "xyes" ; then
+  components_list="$components_list resolver"
+fi
+
+])dnl AX_BIND10_COMPONENTS
diff --git a/src/bin/Makefile.am b/src/bin/Makefile.am
index ea2f1b2..104dc8b 100644
--- a/src/bin/Makefile.am
+++ b/src/bin/Makefile.am
@@ -1,11 +1,15 @@
-if BUILD_EXPERIMENTAL_RESOLVER
-# Build resolver only with --enable-experimental-resolver
-experimental_resolver = resolver
+SUBDIRS = bind10 bindctl cfgmgr ddns loadzone msgq cmdctl auth xfrin \
+	xfrout usermgr zonemgr stats tests \
+	sockcreator dbutil sysinfo
+
+if ENABLE_DHCP
+SUBDIRS += dhcp4 dhcp6 d2
 endif
 
-SUBDIRS = bind10 bindctl cfgmgr ddns loadzone msgq cmdctl auth xfrin \
-	xfrout usermgr zonemgr stats tests $(experimental_resolver) \
-	sockcreator dhcp4 dhcp6 d2 dbutil sysinfo
+if ENABLE_RESOLVER
+# Build resolver only with --enable-experimental-resolver
+SUBDIRS += resolver
+endif
 
 if USE_SHARED_MEMORY
 # Build the memory manager only if we have shared memory.
diff --git a/src/lib/Makefile.am b/src/lib/Makefile.am
index 59cb8e1..6e4fb11 100644
--- a/src/lib/Makefile.am
+++ b/src/lib/Makefile.am
@@ -1,8 +1,11 @@
-if BUILD_EXPERIMENTAL_RESOLVER
-# Build resolver only with --enable-experimental-resolver
-experimental_resolver = resolve
+SUBDIRS = exceptions util log hooks cryptolink dns cc config acl xfr bench \
+          asiolink asiodns nsas cache testutils \
+          datasrc server_common python statistics
+
+if ENABLE_LIBDHCP
+SUBDIRS += dhcp dhcp_ddns dhcpsrv
 endif
 
-SUBDIRS = exceptions util log hooks cryptolink dns cc config acl xfr bench \
-          asiolink asiodns nsas cache $(experimental_resolver) testutils \
-          datasrc server_common python dhcp dhcp_ddns dhcpsrv statistics
+if ENABLE_RESOLVER
+SUBDIRS += resolve
+endif



More information about the bind10-changes mailing list