Results 1 to 5 of 5

Thread: Qt supports which Linux?

  1. #1
    Join Date
    Mar 2010
    Location
    Auckland, NZ
    Posts
    121
    Thanks
    9
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Qt supports which Linux?

    I've been trying to build Qt-4.6.3 (from 2010.04 SDK) on Ubuntu 10.04, and have run into a multitude of errors. The main cause of problems is that many source files are expecting to find one or other of a group of include files: X11/extensions/X*.h, among which are XInput.h, Xrandr.h, Xcursor.h, Xfixes.h ... Explicitly excluding these in the configure options has no effect. These options are not supposed to be part of the linux-g++ build anyway. The MAKEFILE_GENERATOR for linux-g++ is UNIX, and these X11 extensions are not tested for in config.tests/unix, while they are tested for in config.tests/x11. I don't know how they get into the makefiles. I thought I was clever by thinking of placing a set of #defines in mkspecs/linux-g++/qplatformdefs.h:
    #define QT_NO_XINPUT
    #define QT_NO_XFIXES
    #define QT_NO_XRANDR
    #define QT_NO_XRENDER
    #define QT_NO_XINERAMA
    #define QT_NO_XCURSOR
    #define QT_NO_XSYNC
    #define QT_NO_XSHAPE
    #define QT_NO_XKB
    #define QT_NO_XLIB
    #define QT_NO_MITSHM
    but to my disappointment this had no effect either - these defines are not passed through to the makefiles.

    Does anyone know how to exclude all these X11 extensions from a Linux (Ubuntu) build? To be more precise, how to stop the build from compiling X11-specific source files like qcursor_x11.cpp? BTW these extensions do not appear to be available for Ubuntu. I have installed libxext-dev, as suggested, but it doesn't have these extensions.

    I would file a Qt bug report, but from what I've seen of similar reports, the debugging team test with Qt-4.7, find that there is no problem, and mark the issue as closed.

    Thanks
    Gib

  2. #2
    Join Date
    May 2010
    Location
    Romania
    Posts
    1,021
    Thanks
    62
    Thanked 260 Times in 246 Posts
    Qt products
    Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: Qt supports which Linux?

    First i have to say that i didn't build Qt on linux,
    i always used the binary that comes with the SDK (on Ubuntu 8.x, 9.x and 10.04, kubuntu 10.04, Debian 5, OpenSuse 11.2, 11.3 and others)

    Are you trying to static build the Qt framework?
    Or what's the reason for the build, (since Qt SDK comes already build) and works <almost> out of the box, the only difference from windows SDK is that on linux the SDK doesn't come with a C++ compiler and a make tool, so you need to install g++ and make (on most distros make is already installed)

  3. #3
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: Qt supports which Linux?

    To build Qt on Linux you need a bunch of additional libraries. Have you seen http://doc.qt.nokia.com/4.6/requirements-x11.html and added these libraries? (On Ubuntu you always need the "-dev" version.)

    You can exclude these parts by using configure switches. Type "configure -help" to see them. One e.g. is -no-xcursor: http://qt.gitorious.org/qt/qt/blobs/...igure#line4004.

  4. The following user says thank you to Lykurg for this useful post:

    Lawand (5th November 2010)

  5. #4
    Join Date
    Sep 2010
    Posts
    1
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: Qt supports which Linux?

    HI Zlatomir,

    May i ask a question? I install qt-sdk-linux-x86-opensource-2010.04.bin and make a simple project. I want to build the project as static executable file. I build the release mode, but i can't run it in another ubuntu without qt sdk environment.
    I don't know what's wrong.

    I search in google, someone replied it need to rebuild the QT source code and added -static in command line to reconfigure, make and make install.
    reference link :http://doc.qt.nokia.com/4.1/deployment-x11.html

    Could you build the static executable file and run in another ubuntu environment without installing QT SDK?
    If you can do it, please tell me how to do, thanks

    RJ

  6. #5
    Join Date
    May 2010
    Location
    Romania
    Posts
    1,021
    Thanks
    62
    Thanked 260 Times in 246 Posts
    Qt products
    Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: Qt supports which Linux?

    If you want a static build you really need to build Qt again (with configure -static ... and the rest of the options you need)
    Take a look at the link in Lykurg post, there are the requirements to build Qt on linux
    And check the LGPL license, because it has some restrictions related to static build

    My advice is: use the shared libraries (you don't need to build Qt in this case)
    Last edited by Zlatomir; 26th September 2010 at 14:30.

Similar Threads

  1. Qt QDataStream supports data types
    By LoginFailed in forum Qt Programming
    Replies: 2
    Last Post: 30th December 2009, 08:41
  2. QMovie supports no animation formats (PyQt on Windows)
    By jmeyer in forum Qt Programming
    Replies: 3
    Last Post: 5th May 2009, 08:44
  3. ide which supports debugging qt4.3.3 in windows
    By sakthi in forum Qt-based Software
    Replies: 2
    Last Post: 28th January 2008, 12:36

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.