Qt5 development primer



  • Hey All,

    For anybody wanting to contribute to Qt5 I have started a wiki article on how to go about getting the code for the modularised Qt5 and building it.

    Please feel free to edit for other platforms or as things change during development.

    [EDIT: Updated link from nokia.com to wiki.qt.io --JKSH]


  • Moderators

    Hi, I took the liberty to link to this thread from the wiki page :) I'd like to suggest a couple of changes, but on the other side do not want to start an edit war ...

    Don't advocate the use of "./qtrepotools/bin/qt5_tool -p" . It'll check out the master branches of every repo, which more likely than not break compilation . People who really want to live on the bleeding edge will find out how to achieve that ... There should be no further steps necessary (no git remote rm gerrit, no special webkit/v8 handling). It's IMO a high priority bug if that doesn't succeed, so don't advocate workarounds!

    Along the same line, a way to update Qt5 repo isn't qt5_tool -p, but git pull && git submodule update --recursive!



  • Hi! Please feel free to edit the wiki article as to the latest recommendations. I put the basic instructions up a while ago now so I am not surprised if much has changed. The usage of qt5_tool -p came from a troll on #qt-labs at the time.

    A quick question, if we should not use qt5_tool -p then why does it exist?

    Others have added the gerrit-related stuff and other bits and pieces.

    Could you add a brief not on how to live on the bleeding edge then please? This is supposed to be an article to help people do so so that they can contribute back under Open Governance.

    Many thanks for any input you can give.


  • Moderators

    Okay. The thing is that now Qt is modularized, every module moves at it's own speed, but there are of course dependencies. E.g. a recent change in qtbase might break qtdeclarative and so on ... There's no way we can ensure that all master branches at a time work with each other (also due to the CI system). Therefore the qt5.git repo contains a list of 'known' SHA's from every module that are known to work together. It's of course not bleeding edge, but a good baseline to start with.

    I'll do the changes now.



  • Hi. Thanks for the explanation. I may be back with more questions after I read the updated article. ;-)

    Thank you for taking the time to do this. The hope is that it will lower the entry barrier for external contributors.


  • Moderators

    Okay, done. I was bold and removed some of the more obscure hacks that IMO aren't needed any more.



  • Looks good. Many thanks once again.



  • Thanks, looks like a very useful resource!



  • I have a problem compiling modules other than qtbase even when following these instructions
    When running make I always get

    Project ERROR: Cannot load qmodule.pri!

    when trying to build qtsvg and qtxmlpatterns.

    Could the problem be that I am building in a different directory? Source is in ~/devel/qt5 and build dir is ~/devel/build/qt5



  • Quite possibly caused by using a shadow build. Try an in-tree build as this is much better tested at present.



  • I'm afraid I still get same issue with an in-tree build. Maybe I should try with a clean checkout.



  • It seems to work now with a clean checkout, however I get following compilation error:

    qsvgiconengine.cpp:47:26: fatal error: qsvgrenderer.h: File not found.
    compilation terminated.

    when compiling qtsvg.


  • Moderators

    Do you have a qsvgrenderer.h in qt5/qtsvg/include/QtSvG ? If not you can run "syncqt" in your qtsvg root directory.



  • I did a new clean build and for some reason it worked now. Thank you for your help.



  • On mac 10.6.8, I have problems building this. The linker complains about an nonexistent "OpenGl" library. After replacing with "OpenGL" (notice capital L) in the offending files* this issue resolves.
    Unfortunately QtQuick2.0 examples don't work. For some reason importing folders from QML files is not working as it should. qmlscene doesnt recognize the imported folders (despite the fact that they are there at the same level as the invoking qml file). I keep getting:

    .../somefile.qml: "SomeFolder": No such directory

    (*) among them:
    ./qtbase/src/platformsupport/cglconvenience/cglconvenience.pri: LIBS += -framework Cocoa -framework OpenGl


  • Moderators

    @jmfairlie: I'm not working on Mac OS X, sorry. You should raise your problems (after verifying that the problem is still there in latest master branch of e.g. qtbase) on IRC/freenode, #qt-labs channel . Or you raise it on qt5-feedback@qt.nokia.com .



  • Now I tried with Ubuntu 11.04 with an ATI gpu (might be relevant) and linker isn't able to find GL libraries. Indeed, for some reason, there is no /usr/lib/libGL.so in my machine (not sure if this is normal) but only in /usr/lib/mesa and /usr/lib/fglrx.

    If I add "-opengl desktop" to configure then it shows the message:

    The OpenGL functionality test failed!
    You might need to modify the include and library search paths by editing
    QMAKE_INCDIR_OPENGL, QMAKE_LIBDIR_OPENGL and QMAKE_LIBS_OPENGL in
    .../qt5/qtbase/mkspecs/linux-g++.

    If I follow the suggestion and add those lines to qtbase/mkspecs/linux-g++/qmake.conf :

    QMAKE_LIBDIR_OPENGL = /usr/lib/fglrx
    QMAKE_INCDIR_OPENGL = /usr/include/GL
    QMAKE_LIBS_OPENGL = -lGL

    It doesn't make a difference and linker is still unable to find the GL libraries, (I guess those macros are not being used)

    However if I just add a symlink to any of the GL libs to /usr/lib it finally finds them.

    Unfortunately, QtQuick2.0 examples (what I'm interested in) don't work either, this time qmlscene SEGFAULTS in a seemingly unrelated call ... I guess I'll need to wait until a more stable version comes out.


  • Moderators

    Ubuntu 11.04 is used heavily in the development teams, so this should really work out of the box, without any environment variable tinkering. The libgl1-mesa-dev should include the /usr/lib/libGL.so file, try installing this package. (Btw, you can find out which package provides which file by using the "apt-get file search" command).

    For reference, this is the output "configure -nokia-developer -nomake examples -nomake demos -nomake tests" gives me on an Ubuntu 11.04:

    @
    Build type: linux-g++
    Architecture: i386
    Host architecture: i386
    Platform notes:

            - Also available for Linux: linux-kcc linux-icc linux-cxx
    

    Build .................. libs
    Configuration .......... debug shared dll qpa largefile stl precompile_header mmx 3dnow sse sse2 sse3 ssse3 sse4_1 sse4_2 avx minimal-config small-config medium-config large-config full-config fontconfig xlib xcb-xlib phonon-backend accessibility opengl qpa reduce_exports clock-gettime clock-monotonic mremap getaddrinfo ipv6ifname getifaddrs inotify system-jpeg system-mng system-png png system-tiff system-freetype system-zlib nis cups glib gstreamer dbus openssl xcb alsa pulseaudio concurrent audio-backend svg v8 debug private_tests
    Debug .................. yes
    Qt 3 compatibility ..... no
    QtDBus module .......... yes (run-time)
    QtConcurrent code ...... yes
    QtGui module ........... yes
    QtScript module ........ yes
    QtScriptTools module ... yes
    QtXmlPatterns module ... yes
    Phonon module .......... yes
    Multimedia module ...... auto
    SVG module ............. yes
    WebKit module .......... yes
    JavaScriptCore JIT ..... To be decided by JavaScriptCore
    V8 module .............. yes
    Declarative module ..... yes
    Declarative debugging ...yes
    Location module ........ no
    Support for S60 ........ no
    Symbian DEF files ...... no
    STL support ............ yes
    PCH support ............ yes
    MMX/3DNOW/SSE/SSE2/SSE3. yes/yes/yes/yes/yes
    SSSE3/SSE4.1/SSE4.2..... yes/yes/yes
    AVX..................... yes
    IPv6 ifname support .... yes
    getaddrinfo support .... yes
    getifaddrs support ..... yes
    Accessibility .......... yes
    NIS support ............ yes
    CUPS support ........... yes
    Iconv support .......... no
    Glib support ........... yes
    GStreamer support ...... yes
    PulseAudio support ..... yes
    Large File support ..... yes
    GIF support ............ plugin
    TIFF support ........... plugin (system)
    JPEG support ........... plugin (system)
    PNG support ............ yes (system)
    MNG support ............ plugin (system)
    zlib support ........... system
    Session management ..... auto
    OpenGL support ......... yes (Desktop OpenGL)
    OpenVG support ......... no
    MySQL support .......... plugin
    SQLite support ......... plugin (qt)
    OpenSSL support ........ yes (run-time)
    Alsa support ........... yes
    ICD support ............ no
    libICU support ......... no
    Xcb support ............ limited (old version)
    @



  • this is what I got, I'll check on Monday if getting rid of the differences makes any difference:
    @
    --- a/jean
    +++ b/kkoehne
    -QtDBus module .......... no
    +QtDBus module .......... yes (run-time)
    -Phonon module .......... no
    +Phonon module .......... yes
    -CUPS support ........... no
    +CUPS support ........... yes
    -GStreamer support ...... no
    -PulseAudio support ..... no
    +GStreamer support ...... yes
    +PulseAudio support ..... yes
    -MNG support ............ plugin (qt)
    +MNG support ............ plugin (system)
    +MySQL support .......... plugin
    -OpenSSL support ........ no
    -Alsa support ........... no
    +OpenSSL support ........ yes (run-time)
    +Alsa support ........... yes
    @



  • pulled current latest version:

    commit 0a0d66efceb64bcacffbf733053834829c657df7
    Date: Wed Oct 19 07:38:37 2011 +1000

    and this time qmlscene spit some more info after segfault:

    "Cannot create platform GL context, none of GLX, EGL, DRI2 is enabled"

    This message directed me to:
    http://comments.gmane.org/gmane.comp.lib.qt.qml/3060

    which suggests to install libx11-xcb-dev. Indeed I didn't have it, so I installed, cleaned and rebuilt, and now it works.

    If this package is required for qtdeclarative to work properly shouldn't configure notice it and mention it somehow?
    Anyhow, Just added this info to the wiki page.



  • The installation was successful, but when I try to compile my own application I get the following error:
    QDeclarativeView: No such file or directory

    Just read the windows needs python for QDeclarative. What packages do I need for Linux (Ubuntu 10.04) ?

    Does anyone had similar problems?



  • After compiling Qt5 I'd like to do a safe "make install" in my system. With "safe" I mean that I don't want to overwtite my Qt4 libs on my system so they should be installed in (for example) /opt/qt5 if it's possible.

    I also would like to start packaging Qt5 in a Ubuntu PPA, but even if I've a little experience with packaging, I really don't know how to split an installation in multiple packages (I mean: qt-multimedia, qt-database, qt-tools ecc.... just to make you an example): should I take example from the actual Qt4 packages available in Ubuntu? Anyone want to help me? Thanks!



  • How do you force qtbase/src/plugins/platforms/xcb to recompile?



  • I get this at every dir level I tried on Archlinux x86_64...
    @~qt5-git/qtbase git submodule update --init src/3rdparty/v8
    You need to run this command from the toplevel of the working tree.@
    I already have a libv8 3.6.5.1 as part of my system so would it possible for qtbase and whatever else needs libv8 to just link against my system version?



  • Hi! Trying to build Qt 5 for the first time, but I'm not getting very far...
    Seems like the init-repository script is not working properly with the the --http option. All the repos are cloned using "http:", except for the qt3d repo which still tries to use "git:".
    Very simple problem, but with my total lack of experience with perl, I'm not sure how to work around it... If anyone could give me a hint on how to get past this, by fixing init-repository, or doing some manual step, it would be most appreciated.



  • What is the best way to incorporate qtwebkit into a qt5 build?
    @...
    [pid 30835] open(".../qt5-git/.git/modules/qtwebkit/refs/heads/master", O_RDONLY) = -1 ENOENT (No such file or directory)
    [pid 30835] write(2, "fatal: Oops\n", 12fatal: Oops@

    @ludde, I'm not sure why there is not some plain English instructions to clone the repo exactly, or a bash script, rather than buried inside an obfuscated perl script that doesn't seem to work. An example .git/config file would be more useful.



  • Managed to make init-repository clone all the modules (by fiddling a bit with the perl script, without really understanding what I was doing...).

    Also managed to run configure. But compiling (using Microsoft Visual Studio 2005, on Windows 7, 64 bit) eventually fails:

    @
    c:\users\ludde\qt\qt5\qtbase\src\plugins\platforms\windows\qtwindowsglobal.h(178) : error C2065: 'WM_XBUTTONDOWN' : undeclared identifier
    c:\users\ludde\qt\qt5\qtbase\src\plugins\platforms\windows\qtwindowsglobal.h(178) : error C2065: 'WM_XBUTTONDBLCLK' : undeclared identifier
    c:\users\ludde\qt\qt5\qtbase\src\plugins\platforms\windows\qwindowscontext.h(74) : error C2059: syntax error : '<L_TYPE_raw>'
    @

    Any ideas on what might be causing this?


  • Moderators

    @ludde: I filed https://bugreports.qt.nokia.com/browse/QTBUG-23580 regarding your problems with the -http option. About the windows problems ... don't know, it compiles for me :( I guess you're better off subscribing to qt-development@qt-project.org, and posting your problems there.



  • While running
    @./configure -developer-build -opensource -nomake examples -nomake tests@

    i get this error partway through:

    @Creating qmake. Please wait...
    g++ -c -o project.o -pipe -DQMAKE_OPENSOURCE_EDITION -g -g -I. -Igenerators -Igenerators/unix -Igenerators/win32 -Igenerators/mac -Igenerators/integrity -I/home/daniel/qt5/qtbase/include -I/home/daniel/qt5/qtbase/include/QtCore -I/home/daniel/qt5/qtbase/include/QtCore/5.0.0 -I/home/daniel/qt5/qtbase/include/QtCore/5.0.0/QtCore -I/home/daniel/qt5/qtbase/src/corelib/global -I/home/daniel/qt5/qtbase/src/corelib/xml -I/home/daniel/qt5/qtbase/tools/shared -DQT_NO_PCRE -DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_STL -DQT_NO_COMPRESS -I/home/daniel/qt5/qtbase/mkspecs/linux-g++ -DHAVE_QCONFIG_CPP -DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -DQT_NO_DEPRECATED project.cpp
    make: g++: Command not found
    make: *** [project.o] Error 127
    @

    I am using ubuntu, does anyone know where i went wrong?
    Sorry i'm rather new to all this :$



  • Do you have gcc installed...?



  • Had this problem too. For some reason you need not only have gcc installed, but have it available as g++. This can be accomplished by installing the g++ package (and possibly also by just creating an alias from g++ to gcc, but I didn't try this).



  • Ah thanks, that works, i had gcc installed but not g++ it seems.

    Strangely, i cannot run demos as even if i make the executables runnable, then i get something like this:
    @Details: Failed to execute child process "/usr/bin/tea_service" (No such file or directory)@

    after making the qt teaservice.desktop demo executable as a program in its right click properties and trying to run.
    Somehow i get the impression that this is not what i am meant to be doimng anyway, as the idea that i would have to right click and change the permissions of all the demo files that i wanted to run doesn't seem the most fun so i guess i am trying to do it the wrong way :$

    Also, i tried to compile qt creator and the qtquick3d demos myself and got errors.
    (For example, for the qtquick3d):
    @daniel@andy-desktop:~/qt_creator/what$ qmake /home/daniel/qt5/qtquick3d/demos/demos.pro
    daniel@andy-desktop:~/qt_creator/what$ sudo make
    cd quick3d/ && /home/daniel/qt5/qtbase/bin/qmake /home/daniel/qt5/qtquick3d/demos/quick3d/quick3d.pro -o Makefile
    cd quick3d/ && make -f Makefile
    make[1]: Entering directory /home/daniel/qt_creator/what/quick3d' cd model_viewer/ && /home/daniel/qt5/qtbase/bin/qmake /home/daniel/qt5/qtquick3d/demos/quick3d/model_viewer/model_viewer.pro -o Makefile cd model_viewer/ && make -f Makefile make[2]: Entering directory/home/daniel/qt_creator/what/quick3d/model_viewer'
    g++ -c -pipe -g -Wall -W -D_REENTRANT -DQT_DECLARATIVE_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../qt5/qtbase/mkspecs/linux-g++ -I../../../../qt5/qtquick3d/demos/quick3d/model_viewer -I../../../../qt5/qtbase/include/QtCore -I../../../../qt5/qtbase/include/QtGui -I../../../../qt5/qtbase/include/QtWidgets -I../../../../qt5/qtdeclarative/include -I../../../../qt5/qtdeclarative/include/QtDeclarative -I../../../../qt5/qtbase/include -I../../../../qt5/qtbase/include/QtNetwork -I../../../../qt5/qtxmlpatterns/include -I../../../../qt5/qtxmlpatterns/include/QtXmlPatterns -I/usr/X11R6/include -I. -I../../../../qt5/qtquick3d/demos/quick3d/model_viewer -I. -o main.o ../../../../qt5/qtquick3d/demos/quick3d/model_viewer/main.cpp
    In file included from ../../../../qt5/qtbase/include/QtGui/qopengl.h:1:0,
    from ../../../../qt5/qtdeclarative/include/QtDeclarative/../../src/declarative/items/qquickcanvas.h:46,
    from ../../../../qt5/qtdeclarative/include/QtDeclarative/qquickcanvas.h:1,
    from ../../../../qt5/qtdeclarative/include/QtDeclarative/../../src/declarative/items/qquickview.h:46,
    from ../../../../qt5/qtdeclarative/include/QtDeclarative/qquickview.h:1,
    from ../../../../qt5/qtdeclarative/include/QtDeclarative/QQuickView:1,
    from ../../../../qt5/qtquick3d/demos/quick3d/model_viewer/../qmlres.h:47,
    from ../../../../qt5/qtquick3d/demos/quick3d/model_viewer/main.cpp:42:
    ../../../../qt5/qtbase/include/QtGui/../../src/gui/opengl/qopengl.h:69:21: fatal error: GL/gl.h: No such file or directory
    compilation terminated.
    make[2]: *** [main.o] Error 1
    make[2]: Leaving directory /home/daniel/qt_creator/what/quick3d/model_viewer' make[1]: *** [sub-model_viewer-make_default] Error 2 make[1]: Leaving directory/home/daniel/qt_creator/what/quick3d'
    make: *** [sub-quick3d-make_default] Error 2
    @

    Sorry to be a pain.



  • Greetings guys,

    On Windows 7 x64 I get the following:

    @qwindowstheme.cpp: In member function 'virtual QVariant QWindowsTheme::themeHint(QPlatformTheme::ThemeHint) const': qwindowstheme.cpp:77:53: error: 'SPI_GETDROPSHADOW' was not declared in this scope@

    It seems that the SPI_GETDROPSHADOW is under a WIN_NT_32 define.



  • I just restarted my attempt at building Qt5 after spending a day finding out that wayland isn't ready for Debian Wheezy amd64 yet.

    By running configure with the "-v" switch I could see the auto-detection tests and their results - I needed to install libasound2-dev for Alsa.

    Note:
    @make confclean@

    does nothing - "confclean" isn't a valid makefile target, although configure tells you to use this to clean up before another configure run.

    Maybe someone could add
    @confclean:
    <tab>git submodule foreach --recursive 'git clean -dfx'@

    to the right makefile to tie things up.

    Also, see the
    @qtbase/configure: 7201: [: x86_64: unexpected operator@

    error after the "rm -f ..." entries below.

    The error is
    @if [ -n "$_SBOX_DIR" -a "$CFG_ARCH" == "arm" ]; then@

    This is a "bashism" - something only bash understands.
    Although /bin/sh was usually symlinked to /bin/bash, on Debian Wheezy /bin/sh -> dash.

    "dash" and therefore "sh" doesn't recognise "[" and doesn't like "==".

    @if test -n "$_SBOX_DIR" && test "$CFG_ARCH" = "arm"; then@

    It occurs lots of times in this configure script - maybe in others too.

    Somehow it muddles through. I'd recommend using "set -e" to catch these.

    Anyway here's my configure output, after doing the recursive clean command above.

    @

    • /v3c/dev/Graphics/Qt/qt5/qtbase/configure -prefix /v3c/dev/Graphics/Qt/qt5/qtbase -no-wayland -opengl -no-glib -opensource -confirm-license -qpa -v
      Determining system architecture... (Linux:3.0.0-1-amd64:x86_64)
      64-bit AMD 80x86 (x86_64)
      'x86_64' is supported
      System architecture: 'x86_64'
      Host architecture: 'x86_64'
      Precompiled-headers support enabled.
      Symbol visibility control enabled.
      Symbolic function binding enabled.

    This is the Qt Lighthouse Open Source Edition.

    You are licensed to use this software under the terms of
    the Lesser GNU General Public License (LGPL) versions 2.1.

    You have already accepted the terms of the license.
    @
    bootstrapping and feature tests...

    @
    /v3c/dev/Graphics/Qt/qt5/qtbase/configure: 7201: [: x86_64: unexpected operator
    Testing size of pointers ... (/v3c/dev/Graphics/Qt/qt5/qtbase/mkspecs/linux-g++-64 yes /v3c/dev/Graphics/Qt/qt5/qtbase /v3c/dev/Graphics/Qt/qt5/qtbase)
    rm -f ptrsizetest.o
    rm -f *~ core *.core
    g++ -c -m64 -pipe -O2 -Wall -W -I../../../mkspecs/linux-g++-64 -I. -o ptrsizetest.o ptrsizetest.cpp
    g++ -m64 -Wl,-O1 -o ptrsizetest ptrsizetest.o
    Pointer size: 8
    ln: failed to create symbolic link /v3c/dev/Graphics/Qt/qt5/qtbase/include/QtCore/qconfig.h': File exists ln: failed to create symbolic link/v3c/dev/Graphics/Qt/qt5/qtbase/include/Qt/qconfig.h': No such file or directory

        This target is using the GNU C++ compiler (linux-g++-64).
    
        Recent versions of this compiler automatically include code for
        exceptions, which increase both the size of the Qt libraries and
        the amount of memory taken by your applications.
    
        You may choose to re-run configure with the -no-exceptions
        option to compile Qt without exceptions. This is completely binary
        compatible, and existing applications will continue to work.
    

    Build type: linux-g++-64
    Architecture: x86_64
    Host architecture: x86_64
    Platform notes:

            - Also available for Linux: linux-kcc linux-icc linux-cxx
    

    qmake vars .......... cat: .qmake.vars: No such file or directory
    qmake switches .........
    Build .................. libs examples tests
    Configuration .......... release shared dll qpa largefile stl precompile_header mmx 3dnow sse sse2 sse3 ssse3 sse4_1 sse4_2 avx minimal-config small-config medium-config large-config full-config fontconfig xlib xrender xcb-render accessibility openvg opengl qpa reduce_exports reduce_relocations clock-gettime clock-monotonic mremap getaddrinfo ipv6ifname getifaddrs inotify system-jpeg system-png png system-tiff system-freetype system-zlib nis cups dbus openssl xcb alsa concurrent audio-backend svg v8 v8snapshot release
    Debug .................. no
    QtDBus module .......... yes (run-time)
    QtConcurrent code ...... yes
    QtGui module ........... yes
    QtScript module ........ yes
    QtScriptTools module ... yes
    QtXmlPatterns module ... yes
    Phonon module .......... no
    Multimedia module ...... auto
    SVG module ............. yes
    WebKit module .......... yes
    JavaScriptCore JIT ..... To be decided by JavaScriptCore
    V8 module .............. yes
    Declarative module ..... yes
    Declarative debugging ...yes
    Location module ........ no
    STL support ............ yes
    PCH support ............ yes
    MMX/3DNOW/SSE/SSE2/SSE3. yes/yes/yes/yes/yes
    SSSE3/SSE4.1/SSE4.2..... yes/yes/yes
    AVX..................... yes
    IPv6 ifname support .... yes
    getaddrinfo support .... yes
    getifaddrs support ..... yes
    Accessibility .......... yes
    NIS support ............ yes
    CUPS support ........... yes
    Iconv support .......... no
    Glib support ........... no
    GStreamer support ...... no
    PulseAudio support ..... no
    Large File support ..... yes
    GIF support ............ plugin
    TIFF support ........... plugin (system)
    JPEG support ........... plugin (system)
    PNG support ............ yes (system)
    zlib support ........... system
    Session management ..... auto
    OpenGL support ......... yes (Desktop OpenGL)
    OpenVG support ......... yes
    MySQL support .......... plugin
    PostgreSQL support ..... plugin
    SQLite support ......... plugin (qt)
    OpenSSL support ........ yes (run-time)
    Alsa support ........... yes
    libICU support ......... no
    Xcb support ............ limited (old version)
    Xrender support ........ yes
    @
    (continued...)



  • Here's a list of files I had to modify on my way to discovering that libQtdesigner is needed for qtbase/plugins/designer/libqwebview.so but wasn't built yet.

    This needs "Qt += quick"
    @
    ./qtwebkit/Tools/WebKitTestRunner/Target.pri
    @

    This needs to "#include <QNetworkCookie>"
    @
    ./qtwebkit/Tools/QtTestBrowser/cookiejar.cpp
    @

    This uses " QTouchEvent::TouchPoint::Primary" - I commented it (and the "if" statement) out to get further.
    @
    ./qtwebkit/Tools/MiniBrowser/qt/MiniBrowserApplication.cpp
    @

    This needs "Qt += quick"
    @
    ./qtwebkit/Tools/MiniBrowser/qt/MiniBrowser.pro
    @

    This needs to "#include <QNetworkCookie>"
    @
    ./qtwebkit/Source/WebKit/qt/WebCoreSupport/FrameNetworkingContextQt.cpp
    @

    These need "Qt += quick"
    @
    ./qtwebkit/Source/api.pri
    ./qtwebkit/Source/tests.pri
    @

    This wasn't tested with "regular" OpenGL
    @
    ./qtwebkit/Source/WebCore/platform/graphics/cairo/OpenGLShims.cpp
    @

    Here's the change I made to it.
    @
    #if PLATFORM(QT)
    static void* getProcAddress(const char* procName)
    {

    • return QGLContext::currentContext()->getProcAddress(QString::fromLatin1(procName));
    • return (void *)QGLContext::currentContext()
    •    ->getProcAddress(QString::fromLatin1(procName));
      

    }
    #else
    typedef void* (glGetProcAddressType) (const char procName);
    @

    These assume they're only included from within WebKit - untrue.
    Yes, I later realized that this isn't the right place to change them.
    @
    ./qtbase/include/QtWebKit/qwebview.h
    ./qtbase/include/QtWebKit/qwebframe.h
    ./qtbase/include/QtWebKit/qwebkitversion.h
    ./qtbase/include/QtWebKit/qwebpluginfactory.h
    ./qtbase/include/QtWebKit/qwebinspector.h
    ./qtbase/include/QtWebKit/qwebkitplatformplugin.h
    ./qtbase/include/QtWebKit/qwebhistoryinterface.h
    ./qtbase/include/QtWebKit/qwebsecurityorigin.h
    ./qtbase/include/QtWebKit/qwebelement.h
    ./qtbase/include/QtWebKit/qwebpage.h
    ./qtbase/include/QtWebKit/qwebdatabase.h
    ./qtbase/include/QtWebKit/qwebhistory.h
    ./qtbase/include/QtWebKit/qwebkitglobal.h
    ./qtbase/include/QtWebKit/qwebsettings.h
    @

    Hope this helps.



  • I had to choose between OpenGL and GL ES2 but I could also select xcb.

    Isn't qpa building about being able to select between all of these at run-time?

    On Debian Wheezy I've got the libraries and development packages installed to support OpenGL and GL ES2.

    Also, maybe "build.stamp" and "install.stamp" files marking modules as built/installed could help "make" or "make install" skip modules entirely and speed things up.

    If specifying "-prefix $PWD/qtbase" is your way of saying Qt5 isn't ready for "-prefix /usr" then you could have made that point a little more prominently.


  • Moderators

    Philius, I think it would be nice if you posted your findings to Qt development mailing list, where devs are likely to pick it up. And/ or modifying the "Building Qt5 from Git":http://developer.qt.nokia.com/wiki/Building_Qt_5_from_Git wiki page might be a good idea.



  • I re-subscribed and posted an email with a QtWebkit patch although my build still (eventually) fails.

    I think that as long as the install prefix is inside the source tree (not to mention the build path!) you're going to have problems, so I won't try it again at least until these things change.

    From trying to fix problems I noticed that there are several "Release" directories created in the source tree - it looks like someone was at least trying to do some whacky kind of out-of-source-while-still-in-source deal.

    Do a "find . -type d -name Release" once you've tried to build it at least once to see the strangeness.

    I also noticed that the build process was picking header files from the install path in preference to the source directory - I've got projects that use automake that don't do that (it's a shame automake can't do the same for libraries).

    Then there's "make install" trying to copy files over themselves.

    I'll stop here.





  • Those "QT += quick" are needed on Debian Wheezy because of
    @
    ld.bfd: "could not read symbols: Invalid operation" after indirect reference is unhelpful
    http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=629498
    @


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.