Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 8ecfbeadb8dd25228b17df9e36d9b46f27d4d847
https://github.com/WebKit/WebKit/commit/8ecfbeadb8dd25228b17df9e36d9b46f27d4d847
Author: Zak Ridouh <[email protected]>
Date: 2026-04-28 (Tue, 28 Apr 2026)
Changed paths:
M Source/WebCore/PAL/pal/CMakeLists.txt
M Source/cmake/WebKitMacros.cmake
Log Message:
-----------
[CMake] Fix CMake -Xcc flag deduplication in native Swift
target_compile_options
https://bugs.webkit.org/show_bug.cgi?id=312105
rdar://174612505
Reviewed by BJ Burg.
CMake's target_compile_options deduplicates repeated tokens, so
"-Xcc" "-I/a" "-Xcc" "-I/b" loses the second -Xcc and routes -I/b
to swiftc instead of the Clang importer. The custom typecheck
add_custom_command is unaffected. The bug was masked on Apple ports
by -explicit-module-build.
Fix by using the SHELL: prefix (CMake 3.12+) to keep each
"-Xcc <arg>" pair grouped, mirroring the pattern already in
Source/WebKit/PlatformMac.cmake.
* Source/WebCore/PAL/pal/CMakeLists.txt:
Mirror all six -Xcc -I pairs (and -swift-version 6) to native Swift
compilation using SHELL: form; previously only one of six reached it.
* Source/cmake/WebKitMacros.cmake:
(WEBKIT_SETUP_SWIFT_AND_GENERATE_SWIFT_CPP_INTEROP_HEADER): Pair -Xcc
with its argument as a single SHELL: entry when mirroring _swift_options
to target_compile_options.
Canonical link: https://commits.webkit.org/312235@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications