summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorNiels de Vos <ndevos@redhat.com>2015-03-03 00:27:34 +0100
committerKaleb KEITHLEY <kkeithle@redhat.com>2015-03-31 04:11:17 -0700
commit9c37b68bc15c503a0ad5cc2fb04be7b917496d90 (patch)
tree0f8436ca340035c164a727144eba34fdf983d539 /configure.ac
parent6df8d1d8781f59fbab46c4b016dde0b2d33dd189 (diff)
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 <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/9801 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Andreas Schneider <asn@fedoraproject.org> Tested-by: Andreas Schneider <asn@fedoraproject.org> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac11
1 files changed, 3 insertions, 8 deletions
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])