aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2020-08-28 15:13:10 +0200
committerShauren <shauren.trinity@gmail.com>2020-08-28 15:13:10 +0200
commit822a1a86d1b504b54a8623b6899b3c23e9486a39 (patch)
tree6932ea15c3902a8566d83694b75c67246130f7e7
parent19f69fcf060c4abba0cd3102529a4203eecac394 (diff)
Build: Prevent Catch from messing with user cmake preferences
Closes #25348
-rw-r--r--CMakeLists.txt6
1 files changed, 6 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index ef7a576a7b1..a7cb3a0f329 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -98,4 +98,10 @@ if(BUILD_TESTING)
include(Catch)
add_subdirectory(tests)
+
+ # Catch cmakefile messes with our settings we explicitly leave up to the user
+ # restore user preference
+ if (NOT WITH_SOURCE_TREE STREQUAL "hierarchical-folders")
+ set_property(GLOBAL PROPERTY USE_FOLDERS OFF)
+ endif()
endif()