Trying to build QtWebKit for QNX using the bbndk 2.0.1 which uses gcc 4.4.2, I ran across the following issue: make[2]: Entering directory `/home/milian/projects/qt5/build-playbook/qtwebkit/Release/Source' rm -f libQtWebKit.so.5.0.0 libQtWebKit.so libQtWebKit.so.5 libQtWebKit.so.5.0 qcc -Vgcc_ntoarmv7le -lang-c++ -Wl,-rpath-link,/home/milian/bbndk-2.0.1/target/qnx6/armle-v7/lib -Wl,-rpath-link,/home/milian/bbndk-2.0.1/target/qnx6/armle-v7/usr/lib -Wl,-O1 -Wl,-rpath,/home/milian/projects/qt5/install-playbook/lib -Wl,-rpath,/home/milian/projects/qt5/install-playbook/lib -shared -Wl,-Bsymbolic-functions -Wl,-soname,libQtWebKit.so.5 -o libQtWebKit.so.5.0.0 -L/home/milian/bbndk-2.0.1/target/qnx6/armle-v7/lib -L/home/milian/bbndk-2.0.1/target/qnx6/armle-v7/usr/lib -L/home/milian/projects/qt5/build-playbook/qtwebkit/Release/Source/WebKit/release -L/home/milian/projects/qt5/build-playbook/qtwebkit/Release/Source/WebKit2/release -L/home/milian/projects/qt5/build-playbook/qtwebkit/Release/Source/WebCore/release -L/home/milian/projects/qt5/build-playbook/qtwebkit/Release/Source/JavaScriptCore/release -L/home/milian/projects/qt5/build-playbook/qtwebkit/Release/Source/WTF/release -L/home/milian/projects/qt5/install-playbook/lib -Wl,-whole-archive -lWebKit1 -Wl,-no-whole-archive -Wl,-whole-archive -lWebKit2 -Wl,-no-whole-archive -Wl,-whole-archive -lWebCore -Wl,-no-whole-archive -lz -ljpeg -lpng -Wl,-whole-archive -lJavaScriptCore -Wl,-no-whole-archive -Wl,-whole-archive -lWTF -Wl,-no-whole-archive -licui18n -licuuc -licudata -lnbutil -lQtQuick -L/home/milian/projects/qt5/build-playbook/qtdeclarative/lib -lQtPrintSupport -lQtXmlPatterns -lQtQml -lQtV8 -lbacktrace -lQtWidgets -lQtSql -lQtNetwork -lsocket -lQtGui -lQtCore -lm -lbps -lGLESv2 -lEGL cc: no files to process Here is an excerpt of a discussion with tronical in #qtwebkit on Freenode IRC: [13:03] <milian> I'm trying to get it build for qnx which worked ~2months ago... trying to rebase my patches and getting them upstreamed now, I hit this strange error and am really lost [13:03] <milian> is it a qmake bug? [13:04] <tronical> milian: sort of a gcc bug :) [13:04] <milian> is there something I can do to work around it? [13:05] <tronical> milian: the way we build webkit is that we build webcore, javascriptcore, etc. as static libraries [13:05] <tronical> milian: and then link them all together into libqtwebkit.so [13:05] <tronical> milian: it's that last linking step that doesn't involve any .cpp files [13:06] <tronical> milian: it's just gcc -o libqtwebkit.so libwebcore libwtf.a ... [13:06] <tronical> milian: (just linking, no -c as parameter) [13:06] <tronical> milian: gcc and mscv can handle it [13:06] <tronical> milian: see for example -Wl,-whole-archive -lJavaScriptCore -Wl,-no-whole-archive in your paste [13:07] <milian> ok, and this got fixed with a newer gcc? [13:07] <tronical> milian: I haven't run into any gcc yet that doesn't support it, so I'm curious why this fails for you :) [13:08] <tronical> milian: if you take that commandline and change the -Wl,-whole-archive -lJavaScriptCore -Wl,no-whole-archive to -Wl,-whole-archive ../path/to/libJavaScriptCore.a -Wl,-no-whole-archive , does it work then? [13:15] <tronical> milian: alternatively easy workaround: [13:15] <milian> yes, now it's linking [13:15] <tronical> milian: add a dummy .cpp file, add it to api.pri [13:16] <tronical> milian: if that works then it sounds very much like a gcc bug or incorrect serach paths [13:17] <milian> seems to be gcc 4.4.2 in qnx bbndk [13:19] <milian> I'll try to add the dummy .cpp file there, would that be acceptable to be pushed upstream (just for qnx of course)? [13:20] <tronical> milian: yeah, I think that's okay. it should probably be a generated file (i.e. using QMAKE_EXTRA_TARGETS and GENERATED_SOURCES) I'll now try to implement what tronical suggests and prepare a patch.
Created attachment 157195 [details] Patch
Comment on attachment 157195 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=157195&action=review > Source/api.pri:150 > + dummyfile.commands = touch $$dummyfile.target I think you could also use echo > $$dummyfile.target and it would work on Windows, in case we need it there at some point.
Shall I change that now or can it stay like that for now? Is anything else required from my side to get this patch upstream?
(In reply to comment #3) > Shall I change that now or can it stay like that for now? Is anything else required from my side to get this patch upstream? No, I think it's okay as is. Would you like to use the commit queue to land it? Then set cq? :)
Comment on attachment 157195 [details] Patch patch is missing updates to the changelog and it probably won't apply against master anyways due to updates to api.pri, I'll update it now.
Created attachment 158286 [details] Patch
Comment on attachment 158286 [details] Patch Clearing flags on attachment: 158286 Committed r125544: <http://trac.webkit.org/changeset/125544>
All reviewed patches have been landed. Closing bug.