4
votes

I want to compile Qt for Beaglebone Black from source.

I have the following:

  1. cross compiler: gcc-linaro-arm-linux-gnueabihf-4.9-2014.06_linux
  2. qt-everywhere-opensource-src-5.3.1.

My host OS is Scientific Linux 6.3 32-bit. My problem is I have no idea what parameters I need to pass to ./confiure tool. I have following clues:

  1. -xplatform = qtbase/mkspecs/linux-arm-gnueabi-g++
  2. -device = qtbase/mkspecs/devices/linux-beagleboard-g++
  3. -device-option CROSS_COMPILE=/home/anjanu/Downloads/gcc-linaro-arm-linux-gnueabihf-4.9-2014.06_linux/bin/arm-linux-gnueabihf-g++

Is this correct and what all is need to pass to ./configure and also what is sysroot option for?

1
so should this be complete path to Qt's root folder. But how do I know this path even before installing Qt ???Anjanu
Take a look at some embedded Linux distros, that already ship Qt5, like Buildroot.yegorich

1 Answers

1
votes

Basically, this should be enough on its own:

-xplatform = qtbase/mkspecs/linux-arm-gnueabi-g++

All the rest is almost red-herring...

Even though the toolchain binaries are properly named with their long names, e.g. arm-linux-gnueabi-g++, the include and library paths may clash with the system include and library paths. That is exactly what sysroot is meant to handle.

You can set it to the PATH of your cross-toolchain installation. No, this is not the Qt installation. It is the SDK that you got from possibly Linaro, including the whole SDK for cross-platform development. That is, the compiler, linker, stripper, include files, libraries and so on.