* gnu/packages/qt.scm (qtbase, qtsvg, qtshadertools, qtnetworkauth,
qtimageformats, qtlanguageserver, qtpositioning, qtdeclarative, qttools,
qt5compat, qtlottie, qtwebsockets, qttranslations, qtwebchannel, qtwayland,
qtremoteobjects, qtmultimedia, qtspeech, qtsensors, qt-creator, qtwebengine): Update to 6.6.2.
(qtbase)[source]: unbundle pcre2, md4c, remove qtbase-use-TZDIR.patch. Add
qtbase-find-tools-in-PATH.patch,
qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch,
qtbase-qmake-fix-includedir-in-generated-pkg-config.patch,
qtbase-check-in-the-QML-folder-of-this-library-does-.patch.
(qtbase)[arguments]<#:phase>: adjust 'patch-more-paths phase, skip tst_selftests test.
(qtbase)[inputs]: add libb2.
* gnu/packages/patches/qtbase-use-TZDIR.patch: remove this.
* gnu/packages/patches/qtbase-find-tools-in-PATH.patch: New file
* gnu/packages/patches/qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch: New file
* gnu/packages/patches/qtbase-qmake-fix-includedir-in-generated-pkg-config.patch: New file
* gnu/packages/patches/qtbase-check-in-the-QML-folder-of-this-library-does-.patch: New file
* gnu/local.mk(dist_patch_DATA): remove qtbase-use-TZDIR.patch.
Add qtbase-find-tools-in-PATH.patch,
Regist qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch,
qtbase-qmake-fix-includedir-in-generated-pkg-config.patch,
qtbase-check-in-the-QML-folder-of-this-library-does-.patch.
* gnu/packages/patches/qtdeclarative-disable-qmlcache.patch: adjust it.
(qttools)[inputs]: add zstd:lib.
(qtwayland)[arguments]<#:phases>: Adjust set-test-environment phase.
(qtmultimedia)[arguments]<#:phases>: adjust 'disable-integration-tests phase.
gnu: Add qtspeech-5.
* gnu/packages/qt.scm(python-pyside-2):
* gnu/packages/games.scm (chessx):
* gnu/packages/kde-frameworks.scm(ktextwidgets):
* gnu/packages/kde-pim.scm(kdepim-runtime,kpimtextedit):
* gnu/packages/kde-utils.scm(kmouth):
* gnu/packages/kde.scm(okular):
* gnu/packages/radio.scm(sdrangel):
Adjust inputs.
gnu: Add qtsensors-5.
* gnu/packages/qt.scm(python-pyqt,python-pyside-2):
* gnu/packages/education.scm(gcompris-qt):
* gnu/packages/kde-plasma.scm(kscreen):
* gnu/packages/geo.scm(openorienteering-mapper):
Adjust inputs.
(qtwebengine)[source]: Adjust snippet.
[arguments]<#:configure-flags>: Adjust it.
<#:phases>: Add delete-installed-tests phase.
Change-Id: Ibb30850de615c85dca2cc4d6fd55b18a228e0fc9
---
gnu/local.mk | 5 +-
gnu/packages/education.scm | 2 +-
gnu/packages/games.scm | 2 +-
gnu/packages/geo.scm | 2 +-
gnu/packages/kde-frameworks.scm | 2 +-
gnu/packages/kde-pim.scm | 4 +-
gnu/packages/kde-plasma.scm | 2 +-
gnu/packages/kde-utils.scm | 2 +-
gnu/packages/kde.scm | 2 +-
...the-QML-folder-of-this-library-does-.patch | 35 +++
.../patches/qtbase-find-tools-in-PATH.patch | 45 ++++
...mlimportscanner-the-QML2_IMPORT_PATH.patch | 30 +++
...x-includedir-in-generated-pkg-config.patch | 26 +++
gnu/packages/patches/qtbase-use-TZDIR.patch | 141 ------------
.../qtdeclarative-disable-qmlcache.patch | 27 ++-
gnu/packages/qt.scm | 208 ++++++++++++------
gnu/packages/radio.scm | 2 +-
17 files changed, 316 insertions(+), 221 deletions(-)
create mode 100644 gnu/packages/patches/qtbase-check-in-the-QML-folder-of-this-library-does-.patch
create mode 100644 gnu/packages/patches/qtbase-find-tools-in-PATH.patch
create mode 100644 gnu/packages/patches/qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch
create mode 100644 gnu/packages/patches/qtbase-qmake-fix-includedir-in-generated-pkg-config.patch
delete mode 100644 gnu/packages/patches/qtbase-use-TZDIR.patch
Toggle diff (361 lines)
diff --git a/gnu/local.mk b/gnu/local.mk
index 1aa413ebbe..3741cb9cd5 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1951,10 +1951,13 @@ dist_patch_DATA = \
%D%/packages/patches/qemu-fix-agent-paths.patch \
%D%/packages/patches/qrcodegen-cpp-make-install.patch \
%D%/packages/patches/qtbase-absolute-runpath.patch \
+ %D%/packages/patches/qtbase-find-tools-in-PATH.patch \
+ %D%/packages/patches/qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch \
+ %D%/packages/patches/qtbase-qmake-fix-includedir-in-generated-pkg-config.patch \
+ %D%/packages/patches/qtbase-check-in-the-QML-folder-of-this-library-does-.patch \
%D%/packages/patches/qtbase-moc-ignore-gcc-macro.patch \
%D%/packages/patches/qtbase-qmake-use-libname.patch \
%D%/packages/patches/qtbase-5-use-TZDIR.patch \
- %D%/packages/patches/qtbase-use-TZDIR.patch \
%D%/packages/patches/qtscript-disable-tests.patch \
%D%/packages/patches/quagga-reproducible-build.patch \
%D%/packages/patches/quickswitch-fix-dmenu-check.patch \
diff --git a/gnu/packages/education.scm b/gnu/packages/education.scm
index 698f15678b..50d4b332ee 100644
--- a/gnu/packages/education.scm
+++ b/gnu/packages/education.scm
@@ -192,7 +192,7 @@ (define-public gcompris-qt
qtgraphicaleffects
qtmultimedia-5
qtquickcontrols2-5
- qtsensors
+ qtsensors-5
qtsvg-5))
(home-page "https://gcompris.net/index-en.html")
(synopsis "Educational games for small children")
diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index 9ff08e5e74..fdc2d53a77 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -10475,7 +10475,7 @@ (define-public chessx
(native-inputs
(list qttools-5))
(inputs
- (list qtbase-5 qtmultimedia-5 qtspeech qtsvg-5 zlib))
+ (list qtbase-5 qtmultimedia-5 qtspeech-5 qtsvg-5 zlib))
(arguments
`(#:tests? #f
#:phases
diff --git a/gnu/packages/geo.scm b/gnu/packages/geo.scm
index 687effcace..63e66afdb8 100644
--- a/gnu/packages/geo.scm
+++ b/gnu/packages/geo.scm
@@ -2575,7 +2575,7 @@ (define-public openorienteering-mapper
qtbase-5
qtimageformats-5
qtlocation
- qtsensors
+ qtsensors-5
zlib))
(native-inputs
(list doxygen
diff --git a/gnu/packages/kde-frameworks.scm b/gnu/packages/kde-frameworks.scm
index 64e41b510d..227f9a28b1 100644
--- a/gnu/packages/kde-frameworks.scm
+++ b/gnu/packages/kde-frameworks.scm
@@ -3249,7 +3249,7 @@ (define-public ktextwidgets
kwidgetsaddons
kwindowsystem
qtbase-5
- qtspeech))
+ qtspeech-5))
(home-page "https://community.kde.org/Frameworks")
(synopsis "Text editing widgets")
(description "KTextWidgets provides widgets for displaying and editing text.
diff --git a/gnu/packages/kde-pim.scm b/gnu/packages/kde-pim.scm
index e95eac4e2f..9a1c0b8d8e 100644
--- a/gnu/packages/kde-pim.scm
+++ b/gnu/packages/kde-pim.scm
@@ -848,7 +848,7 @@ (define-public kdepim-runtime
qtdeclarative-5
qtkeychain
qtnetworkauth-5
- qtspeech
+ qtspeech-5
qtwebchannel-5
qtwebengine-5
qtxmlpatterns))
@@ -1993,7 +1993,7 @@ (define-public kpimtextedit
kwidgetsaddons
kxmlgui
qtbase-5
- qtspeech
+ qtspeech-5
sonnet))
(arguments
`(#:tests? #f)) ;; TODO - test suite hangs
diff --git a/gnu/packages/kde-plasma.scm b/gnu/packages/kde-plasma.scm
index cf45fa59f7..1d41d35a56 100644
--- a/gnu/packages/kde-plasma.scm
+++ b/gnu/packages/kde-plasma.scm
@@ -793,7 +793,7 @@ (define-public kscreen
libkscreen
libxi
plasma-wayland-protocols
- qtsensors
+ qtsensors-5
qtbase-5
qtx11extras
xcb-util))
diff --git a/gnu/packages/kde-utils.scm b/gnu/packages/kde-utils.scm
index 4e665da599..6c6a669597 100644
--- a/gnu/packages/kde-utils.scm
+++ b/gnu/packages/kde-utils.scm
@@ -874,7 +874,7 @@ (define-public kmouth
kxmlgui
breeze-icons ;; default icon set
qtbase-5
- qtspeech))
+ qtspeech-5))
(home-page "https://apps.kde.org/kmouth/")
(synopsis "Type-and-say frontend for speech synthesizers")
(description "KMouth is a program which enables persons that cannot speak
diff --git a/gnu/packages/kde.scm b/gnu/packages/kde.scm
index 8e8bb32fda..385bb42926 100644
--- a/gnu/packages/kde.scm
+++ b/gnu/packages/kde.scm
@@ -1557,7 +1557,7 @@ (define-public okular
kio
kparts
kpty
- qtspeech
+ qtspeech-5
kwallet
kwindowsystem
libkexiv2
diff --git a/gnu/packages/patches/qtbase-check-in-the-QML-folder-of-this-library-does-.patch b/gnu/packages/patches/qtbase-check-in-the-QML-folder-of-this-library-does-.patch
new file mode 100644
index 0000000000..ed749cb238
--- /dev/null
+++ b/gnu/packages/patches/qtbase-check-in-the-QML-folder-of-this-library-does-.patch
@@ -0,0 +1,35 @@
+From c00e310092d9aeb48adf21dd22f1ee4dbdbf5ebb Mon Sep 17 00:00:00 2001
+From: Nick Cao <nickcao@nichi.co>
+Date: Tue, 10 Oct 2023 10:17:00 -0400
+Subject: [PATCH 10/11] qtbase: check in the QML folder of this library does
+ actually exist
+
+In a modularized installation, this folder will be the location where
+`qtbase` itself is installed, but `qtbase` does not have any QML
+code, and `qmlimportscanner` will complain that it does not exist.
+---
+ src/tools/macdeployqt/shared/shared.cpp | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/src/tools/macdeployqt/shared/shared.cpp b/src/tools/macdeployqt/shared/shared.cpp
+index 320095a972d..87ba0d4e24b 100644
+--- a/src/tools/macdeployqt/shared/shared.cpp
++++ b/src/tools/macdeployqt/shared/shared.cpp
+@@ -1297,9 +1297,12 @@ bool deployQmlImports(const QString &appBundlePath, DeploymentInfo deploymentInf
+ }
+ for (const QString &importPath : qmlImportPaths)
+ argumentList << "-importPath" << importPath;
++
+ QString qmlImportsPath = QLibraryInfo::path(QLibraryInfo::QmlImportsPath);
+- argumentList.append( "-importPath");
+- argumentList.append(qmlImportsPath);
++ if (QFile::exists(qmlImportsPath)) {
++ argumentList.append( "-importPath");
++ argumentList.append(qmlImportsPath);
++ }
+
+ // In a modularized installation of qt as we have in Nix, instead, we will
+ // read the paths from the environment, as they are spread in multiple
+--
+2.42.0
+
diff --git a/gnu/packages/patches/qtbase-find-tools-in-PATH.patch b/gnu/packages/patches/qtbase-find-tools-in-PATH.patch
new file mode 100644
index 0000000000..1d60684e07
--- /dev/null
+++ b/gnu/packages/patches/qtbase-find-tools-in-PATH.patch
@@ -0,0 +1,45 @@
+From a8b9fae710a2bd5e743f5e16364eaa8c38dbd784 Mon Sep 17 00:00:00 2001
+From: rewine <luhongxu@deepin.org>
+Date: Wed, 29 Mar 2023 11:51:33 +0800
+Subject: [PATCH 06/11] qtbase-find-tools-in-PATH
+
+1. find qt's tools in `QTTOOLSPATH` env
+ qt assumes that all components use the same install prefix
+ we can't get the real prefix for qttools when build qtbase
+ we will add /libexec to `QTTOOLSPATH` in qtToolsHook
+ find_path will also search in 'PATH' by default
+ see `CMAKE_FIND_USE_SYSTEM_ENVIRONMENT_PATH`
+
+2. disable tool_dependencies_enabled
+ We can guarantee the build order of qt components in nixpkgs
+ tools in qttools always build before qtdoc
+ qdoc_bin is not a build target now, since we find it in `QTTOOLSPATH`
+---
+ cmake/QtDocsHelpers.cmake | 11 ++++++++---
+ 1 file changed, 8 insertions(+), 3 deletions(-)
+
+diff --git a/cmake/QtDocsHelpers.cmake b/cmake/QtDocsHelpers.cmake
+index 48ed5a324bf..91d8d41fb1f 100644
+--- a/cmake/QtDocsHelpers.cmake
++++ b/cmake/QtDocsHelpers.cmake
+@@ -47,9 +47,14 @@ function(qt_internal_add_docs)
+ set(doc_tools_libexec "${QT_BUILD_INTERNALS_RELOCATABLE_INSTALL_PREFIX}/${INSTALL_LIBEXECDIR}")
+ endif()
+
+- set(qdoc_bin "${doc_tools_bin}/qdoc${CMAKE_EXECUTABLE_SUFFIX}")
+- set(qtattributionsscanner_bin "${doc_tools_libexec}/qtattributionsscanner${CMAKE_EXECUTABLE_SUFFIX}")
+- set(qhelpgenerator_bin "${doc_tools_libexec}/qhelpgenerator${CMAKE_EXECUTABLE_SUFFIX}")
++ set(tool_dependencies_enabled FALSE)
++
++ find_path(qdoc_path name qdoc PATHS ENV QTTOOLSPATH)
++ find_path(qtattributionsscanner_path name qtattributionsscanner PATHS ENV QTTOOLSPATH)
++ find_path(qhelpgenerator_path name qhelpgenerator PATHS ENV QTTOOLSPATH)
++ set(qdoc_bin "${qdoc_path}/qdoc${CMAKE_EXECUTABLE_SUFFIX}")
++ set(qtattributionsscanner_bin "${qtattributionsscanner_path}/qtattributionsscanner${CMAKE_EXECUTABLE_SUFFIX}")
++ set(qhelpgenerator_bin "${qhelpgenerator_path}/qhelpgenerator${CMAKE_EXECUTABLE_SUFFIX}")
+
+ get_target_property(target_type ${target} TYPE)
+ if (NOT target_type STREQUAL "INTERFACE_LIBRARY")
+--
+2.42.0
+
diff --git a/gnu/packages/patches/qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch b/gnu/packages/patches/qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch
new file mode 100644
index 0000000000..7bf2193bc2
--- /dev/null
+++ b/gnu/packages/patches/qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch
@@ -0,0 +1,30 @@
+From d7a9a3b0ecdbb1b5829f25954d763d767f1c8794 Mon Sep 17 00:00:00 2001
+From: Nick Cao <nickcao@nichi.co>
+Date: Tue, 10 Oct 2023 10:12:56 -0400
+Subject: [PATCH 07/11] qtbase: pass to qmlimportscanner the QML2_IMPORT_PATH
+
+---
+ src/tools/macdeployqt/shared/shared.cpp | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/src/tools/macdeployqt/shared/shared.cpp b/src/tools/macdeployqt/shared/shared.cpp
+index 2ae4f998944..ba10ae02bcd 100644
+--- a/src/tools/macdeployqt/shared/shared.cpp
++++ b/src/tools/macdeployqt/shared/shared.cpp
+@@ -1297,6 +1297,13 @@ bool deployQmlImports(const QString &appBundlePath, DeploymentInfo deploymentInf
+ argumentList.append( "-importPath");
+ argumentList.append(qmlImportsPath);
+
++ // In a modularized installation of qt as we have in Nix, instead, we will
++ // read the paths from the environment, as they are spread in multiple
++ // locations and normally set in the environment like this
++ auto envQmlImportPaths = ::qgetenv("QML2_IMPORT_PATH").split(':');
++ for (const QString &importPath : envQmlImportPaths)
++ argumentList << "-importPath" << importPath;
++
+ // run qmlimportscanner
+ QProcess qmlImportScanner;
+ qmlImportScanner.start(qmlImportScannerPath, argumentList);
+--
+2.42.0
+
diff --git a/gnu/packages/patches/qtbase-qmake-fix-includedir-in-generated-pkg-config.patch b/gnu/packages/patches/qtbase-qmake-fix-includedir-in-generated-pkg-config.patch
new file mode 100644
index 0000000000..53f226254a
--- /dev/null
+++ b/gnu/packages/patches/qtbase-qmake-fix-includedir-in-generated-pkg-config.patch
@@ -0,0 +1,26 @@
+From 6088085d3074316dd74639fc6c1233e5862aff11 Mon Sep 17 00:00:00 2001
+From: Nick Cao <nickcao@nichi.co>
+Date: Fri, 14 Apr 2023 09:34:46 +0800
+Subject: [PATCH 03/11] qtbase: qmake: fix includedir in generated pkg-config
+
+---
+ qmake/generators/makefile.cpp | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp
+index 11d2f0ff7df..c78ed0d3485 100644
+--- a/qmake/generators/makefile.cpp
++++ b/qmake/generators/makefile.cpp
+@@ -3412,8 +3412,7 @@ MakefileGenerator::writePkgConfigFile()
+ << varGlue("QMAKE_PKGCONFIG_CFLAGS", "", " ", " ")
+ // << varGlue("DEFINES","-D"," -D"," ")
+ ;
+- if (!project->values("QMAKE_DEFAULT_INCDIRS").contains(includeDir))
+- t << "-I${includedir}";
++ t << "-I${includedir}";
+ if (target_mode == TARG_MAC_MODE && project->isActiveConfig("lib_bundle")
+ && libDir != QLatin1String("/Library/Frameworks")) {
+ t << " -F${libdir}";
+--
+2.42.0
+
diff --git a/gnu/packages/patches/qtbase-use-TZDIR.patch b/gnu/packages/patches/qtbase-use-TZDIR.patch
deleted file mode 100644
index 98bf7493e9..0000000000
--- a/gnu/packages/patches/qtbase-use-TZDIR.patch
+++ /dev/null
@@ -1,141 +0,0 @@
-From 1075606f8b2f9e153c82f8e50cbd69cea9c72e87 Mon Sep 17 00:00:00 2001
-From: Edward Welbourne <edward.welbourne@qt.io>
-Date: Mon, 11 Sep 2023 11:41:39 +0200
-Subject: [PATCH] Support the TZDIR environment variable
-
-On Linux / glibc, this overrides the default system location for the
-zone info. So check for files there first. Break out a function to
-manage the trying of (now three) zoneinfo directories when opening a
-file by name relative to there.
-
-Pick-to: 6.6 6.5
-Task-number: QTBUG-116017
-Change-Id: I1f97107aabd9015c0a5543639870f1d70654ca67
----
-* Rebased on top of v6.5.2.
-
- src/corelib/time/qtimezoneprivate_tz.cpp | 73 ++++++++++++++++--------
- 1 file changed, 49 insertions(+), 24 deletions(-)
-
-diff --git a/src/corelib/time/qtimezoneprivate_tz.cpp b/src/corelib/time/qtimezoneprivate_tz.cpp
-index 067191d816..a8b2fc894e 100644
---- a/src/corelib/time/qtimezoneprivate_tz.cpp
-+++ b/src/corelib/time/qtimezoneprivate_tz.cpp
-@@ -51,17 +51,41 @@ typedef QHash<QByteArray, QTzTimeZone> QTzTimeZoneHash;
-
- static bool isTzFile(const QString &name);
-
-+// Open a named file under the zone info directory:
-+static bool openZoneInfo(QString name, QFile *file)
-+{
-+ // At least on Linux / glibc (see man 3 tzset), $TZDIR overrides the system
-+ // default location for zone info:
-+ const QString tzdir = qEnvironmentVariable("TZDIR");
-+ if (!tzdir.isEmpty()) {
-+ file->setFileName(QDir(tzdir).filePath(name));
-+ if (file->open(QIODevice::ReadOnly))
-+ return true;
-+ }
-+ // Try modern system path first:
-+ constexpr auto zoneShare = "/usr/share/zoneinfo/"_L1;
-+ if (tzdir != zoneShare && tzdir != zoneShare.chopped(1)) {
-+ file->setFileName(zoneShare + name);
-+ if (file->open(QIODevice::ReadOnly))
-+ return true;
-+ }
-+ // Fall back to legacy system path:
-+ constexpr auto zoneLib = "/usr/lib/zoneinfo/"_L1;
-+ if (tzdir != zoneLib && tzdir != zoneLib.chopped(1)) {
-+ file->setFileName(zoneShare + name);
-+ if (file->open(QIODevice::ReadOnly))
-+ return true;
-+ }
-+ return false;
-+}
-+
- // Parse zone.tab table for territory information, read directories to ensure we
- // find all installed zones (many are omitted from zone.tab; even more from
- // zone1970.tab).
- static QTzTimeZoneHash loadTzTimeZones()
- {
-- QString path = QStringLiteral("/usr/share/zoneinfo/zone.tab");
-- if (!QFile::exists(path))
-- path = QStringLiteral("/usr/lib/zoneinfo/zone.tab");