From c4ca9aef9f903bd5d278389fa4bdb7e52398b597 Mon Sep 17 00:00:00 2001 From: Chris Glover Date: Fri, 30 Oct 2026 10:50:40 +0000 Subject: [PATCH] Replace CONFIGURE_DEPENDS with BOOST_CONFIGURE_DEPENDS Allows projects building boost via add_subdirectory to avoid the cost of GLOB on every build. --- CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 0459e595..2ad1a459 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -260,7 +260,7 @@ endif () # Library # #------------------------------------------------- -file(GLOB_RECURSE BOOST_OPENMETHOD_HEADERS CONFIGURE_DEPENDS include/boost/*.hpp) +file(GLOB_RECURSE BOOST_OPENMETHOD_HEADERS ${BOOST_CONFIGURE_DEPENDS} include/boost/*.hpp) set_property(GLOBAL PROPERTY USE_FOLDERS ON) source_group(TREE ${CMAKE_CURRENT_SOURCE_DIR}/include/boost PREFIX "" FILES ${BOOST_OPENMETHOD_HEADERS}) @@ -288,7 +288,7 @@ endfunction() add_library(boost_openmethod INTERFACE) -if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.19) +if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.19 AND CMAKE_GENERATOR MATCHES "Visual Studio") target_sources(boost_openmethod PRIVATE ${BOOST_OPENMETHOD_HEADERS}) endif()