summaryrefslogtreecommitdiff
path: root/Modules/Internal/HeaderpadWorkaround.cmake
Commit message (Collapse)AuthorAgeFilesLines
* Modules:Check*: refactor: use block(SCOPE_FOR POLICIES)scivision2023-03-081-2/+2
|
* CheckSourceCompiles: Avoid linker warning with -fembed-bitcodeCraig Scott2022-04-091-0/+69
When the Apple linker sees -headerpad_max_install_names and bitcode is enabled with a flag like -fembed-bitcode, it issues a warning and ignores the -headerpad_max_install_names flag. This causes unrelated compiler and linker flag checks to fail for valid flags. In f745e0497e (CheckCompilerFlags: Catch linker warning about ignored flags, 2022-01-03), we started detecting linker warnings, which caused a regression for projects that were setting -fembed-bitcode in their CMAKE_CXX_FLAGS or similar. Prevent that regression by removing the -headerpad_max_install_names linker flag when we know it will warn and be ignored anyway. Fixes: #23390 Issue: #23408