Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: d49b603f371fe2ae6cca41b5a1f008e1b03aba31
https://github.com/WebKit/WebKit/commit/d49b603f371fe2ae6cca41b5a1f008e1b03aba31
Author: Ben Nham <[email protected]>
Date: 2026-09-15 (Tue, 15 Sep 2026)
Changed paths:
M Source/cmake/WebKitMacros.cmake
Log Message:
-----------
[cmake] Fix race between linking WebKit and codesigning dylibs
https://bugs.webkit.org/show_bug.cgi?id=324218
rdar://problem/187440308
Reviewed by Jean-Yves Avenard.
After 320929@main, I am getting sporadic build failures like this:
[12882/12931] Linking Swift shared library
WebKit.framework/Versions/A/WebKit
FAILED: [code=1] WebKit.framework/Versions/A/WebKit
error: input file 'libANGLE-shared.dylib' was modified during the build
[12884/12931] Code signing ANGLE-shared
>From that log, it looks like these things are happening concurrently:
1. ld is linking WebKit against libANGLE-shared
2. codesign is codesigning libANGLE-shared
This causes the build to fail because ld will fail to link if it detects that
one of the libraries
you're linking against was modified while linking.
To fix this we need to have these dylibs (like libANGLE-shared, libwebrtc, and
WebKitSwift) sign
with _WEBKIT_ADD_CODE_SIGN in POST_BUILD. This will cause those binaries to get
signed before any
dependent steps start running. This already happens for executables. This patch
makes
_WEBKIT_ADD_CODE_SIGN in POST_BUILD happen for both executables and dylibs
(i.e. non-framework
targets).
Framework targets still need to sign last using the codesign stamping mechanism
so that they are
signed last after any embedded targets (e.g. WebKit.framework needs to sign
after the embedded
WebContent is signed).
* Source/cmake/WebKitMacros.cmake:
(_WEBKIT_ADD_CODE_SIGN):
Canonical link: https://commits.webkit.org/321176@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications