Important: Please read the Qt Code of Conduct -

Qtuitools compiling for uclinux

  • I am trying to get the version of qt-5.3.2 to work on a uclinux build and when I go to run qmake I get the following error Project Error: Unknown module(s) in QT: uitools. I am able to compile the uitools not sure if I have something in my configure that I need to change

    //This is how I am configuring the qt
    ./configure -device linux-arm-k70-som-g++ -confirm-license -opensource -device-option CROSS_COMPILE=linux-arm-uclinuxeabi
    -static -no-c++11 -no-compile-examples -no-xcb -no-qml-debug -no-sql-sqlite --enable-tslib -qreal float -I ${INSTALL_ROOT}/A2F/tslib/src -L ${INSTALL_ROOT}/A2F/root/usr/lib

  • Lifetime Qt Champion

    Hi and welcome to devnet,

    The qtuitools module is not built when you cross-compile. Why do you need it ?

  • We did a previous project for an embedded processor using 4.7.4. We built the project using the cross compilier linux-arm-gnueabi. We did this so we could use the qt creator to edit the screens and then we could easily compile for Linux and Windows versus the embedded processor. I know you don't need the editor and you can position everything with code just wondering what is different when trying to go to qt5.

  • Lifetime Qt Champion

    Are you using QUiLoader in your code ?

  • Yes, what other ways can I do this or do I need to do something else to enable the QUiLoader?

  • Lifetime Qt Champion

    You have to build it by hand, it's in qttools/src/designer/src/uitools/

  • I have gone to the location qttools/src/designer/src/uitools/

    1. qmake uitools (used the qmake with the cross compilier using the absolute location)
    2. make
    3. make install

    After try and run qmake and still get the same error

  • Lifetime Qt Champion

    Has everything run without any error ?

  • I compile the project with uitools and run on my linux machine without any errors. I also have another project that doesn't use uitools that I can get to compile and run on the embedded device.

  • Lifetime Qt Champion

    There's something not clear here. From your previous post, you are saying you still have the error from before and now you write that everything is running fine. So which case is it ?

  • I have 2 different projects that I am working with. The project that I can compile and load on the device doesn't have QtUiTools included, the GUI is written in C++ without using any *.ui files. The second project I am using QtUiTools and *.ui files that compiles and runs on a linux machine so there are no errors in the code. I then try to do qmake (for the embedded linux) on the same code, and receive the error Project Error: Unknown module(s) in QT: uitools.

  • Lifetime Qt Champion

    Might be a silly question but did you call make install after your cross-compiled the module ?

  • Yes I have done the make install in both the qt5 directory and the qtuitools directory. I also setup a new machine with a new version of Ubuntu 16.04 previous version was Ubuntu 14.04 and setup everything and still get the same error on both machines. I installed Qt by downloading the qt-everywhere-opensource-src-5.3.2.tar.gz. I did find something strange on the new machine I haven't installed qt4 but when I run a qmake it is pointing to the location /usr/lib/x86_64-linux-gnu/qt4/bin/qmake but it is not there. I ran some patches that were provided by EmCraft for the module I am using maybe it has changed something? How can I change the path so it goes to the right place for qmake?

  • Lifetime Qt Champion

    Just use the full path so you ensure you are using the correct version.

  • That is what I did for qmake I typed <path to>/qt.5.3.2/qtbase/qmake *.pro. Any other ideas for me to try or information I can give to see how to get this working.

  • Lifetime Qt Champion

    What do you have in your cross-compiled qt5/qtbase/mkspecs/modules/ folder ?

  • I have 27 files in there not sure if you want me to list them all, but I don't see anything in here for the qtuittools I will list the ones that tool in the file name. All the files have the prefix of (qt_tool_) moc, qdoc, dlalr, rcc, syncqt, uic.

  • Lifetime Qt Champion

    Looks like there's something fishy then. Take a look at the output of the make install command to see where everything is put.

  • It looks like it is putting the files in the usr/local location instead of the location of the qt5 source can I change this or should I just copy all the files. I copied files from qttools/lib to qtbase/lib qttools/include to qtbase/include. I am not sure if I have everything in the right place because I now get a new error.

    /linux-cortexm-1.14.2/tools/arm-2010q1/arm-uclinuxeabi/bin/elf2flt: error: text=0x4d6ca0 overlaps data=0x4d66e4 ?
    collect2: ld returned 1 exit status
    make: *** [demo_prj] Error 1

  • Lifetime Qt Champion

    Check that you are using the right qmake when cross-compiling.

  • I am using the absolute path for qmake but when I do a make it is putting the include files in the usr/local/Qt-5.3.2 not the path to the folder I have installed it appears the error I am getting is the qmake is using the x86 and not the arm compilier. Is there something I can do to force the location for the qmake to go into the folders I want, or do you recommend another way to do my setup.

  • Lifetime Qt Champion

    You should be using the qmake that was built when you cross-compile Qt.

Log in to reply