From bd43426210b2d12dcf617e942203630d88569cce Mon Sep 17 00:00:00 2001 From: tasn Date: Tue, 2 Aug 2011 10:50:13 +0000 Subject: [PATCH] Eina: Moved valgrind check to the libararies check section. As suggested by vtorri. git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/eina@61990 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- configure.ac | 57 +++++++++++++++++++++++++++++---------------------------- 1 file changed, 29 insertions(+), 28 deletions(-) diff --git a/configure.ac b/configure.ac index 73f918e..b5996e5 100644 --- a/configure.ac +++ b/configure.ac @@ -150,34 +150,6 @@ if test "x${have_magic_debug}" = "xyes" ; then fi AC_SUBST(EINA_CONFIGURE_MAGIC_DEBUG) -# Valgrind -want_valgrind="auto" -have_valgrind="no" - -AC_MSG_CHECKING(whether to enable build with valgrind) -AC_ARG_ENABLE(valgrind, - AC_HELP_STRING([--enable-valgrind], [improve valgrind support by hinting it of our memory usages, having it to report proper mempool leaks.]), - [want_valgrind=$enableval] -) -AC_MSG_RESULT($want_valgrind) - -if test "x${want_valgrind}" = "xyes" -o "x${want_valgrind}" = "xauto"; then - PKG_CHECK_MODULES(VALGRIND, valgrind >= 2.4.0, - [ - requirement_eina="valgrind ${requirement_eina}" - have_valgrind="yes" - ], - [ - AC_DEFINE(NVALGRIND, 1, [Valgrind support disabled]) - if test "x$want_valgrind" = "xyes"; then - AC_MSG_ERROR([Valgrind >= 2.4.0 is required)]) - fi - ] - ) -else - AC_DEFINE(NVALGRIND, 1, [Valgrind support disabled]) -fi - # Safety checks (avoid crashes on wrong api usage) AC_ARG_ENABLE(safety-checks, [AC_HELP_STRING([--disable-safety-checks], [disable safety checks for NULL pointers and like. @<:@default=enabled@:>@])], @@ -308,6 +280,35 @@ EFL_CHECK_DOXYGEN([build_doc="yes"], [build_doc="no"]) ### Checks for libraries +# Valgrind +want_valgrind="auto" +have_valgrind="no" + +AC_MSG_CHECKING(whether to enable build with valgrind) +AC_ARG_ENABLE(valgrind, + AC_HELP_STRING([--enable-valgrind], [improve valgrind support by hinting it of our memory usages, having it to report proper mempool leaks.]), + [want_valgrind=$enableval] +) +AC_MSG_RESULT($want_valgrind) + +if test "x${want_valgrind}" = "xyes" -o "x${want_valgrind}" = "xauto"; then + PKG_CHECK_MODULES(VALGRIND, valgrind >= 2.4.0, + [ + requirement_eina="valgrind ${requirement_eina}" + have_valgrind="yes" + ], + [ + AC_DEFINE(NVALGRIND, 1, [Valgrind support disabled]) + if test "x$want_valgrind" = "xyes"; then + AC_MSG_ERROR([Valgrind >= 2.4.0 is required)]) + fi + ] + ) +else + AC_DEFINE(NVALGRIND, 1, [Valgrind support disabled]) +fi + + # Evil library for compilation on Windows CE EFL_EINA_BUILD="" -- 2.7.4