Files
cmake/Tests/RunCMake/CXXModules/NoScanningFileSetProperty.cmake
Marc Chevrier df0a2aca6d FILE_SET: Add CXX_SCAN_FOR_MODULES property for per-file-set scanning control
This is more specific than both the target property and the
directory-wide source file property of the same name.
2026-04-03 09:29:29 -04:00

17 lines
521 B
CMake

enable_language(CXX)
unset(CMAKE_CXX_SCANDEP_SOURCE)
add_executable(noscanning-fs-property)
target_sources(noscanning-fs-property PRIVATE
FILE_SET SOURCES FILES sources/module-use.cxx)
set_target_properties(noscanning-fs-property
PROPERTIES
CXX_STANDARD 20
CXX_STANDARD_REQUIRED ON
CXX_SCAN_FOR_MODULES 0)
set_source_files_properties(sources/module-use.cxx
PROPERTIES
CXX_SCAN_FOR_MODULES 0)
set_property(FILE_SET SOURCES TARGET noscanning-fs-property
PROPERTY CXX_SCAN_FOR_MODULES 1)