×

Discussion Board

Results 1 to 9 of 9
  1. #1
    Nokia Developer Expert
    Join Date
    Jun 2009
    Posts
    36

    Question QT4.6 and scratchbox incompatability

    Hi,

    Hi,

    I installed QT4.6 for linux/x11 (qt-sdk-linux-x86-opensource-2009.05.bin) on Ubuntu 9.1. I designed the UI in QTCreator 1.3, compiled my application with no errors and it ran successfully in the native WMWare environment within QT.

    Flushed with success I fired up the scratchbox (x86 target) which has libqt4-maemo5-dev installed (and qt4.5.2).

    The x86 compilation failed.

    qmake -project
    qmake CamerDepthOfField
    make

    produced the following:

    [sbox-FREMANTLE_X86: ~/workspaceqt/CameraDOF/CameraDepthOfField] > cat CameraDepthOfField.pro
    # -------------------------------------------------
    # Project created by QtCreator 2009-12-31T12:42:02
    # -------------------------------------------------
    TARGET = CameraDepthOfField
    TEMPLATE = app
    SOURCES += main.cpp \
    mainwindow.cpp \
    dof_functions.cpp
    HEADERS += mainwindow.h \
    dof_functions.h
    FORMS += DOF_Form.ui
    [sbox-FREMANTLE_X86: ~/workspaceqt/CameraDOF/CameraDepthOfField] > qmake -project
    [sbox-FREMANTLE_X86: ~/workspaceqt/CameraDOF/CameraDepthOfField] > qmake CameraDepthOfField.pro
    [sbox-FREMANTLE_X86: ~/workspaceqt/CameraDOF/CameraDepthOfField] > make
    g++ -c -pipe -g -g -O0 -Wall -W -D_REENTRANT -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED

    -I/targets/FREMANTLE_X86/usr/share/qt4/mkspecs/linux-g++-opengl -I. -I/targets/FREMANTLE_X86/usr/include/qt4/QtCore

    -I/targets/FREMANTLE_X86/usr/include/qt4/QtGui -I/targets/FREMANTLE_X86/usr/include/qt4 -I. -I. -I. -o dof_functions.o

    dof_functions.cpp
    In file included from dof_functions.h:6,
    from dof_functions.cpp:2:
    ui_DOF_Form.h: In member function 'void Ui_MainWindow::setupUi(QMainWindow*)':
    ui_DOF_Form.h:97: error: 'class QLineEdit' has no member named 'setInputMethodHints'
    ui_DOF_Form.h:97: error: 'ImhDigitsOnly' is not a member of 'Qt'
    ui_DOF_Form.h:97: error: 'ImhFormattedNumbersOnly' is not a member of 'Qt'
    ui_DOF_Form.h:97: error: 'ImhPreferNumbers' is not a member of 'Qt'
    ui_DOF_Form.h:146: error: 'class QLineEdit' has no member named 'setInputMethodHints'
    ui_DOF_Form.h:146: error: 'ImhFormattedNumbersOnly' is not a member of 'Qt'
    ui_DOF_Form.h:146: error: 'ImhPreferNumbers' is not a member of 'Qt'
    ui_DOF_Form.h:220: error: 'class QDoubleSpinBox' has no member named 'setInputMethodHints'
    ui_DOF_Form.h:220: error: 'ImhDigitsOnly' is not a member of 'Qt'
    ui_DOF_Form.h:220: error: 'ImhFormattedNumbersOnly' is not a member of 'Qt'


    Am I being too ambitious or have I managed to misconfigure the libraries/got the wrong versions? What do I need to check or update?

    Many thanks,
    David

  2. #2
    Nokia Developer Moderator
    Join Date
    Oct 2009
    Posts
    4,326

    Re: QT4.6 and scratchbox incompatability

    You cannot compile Qt 4.6 specific code against Qt 4.5.3. There is wiki explaining how to install Qt 4.6 technical preview in Fremantle scratchbox: http://wiki.maemo.org/Qt4Hildon#Fremantle

  3. #3
    Registered User
    Join Date
    Nov 2008
    Posts
    15

    Re: QT4.6 and scratchbox incompatability

    Quote Originally Posted by davidmct View Post
    Hi,

    The x86 compilation failed.

    qmake -project
    qmake CamerDepthOfField
    make
    Try running /opt/qt4-maemo5/bin/qmake -project; /opt/qt4-maemo5/bin/qmake CamerDepthOfField;make

    You're propably using the qmake that is included in the 4.5.x version.

    >> Johannes <<

  4. #4
    Nokia Developer Moderator
    Join Date
    Oct 2009
    Posts
    4,326

    Re: QT4.6 and scratchbox incompatability

    Quote Originally Posted by kleimola View Post
    Try running /opt/qt4-maemo5/bin/qmake -project; /opt/qt4-maemo5/bin/qmake CamerDepthOfField;make
    If it's installed.

  5. #5
    Nokia Developer Expert
    Join Date
    Jun 2009
    Posts
    36

    Thumbs up Re: QT4.6 and scratchbox incompatability

    Hi,

    I had previously installed the Qt4.6 technical preview and the commands...

    "/opt/qt4-maemo5/bin/qmake -project
    /opt/qt4-maemo5/bin/qmake CameraDepthOfField.pro
    make
    "

    Worked a treat. Note that without the .pro extension qmake failed to find the file.

    Any suggestions on how I can change the version being used by default? The $PATH env variable is currently ...
    PATH=/host_usr/bin:/scratchbox/devkits/git/bin:/scratchbox/devkits/svn/bin:/scratchbox/devkits/doctools/bin:/scratchbox/devkits/debian-etch/bin:/scratchbox/devkits/perl/bin:/scratchbox/tools/bin:/targets/links/arch_tools/bin:/scratchbox/compilers/bin:/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin:/sbin:/usr/sbin

    Many thanks again for the assistance.

    BR David

  6. #6
    Nokia Developer Moderator
    Join Date
    Oct 2009
    Posts
    4,326

    Re: QT4.6 and scratchbox incompatability

    The easiest way is to remove Qt 4.5.3 and Qt 4.6 and install Qt 4.6 back.

  7. #7
    Nokia Developer Expert
    Join Date
    Jun 2009
    Posts
    36

    Re: QT4.6 and scratchbox incompatability

    Hi,

    Sorry to be a bit naive but what is the best way to uninstall?

    I installed Qt4.6 outside scratchbox and the technical preview within scratchbox.

    Thanks,
    David

  8. #8
    Nokia Developer Expert
    Join Date
    Jun 2009
    Posts
    36

    Re: QT4.6 and scratchbox incompatability

    further note.

    I installed libqt4-maemo5-dev as per the instructions you pointed at. I do recall that the step ... ./autogen.sh QT_PATH=/opt/qt4-maemo5/bin in the following failed because ./autogen.sh cpuldn't be found.

    [sbox-FREMANTLE_X86: ~] > cd ~/your/project/folder
    [sbox-FREMANTLE_X86: ~] > make distclean #dont worry if it fails
    [sbox-FREMANTLE_X86: ~] > ./autogen.sh QT_PATH=/opt/qt4-maemo5/bin
    [sbox-FREMANTLE_X86: ~] > make

    I assume this could be as simple as the QT_PATH not being set.

    BR David

  9. #9
    Nokia Developer Moderator
    Join Date
    Oct 2009
    Posts
    4,326

    Re: QT4.6 and scratchbox incompatability

    Quote Originally Posted by davidmct View Post
    further note.

    I installed libqt4-maemo5-dev as per the instructions you pointed at. I do recall that the step ... ./autogen.sh QT_PATH=/opt/qt4-maemo5/bin in the following failed because ./autogen.sh cpuldn't be found.

    [sbox-FREMANTLE_X86: ~] > cd ~/your/project/folder
    [sbox-FREMANTLE_X86: ~] > make distclean #dont worry if it fails
    [sbox-FREMANTLE_X86: ~] > ./autogen.sh QT_PATH=/opt/qt4-maemo5/bin
    [sbox-FREMANTLE_X86: ~] > make

    I assume this could be as simple as the QT_PATH not being set.

    BR David
    It says If you happen to use autotools and you are not using autotools, but qmake instead.

Similar Threads

  1. Qt4.6 OpenGL ES 2.0 example
    By feldi13 in forum Nokia N9
    Replies: 3
    Last Post: 2009-12-23, 17:14
  2. Not able to access bluetooth dongle from Maemo Scratchbox
    By nagendraravuri in forum Bluetooth Technology
    Replies: 0
    Last Post: 2008-04-21, 06:45

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •