From ee98605f961c82a8f76ece4fae228bf4ddfed4c4 Mon Sep 17 00:00:00 2001 From: Kaushal M Date: Mon, 8 Apr 2013 16:49:34 +0530 Subject: build: Better configure control & messages for xml output Users were not given a correct indication to whether xml output was going to be built on running configure as the only information was lost in the checks output. This would lead to conditions where the user would assume gluster was compiled with xml output, when it wasn't the case. With this change, a new line is added to the end of the configure output which indicates if xml output is being built or not. Also, a new configure flag, '--disable-xml-output', has been introduced which can be used to explicitly disable xml outpu from being built. Change-Id: Ie80ba0372b4c3967a836769c61b60263c8e5e350 BUG: 947226 Signed-off-by: Kaushal M Reviewed-on: http://review.gluster.org/4793 Reviewed-by: Amar Tumballi Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- configure.ac | 25 ++++++++++++++++++------- 1 file changed, 18 insertions(+), 7 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 70cc7fd9f..ff8835eff 100644 --- a/configure.ac +++ b/configure.ac @@ -481,14 +481,24 @@ if test "x${DTRACE}" = "xyes" -a "x${SDT_H_FOUND}" = "xyes"; then fi # end of systemtap/dtrace -#check if libxml is present if so enable HAVE_LIB_XML -echo -n "checking if libxml2 is present... " - -AM_PATH_XML2([2.6.19]) - -if test "x${no_xml}" = "x"; then - AC_DEFINE([HAVE_LIB_XML], [1], [Define to 1 if using libxml2.]) +# xml-output +AC_ARG_ENABLE([xml-output], + AC_HELP_STRING([--disable-xml-output], + [Disable the xml output])) +BUILD_XML_OUTPUT="yes" +if test "x$enable_xml_output" != "xno"; then + #check if libxml is present if so enable HAVE_LIB_XML + AM_PATH_XML2([2.6.19]) + + if test "x${no_xml}" = "x"; then + AC_DEFINE([HAVE_LIB_XML], [1], [Define to 1 if using libxml2.]) + else + BUILD_XML_OUTPUT="no" + fi +else + BUILD_XML_OUTPUT="no" fi +# end of xml-output dnl FreeBSD > 5 has execinfo as a Ported library for giving a workaround dnl solution to GCC backtrace functionality @@ -803,4 +813,5 @@ echo "systemtap : $BUILD_SYSTEMTAP" echo "Block Device backend : $BUILD_BD_XLATOR" echo "glupy : $BUILD_GLUPY" echo "Use syslog : $USE_SYSLOG" +echo "XML output : $BUILD_XML_OUTPUT" echo -- cgit