From 38f492c5cbfa3ab5925fb485a2caf2b3d2dfe31c Mon Sep 17 00:00:00 2001 From: Patrick Franz Date: Sat, 21 Jan 2023 14:28:35 +0100 Subject: [PATCH] Fix FTCBFS (Closes: #1023054). --- debian/changelog | 9 +++++++++ debian/control | 1 + debian/not-installed | 5 +++++ debian/patches/cross.patch | 22 ++++++++++++++++++++++ debian/patches/series | 1 + debian/rules | 8 ++++++++ 6 files changed, 46 insertions(+) create mode 100644 debian/patches/cross.patch diff --git a/debian/changelog b/debian/changelog index d152310..b46c699 100644 --- a/debian/changelog +++ b/debian/changelog @@ -3,6 +3,15 @@ qt6-base (6.4.2+dfsg-1) UNRELEASED; urgency=medium [ Patrick Franz ] * Switch to the official 6.4.2 tarball, the tarball is the same. + [ Helmut Grohne ] + * Fix FTCBFS: Pass QT_HOST_PATH. (Closes: #1023054) + + cross.patch: Honour PKG_CONFIG_EXECUTABLE + + cross.patch: Allow building android tools + + Pass QT_HOST_* variables to build. + + Depend on a native qt toolchain for the former. + + Do build tools even when cross building. + + Add excess files to debian/not-installed. + -- Debian Qt/KDE Maintainers Sat, 21 Jan 2023 13:42:21 +0100 qt6-base (6.4.2+dfsg~rc1-3) unstable; urgency=medium diff --git a/debian/control b/debian/control index 605222a..bb6db7e 100644 --- a/debian/control +++ b/debian/control @@ -71,6 +71,7 @@ Build-Depends: cmake (>= 3.24~), ninja-build, pkg-config, pkg-kde-tools (>= 0.15.17~), + qt6-base-dev:native , unixodbc-dev, zlib1g-dev, Standards-Version: 4.6.2 diff --git a/debian/not-installed b/debian/not-installed index d55debf..46f4ea8 100644 --- a/debian/not-installed +++ b/debian/not-installed @@ -8,3 +8,8 @@ usr/lib/${DEB_HOST_MULTIARCH}/cmake/Qt6PrintSupport/Qt6PrintSupportPlugins.cmake usr/lib/${DEB_HOST_MULTIARCH}/cmake/Qt6Sql/Qt6SqlPlugins.cmake usr/lib/qt6/bin/qmake usr/lib/qt6/bin/qtpaths +# cross build specific: +usr/lib/qt6/bin/host-qmake +usr/lib/qt6/bin/host-qtpaths +usr/lib/qt6/bin/target_qt.conf +usr/lib/${DEB_HOST_MULTIARCH}/qt6/mkspecs/qdevice.pri diff --git a/debian/patches/cross.patch b/debian/patches/cross.patch new file mode 100644 index 0000000..1a7ebd3 --- /dev/null +++ b/debian/patches/cross.patch @@ -0,0 +1,22 @@ +--- a/cmake/QtBuildInternals/QtBuildInternalsConfig.cmake ++++ b/cmake/QtBuildInternals/QtBuildInternalsConfig.cmake +@@ -146,8 +146,6 @@ + set(FEATURE_pkg_config "${pkg_config_enabled}" CACHE STRING "Using pkg-config") + if(NOT pkg_config_enabled) + qt_build_internals_disable_pkg_config() +- else() +- unset(PKG_CONFIG_EXECUTABLE CACHE) + endif() + endfunction() + +--- a/src/tools/configure.cmake ++++ b/src/tools/configure.cmake +@@ -2,7 +2,7 @@ + SECTION "Deployment" + LABEL "Android deployment tool" + PURPOSE "The Android deployment tool automates the process of creating Android packages." +- CONDITION NOT CMAKE_CROSSCOMPILING AND QT_FEATURE_regularexpression) ++ CONDITION QT_FEATURE_regularexpression) + + qt_feature("macdeployqt" PRIVATE + SECTION "Deployment" diff --git a/debian/patches/series b/debian/patches/series index 98eae72..2d27cc9 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -5,6 +5,7 @@ upstream_Add-M68k-detection.patch # Debian specific remove_privacy_breaches.diff build_path_embedded_qtbuildinternalsextra_cmake.patch +cross.patch # Don't use yield on CPUs that might not support it armel-noyield.patch diff --git a/debian/rules b/debian/rules index ecfee1a..fe61815 100755 --- a/debian/rules +++ b/debian/rules @@ -19,6 +19,14 @@ else extra_cmake_args += -DFEATURE_sctp=OFF endif +# cross-builds +ifneq ($(DEB_BUILD_ARCH),$(DEB_HOST_ARCH)) + extra_cmake_args += \ + -DQT_HOST_PATH=/usr \ + -DQT_HOST_PATH_CMAKE_DIR=/usr/lib/${DEB_BUILD_MULTIARCH}/cmake \ + -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=ON +endif + %: dh $@ --with pkgkde_symbolshelper --buildsystem=cmake+ninja