Cross compile Qt with -xcb failed
-
Note: Also available for Linux: linux-clang linux-icc
Note: No wayland-egl support detected. Cross-toolkit compatibility disabled.
Note: The following modules are not being compiled in this configuration:
3dcore
3drender
webenginecore
webengine
webenginewidgets
pdf
pdfwidgetsWARNING: Cross compiling without sysroot. Disabling pkg-config
WARNING: A pkg-config support is required to build QtWebEngine.
WARNING: A pkg-config support is required to build QtPdf.
WARNING: QtWebEngine will not be built.
WARNING: QtPdf will not be built.
Qt is now configured for building. Just run 'make'.
Once everything is built, you must run 'make install'.
Qt will be installed into '/usr/local/Qt-5.15.2-arm'. -
@quan-wei-jun Please provide proper description of your problem and build log so that others can see what actually failed!
I don't see anything "failing" in what you posed... -
@jsulm My QT source code (5.15.2) is configured as follows: ./configure -prefix /usr/local/Qt-5.15.2-arm -release -opensource -nomake examples -nomake tests -no-opengl -skip qtlocation -skip qtconnectivity -xplatform linux-aarch64-gnu-g++ -recheck-all.
The cross-compiler I'm using is gcc-arm-10.3-2021.07-x86_64-aarch64-none-linux-gnu, and I have modified qtbase/mkspecs/linux-aarch64-gnu-g++/qmake.conf to set the compiler path to the absolute path of the cross-compiler.
I require the following modules:
webenginecore
webengine
webenginewidgets
QtWebEngine
QtPd -
@quan-wei-jun If those modules were disabled then check the config.log file (in your build folder) to see why...
For some of the modules you can already see why they are disabled from the warnings.
It also is strange that you're cross compiling without a sysroot. -
@jsulm said in Cross compile Qt with -xcb failed:
It also is strange that you're cross compiling without a sysroot.
What does this mean? -
@quan-wei-jun Usually you do cross compilation using a sysroot.
Take a look at https://wiki.qt.io/Cross-Compile_Qt_6_for_Raspberry_Pi -
@jsulm I have encountered another error: checking for machine tuple Yes
Cannot compile a minimum program The toolchain or QMakeSpec is broken
Config. log: command line: - prefix/usr/local/Qt-5.15.2-arm - release - open source - make examples - make tests - no opengl - skip qtlocation - xplatform Linux arch64 gnu g++- check all
Executing config test machineTuple
+/home/gcc arm-10.3-2021.07 aarch64 arch64 none elf/bin/arch64 none elf g++- dumpmachine
Aarch64 none elf
Test config.qtbase.tests.machineTuple succeeded
Executing config test verifyspec
+Cd/home/work/Qt_ Source/qt everywhere src-5.15.2/config.test/verifyspec&&/home/work/Qt_ Source/qt everywhere src-5.15.2/qtbase/bin/qmake "CONFIG -=qt debug_and-release app_bundle lib_bundle" "CONFIG+=shared warn off console single arch" - early "CONFIG+=cross_compile"/home/work/Qt_ Source/qt everywhere src-5.15.2/qtbase/config.tests/verifyspec
+Cd/home/work/Qt_ Source/qt everywhere src-5.15.2/config.test/verifyspec&&MAKEFLAGS=/usr/bin/make clean&&MAKEFLAGS=/usr/bin/make
Rm - f verifyspec. o
Rm - f *~core *. core
/home/gcc arm-10.3-2021.07 aarch64 arch64 none elf/bin/arch64 none elf g++- c pipe O2 std=gnu++11 w fPIC - I/home/work/Qt_ Source/qt everywhere src-5.15.2/qtbase/config.test/verifyspec I- I/home/work/Qt_ Source/qt everywhere src-5.15.2/qtbase/mkspecs/Linux arch64 gnu g++- o verifyspec. o/home/work/Qt_ Source/qt everywhere src-5.15.2/qtbase/config.test/verifyspec/verifyspec.cpp
/home/gcc arm-10.3-2021.07 aarch64 arch64 none elf/bin/arch64 none elf g++- Wl, - O1- o verifyspec verifyspec. o
/home/gcc arm-10.3-2021.07 aarch64 arch64 none elf/bin// Lib/gcc/arch64 none elf/10.31/../../../../../../arch64 none elf/bin/ld:/lib/arch64 Linux gnu/libc. so. 6: version ` GLIBC_ 2.27 'not found (required by/home/gcc arm-10.3-2021.07 aarch64 arch64 none elf/bin/../lib/gcc/arch64 none elf/10.31/../../../../../arch64 none elf/bin/ld)
Collect2: error: ld returned 1 exit status
Makefile: 68: recipe for target 'verifyspec' failed
Make: * * * [verifyspec] Error 1
Can you help me? Thank you very much
-
@quan-wei-jun type command to check your glibc version
ldd --version
You need GLIBC_2.27 to build. If it is not installed, install it. -
@JoeCFD said in Cross compile Qt with -xcb failed:
GLIBC_2.27
I dare not upgrade to GLIBC_ 2.27, my glibcs is 2.23, and I am afraid it may be incompatible. Do you suggest upgrading