M gnu/local.mk => gnu/local.mk +0 -1
@@ 2198,7 2198,6 @@ dist_patch_DATA = \
%D%/packages/patches/qemu-fix-agent-paths.patch \
%D%/packages/patches/qrcodegen-cpp-cmake.patch \
%D%/packages/patches/qtbase-absolute-runpath.patch \
- %D%/packages/patches/qtbase-find-tools-in-PATH.patch \
%D%/packages/patches/qtbase-qmake-fix-includedir.patch \
%D%/packages/patches/qtbase-qmlimportscanner-qml-import-path.patch \
%D%/packages/patches/qtbase-moc-ignore-gcc-macro.patch \
D gnu/packages/patches/qtbase-find-tools-in-PATH.patch => gnu/packages/patches/qtbase-find-tools-in-PATH.patch +0 -49
@@ 1,49 0,0 @@
-Patch retrieved from NixOS
-
-https://github.com/NixOS/nixpkgs/blob/93ecdaa1f34354c9476062dc4fe323b442c087d5/pkgs/development/libraries/qt-6/patches/0006-qtbase-find-tools-in-PATH.patch
-
-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
-
M gnu/packages/patches/qtbase-qmake-use-libname.patch => gnu/packages/patches/qtbase-qmake-use-libname.patch +9 -16
@@ 12,15 12,11 @@ and then used in linker flags. However as the libraries can be provided
by qt modules other than the one currently being built, the ebedded
paths can be incorrect.
---
- cmake/QtFinishPrlFile.cmake | 7 ++++---
- cmake/QtGenerateLibHelpers.cmake | 3 ---
- 2 files changed, 4 insertions(+), 6 deletions(-)
-
diff --git a/cmake/QtFinishPrlFile.cmake b/cmake/QtFinishPrlFile.cmake
index 32169e418c..4e754af367 100644
--- a/cmake/QtFinishPrlFile.cmake
+++ b/cmake/QtFinishPrlFile.cmake
-@@ -61,9 +61,10 @@ foreach(line ${lines})
+@@ -69,9 +69,10 @@ foreach(line ${lines})
endif()
list(APPEND adjusted_libs "-framework" "${CMAKE_MATCH_1}")
else()
@@ 38,16 34,13 @@ diff --git a/cmake/QtGenerateLibHelpers.cmake b/cmake/QtGenerateLibHelpers.cmake
index e3f4bbf881..f8bd26acc7 100644
--- a/cmake/QtGenerateLibHelpers.cmake
+++ b/cmake/QtGenerateLibHelpers.cmake
-@@ -70,9 +70,6 @@ function(qt_transform_absolute_library_paths_to_link_flags out_var library_path_
- string(TOLOWER "${dir}" dir_lower)
- # If library_path isn't in default link directories, we should add it to link flags.
- list(FIND IMPLICIT_LINK_DIRECTORIES_LOWER "${dir_lower}" index)
-- if(${index} EQUAL -1)
-- list(APPEND out_list "-L\"${dir}\"")
-- endif()
+@@ -82,9 +82,6 @@ function(qt_transform_absolute_library_paths_to_link_flags out_var library_path_
+ # If library_path isn't in default link directories, we should add it to link flags.
+ # But we shouldn't add it duplicately.
+ list(FIND IMPLICIT_LINK_DIRECTORIES_LOWER "${dir_lower}" index)
+- if(index EQUAL -1 AND NOT "-L\"${dir}\"" IN_LIST out_list)
+- list(APPEND out_list "-L\"${dir}\"")
+- endif()
+ endif()
list(APPEND out_list "${lib_name_with_link_flag}")
else()
- list(APPEND out_list "${library_path}")
---
-2.39.2
-
M gnu/packages/qt.scm => gnu/packages/qt.scm +38 -9
@@ 1,6 1,6 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013, 2014, 2015, 2023 Andreas Enge <andreas@enge.fr>
-;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
+;;; Copyright © 2015, 2025 宋文武 <iyzsong@envs.net>
;;; Copyright © 2015, 2018, 2019, 2020, 2021, 2023 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2015-2019, 2024 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2016, 2017 Nikita <nikita@n0.is>
@@ 763,13 763,13 @@ developers using C++ or QML, a CSS & JavaScript like language.")
(package
(inherit qtbase-5)
(name "qtbase")
- (version "6.7.2")
+ (version "6.8.2")
(source (origin
(inherit (package-source qtbase-5))
(uri (qt-url name version))
(sha256
(base32
- "16bmfrjfxjajs6sqg1383ihhfwwf69ihkpnpvsajh5pv21g2mwn5"))
+ "01gy1p8zvxq8771x6iqkrc7s3kzdddgf1i7xj656w7j1dp746801"))
(modules '((guix build utils)))
(snippet
;; corelib uses bundled harfbuzz, md4, md5, sha3
@@ 783,14 783,14 @@ developers using C++ or QML, a CSS & JavaScript like language.")
"qtbase-absolute-runpath.patch"
"qtbase-qmake-use-libname.patch"
"qtbase-qmlimportscanner-qml-import-path.patch"
- "qtbase-find-tools-in-PATH.patch"
"qtbase-qmake-fix-includedir.patch"))))
(build-system cmake-build-system)
(arguments
(substitute-keyword-arguments (package-arguments qtbase-5)
((#:configure-flags _ ''())
`(let ((out (assoc-ref %outputs "out")))
- (list "-DQT_BUILD_TESTS=ON"
+ (list "-GNinja" ;officially supported
+ "-DQT_BUILD_TESTS=ON"
(string-append "-DINSTALL_ARCHDATADIR=" out "/lib/qt6")
(string-append "-DINSTALL_DATADIR=" out "/share/qt6")
(string-append "-DINSTALL_DOCDIR=" out "/share/doc/qt6")
@@ 823,6 823,16 @@ developers using C++ or QML, a CSS & JavaScript like language.")
"-DBUILD_WITH_PCH=OFF")))
((#:phases phases)
#~(modify-phases #$phases
+ (replace 'build
+ (lambda* (#:key parallel-build? #:allow-other-keys)
+ (apply invoke "cmake" "--build" "."
+ (if parallel-build?
+ `("--parallel" ,(number->string
+ (parallel-job-count)))
+ '()))))
+ (replace 'install
+ (lambda _
+ (invoke "cmake" "--install" ".")))
(add-after 'unpack 'honor-CMAKE_PREFIX_PATH
(lambda _
;; The configuration files for other Qt packages are searched
@@ 842,8 852,12 @@ developers using C++ or QML, a CSS & JavaScript like language.")
;; 'qmlimportscanner' from qtdeclarative work out of the
;; box.
(substitute* "cmake/QtConfig.cmake.in"
- (("(set\\(QT_ADDITIONAL_PACKAGES_PREFIX_PATH )\"\"" _ head)
- (string-append head "\"$ENV{CMAKE_PREFIX_PATH}\"")))))
+ (("set\\(QT_ADDITIONAL_HOST_PACKAGES_PREFIX_PATH" below)
+ (string-append "
+if(QT_ADDITIONAL_PACKAGES_PREFIX_PATH STREQUAL \"\")
+ cmake_path(CONVERT $ENV{CMAKE_PREFIX_PATH} TO_CMAKE_PATH_LIST
+ QT_ADDITIONAL_PACKAGES_PREFIX_PATH)
+endif()\n" below)))))
(delete 'patch-bin-sh)
(delete 'patch-xdg-open)
;; Some tests fail to build on i686-linux
@@ 882,7 896,8 @@ tst_qt_cmake_create.cpp"
(delete 'do-not-capture-python) ;move after patch-source-shebangs
(add-after 'patch-source-shebangs 'do-not-capture-python
(lambda _
- (substitute* '("mkspecs/features/uikit/devices.py"
+ (substitute* '("libexec/qt-android-runner.py"
+ "mkspecs/features/uikit/devices.py"
"util/testrunner/qt-testrunner.py"
"util/testrunner/sanitizer-testrunner.py")
(((which "python3"))
@@ 1061,6 1076,14 @@ tst_qt_cmake_create.cpp"
;; "/home", "/etc" or "/root" and fail.
"tst_qcompleter"
"tst_qfiledialog"
+ ;; The following tests fail with: "Generation of UI
+ ;; files were triggered in the second build", but could
+ ;; pass in `guix shell --container`.
+ "test_qt_add_ui_1"
+ "test_qt_add_ui_2"
+ "test_qt_add_ui_6"
+ "test_qt_add_ui_8"
+ "test_qt_add_ui_9"
;; This test is susceptible to the 600 ms timeout used:
"tst_qpauseanimation")
#$@(cond
@@ 1149,11 1172,17 @@ tst_qt_cmake_create.cpp"
(string-append #$output "/tests"))))))))
(native-inputs
(modify-inputs (package-native-inputs qtbase-5)
- (prepend tzdata-for-tests
+ (prepend ninja ;CMake Generator, also used for tests
+ tzdata-for-tests
wayland-protocols
xvfb-run)))
+ (propagated-inputs
+ (modify-inputs (package-propagated-inputs qtbase-5)
+ ;; Required by Qt6GuiDependencies.cmake.
+ (prepend libxkbcommon vulkan-headers)))
(inputs
(modify-inputs (package-inputs qtbase-5)
+ (delete "libxkbcommon") ;qtbase-5 use libxkbcommon-1.5
(prepend at-spi2-core
bash-minimal
coreutils-minimal