Qt on Qnx 6.4.0



  • Hello

    I have got Qt Creator 2.7.0 installed in my Windows XP machine and my target device is QNX 6.4.0 and Beagle Board. I need to build qt application in target device.

    The Qt version I have downloaded from http://qt-project.org/ is Qt 5.0.2 for Windows 32-bit (MinGW 4.7, 650 MB)

    I am very new to this. I am not getting how to configure qt creator for QNX in Windows machine, Cross Compiling and building. Please help me.

    Thanks



  • I'm not aware of any support for QNX 6.4.0. All the recent support in Qt for QNX is for QNX 6.5.0 SP1 + the new graphics stack. Please contact your QNX sales rep to get access to a BSP.



  • Thank you very much for your time.

    Is Qt 5.0 open source license will support for QNX 6.5.0 SP1. I got one post in Qt blog regarding Qt Commercial Support with QNX on Windows.



  • Yes if you have QNX 6.5.0SP1 (or BB10) you can easily use the Open Source edition of Qt5. All of the QNX QPA plugin for Qt is open source as is the qnx plugin for QtCreator.



  • I have managed to crosscompile Qt 4.8.4 for QNX 6.5.0 on Linux, if you need help I can try...



  • Thanks for your quick reply.

    Portoist really i need your help. Host machine I need to use is Windows XP. On XP in virtual machine QNX Momentics IDE 4.7 is installed for qcc compiler.

    The Qt version I have downloaded from http://qt-project.org/ is Qt 5.0.2 for Windows 32-bit (MinGW 4.7, 650 MB). Now I am trying to configure Qt creator 2.7.0. I have read so many documents to set qt creator. still i am not clear with kits, qt version(Version name, qmake location) and compiler(make path, ABI) settings.

    Please help me.



  • To get Qt5 working on QNX you will need the new graphical environment ZapB has mentioned. I don't have this and I don't know how to build Qt5 for QNX. But Qt 4.8 is also fine to use and nice to work with:)

    As of my setup I have:
    Windows machine - with Qt 4.8.4 that I use for development.
    Linux virtual machine (Linux Mint) - with QNX Momentics inside - I use this virtual machine to crosscompile Qt libraries for QNX and to build my project for QNX.
    QNX target - where I deploy and run my app.

    This binary package from QNX is required, it can be downloaded "here":http://community.qnx.com/sf/wiki/do/viewPage/projects.qt/wiki/Downloads It need to be downloaded into virtual machine and extracted. This package contains binaries of Qt 4.7.1, and also configuration scripts that are usefull for crosscompiling application for QNX. Inside there are qt_qnx_target.tars.gz and qt_qnx_host_linux_x86.tar.gz - extract these in /opt/qnx650 (Or where is your QNX Momentics installed)
    @
    tar xzf qt_qnx_target.tars.gz -C /opt/qnx650
    tar xzf qt_qnx_host_linux_x86.tar.gz -C /opt/qnx650
    @

    Now to build latest Qt libraries for QNX. In linux virtual machine download latest qt 4.8.5 source from "here":http://download.qt-project.org/official_releases/qt/4.8/4.8.5/qt-everywhere-opensource-src-4.8.5.tar.gz . Extract it and in terminal navigate into the directory where qt was extracted. Here execute configure command with following (assuming your QNX target will use i386):
    @
    ./configure -xplatform qws/qnx-i386-g++ -embedded i386 -no-gfx-linuxfb -no-mouse-linuxtp -no-kbd-tty -no-qt3support -qt-gfx-qnx -qt-mouse-qnx -qt-kbd-qnx -no-exceptions -opengl es2 -nomake exapmles -nomake tests -nomake demos -nomake webkit -opensource -confirm-license
    @
    After configuration is successful, just run:
    @
    make
    make-install
    @
    Now Qt should be installed in /usr/local/Trolltech/QtEmbedded-4.8.5-i386.
    Copy lib and plugins directories into QNX target - they can be put in the same path - /usr/local/Trolltech/QtEmbedded-4.8.5-i386.

    Now everything should be ready to compile and run app on QNX. Create new project on Windows machine and in its root directory create text file called "MakefileQNX" and put following inside:
    @
    LIST=OS CPU VARIANT
    MAKEFILE=GNUmakefile
    include recurse.mk
    ##eof
    @
    Now still in project directory create new directory and name it "nto-x86-o". In this directory create file "GNUmakefile" and put following inside:
    @
    ifndef QCONFIG
    QCONFIG=qconfig.mk
    endif
    include $(QCONFIG)
    include $(MKFILES_ROOT)/qmake-qt.mk
    ##eof
    @
    When app is ready to be deployed on QNX target, copy it inside linux virtual and in its directory run:
    @
    make -f MakefileQNX
    @
    If everything is ok, there should be binary file inside nto-x86-o directory. Copy this file inside QNX target.
    Now to run binary on QNX target Photon has to be disabled and these environment variables need to be set:
    @
    export LD_LIBRARY_PATH=/usr/local/Trolltech/QtEmbedded-4.8.5-i386:$LD_LIBRARY_PATH
    export QWS_KEYBOARD=qnx
    export QWS_DISPLAY="qnx"
    export QWS_MOUSE_PROTO="qnx:/dev/devi/touch0 qnx:/dev/devi/mouse0"
    export QT_QWS_FONTDIR=/usr/local/Trolltech/QtEmbedded-4.8.5-i386/fonts
    @
    And now run application:
    @
    ./App -qws
    @
    Maybe somebody has more simple solution. I am using this since Qt 4.7.2 on QNX 6.5.0 and it works ok for me.



  • Thank you very much for all your help and useful information.
    I thank you for taking time out to answer my question Portoist.


Log in to reply
 

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