From 9c1bdb2bc84ac6caa30cf3e28a73b8430615469e Mon Sep 17 00:00:00 2001 From: j-berman Date: Fri, 18 Sep 2026 03:03:07 -0700 Subject: [PATCH] cmake: static builds need to indicate desired boost build variant --- CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index d27cd0180..fe5702b34 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -946,6 +946,11 @@ if(STATIC) set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${STATIC_FLAGS} ") endif() +if(STATIC) + set(Boost_USE_STATIC_LIBS ON) + set(Boost_USE_STATIC_RUNTIME ON) +endif() + # Find Boost headers set(BOOST_MIN_VER 1.69) find_package(Boost ${BOOST_MIN_VER} QUIET REQUIRED CONFIG)