Hitting this on arm-buildroot-linux-gnueabihf with GCC 9.2.0, [ 74%] Linking CXX executable ../../../bin/jsc /home/cht/igalia/buildroot/output/host/lib/gcc/arm-buildroot-linux-gnueabihf/9.2.0/../../../../arm-buildroot-linux-gnueabihf/bin/ld: ../../../lib/../Source/JavaScriptCore/CMakeFiles/JavaScriptCore.dir/__/__/DerivedSources/JavaScriptCore/unified-sources/UnifiedSource-f2e18ffc-25.cpp.o: in function `JSC::ExecutableBase::hasJITCodeFor(JSC::CodeSpecializationKind) const': /home/cht/igalia/buildroot/output/build/wpewebkit-2.26.4/Source/JavaScriptCore/runtime/ExecutableBase.h:183: undefined reference to `JSC::ExecutableBase::hasJITCodeForCall() const' /home/cht/igalia/buildroot/output/host/lib/gcc/arm-buildroot-linux-gnueabihf/9.2.0/../../../../arm-buildroot-linux-gnueabihf/bin/ld: /home/cht/igalia/buildroot/output/build/wpewebkit-2.26.4/Source/JavaScriptCore/runtime/ExecutableBase.h:185: undefined reference to `JSC::ExecutableBase::hasJITCodeForConstruct() const' collect2: error: ld returned 1 exit status Adding #include "ExecutableBaseInlines.h" to Source/JavaScriptCore/runtime/NativeExecutable.cpp fixes the issue, not sure if that's the best solution.
Created attachment 391047 [details] Patch
Comment on attachment 391047 [details] Patch Not sure if this its the best fix. Source/JavaScriptCore/runtime/ExecutableBase.h declares the function prototype for hasJITCodeForCall() and hasJITCodeForConstruct() but ExecutableBase.cpp doesn't define the function hasJITCodeForCall() neither hasJITCodeForConstruct() The functions hasJITCodeForCall() and hasJITCodeForConstruct() seem defined in ScriptExecutable.h I wonder if a better fix would be to remove from ExecutableBase.h the prototypes of hasJITCodeForCall() and hasJITCodeForConstruct() and include ScriptExecutable.h inside ExecutableBase.h ?
(In reply to Carlos Alberto Lopez Perez from comment #2) > Comment on attachment 391047 [details] > Patch > > Not sure if this its the best fix. > > Source/JavaScriptCore/runtime/ExecutableBase.h declares the function > prototype for hasJITCodeForCall() and hasJITCodeForConstruct() but > ExecutableBase.cpp doesn't define the function hasJITCodeForCall() neither > hasJITCodeForConstruct() > > The functions hasJITCodeForCall() and hasJITCodeForConstruct() seem defined > in ScriptExecutable.h They're also in ExecutableBaseInlines.h, and I don't know what purpose this organisation serves. I guess for some sort of ODR-workaround? > > I wonder if a better fix would be to remove from ExecutableBase.h the > prototypes of hasJITCodeForCall() and hasJITCodeForConstruct() and include > ScriptExecutable.h inside ExecutableBase.h ? ScriptExectable is a subclass and the base needs visibility of these symbols, so removing their prototypes doesn't work correctly. This is a hairy organisation which I think is best left to the discretion of a JSC maintainer.
Comment on attachment 391047 [details] Patch r=me
Comment on attachment 391047 [details] Patch Clearing flags on attachment: 391047 Committed r257695: <https://trac.webkit.org/changeset/257695>
All reviewed patches have been landed. Closing bug.