nixpkgs/pkgs/development/libraries/qt-6/patches/0005-qtbase-qt-cmake-always-use-cmake-from-path.patch
2023-11-27 10:37:13 -05:00

33 lines
1.0 KiB
Diff

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