Maybe you forgot to setup the environment?
-
Hello
I am new to QT and i am following the "Raspberry Pi Beginners Guide" on your website because i want to cross compile for a raspberry pi 3.
Everything works fine untill "Compiling Qtbase" . Here i get this error
Project ERROR: Cannot run target compiler '/home/tonnie/opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf-g++'. Output:
sh: 1: /home/tonnie/opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf-g++: not found
Maybe you forgot to setup the environment?
But when i check the path, the file "arm-linux-gnueabihf-g++" is there.
I don't know what i have to do in the enviroment ????Thanks in advance
-
Hi,
You should show the configure options you used to cross-compile Qt.
-
Hello
This is the command i use (copied from the website http://wiki.qt.io/Raspberry_Pi_Beginners_Guide)
./configure -opengl es2 -device linux-rasp-pi-g++ -device-option CROSS_COMPILE=~/opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /mnt/rasp-pi-rootfs -opensource -confirm-license -optimized-qmake -reduce-exports -release -make libs -prefix /usr/local/qt5pi -hostprefix /usr/local/qt5pi
I followed the instruction on this website and everything works fine until here
-
@Softtoon said in Maybe you forgot to setup the environment?:
/home/tonnie/opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf-g++
What do you get if you run that line in your terminal ?
-
Hello
When ik run the ./configure command i get
- cd qtbase
- /home/tonnie/opt/qt5/qtbase/configure -top-level -opengl es2 -device linux-rasp-pi-g++ -device-option CROSS_COMPILE=/home/tonnie/opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /mnt/rasp-pi-rootfs -opensource -confirm-license -optimized-qmake -reduce-exports -release -make libs -prefix /usr/local/qt5pi -hostprefix /usr/local/qt5pi
<srcbase> = /home/tonnie/opt/qt5/qtbase
<bldbase> = /home/tonnie/opt/qt5/qtbase
<outbase> = /home/tonnie/opt/qt5/qtbase
Creating qmake...
.Done.
Info: creating super cache file /home/tonnie/opt/qt5/.qmake.super
Project ERROR: Cannot run target compiler '/home/tonnie/opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf-g++'. Output:
===================
sh: 1: /home/tonnie/opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf-g++: not found
===================
Maybe you forgot to setup the environment?
It complains that it cant find the compiler but the compiler is the correct location
~/opt/gcc-4.7-linaro-rpi-gnueabihf/binDo i have to add a path somewhere ? I am not familiar with linux
-
What do you get if you call
/home/tonnie/opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf-gcc --version
? -
Hello
Sorry for the misunderstanding.
After running the command that you suggested i had to install gcc-arm-linux-gnueabihf
I did this by enteringsudo apt install gcc-arm-linux-gnueabihf
Now when i run
~/opt/qt5/qtbase$ ./configure -opengl es2 -device linux-rasp-pi-g++ -device-option CROSS_COMPILE=~/opt/gcc-4.7-linaro-rpi-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /mnt/rasp-pi-rootfs -opensource -confirm-license -optimized-qmake -reduce-exports -release -make libs -make tools -prefix /usr/local/qt5pi -hostprefix /usr/local/qt5piI get this error :
ERROR: You cannot configure qtbase separately within a top-level build.What does this mean ?
-
Are you building from a clear source ?
You should rather do out of source builds, it makes things easier when you have to restart.
-
try the command below before runnig the ./configure :
sudo apt-get install lib32stdc++6