[Solved] Qt Compiler Error: Looking in wrong location for cross compiler
-
Hello,
I have been following the insturctions in the link below, in order to cross-compile Qt5 on the Rasberry Pi.
Instructions: http://raspberry-qt.org/I beleive that I have successfully followed the instructions, but am getting hung up while trying to build the example project. Here is my Compile Output:
@ 16:46:21: Running steps for project pip...
16:46:21: Starting: "/usr/local/qt5pi/bin/qmake" /home/morgan/Programming/pip/pip.pro -r -spec devices/linux-rasp-pi-g++ CONFIG+=debug CONFIG+=declarative_debug CONFIG+=qml_debug
Project ERROR: Compiler /home/stpease/opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf-g++ not found. Check the value of CROSS_COMPILE -device-option
Could not read qmake configuration file /usr/local/qt5pi/mkspecs/devices/linux-rasp-pi-g++/qmake.conf.
Error processing project file: /home/morgan/Programming/pip/pip.pro
16:46:21: The process "/usr/local/qt5pi/bin/qmake" exited with code 3.
Error while building/deploying project pip (kit: Raspberry Pi)
When executing step 'qmake'
16:46:21: Elapsed time: 00:00.
@For some reason, which is probably pretty self evidant to users more experienced in Linux than I, it is looking for the compliler in the /home/stpease/ folder, which does not exist. In Qt Creator, I specified in Build&Run->Compilers the Compiler Path to be /opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf-g++
Any help with this would be much appreciated! I have tried looking for existing help on this, but have been unsuccessful.
Much thanks in advance!
-
Hi and welcome to devnet,
@/usr/local/qt5pi/mkspecs/devices/linux-rasp-pi-g++/qmake.conf@
This is pretty strange, where did you install your qt5pi ?
-
Thanks for the reply!
qt5pi is installed in /usr/local/. I was looked in qmake.conf, but do not see the problem. I tried to follow the dependencies to fine CROSS_COMPILE, but couldn't find the config file it is refrenced in.
Here is the qmake.conf file:
@#qmake configuration for Broadcom's Raspberry PI
http://wiki.qt-project.org/Devices/RaspberryPi
include(../common/linux_device_pre.conf)
QT_QPA_DEFAULT_PLATFORM = wayland
QMAKE_LFLAGS += -Wl,-rpath-link,$$[QT_SYSROOT]/opt/vc/lib
QMAKE_LIBDIR_OPENGL_ES2 = $$[QT_SYSROOT]/opt/vc/lib
QMAKE_LIBDIR_EGL = $$QMAKE_LIBDIR_OPENGL_ES2QMAKE_INCDIR_EGL = $$[QT_SYSROOT]/opt/vc/include $$[QT_SYSROOT]/opt/vc/include/interface/vcos/pthreads
QMAKE_INCDIR_OPENGL_ES2 = $${QMAKE_INCDIR_EGL}QMAKE_LIBS_EGL = -lEGL -lGLESv2
contains(DISTRO, squeeze) {
#Debian Squeeze: Legacy everything
QMAKE_LIBS_OPENGL_ES2 = -lGLESv2 -lEGL
QT_QPA_DEFAULT_PLATFORM = eglfs
} else:contains(DISTRO, arch) {
#On principle: no wizardry required
} else {
#This is not strictly necessary
DISTRO_OPTS += deb-multi-arch
DISTRO_OPTS += hard-float
}QMAKE_CFLAGS +=
-marm
-mfpu=vfp
-mtune=arm1176jzf-s
-march=armv6zk
-mabi=aapcs-linuxQMAKE_CXXFLAGS = $$QMAKE_CFLAGS
EGLFS_PLATFORM_HOOKS_SOURCES = $$PWD/qeglfshooks_pi.cpp
EGLFS_PLATFORM_HOOKS_LIBS = -lbcm_hostinclude(../common/linux_device_post.conf)
load(qt_config)
@ -
Try searching for stpease in qt5pi
-
You're welcome !
Since it's now building correctly, please update the thread title prepending [solved] so other forum users may know a solution has been found :)