diff options
author | Alyssa Ross <hi@alyssa.is> | 2024-05-03 15:14:25 +0200 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2024-05-07 11:19:19 +0200 |
commit | d92b2b6a1bbd322dd65a8b6f51019610d350046e (patch) | |
tree | 7f7c21927b9cc05676501f297c51eb76b49e326c /nixpkgs/pkgs/development/libraries/qt-6/patches | |
parent | 93c9e56b40530cc627d921cfc255c05b495d4017 (diff) | |
parent | 49050352f602fe87d16ff7b2b6a05b79eb20dc6f (diff) | |
download | nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar.gz nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar.bz2 nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar.lz nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar.xz nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar.zst nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.zip |
Merge remote-tracking branch 'nixpkgs/nixos-unstable-small'
Conflicts: nixpkgs/nixos/modules/services/mail/mailman.nix nixpkgs/nixos/modules/services/mail/public-inbox.nix nixpkgs/pkgs/build-support/go/module.nix
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/qt-6/patches')
19 files changed, 159 insertions, 206 deletions
diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0001-qtbase-qmake-always-use-libname-instead-of-absolute-.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0001-qtbase-qmake-always-use-libname-instead-of-absolute-.patch index de35178f7929..a8bb8f71cdbf 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0001-qtbase-qmake-always-use-libname-instead-of-absolute-.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0001-qtbase-qmake-always-use-libname-instead-of-absolute-.patch @@ -1,8 +1,8 @@ -From 90734859d2f9e6b9a1754c3e694ceb1a3c870bce Mon Sep 17 00:00:00 2001 +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Nick Cao <nickcao@nichi.co> Date: Thu, 13 Apr 2023 23:42:29 +0800 -Subject: [PATCH 01/11] qtbase: qmake: always use libname instead of absolute - path in qmake files +Subject: [PATCH] qtbase: qmake: always use libname instead of absolute path in + qmake files In generated qmake files, absolute paths to qt libraries are embedded and then used in linker flags. However as the libraries can be provided @@ -45,6 +45,3 @@ index 3ffe354fd8d..441332d4582 100644 list(APPEND out_list "${lib_name_with_link_flag}") else() list(APPEND out_list "${library_path}") --- -2.42.0 - diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/qtdeclarative-default-disable-qmlcache.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0001-qtdeclarative-disable-qml-disk-cache.patch index a204d52c9f0c..9afcc8240ab3 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/qtdeclarative-default-disable-qmlcache.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0001-qtdeclarative-disable-qml-disk-cache.patch @@ -1,4 +1,4 @@ -From 2d561e0a80f2d123a7348187975ee845f9dcd9e0 Mon Sep 17 00:00:00 2001 +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Nick Cao <nickcao@nichi.co> Date: Tue, 10 Oct 2023 11:12:27 -0400 Subject: [PATCH] qtdeclarative: disable qml disk cache @@ -8,10 +8,10 @@ Subject: [PATCH] qtdeclarative: disable qml disk cache 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/qml/jsruntime/qv4engine.cpp b/src/qml/jsruntime/qv4engine.cpp -index d1b4c4fff6..50f8a07420 100644 +index 506b920142..3cadb4fe06 100644 --- a/src/qml/jsruntime/qv4engine.cpp +++ b/src/qml/jsruntime/qv4engine.cpp -@@ -2232,11 +2232,7 @@ ExecutionEngine::DiskCacheOptions ExecutionEngine::diskCacheOptions() const +@@ -2202,11 +2202,7 @@ ExecutionEngine::DiskCacheOptions ExecutionEngine::diskCacheOptions() const { if (forceDiskCache()) return DiskCache::Enabled; @@ -24,6 +24,3 @@ index d1b4c4fff6..50f8a07420 100644 } void ExecutionEngine::callInContext(QV4::Function *function, QObject *self, --- -2.42.0 - diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0002-qtbase-qmake-fix-mkspecs-for-darwin.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0002-qtbase-qmake-fix-mkspecs-for-darwin.patch index 6cdbec5abfc7..1e548950a2a6 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0002-qtbase-qmake-fix-mkspecs-for-darwin.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0002-qtbase-qmake-fix-mkspecs-for-darwin.patch @@ -1,19 +1,19 @@ -From a804a9b1efdab0a71b9947e5c2bf9f6f5e316e0e Mon Sep 17 00:00:00 2001 +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Nick Cao <nickcao@nichi.co> Date: Fri, 14 Apr 2023 21:43:04 +0800 -Subject: [PATCH 02/11] qtbase: qmake: fix mkspecs for darwin +Subject: [PATCH] qtbase: qmake: fix mkspecs for darwin --- mkspecs/common/mac.conf | 2 +- - mkspecs/features/mac/default_post.prf | 263 -------------------------- + mkspecs/features/mac/default_post.prf | 264 -------------------------- mkspecs/features/mac/default_pre.prf | 58 ------ mkspecs/features/mac/sdk.mk | 27 --- mkspecs/features/mac/sdk.prf | 61 ------ mkspecs/features/mac/toolchain.prf | 5 - - 6 files changed, 1 insertion(+), 415 deletions(-) + 6 files changed, 1 insertion(+), 416 deletions(-) diff --git a/mkspecs/common/mac.conf b/mkspecs/common/mac.conf -index 61bea952b2..9909dae726 100644 +index 61bea952b22..9909dae7260 100644 --- a/mkspecs/common/mac.conf +++ b/mkspecs/common/mac.conf @@ -23,7 +23,7 @@ QMAKE_INCDIR_OPENGL = \ @@ -26,7 +26,7 @@ index 61bea952b2..9909dae726 100644 QMAKE_LFLAGS_REL_RPATH = diff --git a/mkspecs/features/mac/default_post.prf b/mkspecs/features/mac/default_post.prf -index 0b64a586b9..3b40328304 100644 +index 0b64a586b93..3b40328304d 100644 --- a/mkspecs/features/mac/default_post.prf +++ b/mkspecs/features/mac/default_post.prf @@ -1,9 +1,5 @@ @@ -311,7 +311,7 @@ index 0b64a586b9..3b40328304 100644 generate_xcode_project.commands = @$(QMAKE) -spec macx-xcode \"$(EXPORT__PRO_FILE_)\" $$QMAKE_ARGS generate_xcode_project.target = xcodeproj diff --git a/mkspecs/features/mac/default_pre.prf b/mkspecs/features/mac/default_pre.prf -index e3534561a5..3b01424e67 100644 +index e3534561a56..3b01424e67b 100644 --- a/mkspecs/features/mac/default_pre.prf +++ b/mkspecs/features/mac/default_pre.prf @@ -1,60 +1,2 @@ @@ -376,7 +376,7 @@ index e3534561a5..3b01424e67 100644 -xcode_copy_phase_strip_setting.value = NO -QMAKE_MAC_XCODE_SETTINGS += xcode_copy_phase_strip_setting diff --git a/mkspecs/features/mac/sdk.mk b/mkspecs/features/mac/sdk.mk -index a32ceacb6c..e69de29bb2 100644 +index a32ceacb6ce..e69de29bb2d 100644 --- a/mkspecs/features/mac/sdk.mk +++ b/mkspecs/features/mac/sdk.mk @@ -1,27 +0,0 @@ @@ -408,7 +408,7 @@ index a32ceacb6c..e69de29bb2 100644 - endif -endif diff --git a/mkspecs/features/mac/sdk.prf b/mkspecs/features/mac/sdk.prf -index 3a9c2778bb..e69de29bb2 100644 +index 3a9c2778bbe..e69de29bb2d 100644 --- a/mkspecs/features/mac/sdk.prf +++ b/mkspecs/features/mac/sdk.prf @@ -1,61 +0,0 @@ @@ -474,7 +474,7 @@ index 3a9c2778bb..e69de29bb2 100644 - cache($$tool_variable, set stash, $$tool) -} diff --git a/mkspecs/features/mac/toolchain.prf b/mkspecs/features/mac/toolchain.prf -index df191eb13c..e69de29bb2 100644 +index df191eb13c4..e69de29bb2d 100644 --- a/mkspecs/features/mac/toolchain.prf +++ b/mkspecs/features/mac/toolchain.prf @@ -1,5 +0,0 @@ diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/qtdeclarative-qml-paths.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0002-qtdeclarative-also-use-versioned-qml-paths.patch index 39b7a30892cf..d857d7ac1bba 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/qtdeclarative-qml-paths.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0002-qtdeclarative-also-use-versioned-qml-paths.patch @@ -1,8 +1,17 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Nick Cao <nickcao@nichi.co> +Date: Wed, 7 Feb 2024 11:49:04 -0500 +Subject: [PATCH] qtdeclarative: also use versioned qml paths + +--- + src/qml/qml/qqmlimport.cpp | 1 + + 1 file changed, 1 insertion(+) + diff --git a/src/qml/qml/qqmlimport.cpp b/src/qml/qml/qqmlimport.cpp -index 2e482c220d..4873809bec 100644 +index f9cc8da240..f8cb033be0 100644 --- a/src/qml/qml/qqmlimport.cpp +++ b/src/qml/qml/qqmlimport.cpp -@@ -1517,6 +1517,7 @@ QQmlImportDatabase::QQmlImportDatabase(QQmlEngine *e) +@@ -1520,6 +1520,7 @@ QQmlImportDatabase::QQmlImportDatabase(QQmlEngine *e) // env import paths addEnvImportPath("QML_IMPORT_PATH"); addEnvImportPath("QML2_IMPORT_PATH"); diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0003-qtbase-qmake-fix-includedir-in-generated-pkg-config.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0003-qtbase-qmake-fix-includedir-in-generated-pkg-config.patch index 53f226254a19..f2f9425841a8 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0003-qtbase-qmake-fix-includedir-in-generated-pkg-config.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0003-qtbase-qmake-fix-includedir-in-generated-pkg-config.patch @@ -1,14 +1,14 @@ -From 6088085d3074316dd74639fc6c1233e5862aff11 Mon Sep 17 00:00:00 2001 +From 0000000000000000000000000000000000000000 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 +Subject: [PATCH] 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 +index 482ef2e2697..49217e62cda 100644 --- a/qmake/generators/makefile.cpp +++ b/qmake/generators/makefile.cpp @@ -3412,8 +3412,7 @@ MakefileGenerator::writePkgConfigFile() @@ -21,6 +21,3 @@ index 11d2f0ff7df..c78ed0d3485 100644 if (target_mode == TARG_MAC_MODE && project->isActiveConfig("lib_bundle") && libDir != QLatin1String("/Library/Frameworks")) { t << " -F${libdir}"; --- -2.42.0 - diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0004-qtbase-deal-with-a-font-face-at-index-0-as-Regular-f.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0004-qtbase-deal-with-a-font-face-at-index-0-as-Regular-f.patch deleted file mode 100644 index ccd0fb02fcd8..000000000000 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0004-qtbase-deal-with-a-font-face-at-index-0-as-Regular-f.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 82e243f326aea40e7f3da935d8166979b11e8063 Mon Sep 17 00:00:00 2001 -From: Nick Cao <nickcao@nichi.co> -Date: Tue, 21 Mar 2023 15:48:49 +0800 -Subject: [PATCH 04/11] qtbase: deal with a font face at index 0 as Regular for - Variable fonts - -Reference: https://bugreports.qt.io/browse/QTBUG-111994 ---- - src/gui/text/unix/qfontconfigdatabase.cpp | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/src/gui/text/unix/qfontconfigdatabase.cpp b/src/gui/text/unix/qfontconfigdatabase.cpp -index 474644b871f..c7a117fd134 100644 ---- a/src/gui/text/unix/qfontconfigdatabase.cpp -+++ b/src/gui/text/unix/qfontconfigdatabase.cpp -@@ -556,6 +556,7 @@ void QFontconfigDatabase::populateFontDatabase() - FcObjectSetAdd(os, *p); - ++p; - } -+ FcPatternAddBool(pattern, FC_VARIABLE, FcFalse); - fonts = FcFontList(nullptr, pattern, os); - FcObjectSetDestroy(os); - FcPatternDestroy(pattern); --- -2.42.0 - diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0004-qtbase-qt-cmake-always-use-cmake-from-path.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0004-qtbase-qt-cmake-always-use-cmake-from-path.patch new file mode 100644 index 000000000000..56d19e0bb817 --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0004-qtbase-qt-cmake-always-use-cmake-from-path.patch @@ -0,0 +1,48 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Nick Cao <nickcao@nichi.co> +Date: Wed, 12 Apr 2023 10:13:50 +0800 +Subject: [PATCH] qtbase: qt-cmake: always use cmake from path + +The generated qt-cmake scripts embeds the absolute path of cmake used +during the build of qtbase, bloating the runtime closure of qtbase. +--- + bin/qt-cmake-create.in | 7 +------ + bin/qt-cmake.in | 7 +------ + 2 files changed, 2 insertions(+), 12 deletions(-) + +diff --git a/bin/qt-cmake-create.in b/bin/qt-cmake-create.in +index 7865d0fe91b..884dc4aba93 100755 +--- a/bin/qt-cmake-create.in ++++ b/bin/qt-cmake-create.in +@@ -7,12 +7,7 @@ HELP_MESSAGE="Usage + script_dir_path=`dirname $0` + script_dir_path=`(cd "$script_dir_path"; /bin/pwd)` + +-# Try to use original cmake, otherwise to make it relocatable, use any cmake found in PATH. +-original_cmake_path="@CMAKE_COMMAND@" +-cmake_path=$original_cmake_path +-if ! test -f "$cmake_path"; then +- cmake_path="cmake" +-fi ++cmake_path="cmake" + + if [ "$#" -gt 1 ]; then + echo "Invalid number of arguments" +diff --git a/bin/qt-cmake.in b/bin/qt-cmake.in +index f719257f602..571ffe788fa 100755 +--- a/bin/qt-cmake.in ++++ b/bin/qt-cmake.in +@@ -4,12 +4,7 @@ + script_dir_path=`dirname $0` + script_dir_path=`(cd "$script_dir_path"; /bin/pwd)` + +-# Try to use original cmake, otherwise to make it relocatable, use any cmake found in PATH. +-original_cmake_path="@CMAKE_COMMAND@" +-cmake_path=$original_cmake_path +-if ! test -f "$cmake_path"; then +- cmake_path="cmake" +-fi ++cmake_path="cmake" + + toolchain_path="$script_dir_path/@__GlobalConfig_relative_path_from_bin_dir_to_cmake_config_dir@/qt.toolchain.cmake" + diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0006-qtbase-find-tools-in-PATH.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0005-qtbase-find-tools-in-PATH.patch index 1d60684e0700..df1b67654b61 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0006-qtbase-find-tools-in-PATH.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0005-qtbase-find-tools-in-PATH.patch @@ -1,7 +1,7 @@ -From a8b9fae710a2bd5e743f5e16364eaa8c38dbd784 Mon Sep 17 00:00:00 2001 +From 0000000000000000000000000000000000000000 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 +Subject: [PATCH] qtbase: find tools in PATH 1. find qt's tools in `QTTOOLSPATH` env qt assumes that all components use the same install prefix @@ -19,10 +19,10 @@ Subject: [PATCH 06/11] qtbase-find-tools-in-PATH 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/cmake/QtDocsHelpers.cmake b/cmake/QtDocsHelpers.cmake -index 48ed5a324bf..91d8d41fb1f 100644 +index 8b631e88ca5..922639a9985 100644 --- a/cmake/QtDocsHelpers.cmake +++ b/cmake/QtDocsHelpers.cmake -@@ -47,9 +47,14 @@ function(qt_internal_add_docs) +@@ -72,9 +72,14 @@ function(qt_internal_add_docs) set(doc_tools_libexec "${QT_BUILD_INTERNALS_RELOCATABLE_INSTALL_PREFIX}/${INSTALL_LIBEXECDIR}") endif() @@ -40,6 +40,3 @@ index 48ed5a324bf..91d8d41fb1f 100644 get_target_property(target_type ${target} TYPE) if (NOT target_type STREQUAL "INTERFACE_LIBRARY") --- -2.42.0 - diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0005-qtbase-qt-cmake-always-use-cmake-from-path.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0005-qtbase-qt-cmake-always-use-cmake-from-path.patch deleted file mode 100644 index ad30ebc71413..000000000000 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0005-qtbase-qt-cmake-always-use-cmake-from-path.patch +++ /dev/null @@ -1,32 +0,0 @@ -From b480022b364b262d5ff63738c02318da925f5c79 Mon Sep 17 00:00:00 2001 -From: Nick Cao <nickcao@nichi.co> -Date: Wed, 12 Apr 2023 10:13:50 +0800 -Subject: [PATCH 05/11] qtbase: qt-cmake: always use cmake from path - -The generated qt-cmake scripts embeds the absolute path of cmake used -during the build of qtbase, bloating the runtime closure of qtbase. ---- - bin/qt-cmake.in | 7 +------ - 1 file changed, 1 insertion(+), 6 deletions(-) - -diff --git a/bin/qt-cmake.in b/bin/qt-cmake.in -index f719257f602..571ffe788fa 100755 ---- a/bin/qt-cmake.in -+++ b/bin/qt-cmake.in -@@ -4,12 +4,7 @@ - script_dir_path=`dirname $0` - script_dir_path=`(cd "$script_dir_path"; /bin/pwd)` - --# Try to use original cmake, otherwise to make it relocatable, use any cmake found in PATH. --original_cmake_path="@CMAKE_COMMAND@" --cmake_path=$original_cmake_path --if ! test -f "$cmake_path"; then -- cmake_path="cmake" --fi -+cmake_path="cmake" - - toolchain_path="$script_dir_path/@__GlobalConfig_relative_path_from_bin_dir_to_cmake_config_dir@/qt.toolchain.cmake" - --- -2.42.0 - diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0007-qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0006-qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch index 7bf2193bc208..de4c12ef0448 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0007-qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0006-qtbase-pass-to-qmlimportscanner-the-QML2_IMPORT_PATH.patch @@ -1,17 +1,17 @@ -From d7a9a3b0ecdbb1b5829f25954d763d767f1c8794 Mon Sep 17 00:00:00 2001 +From 0000000000000000000000000000000000000000 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 +Subject: [PATCH] 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 +index b7ee93f6fc1..57b68627eba 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 +@@ -1300,6 +1300,13 @@ bool deployQmlImports(const QString &appBundlePath, DeploymentInfo deploymentInf argumentList.append( "-importPath"); argumentList.append(qmlImportsPath); @@ -25,6 +25,3 @@ index 2ae4f998944..ba10ae02bcd 100644 // run qmlimportscanner QProcess qmlImportScanner; qmlImportScanner.start(qmlImportScannerPath, argumentList); --- -2.42.0 - diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0008-qtbase-allow-translations-outside-prefix.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0007-qtbase-allow-translations-outside-prefix.patch index 07f1973d7607..d8061f1610e9 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0008-qtbase-allow-translations-outside-prefix.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0007-qtbase-allow-translations-outside-prefix.patch @@ -1,14 +1,14 @@ -From 79da6bb6ff075e8cf972be8a462630f1ec86bf0a Mon Sep 17 00:00:00 2001 +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Nick Cao <nickcao@nichi.co> Date: Tue, 10 Oct 2023 10:14:40 -0400 -Subject: [PATCH 08/11] qtbase: allow translations outside prefix +Subject: [PATCH] qtbase: allow translations outside prefix --- - cmake/QtBuild.cmake | 2 +- + cmake/QtBuildPathsHelpers.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmake/QtBuildPathsHelpers.cmake b/cmake/QtBuildPathsHelpers.cmake -index edc43f2f14..78fa219515 100644 +index 18082ac6a5f..e16aea7d7c6 100644 --- a/cmake/QtBuildPathsHelpers.cmake +++ b/cmake/QtBuildPathsHelpers.cmake @@ -134,7 +134,7 @@ function(qt_configure_process_path name default docstring) diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0009-qtbase-find-qmlimportscanner-in-macdeployqt-via-envi.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0008-qtbase-find-qmlimportscanner-in-macdeployqt-via-envi.patch index fb17a539f053..597dd7e6550d 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0009-qtbase-find-qmlimportscanner-in-macdeployqt-via-envi.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0008-qtbase-find-qmlimportscanner-in-macdeployqt-via-envi.patch @@ -1,8 +1,7 @@ -From d503be89320f0b89b80acb19769971e855be6ae1 Mon Sep 17 00:00:00 2001 +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Pedro=20Bol=C3=ADvar=20Puente?= <raskolnikov@gnu.org> Date: Wed, 9 Aug 2023 16:16:21 +0200 -Subject: [PATCH 09/11] qtbase: find qmlimportscanner in macdeployqt via - environment +Subject: [PATCH] qtbase: find qmlimportscanner in macdeployqt via environment The qmlimportscanner tool is provided by qtdeclarative. Because of the modularized installation in Nix, it can not be found via the usual @@ -17,10 +16,10 @@ a workaround for users. 1 file changed, 4 insertions(+) diff --git a/src/tools/macdeployqt/shared/shared.cpp b/src/tools/macdeployqt/shared/shared.cpp -index ba10ae02bcd..320095a972d 100644 +index 57b68627eba..2b972a76c49 100644 --- a/src/tools/macdeployqt/shared/shared.cpp +++ b/src/tools/macdeployqt/shared/shared.cpp -@@ -1277,6 +1277,10 @@ bool deployQmlImports(const QString &appBundlePath, DeploymentInfo deploymentInf +@@ -1280,6 +1280,10 @@ bool deployQmlImports(const QString &appBundlePath, DeploymentInfo deploymentInf if (!QFile::exists(qmlImportScannerPath)) qmlImportScannerPath = QCoreApplication::applicationDirPath() + "/qmlimportscanner"; @@ -31,6 +30,3 @@ index ba10ae02bcd..320095a972d 100644 // Verify that we found a qmlimportscanner binary if (!QFile::exists(qmlImportScannerPath)) { LogError() << "qmlimportscanner not found at" << qmlImportScannerPath; --- -2.42.0 - diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/0010-qtbase-check-in-the-QML-folder-of-this-library-does-.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0009-qtbase-check-in-the-QML-folder-of-this-library-does-.patch index ed749cb238a5..890c68a97f77 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0010-qtbase-check-in-the-QML-folder-of-this-library-does-.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0009-qtbase-check-in-the-QML-folder-of-this-library-does-.patch @@ -1,8 +1,8 @@ -From c00e310092d9aeb48adf21dd22f1ee4dbdbf5ebb Mon Sep 17 00:00:00 2001 +From 0000000000000000000000000000000000000000 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 +Subject: [PATCH] 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 @@ -12,10 +12,10 @@ code, and `qmlimportscanner` will complain that it does not exist. 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 +index 2b972a76c49..96c61b3824a 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 +@@ -1300,9 +1300,12 @@ bool deployQmlImports(const QString &appBundlePath, DeploymentInfo deploymentInf } for (const QString &importPath : qmlImportPaths) argumentList << "-importPath" << importPath; @@ -30,6 +30,3 @@ index 320095a972d..87ba0d4e24b 100644 // 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/nixpkgs/pkgs/development/libraries/qt-6/patches/0011-qtbase-derive-plugin-load-path-from-PATH.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/0010-qtbase-derive-plugin-load-path-from-PATH.patch index cae39e879120..b950b7d4ac79 100644 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/0011-qtbase-derive-plugin-load-path-from-PATH.patch +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/0010-qtbase-derive-plugin-load-path-from-PATH.patch @@ -1,17 +1,17 @@ -From 6f0e6fe1e13ca5844a93d3b97111b7ece7e60f0f Mon Sep 17 00:00:00 2001 +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Milan=20P=C3=A4ssler?= <me@pbb.lc> Date: Sun, 10 May 2020 12:47:28 +0200 -Subject: [PATCH 11/11] qtbase: derive plugin load path from PATH +Subject: [PATCH] qtbase: derive plugin load path from PATH --- src/corelib/kernel/qcoreapplication.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/corelib/kernel/qcoreapplication.cpp b/src/corelib/kernel/qcoreapplication.cpp -index a80efbb5622..0d41dabeed3 100644 +index 1ce2642cf2d..48fd91a0d7f 100644 --- a/src/corelib/kernel/qcoreapplication.cpp +++ b/src/corelib/kernel/qcoreapplication.cpp -@@ -3032,6 +3032,15 @@ QStringList QCoreApplication::libraryPathsLocked() +@@ -3038,6 +3038,15 @@ QStringList QCoreApplication::libraryPathsLocked() app_libpaths->append(installPathPlugins); } @@ -27,6 +27,3 @@ index a80efbb5622..0d41dabeed3 100644 // If QCoreApplication is not yet instantiated, // make sure we add the application path when we construct the QCoreApplication if (self) self->d_func()->appendApplicationPathToLibraryPaths(); --- -2.43.1 - diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/fix-qtgui-include-incorrect-case.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/fix-qtgui-include-incorrect-case.patch new file mode 100644 index 000000000000..563906fb3157 --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/fix-qtgui-include-incorrect-case.patch @@ -0,0 +1,13 @@ +diff --git a/src/plugins/multimedia/ffmpeg/qffmpegscreencapture_dxgi.cpp b/src/plugins/multimedia/ffmpeg/qffmpegscreencapture_dxgi.cpp +index affa52d..b71b461 100644 +--- a/src/plugins/multimedia/ffmpeg/qffmpegscreencapture_dxgi.cpp ++++ b/src/plugins/multimedia/ffmpeg/qffmpegscreencapture_dxgi.cpp +@@ -7,7 +7,7 @@ + #include <private/qabstractvideobuffer_p.h> + #include <private/qmultimediautils_p.h> + #include <private/qwindowsmultimediautils_p.h> +-#include <qtgui/qscreen_platform.h> ++#include <QtGui/qscreen_platform.h> + #include "qvideoframe.h" + + #include <qloggingcategory.h> diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/qtmultimedia-windows-no-uppercase-libs.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/qtmultimedia-windows-no-uppercase-libs.patch new file mode 100644 index 000000000000..05f009bacdad --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/qtmultimedia-windows-no-uppercase-libs.patch @@ -0,0 +1,13 @@ +diff --git a/src/plugins/multimedia/ffmpeg/qffmpegscreencapture_dxgi.cpp b/src/plugins/multimedia/ffmpeg/qffmpegscreencapture_dxgi.cpp +index c0fbb53..3c82085 100644 +--- a/src/plugins/multimedia/ffmpeg/qffmpegscreencapture_dxgi.cpp ++++ b/src/plugins/multimedia/ffmpeg/qffmpegscreencapture_dxgi.cpp +@@ -14,7 +14,7 @@ + #include <qwaitcondition.h> + #include <qmutex.h> + +-#include "D3d11.h" ++#include "d3d11.h" + #include "dxgi1_2.h" + + #include <system_error> diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/qtmultimedia-windows-resolve-function-name.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/qtmultimedia-windows-resolve-function-name.patch new file mode 100644 index 000000000000..681e36e0c513 --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/qt-6/patches/qtmultimedia-windows-resolve-function-name.patch @@ -0,0 +1,30 @@ +diff --git a/src/plugins/multimedia/ffmpeg/qwincapturablewindows.cpp b/src/plugins/multimedia/ffmpeg/qwincapturablewindows.cpp +index aac77ae..71ffed6 100644 +--- a/src/plugins/multimedia/ffmpeg/qwincapturablewindows.cpp ++++ b/src/plugins/multimedia/ffmpeg/qwincapturablewindows.cpp +@@ -42,11 +42,7 @@ static QString windowTitle(HWND hwnd) { + return QString::fromStdWString(buffer); + } + +-QList<QCapturableWindow> QWinCapturableWindows::windows() const +-{ +- QList<QCapturableWindow> result; +- +- auto windowHandler = [](HWND hwnd, LPARAM lParam) { ++static int __stdcall windowHandler(HWND hwnd, LPARAM lParam) { + if (!canCaptureWindow(hwnd)) + return TRUE; // Ignore window and continue enumerating + +@@ -58,7 +54,11 @@ QList<QCapturableWindow> QWinCapturableWindows::windows() const + windows.push_back(windowData.release()->create()); + + return TRUE; +- }; ++} ++ ++QList<QCapturableWindow> QWinCapturableWindows::windows() const ++{ ++ QList<QCapturableWindow> result; + + ::EnumWindows(windowHandler, reinterpret_cast<LPARAM>(&result)); + diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/qtwebengine-darwin-no-copy-certificate-chain.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/qtwebengine-darwin-no-copy-certificate-chain.patch deleted file mode 100644 index c7e461945c04..000000000000 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/qtwebengine-darwin-no-copy-certificate-chain.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff --git a/src/3rdparty/chromium/net/cert/x509_util_apple.cc b/src/3rdparty/chromium/net/cert/x509_util_apple.cc -index ae69948dfca..7062a9a9b97 100644 ---- a/src/3rdparty/chromium/net/cert/x509_util_apple.cc -+++ b/src/3rdparty/chromium/net/cert/x509_util_apple.cc -@@ -139,11 +139,6 @@ SHA256HashValue CalculateFingerprint256(SecCertificateRef cert) { - - base::ScopedCFTypeRef<CFArrayRef> CertificateChainFromSecTrust( - SecTrustRef trust) { -- if (__builtin_available(macOS 12.0, iOS 15.0, *)) { -- return base::ScopedCFTypeRef<CFArrayRef>( -- SecTrustCopyCertificateChain(trust)); -- } -- - base::ScopedCFTypeRef<CFMutableArrayRef> chain( - CFArrayCreateMutable(kCFAllocatorDefault, 0, &kCFTypeArrayCallBacks)); - const CFIndex chain_length = SecTrustGetCertificateCount(trust); diff --git a/nixpkgs/pkgs/development/libraries/qt-6/patches/qtwebengine-darwin-no-low-latency-flag.patch b/nixpkgs/pkgs/development/libraries/qt-6/patches/qtwebengine-darwin-no-low-latency-flag.patch deleted file mode 100644 index 3df917edf5cc..000000000000 --- a/nixpkgs/pkgs/development/libraries/qt-6/patches/qtwebengine-darwin-no-low-latency-flag.patch +++ /dev/null @@ -1,61 +0,0 @@ -diff --git a/src/3rdparty/chromium/media/gpu/mac/vt_video_encode_accelerator_mac.cc b/src/3rdparty/chromium/media/gpu/mac/vt_video_encode_accelerator_mac.cc -index d4b0161b2e..e5a0eb1967 100644 ---- a/src/3rdparty/chromium/media/gpu/mac/vt_video_encode_accelerator_mac.cc -+++ b/src/3rdparty/chromium/media/gpu/mac/vt_video_encode_accelerator_mac.cc -@@ -29,12 +29,6 @@ - #include "media/base/video_types.h" - #include "media/video/video_encode_accelerator.h" - --// This is a min version of macOS where we want to support SVC encoding via --// EnableLowLatencyRateControl flag. The flag is actually supported since 11.3, --// but there we see frame drops even with ample bitrate budget. Excessive frame --// drops were fixed in 12.0.1. --#define LOW_LATENCY_FLAG_AVAILABLE_VER 12.0.1 -- - namespace media { - - namespace { -@@ -277,8 +271,6 @@ VTVideoEncodeAccelerator::GetSupportedH264Profiles() { - profile.rate_control_modes = VideoEncodeAccelerator::kConstantMode | - VideoEncodeAccelerator::kVariableMode; - profile.scalability_modes.push_back(SVCScalabilityMode::kL1T1); -- if (__builtin_available(macOS LOW_LATENCY_FLAG_AVAILABLE_VER, *)) -- profile.scalability_modes.push_back(SVCScalabilityMode::kL1T2); - - for (const auto& supported_profile : kSupportedProfiles) { - if (VideoCodecProfileToVideoCodec(supported_profile) == VideoCodec::kH264) { -@@ -814,14 +806,6 @@ bool VTVideoEncodeAccelerator::CreateCompressionSession( - encoder_values.push_back(kCFBooleanFalse); - } - -- if (__builtin_available(macOS LOW_LATENCY_FLAG_AVAILABLE_VER, *)) { -- // Remove the validation once HEVC SVC mode is supported on macOS. -- if (require_low_delay_ && codec == VideoCodec::kH264) { -- encoder_keys.push_back( -- kVTVideoEncoderSpecification_EnableLowLatencyRateControl); -- encoder_values.push_back(kCFBooleanTrue); -- } -- } - base::ScopedCFTypeRef<CFDictionaryRef> encoder_spec = - video_toolbox::DictionaryWithKeysAndValues( - encoder_keys.data(), encoder_values.data(), encoder_keys.size()); -@@ -891,19 +875,8 @@ bool VTVideoEncodeAccelerator::ConfigureCompressionSession(VideoCodec codec) { - - // Remove the validation once HEVC SVC mode is supported on macOS. - if (num_temporal_layers_ == 2 && codec_ == VideoCodec::kH264) { -- if (__builtin_available(macOS LOW_LATENCY_FLAG_AVAILABLE_VER, *)) { -- if (!session_property_setter.IsSupported( -- kVTCompressionPropertyKey_BaseLayerFrameRateFraction)) { -- DLOG(ERROR) << "BaseLayerFrameRateFraction is not supported"; -- return false; -- } -- rv &= session_property_setter.Set( -- kVTCompressionPropertyKey_BaseLayerFrameRateFraction, 0.5); -- DLOG_IF(ERROR, !rv) << " Setting BaseLayerFrameRate property failed."; -- } else { - DLOG(ERROR) << "SVC encoding is not supported on this OS version."; - rv = false; -- } - } - - return rv; |