qt cross compile build
-
../qt-everywhere-src-5.15.2/configure -opengl es2 -device linux-rasp-pi4-v3d-g++ -device-option CROSS_COMPILE=/opt/qt5pi/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /opt/qt5pi/sysroot -prefix /usr/local/qt5pi/ -opensource -confirm-license -skip qtscript -skip qtwayland -skip qtdatavis3d -nomake examples -make libs -pkg-config -no-use-gold-linker -v
cd qtbase
/opt/qt5pi/qt-everywhere-src-5.15.2/qtbase/configure -top-level -opengl es2 -device linux-rasp-pi4-v3d-g++ -device-option CROSS_COMPILE=/opt/qt5pi/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /opt/qt5pi/sysroot -prefix /usr/local/qt5pi/ -opensource -confirm-license -skip qtscript -skip qtwayland -skip qtdatavis3d -nomake examples -make libs -pkg-config -no-use-gold-linker -v
Performing shadow build...
Preparing build tree...
Creating qmake...
make: 'first'을(를) 위해 할 일이 없습니다.
Command line: -opengl es2 -device linux-rasp-pi4-v3d-g++ -device-option CROSS_COMPILE=/opt/qt5pi/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /opt/qt5pi/sysroot -prefix /usr/local/qt5pi/ -opensource -confirm-license -skip qtscript -skip qtwayland -skip qtdatavis3d -nomake examples -make libs -pkg-config -no-use-gold-linker -vThis is the Qt Open Source Edition.
You have already accepted the terms of the Open Source license.
Running configuration tests...
/opt/qt5pi/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ -dumpmachine
arm-linux-gnueabihf
Checking for valid makespec...
cd /opt/qt5pi/qt5build/config.tests/verifyspec && /opt/qt5pi/qt5build/qtbase/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" "QMAKE_CFLAGS += --sysroot=/opt/qt5pi/sysroot" "QMAKE_CXXFLAGS += --sysroot=/opt/qt5pi/sysroot" "QMAKE_LFLAGS += --sysroot=/opt/qt5pi/sysroot" -early "CONFIG += cross_compile" /opt/qt5pi/qt-everywhere-src-5.15.2/qtbase/config.tests/verifyspec
cd /opt/qt5pi/qt5build/config.tests/verifyspec && MAKEFLAGS= /usr/bin/make clean && MAKEFLAGS= /usr/bin/make
rm -f verifyspec.o
rm -f *~ core *.core
/opt/qt5pi/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ -c -march=armv8-a -mtune=cortex-a72 -mfpu=crypto-neon-fp-armv8 -mfloat-abi=hard --sysroot=/opt/qt5pi/sysroot -O2 -w -fPIC -I/opt/qt5pi/qt-everywhere-src-5.15.2/qtbase/config.tests/verifyspec -I. -I/opt/qt5pi/qt-everywhere-src-5.15.2/qtbase/mkspecs/devices/linux-rasp-pi4-v3d-g++ -o verifyspec.o /opt/qt5pi/qt-everywhere-src-5.15.2/qtbase/config.tests/verifyspec/verifyspec.cpp
/opt/qt5pi/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ -mfloat-abi=hard --sysroot=/opt/qt5pi/sysroot -Wl,-O1 -Wl,-rpath-link,/opt/qt5pi/sysroot/usr/lib/arm-linux-gnueabihf -Wl,-rpath-link,/opt/qt5pi/sysroot/lib/arm-linux-gnueabihf -o verifyspec verifyspec.o
/opt/qt5pi/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.5.0/../../../../arm-linux-gnueabihf/bin/ld: cannot find crt1.o: 그런 파일이나 디렉터리가 없습니다
/opt/qt5pi/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.5.0/../../../../arm-linux-gnueabihf/bin/ld: cannot find crti.o: 그런 파일이나 디렉터리가 없습니다
/opt/qt5pi/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.5.0/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lm
collect2: error: ld returned 1 exit status
make: *** [Makefile:68: verifyspec] 오류 1
Note: Also available for Linux: linux-clang linux-iccERROR: Cannot compile a minimal program. The toolchain or QMakeSpec is broken.
I've been struggling with cross-compiling for days.
I get the following error:
How can I solve this? -
@IknowQT Please stop double posting!
You already have these posts for the same topic:
https://forum.qt.io/topic/131394/raspberry-cross-compiler-setting-cannot-run-target-compiler
https://forum.qt.io/topic/131382/build-qt-to-cross-compile-for-arm-tutorial