mirror of
https://github.com/catchorg/Catch2.git
synced 2024-11-25 23:06:10 +01:00
CatchMiscFunctions.cmake: Use PRIVATE for target_compile_options (#2553)
With the changes to how `-ffile-prefix-map` is detected, Catch2 started propagating the flag to its dependents, which isn't the desired behaviour, the normalization should only apply to Catch2's impl.
This commit is contained in:
parent
a43f67962e
commit
8ce92d2c72
@ -13,7 +13,7 @@ function(add_cxx_flag_if_supported_to_targets flagname targets)
|
|||||||
|
|
||||||
if (HAVE_FLAG_${flag_identifier})
|
if (HAVE_FLAG_${flag_identifier})
|
||||||
foreach(target ${targets})
|
foreach(target ${targets})
|
||||||
target_compile_options(${target} PUBLIC ${flagname})
|
target_compile_options(${target} PRIVATE ${flagname})
|
||||||
endforeach()
|
endforeach()
|
||||||
endif()
|
endif()
|
||||||
endfunction()
|
endfunction()
|
||||||
|
Loading…
Reference in New Issue
Block a user