diff options
author | Benjamin Dauvergne <bdauvergne@entrouvert.com> | 2010-09-17 17:00:21 +0200 |
---|---|---|
committer | Benjamin Dauvergne <bdauvergne@entrouvert.com> | 2010-09-17 17:02:41 +0200 |
commit | 88623c29f3dfb56483138961a4a906c75f48e355 (patch) | |
tree | 7d71195a4cef99f20cde5ba0c2d283a2ea41e7f6 /tests | |
parent | 19aad7629ad4c41a7b95ad0603cc72b59dbf07e6 (diff) | |
download | lasso-88623c29f3dfb56483138961a4a906c75f48e355.tar.gz lasso-88623c29f3dfb56483138961a4a906c75f48e355.tar.xz lasso-88623c29f3dfb56483138961a4a906c75f48e355.zip |
[Tests] add valgrind targets in the Makefile: leakcheck, leakcheck-reachable and massif
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Makefile.am | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/Makefile.am b/tests/Makefile.am index 20b408b0..15eb4e9a 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -40,6 +40,29 @@ perfs_SOURCES = perfs.c perfs_LDADD = $(top_builddir)/lasso/liblasso.la $(LASSO_LIBS) perfs_LDFLAGS = -rpath `cd $(top_builddir)/lasso/.libs/; pwd` +.PHONY: valgrind + +LEAKCHECK = G_DEBUG=gc-friendly MALLOC_CHECK_=2 G_SLICE=always-malloc CK_FORK=no \ + valgrind --leak-check=full --log-file=valgrind.log \ + --suppressions=$(top_srcdir)/tests/valgrind/glib.supp \ + --suppressions=$(top_srcdir)/tests/valgrind/openssl.supp \ + --suppressions=$(top_srcdir)/tests/valgrind/lasso.supp \ + --num-callers=50 + +LEAKCHECK_REACHABLE = $(LEAKCHECK) --show-reachable=yes + +MASSIF = G_DEBUG=gc-friendly MALLOC_CHECK_=2 G_SLICE=always-malloc CK_FORK=no \ + valgrind --tool=massif + +leakcheck: + $(LEAKCHECK) ./tests + +leakcheck-reachable: + $(LEAKCHECK_REACHABLE) ./tests + +massif: + $(MASSIF) ./tests + endif EXTRA_DIST = metadata valgrind tests.h $(tests_SOURCES) |