Build failing for Qt6 (Cross Compiling for STM32 armv7ve)
-
@Athem said in Build failing for Qt6 (Cross Compiling for STM32 armv7ve):
Brotli Decompression Support ........... no
[...]
/home/pi/rpi-sdk/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 -lbrotlidecThis is weird, because configure reports brotli as not found, so -lbrotlidec shouldn't be added.
Can you try with a completely clean build (in particular, get rid of the
CMakeCache.txtfile?) -
@Athem said in Build failing for Qt6 (Cross Compiling for STM32 armv7ve):
Brotli Decompression Support ........... no
[...]
/home/pi/rpi-sdk/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 -lbrotlidecThis is weird, because configure reports brotli as not found, so -lbrotlidec shouldn't be added.
Can you try with a completely clean build (in particular, get rid of the
CMakeCache.txtfile?)@kkoehne I retook the clone of the qtbase 6.0.0 and reconfigured, then built and now it gets stuck with similar error:
[598/1478] Building CXX object src/network/CMakeFiles/Network.dir/access/qdecompresshelper.cpp.o
FAILED: src/network/CMakeFiles/Network.dir/access/qdecompresshelper.cpp.o
/home/pi/rpi-sdk/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ --sysroot=/home/pi/rpi-sdk/sysroot -DNetwork_EXPORTS -DQT_ASCII_CAST_WARNINGS -DQT_BUILDING_QT -DQT_BUILD_NETWORK_LIB -DQT_CORE_LIB -DQT_DEPRECATED_WARNINGS -DQT_DEPRECATED_WARNINGS_SINCE=0x060000 -DQT_DISABLE_DEPRECATED_BEFORE=0x050000 -DQT_MOC_COMPAT -DQT_NO_CAST_TO_ASCII -DQT_NO_DEBUG -DQT_NO_EXCEPTIONS -DQT_NO_FOREACH -DQT_NO_USING_NAMESPACE -DQT_USE_QSTRINGBUILDER -DQT_USE_SYSTEM_PROXIES -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/Network_autogen/include -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtNetwork -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/kernel -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtNetwork/6.0.0 -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtNetwork/6.0.0/QtNetwork -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtCore -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/mkspecs/linux-g++ -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/corelib -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtCore/6.0.0 -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtCore/6.0.0/QtCore -fPIC -Wl,-rpath-link,/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf -L/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf -DNDEBUG -O2 -fPIC -fvisibility=hidden -fvisibility-inlines-hidden -Wall -Wextra -fno-exceptions -pthread -std=c++1z -Winvalid-pch -include /home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/CMakeFiles/Network.dir/cmake_pch.hxx -MD -MT src/network/CMakeFiles/Network.dir/access/qdecompresshelper.cpp.o -MF src/network/CMakeFiles/Network.dir/access/qdecompresshelper.cpp.o.d -o src/network/CMakeFiles/Network.dir/access/qdecompresshelper.cpp.o -c /home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/access/qdecompresshelper.cpp
/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/access/qdecompresshelper.cpp:48:14: fatal error: brotli/decode.h: No such file or directoryinclude <brotli/decode.h>
^~~~~~~~~~~~~~~~~compilation terminated.
[601/1478] Building CXX object src/network/CMakeFiles/Network.dir/access/qabstractprotocolhandler.cpp.o
ninja: build stopped: subcommand failed. -
@kkoehne I retook the clone of the qtbase 6.0.0 and reconfigured, then built and now it gets stuck with similar error:
[598/1478] Building CXX object src/network/CMakeFiles/Network.dir/access/qdecompresshelper.cpp.o
FAILED: src/network/CMakeFiles/Network.dir/access/qdecompresshelper.cpp.o
/home/pi/rpi-sdk/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ --sysroot=/home/pi/rpi-sdk/sysroot -DNetwork_EXPORTS -DQT_ASCII_CAST_WARNINGS -DQT_BUILDING_QT -DQT_BUILD_NETWORK_LIB -DQT_CORE_LIB -DQT_DEPRECATED_WARNINGS -DQT_DEPRECATED_WARNINGS_SINCE=0x060000 -DQT_DISABLE_DEPRECATED_BEFORE=0x050000 -DQT_MOC_COMPAT -DQT_NO_CAST_TO_ASCII -DQT_NO_DEBUG -DQT_NO_EXCEPTIONS -DQT_NO_FOREACH -DQT_NO_USING_NAMESPACE -DQT_USE_QSTRINGBUILDER -DQT_USE_SYSTEM_PROXIES -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/Network_autogen/include -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtNetwork -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/kernel -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtNetwork/6.0.0 -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtNetwork/6.0.0/QtNetwork -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtCore -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/mkspecs/linux-g++ -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/corelib -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtCore/6.0.0 -I/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/include/QtCore/6.0.0/QtCore -fPIC -Wl,-rpath-link,/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf -L/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf -DNDEBUG -O2 -fPIC -fvisibility=hidden -fvisibility-inlines-hidden -Wall -Wextra -fno-exceptions -pthread -std=c++1z -Winvalid-pch -include /home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/CMakeFiles/Network.dir/cmake_pch.hxx -MD -MT src/network/CMakeFiles/Network.dir/access/qdecompresshelper.cpp.o -MF src/network/CMakeFiles/Network.dir/access/qdecompresshelper.cpp.o.d -o src/network/CMakeFiles/Network.dir/access/qdecompresshelper.cpp.o -c /home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/access/qdecompresshelper.cpp
/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/access/qdecompresshelper.cpp:48:14: fatal error: brotli/decode.h: No such file or directoryinclude <brotli/decode.h>
^~~~~~~~~~~~~~~~~compilation terminated.
[601/1478] Building CXX object src/network/CMakeFiles/Network.dir/access/qabstractprotocolhandler.cpp.o
ninja: build stopped: subcommand failed.@Athem said in Build failing for Qt6 (Cross Compiling for STM32 armv7ve):
fatal error: brotli/decode.h: No such file or directory
This is now compiler error.
Did you install brotli dev package which contains the header files? -
@Athem said in Build failing for Qt6 (Cross Compiling for STM32 armv7ve):
fatal error: brotli/decode.h: No such file or directory
This is now compiler error.
Did you install brotli dev package which contains the header files?@jsulm said in Build failing for Qt6 (Cross Compiling for STM32 armv7ve):
brotli dev package
yes. I have it installed. I tried reinstalling it and it confirmed that it already had it:
sudo apt-get install libbrotli-dev
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
libbrotli-dev is already the newest version (1.0.9-2build6).
libbrotli-dev set to manually installed.
0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded. -
@jsulm said in Build failing for Qt6 (Cross Compiling for STM32 armv7ve):
brotli dev package
yes. I have it installed. I tried reinstalling it and it confirmed that it already had it:
sudo apt-get install libbrotli-dev
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
libbrotli-dev is already the newest version (1.0.9-2build6).
libbrotli-dev set to manually installed.
0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded. -
@Athem Can you search for decode.h from brotly on your system? And post the path to it. Maybe your OS packes brotli headers differently.
@jsulm I reconfigured after deleting the cache by adding -DQT_FEATURE_brotli=OFF argument in the configure command, so the output of configure confirmed the brotli being off. Now when I gave "cmake --build . --parallel 4" command, it got stuck at another place in network: I am starting to think network modules are a pain to compile (or maybe I am making a mistake somewhere).
Edit: the configure command goes as following:
cmake -GNinja -DCMAKE_BUILD_TYPE=Release -DQT_FEATURE_eglfs_egldevice=ON -DQT_FEATURE_eglfs_gbm=ON -DQT_FEATURE_brotli=OFF -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=ON -DQT_BUILD_EXAMPLES=OFF -DQT_BUILD_TESTS=OFF -DQT_HOST_PATH=/home/pi/qt-host/6.0.0/gcc_64/ -DCMAKE_STAGING_PREFIX=/home/pi/qt6-rpi -DCMAKE_INSTALL_PREFIX=/usr/local/qt6 -DCMAKE_PREFIX_PATH=/home/pi/rpi-sdk/sysroot/usr/lib/ -DCMAKE_TOOLCHAIN_FILE=/home/pi/qt-cross/toolchain.cmake /home/pi/qt-cross/qtbase-everywhere-src-6.0.0/Build Result:
523/1478] Automatic MOC for target Network
AutoMoc: /home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/access/qnetworkaccessdebugpipebackend_p.h:0:1: note: No relevant classes found. No output generated.
[634/1478] Linking CXX executable bin/uic
FAILED: bin/uic
: && /home/pi/rpi-sdk/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ --sysroot=/home/pi/rpi-sdk/sysroot -fPIC -Wl,-rpath-link,/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf -L/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf -DNDEBUG -O2 -fPIC -Wl,-rpath-link,/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf -L/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf src/tools/uic/CMakeFiles/uic_native.dir/uic_native_autogen/mocs_compilation.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/cpp/cppwritedeclaration.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/cpp/cppwriteincludes.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/cpp/cppwriteinitialization.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/customwidgetsinfo.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/databaseinfo.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/driver.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/main.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/python/pythonwritedeclaration.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/python/pythonwriteimports.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/shared/language.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/treewalker.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/ui4.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/uic.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/validator.cpp.o -o bin/uic -Wl,-rpath,/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/lib: lib/libQt6Core.so.6.0.0 -pthread && :
/home/pi/rpi-sdk/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: warning: libz.so.1, needed by lib/libQt6Core.so.6.0.0, not found (try using -rpath or -rpath-link)
/home/pi/rpi-sdk/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: warning: libdl.so.2, needed by lib/libQt6Core.so.6.0.0, not found (try using -rpath or -rpath-link)
/home/pi/rpi-sdk/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: warning: libpcre.so.3, needed by /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0, not found (try using -rpath or -rpath-link)
lib/libQt6Core.so.6.0.0: undefined reference todlopen@GLIBC_2.4' lib/libQt6Core.so.6.0.0: undefined reference todlsym@GLIBC_2.4'
/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_exec' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_study'
/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_dfa_exec' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_fullinfo'
lib/libQt6Core.so.6.0.0: undefined reference toinflateInit2_' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_get_stringnumber'
/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_compile2' lib/libQt6Core.so.6.0.0: undefined reference todlerror@GLIBC_2.4'
lib/libQt6Core.so.6.0.0: undefined reference todlclose@GLIBC_2.4' lib/libQt6Core.so.6.0.0: undefined reference todladdr@GLIBC_2.4'
lib/libQt6Core.so.6.0.0: undefined reference toinflate' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_get_stringtable_entries'
lib/libQt6Core.so.6.0.0: undefined reference tocompress2' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_free'
lib/libQt6Core.so.6.0.0: undefined reference touncompress' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_config'
lib/libQt6Core.so.6.0.0: undefined reference to `inflateEnd'
collect2: error: ld returned 1 exit status
[637/1478] Building CXX object src/xml/CMakeFiles/Xml.dir/cmake_pch.hxx.gch
ninja: build stopped: subcommand failed. -
@jsulm I reconfigured after deleting the cache by adding -DQT_FEATURE_brotli=OFF argument in the configure command, so the output of configure confirmed the brotli being off. Now when I gave "cmake --build . --parallel 4" command, it got stuck at another place in network: I am starting to think network modules are a pain to compile (or maybe I am making a mistake somewhere).
Edit: the configure command goes as following:
cmake -GNinja -DCMAKE_BUILD_TYPE=Release -DQT_FEATURE_eglfs_egldevice=ON -DQT_FEATURE_eglfs_gbm=ON -DQT_FEATURE_brotli=OFF -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=ON -DQT_BUILD_EXAMPLES=OFF -DQT_BUILD_TESTS=OFF -DQT_HOST_PATH=/home/pi/qt-host/6.0.0/gcc_64/ -DCMAKE_STAGING_PREFIX=/home/pi/qt6-rpi -DCMAKE_INSTALL_PREFIX=/usr/local/qt6 -DCMAKE_PREFIX_PATH=/home/pi/rpi-sdk/sysroot/usr/lib/ -DCMAKE_TOOLCHAIN_FILE=/home/pi/qt-cross/toolchain.cmake /home/pi/qt-cross/qtbase-everywhere-src-6.0.0/Build Result:
523/1478] Automatic MOC for target Network
AutoMoc: /home/pi/qt-cross/qtbase-everywhere-src-6.0.0/src/network/access/qnetworkaccessdebugpipebackend_p.h:0:1: note: No relevant classes found. No output generated.
[634/1478] Linking CXX executable bin/uic
FAILED: bin/uic
: && /home/pi/rpi-sdk/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ --sysroot=/home/pi/rpi-sdk/sysroot -fPIC -Wl,-rpath-link,/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf -L/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf -DNDEBUG -O2 -fPIC -Wl,-rpath-link,/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf -L/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf src/tools/uic/CMakeFiles/uic_native.dir/uic_native_autogen/mocs_compilation.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/cpp/cppwritedeclaration.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/cpp/cppwriteincludes.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/cpp/cppwriteinitialization.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/customwidgetsinfo.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/databaseinfo.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/driver.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/main.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/python/pythonwritedeclaration.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/python/pythonwriteimports.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/shared/language.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/treewalker.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/ui4.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/uic.cpp.o src/tools/uic/CMakeFiles/uic_native.dir/validator.cpp.o -o bin/uic -Wl,-rpath,/home/pi/qt-cross/qtbase-everywhere-src-6.0.0/lib: lib/libQt6Core.so.6.0.0 -pthread && :
/home/pi/rpi-sdk/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: warning: libz.so.1, needed by lib/libQt6Core.so.6.0.0, not found (try using -rpath or -rpath-link)
/home/pi/rpi-sdk/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: warning: libdl.so.2, needed by lib/libQt6Core.so.6.0.0, not found (try using -rpath or -rpath-link)
/home/pi/rpi-sdk/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: warning: libpcre.so.3, needed by /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0, not found (try using -rpath or -rpath-link)
lib/libQt6Core.so.6.0.0: undefined reference todlopen@GLIBC_2.4' lib/libQt6Core.so.6.0.0: undefined reference todlsym@GLIBC_2.4'
/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_exec' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_study'
/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_dfa_exec' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_fullinfo'
lib/libQt6Core.so.6.0.0: undefined reference toinflateInit2_' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_get_stringnumber'
/home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_compile2' lib/libQt6Core.so.6.0.0: undefined reference todlerror@GLIBC_2.4'
lib/libQt6Core.so.6.0.0: undefined reference todlclose@GLIBC_2.4' lib/libQt6Core.so.6.0.0: undefined reference todladdr@GLIBC_2.4'
lib/libQt6Core.so.6.0.0: undefined reference toinflate' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_get_stringtable_entries'
lib/libQt6Core.so.6.0.0: undefined reference tocompress2' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_free'
lib/libQt6Core.so.6.0.0: undefined reference touncompress' /home/pi/rpi-sdk/sysroot/usr/lib/arm-linux-gnueabihf/libglib-2.0.so.0: undefined reference topcre_config'
lib/libQt6Core.so.6.0.0: undefined reference to `inflateEnd'
collect2: error: ld returned 1 exit status
[637/1478] Building CXX object src/xml/CMakeFiles/Xml.dir/cmake_pch.hxx.gch
ninja: build stopped: subcommand failed.@Athem Since the issue involes moc and uic, I found the following mentioned in the Qt website: "By default, when cross-compiling, only the Qt libraries and tools that are supposed to run on the target device are built. Build-related tools like moc and uic are not built. Building such tools can be enabled by setting QT_FORCE_BUILD_TOOLS to ON."
sourceCan someone tell me how can I pass QT_FORCE_BUILD_TOOLS to ON? I tried adding it to configure command but it ignores it.
-
@Athem Since the issue involes moc and uic, I found the following mentioned in the Qt website: "By default, when cross-compiling, only the Qt libraries and tools that are supposed to run on the target device are built. Build-related tools like moc and uic are not built. Building such tools can be enabled by setting QT_FORCE_BUILD_TOOLS to ON."
sourceCan someone tell me how can I pass QT_FORCE_BUILD_TOOLS to ON? I tried adding it to configure command but it ignores it.
configure ... -- -DQT_FORCE_BUILD_TOOLS=ON-- is important (see https://doc-snapshots.qt.io/qt6-dev/configure-linux-device.html)!
-
configure ... -- -DQT_FORCE_BUILD_TOOLS=ON-- is important (see https://doc-snapshots.qt.io/qt6-dev/configure-linux-device.html)!
@jsulm I read here https://codereview.qt-project.org/c/qt%2Fqtdeclarative/+/375768 that if the QTBuildTools are disabled, then qml, qmlscene and qmlpreview have issues when cross compiling. The same issue I am facing when trying to add qtDeclarative on top of the already cross compilled base module:
[1/2] Linking CXX executable bin/qmlpreview FAILED: bin/qmlpreview
[2/2] Linking CXX executable bin/qml FAILED: bin/qmlDo you know about it?
-
@Athem , any particular reason you're using Qt 6.0.0? I recommend at least Qt 6.2 (or, better: Qt 6.3). Quite some cross-compiling issues have been fixed since Qt 6.0.0 ...