From bd22dc73a6da58dea8b709ef27f4c11eb598f42c Mon Sep 17 00:00:00 2001 From: Alex Merry Date: Tue, 3 Jun 2014 15:26:47 +0100 Subject: Provide an option to exclude the tests While the tests in ECM are not "built" as such (at least, not until they are run), disabling the tests might be desirable to avoid the compiler checks and to make the whole build process architecture-independent. REVIEW: 118498 --- CMakeLists.txt | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a92d621f..f3f751e5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -8,8 +8,11 @@ set(ECM_PATCH_VERSION 14) set(ECM_VERSION ${ECM_MAJOR_VERSION}.${ECM_MINOR_VERSION}.${ECM_PATCH_VERSION}) -enable_testing() -add_subdirectory(tests) +option(BUILD_TESTING "Build automated tests." ON) +if(BUILD_TESTING) + enable_testing() + add_subdirectory(tests) +endif() set(SHARE_INSTALL_DIR share) set(MODULES_INSTALL_DIR ${SHARE_INSTALL_DIR}/ECM/modules/) -- cgit v1.2.1