[Webkit-unassigned] [Bug 183788] Non-deterministic build failure (missing JavaScriptCore/JSContextRef.h)

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Mar 31 08:12:21 PDT 2018


https://bugs.webkit.org/show_bug.cgi?id=183788

li <crispyfrog at 163.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |crispyfrog at 163.com

--- Comment #4 from li <crispyfrog at 163.com> ---
This bug happens every time for me. I build it with ninja -j1.
I think the problem is in some CMake rules.
The missing header JavaScriptCore/JsContextRef.h should be generated during build, as with many other headers, they're are copied from their respective locations to build/DerivedSources/ForwardingHeaders. There's a rule in build/build.ninja to make this happen: 
build JavascriptCoreForwardingHeaders: phony Source/JavaScriptCore/JavaScriptCoreForwardingHeaders

This rule should be a prerequisite of JavaScriptCore, but it doesn't happen due to some bugs in Cmake rules I suppose.

The lines in Cmake files to generate the ninja rules are at: Source/JavaScriptCore/CMakeLists.txt:1152,
it calls function WEBKIT_MAKE_FORWARDING_HEADERS, which is defined at Source/cmake/WebKitMacros.cmake
:218

Here line 267 might be the problem: add_dependencies(...)
in short, this line should instruct cmake to add JavaScriptCoreForwardingHeaders as a prerequisite for JavaScriptCore in the generated ninja build file, but for some reason it doesn't work.

Due to my limited knowledge to CMake, I couldn't​ figure out the right way to fix this. Well still there's a workaround, that is to call ninja to generate those headers explicitly. Do this after cmake and before you run ninja to build: 
ninja JavaScriptCoreForwardingHeaders WTFForwardingHeaders

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180331/3fa870f3/attachment.html>


More information about the webkit-unassigned mailing list