1- # Copyright 2018-2023 Peter Dimov
1+ # Copyright 2018-2025 Peter Dimov
22# Distributed under the Boost Software License, Version 1.0.
33# https://www.boost.org/LICENSE_1_0.txt
44
5- # We support CMake 3.5 , but prefer 3.20 policies and behavior
6- cmake_minimum_required (VERSION 3.5 ...3.20 )
5+ # We support CMake 3.8 , but prefer 3.31 policies and behavior
6+ cmake_minimum_required (VERSION 3.8 ...3.31 )
77
88project (boost_assert VERSION "${BOOST_SUPERPROJECT_VERSION} " LANGUAGES CXX)
99
@@ -17,14 +17,14 @@ target_link_libraries(boost_assert
1717 Boost::config
1818)
1919
20- if ( CMAKE_VERSION VERSION_GREATER 3.18 AND CMAKE_GENERATOR MATCHES "Visual Studio" )
20+ # Add headers and .natvis to project, for better IDE integration
2121
22- file (GLOB_RECURSE boost_assert_IDEFILES CONFIGURE_DEPENDS include /*.hpp)
23- source_group (TREE ${PROJECT_SOURCE_DIR} /include FILES ${boost_assert_IDEFILES } PREFIX "Header Files" )
24- list ( APPEND boost_assert_IDEFILES extra/boost_assert.natvis )
25- target_sources (boost_assert PRIVATE ${boost_assert_IDEFILES} )
22+ file (GLOB_RECURSE boost_assert_HDRFILES CONFIGURE_DEPENDS include /*.hpp)
23+ source_group (TREE ${PROJECT_SOURCE_DIR} /include FILES ${boost_assert_HDRFILES } PREFIX "Header Files" )
24+ target_sources (boost_assert PRIVATE ${boost_assert_HDRFILES} )
25+ unset (boost_assert_HDRFILES )
2626
27- endif ( )
27+ target_sources (boost_assert PUBLIC extra/boost_assert.natvis )
2828
2929# BUILD_TESTING is the standard CTest variable that enables testing
3030
0 commit comments