The ANGLE Xcode project contains two Build Phases: one that copies some headers, and another that modifies those headers. This combination does not work with XCBuild, which gets confused when it finds that headers that it's copied have been changed. When it detects this, XCBuild thinks that it should recopy those headers on the next build, causing their modification dates to change and for all dependent files to be rebuilt. This essentially turns an incremental rebuild into a full rebuild. Address this problem by using a new facility in Xcode 11. This facility supports the copying and modifying headers files in a single step. It is achieved by first enabling the facility by setting APPLY_RULES_IN_COPY_HEADERS to YES. Next, we add a new Build Rule that invokes a custom script when the header files are copied. Third, we provide this script, which can essentially be a stripped down version of the one already used to modify the exported headers files. Finally, we disable the use of that old script when we are using Xcode 11. In this way, the old script that modifies the exported headers is used in Xcode 10, and the new facility is used in Xcode 11. See also Bug 197340 for where this process was also applied to JavaScriptCore, WebKit, and WebKitLegacy.
<rdar://problem/54410420>
Created attachment 376548 [details] Patch
Note that there are important steps to take when updating ANGLE. See http://trac.webkit.org/wiki/UpdatingANGLE
Comment on attachment 376548 [details] Patch Clearing flags on attachment: 376548 Committed r248813: <https://trac.webkit.org/changeset/248813>
All reviewed patches have been landed. Closing bug.