5

I want to cross compile my QT Application to Toradex embedded linux platform. The QT Creator Commercial version comes with in-built compiler for embedded linux but open source doesn't.

So, is there any way to compile and run it on embedded linux.

3
  • 1
    Did you take a look at their existing documentation here? It should already be all there. Commented Apr 22, 2019 at 8:14
  • @SanchayanMaity It is for QT commercial version not for Community version. Commented Apr 23, 2019 at 8:24
  • The one which can be included with Yocto/OE is not the commercial version. Commented Apr 23, 2019 at 8:36

1 Answer 1

4
After some research, I finally get a way to do it. Here are the steps:

1. Download QT Creator and Install

2. Download QT Everywhere
https://download.qt.io/archive/qt/5.8/5.8.0/single/qt-everywhere-opensource-src-5.8.0.tar.gz.mirrorlist

3. Extract It

4. Change path to path/to/qt-everywhere

5. Configure qt-everywhere

    ./configure -release -device linux-imx7-g++ -device-option CROSS_COMPILE=/usr/local/oecore-x86_64/sysroots/x86_64-angstromsdk-linux/usr/bin/arm-angstrom-linux-gnueabi/arm-angstrom-linux-gnueabi- -sysroot /usr/local/oecore-x86_64/sysroots/armv7at2hf-neon-angstrom-linux-gnueabi -skip qtwebengine -skip qtwebkit -skip qtwebkit-examples -prefix /usr/local/qt5-imx

(QT will save on the location listed in prefix, i.e here /usr/local/qt5-imx)

6. Open QT Creator

7. Goto Tools->Options, Add Compiler
-> Add GCC Compiler, add path /usr/local/oecore-x86_64/sysroots/x86_64-angstromsdk-linux/usr/bin/arm-angstrom-linux-gnueabi/arm-angstrom-linux-gnueabi-g++

8. Add QT Version:
path: /usr/local/oecore-x86_64/sysroots/armv7at2hf-neon-angstrom-linux-gnueabi/usr/local/qt5-imx/bin/qmake

9. Add Debugger :
path: /usr/local/oecore-x86_64/sysroots/x86_64-angstromsdk-linux/usr/bin/arm-angstrom-linux-gnueabi/arm-angstrom-linux-gnueabi-gdb

10. Add Kit
-> Select Generic Linux Device:
-> Specify GCC compiler and debugger path, which is created above
-> Add Sysroot location: /usr/local/oecore-x86_64/sysroots
-> Add QT Version: select qt version, created above
-> Apply and Close
Sign up to request clarification or add additional context in comments.

1 Comment

You seem to be using SDK build by OE based on your toolchain. Why not use the meta-qt5 layer for Qt support?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.