From 1f23f7818e697109c89b446680d3262aaf06861a Mon Sep 17 00:00:00 2001 From: Chris Thrasher Date: Thu, 22 Jun 2023 14:33:41 -0600 Subject: [PATCH] Don't override `CMAKE_MODULE_PATH` The Conan package for SFML has to fix this so apparently it's a real world problem. --- cmake/Macros.cmake | 2 +- src/SFML/CMakeLists.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cmake/Macros.cmake b/cmake/Macros.cmake index e0118eb68..77a7d11e4 100644 --- a/cmake/Macros.cmake +++ b/cmake/Macros.cmake @@ -384,7 +384,7 @@ function(sfml_find_package) message(FATAL_ERROR "Unknown arguments when calling sfml_import_library: ${THIS_UNPARSED_ARGUMENTS}") endif() - set(CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake/Modules/") + list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake/Modules/") if (SFML_OS_IOS) find_host_package(${target} REQUIRED) else() diff --git a/src/SFML/CMakeLists.txt b/src/SFML/CMakeLists.txt index 84a770593..c60bc4fc9 100644 --- a/src/SFML/CMakeLists.txt +++ b/src/SFML/CMakeLists.txt @@ -40,7 +40,7 @@ elseif(SFML_OS_ANDROID) endif() # define the path of our additional CMake modules -set(CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake/Modules/") +list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake/Modules/") # set the output directory for SFML libraries set(LIBRARY_OUTPUT_PATH "${PROJECT_BINARY_DIR}/lib")