[PATCH] configure.ac: Fix up --with-profiler test

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



According to http://www.gnu.org/software/autoconf/manual/autoconf.html,
the <action-if-given> test for AC_ARG_WITH is done if either of
--with-package or --without-package is on the configure line.
The <action-if-not-given> is done if neither is present on
the command line.

This commit causes both --without-profiler and --with-profiler=no
to work correctly.  It also allows a default configure/build
(i.e. --with-profiler not specified) to work correctly on a system
that does not have the appropriate profiling library.

Signed-off-by: Jim Schutt <jaschut@xxxxxxxxxx>
---
 configure.ac |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/configure.ac b/configure.ac
index c76f605..9357a47 100644
--- a/configure.ac
+++ b/configure.ac
@@ -37,9 +37,9 @@ PKG_CHECK_MODULES([CRYPTOPP], [libcrypto++], [], [
 # profiler?
 AC_ARG_WITH([profiler],
             [AS_HELP_STRING([--with-profiler], [build extra profiler binaries])],
-	    [with_profiler=yes],
+	    [],
             [with_profiler=no])
-AS_IF([test "x$with_profiler" != xyes],
+AS_IF([test "x$with_profiler" != xno],
 	    [AC_CHECK_LIB([profiler], [ProfilerFlush], [],
 	        	  [AC_MSG_FAILURE([--with-profiler was given but libprofiler (libgoogle-perftools-dev on debian) not found])])],
 	    [])
-- 
1.6.6


--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [CEPH Users]     [Ceph Large]     [Information on CEPH]     [Linux BTRFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux