aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorAlex Merry <alex.merry@kde.org>2014-06-03 15:26:47 +0100
committerAlex Merry <alex.merry@kde.org>2014-06-17 19:17:14 +0100
commitbd22dc73a6da58dea8b709ef27f4c11eb598f42c (patch)
tree41a74cbf7fa9df1433a754277933b586041f9e13 /CMakeLists.txt
parent3afc8f9875979e57cce97edd68a5971d6771e097 (diff)
downloadextra-cmake-modules-bd22dc73a6da58dea8b709ef27f4c11eb598f42c.tar.gz
extra-cmake-modules-bd22dc73a6da58dea8b709ef27f4c11eb598f42c.tar.bz2
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
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt7
1 files 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/)