From bfd964961ea5006a8547e3653e9fa260ca2b470e Mon Sep 17 00:00:00 2001 From: Farmer_Markus <145863173+Farmer-Markus@users.noreply.github.com> Date: Fri, 15 Aug 2025 19:38:06 +0200 Subject: [PATCH] Added boost source build support --- CMakeLists.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index d65ba4e..c232f78 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -18,7 +18,11 @@ option(TURTLE_INSTALL "Enable to add install target" ${IS_ROOT_PROJECT}) if(WIN32 AND NOT DEFINED Boost_USE_STATIC_LIBS) set(Boost_USE_STATIC_LIBS ON) endif() -find_package(Boost 1.58 REQUIRED) + +# Allows boost to be build by parent project +if(NOT TARGET Boost::boost) + find_package(Boost 1.58 REQUIRED) +endif() set(MOCK_VERSION "\"${PROJECT_VERSION}\"") set(_turtleVersionFile ${CMAKE_CURRENT_BINARY_DIR}/include/turtle/version.hpp)