From 0cfa8b7cea63d5f319bbc4fe0fc7bc10fa390c3c Mon Sep 17 00:00:00 2001 From: Jimmy Tremblay-Bernier Date: Thu, 21 Nov 2024 16:25:34 -0500 Subject: [PATCH] CONGE-1 Special case between windows and mac. Will have to test if it's the case on other machines --- CMakeLists.txt | 10 +++++++--- Configure.bat | 4 ++-- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6bc9f3d..fa0168c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -18,10 +18,14 @@ endif() set(CMAKE_BINARY_DIR ${CMAKE_SOURCE_DIR}/build) # Include the Conan-generated files -list(APPEND CMAKE_PREFIX_PATH "${CMAKE_BINARY_DIR}/${CMAKE_BUILD_TYPE}/generators") - -include("${CMAKE_BINARY_DIR}/${CMAKE_BUILD_TYPE}/generators/conan_toolchain.cmake") +IF (WIN32) + list(APPEND CMAKE_PREFIX_PATH "${CMAKE_BINARY_DIR}/${CMAKE_BUILD_TYPE}/generators") + include("${CMAKE_BINARY_DIR}/generators/conan_toolchain.cmake") +ELSE() + list(APPEND CMAKE_PREFIX_PATH "${CMAKE_BINARY_DIR}/generators") + include("${CMAKE_BINARY_DIR}/generators/conan_toolchain.cmake") +ENDIF() # Set common output directories set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_SOURCE_DIR}/intermediates/${CMAKE_BUILD_TYPE}/${ARCH}/${PROJECT_NAME}) diff --git a/Configure.bat b/Configure.bat index 95abdad..e4a13c0 100644 --- a/Configure.bat +++ b/Configure.bat @@ -2,7 +2,7 @@ rmdir build /s /q @REM DEBUG -conan install . -of build -s build_type=Debug --build=missing +conan install . -s build_type=Debug --build=missing @REM RELEASE -conan install . -of build -s build_type=Release --build=missing +conan install . -s build_type=Release --build=missing