From 667b60db8feddc3bc72094e1e5b142abbb6f28d8 Mon Sep 17 00:00:00 2001 From: Lanchid Date: Fri, 7 Dec 2012 13:34:05 +0100 Subject: [PATCH] Added absolute path names for command line parameters for valgrind in make targets (by CMAKE variables), so it should work with out of source builds; and a dependency to the executables (so it is built automatically if that has not been done before) --- CMakeLists.txt | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 77b790509..46518e999 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -189,5 +189,8 @@ configure_file ( "${PROJECT_BINARY_DIR}/mrmc-config.h" ) -add_custom_target(memcheck valgrind --leak-check=full --show-reachable=yes ./mrmc examples/dtmc/crowds/crowds5_5.tra examples/dtmc/crowds/crowds5_5.lab) -add_custom_target(memcheck-tests valgrind --leak-check=full --show-reachable=yes ./mrmc-tests) +add_custom_target(memcheck valgrind --leak-check=full --show-reachable=yes ${PROJECT_BINARY_DIR}/mrmc ${PROJECT_SOURCE_DIR}/examples/dtmc/crowds/crowds5_5.tra examples/dtmc/crowds/crowds5_5.lab + DEPENDS mrmc) +add_custom_target(memcheck-tests valgrind --leak-check=full --show-reachable=yes ${PROJECT_BINARY_DIR}/mrmc-tests + DEPENDS mrmc-tests) +