aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2020-08-28 15:13:10 +0200
committerShauren <shauren.trinity@gmail.com>2022-02-04 11:01:08 +0100
commit94668343c6638e03c0c787580ed5527cdc6a1b07 (patch)
treeb7fda9d44da1402b98cb78c61fe684f0399fd391 /CMakeLists.txt
parentbb185a78fb7edf8291ee92f5b71bc1b264b6a8c3 (diff)
Build: Prevent Catch from messing with user cmake preferences
Closes #25348 (cherry picked from commit 822a1a86d1b504b54a8623b6899b3c23e9486a39)
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt6
1 files changed, 6 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5bb85d960dd..957a2cc1fa1 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()