[CMake] Different memcheck options for different tests

Roland Schulz roland at utk.edu
Fri Dec 16 17:05:34 EST 2011


Hi,

how can I specify different memcheck options (e.g.
CTEST_MEMORYCHECK_COMMAND_OPTIONS) for different tests. Ideally I
would like to be able to specify it depending on the test label or the
directory.

Ideally I could run "ctest -D ExperimentalMemCheck" and each test
would be run with the respective options.
But it would also be OK to have to run ctest more than once for the
different labels.

I have tried:
1) setting CTEST_MEMORYCHECK_COMMAND_OPTIONS different in the
respective CMakeLists.txt per folder
2) setting CTEST_MEMORYCHECK_COMMAND_OPTIONS as an environment
variable before executing ctest.

This both doesn't seem to work.

What would be the best approach to set different options for different tests?

Roland

-- 
ORNL/UT Center for Molecular Biophysics cmb.ornl.gov
865-241-1537, ORNL PO BOX 2008 MS6309


More information about the CMake mailing list