From 9c37b68bc15c503a0ad5cc2fb04be7b917496d90 Mon Sep 17 00:00:00 2001 From: Niels de Vos Date: Tue, 3 Mar 2015 00:27:34 +0100 Subject: build: require cmocka >= 1.0.1 Our mem-pool unit test does a funky realloc(ptr, 0) as an alternative to free(ptr). cmocka 1.0.0 has a bug where this is not handled correctly and thinks to detect a memory leak. The next cmocka release will have this bug fixed, making our unit tests require cmocka >= 1.0.1. URL: https://cmocka.org/archive/cmocka/2015-02/0000059.html Change-Id: I3d7f9b4cf7ace3f958158425ecbcc8f176579122 BUG: 1067059 Signed-off-by: Niels de Vos Reviewed-on: http://review.gluster.org/9801 Tested-by: Gluster Build System Reviewed-by: Andreas Schneider Tested-by: Andreas Schneider Reviewed-by: Kaleb KEITHLEY --- configure.ac | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 7392b706bb8..5fe304abf4d 100644 --- a/configure.ac +++ b/configure.ac @@ -1196,14 +1196,9 @@ AC_ARG_ENABLE([cmocka], [Enable cmocka build options.])) if test "x$enable_cmocka" = "xyes"; then BUILD_UNITTEST="yes" - PKG_CHECK_MODULES([UNITTEST], [cmocka], [],[ - AC_CHECK_LIB([cmocka], [mock_assert], [ - UNITTEST_LDFLAGS="-lcmocka -lgcov" - UNITTEST_CFLAGS="-Wall -Werror" - ], [ - AC_MSG_ERROR([cmocka library is required to build glusterfs]) - ]) - ]) + PKG_CHECK_MODULES([UNITTEST], [cmocka >= 1.0.1], [BUILD_UNITTEST="yes"], + [AC_MSG_ERROR([cmocka library is required to build glusterfs])] + ) fi AM_CONDITIONAL([UNITTEST], [test x$BUILD_UNITTEST = xyes]) -- cgit