Package: guix-patches;
Reported by: John Kehayias <john.kehayias <at> protonmail.com>
Date: Fri, 6 Sep 2024 15:02:01 UTC
Severity: normal
Tags: patch
Done: John Kehayias <john.kehayias <at> protonmail.com>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 73071 in the body.
You can then email your comments to 73071 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
View this report as an mbox folder, status mbox, maintainer mbox
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 06 Sep 2024 15:02:02 GMT) Full text and rfc822 format available.John Kehayias <john.kehayias <at> protonmail.com>
:guix-patches <at> gnu.org
.
(Fri, 06 Sep 2024 15:02:02 GMT) Full text and rfc822 format available.Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: guix-patches <at> gnu.org Cc: John Kehayias <john.kehayias <at> protonmail.com>, aurtzy <at> gmail.com, efraim <at> flashner.co.il Subject: [PATCH mesa-updates 0/8] Various updates for mesa to 24.2.2 Date: Fri, 06 Sep 2024 15:00:53 +0000
Hello Guix, This is a series of patches to update mesa to the latest, 24.2.2, some dependencies, and fix a vulkan issue <https://issues.guix.gnu.org/71109>. Along the way I updated llvm-for-mesa and mesa inputs, which unifies the changes made to build on aarch64-linux, for instance. Hopefully this doesn't introduce regressions. To that end, I've pushed this series now to the mesa-updates branch to see how building on Cuirass goes. (A previous version was there already, but I have updated/rebased and now finally sending this.) Some notes: 1. The closure size of mesa has increased, something like from 374 MiB to 542 MiB, mostly due to itself (not sure why) and then also from llvm. This is from going from v15 to v18 and as you'll see in a patch I had to enable building all targets. Possibly this can be alleviated by building a smaller clang for mesa? 2. Previous discussion was about getting NVK (which requires rust) built in the last mesa update. I'm not sure the current status but will check with those that were working on it before <https://issues.guix.gnu.org/69637>. I believe it is no longer experimental, so we should try to include it. Hopefully the patch changes and brief comments explain all, but please do provide any feedback, changes, fixes, etc. The branch has just been rebased on master but we can rebase as needed or if there are some critical errors on these patches I missed. Thanks! John PS: I guess python-team will get this series as I added two comments (no code changes) to python packages now needed for mesa. One already has a huge number of dependents anyway, but good to note I suppose. John Kehayias (6): gnu: libdrm: Update to 2.4.123. gnu: wayland-protocols: Update to 1.37. gnu: Remove wayland-protocols-next. gnu: llvm-for-mesa: Update to llvm-18. gnu: llvm-for-mesa: Build all targets. gnu: mesa: Update to 24.2.2. nathan (2): gnu: vulkan-headers: Hard-code libvulkan.so file name. gnu: volk: Hard-code path of vulkan-loader for dynamic loading gnu/packages/freedesktop.scm | 17 ++----------- gnu/packages/gl.scm | 49 ++++++++++++++---------------------- gnu/packages/kde-plasma.scm | 2 +- gnu/packages/llvm.scm | 29 ++++++++++----------- gnu/packages/python-xyz.scm | 2 ++ gnu/packages/vulkan.scm | 41 ++++++++++++++++++++++++++---- gnu/packages/xdisorg.scm | 4 +-- 7 files changed, 75 insertions(+), 69 deletions(-) base-commit: d4fbd1ab341de85c1e5c77e0f7adc5aae056be15 -- 2.45.2
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 06 Sep 2024 15:06:02 GMT) Full text and rfc822 format available.Message #8 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: 73071 <at> debbugs.gnu.org Cc: John Kehayias <john.kehayias <at> protonmail.com>, aurtzy <at> gmail.com, efraim <at> flashner.co.il Subject: [PATCH mesa-updates 1/8] gnu: libdrm: Update to 2.4.123. Date: Fri, 06 Sep 2024 15:05:41 +0000
* gnu/packages/xdisorg.scm (libdrm): Update to 2.4.123. Change-Id: I28ace4f3f121a7177cfc78de8e50364753114e8c --- gnu/packages/xdisorg.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm index c041ab1fc0..f78d06b32f 100644 --- a/gnu/packages/xdisorg.scm +++ b/gnu/packages/xdisorg.scm @@ -791,7 +791,7 @@ (define-public pixman (define-public libdrm (package (name "libdrm") - (version "2.4.120") + (version "2.4.123") (source (origin (method url-fetch) (uri (string-append @@ -799,7 +799,7 @@ (define-public libdrm version ".tar.xz")) (sha256 (base32 - "0yijzgg6rdsa68bz03sw0lcfa2nclv9m3as1cja50wkcyxim7x9v")))) + "17mpmp59icp8vaa47dz9gdpdh583kigq47p9a07lp9s9l5kqbfd2")))) (build-system meson-build-system) (arguments (list #:configure-flags -- 2.45.2
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 06 Sep 2024 15:08:02 GMT) Full text and rfc822 format available.Message #11 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: 73071 <at> debbugs.gnu.org Cc: John Kehayias <john.kehayias <at> protonmail.com>, aurtzy <at> gmail.com, efraim <at> flashner.co.il Subject: [PATCH mesa-updates 3/8] gnu: Remove wayland-protocols-next. Date: Fri, 06 Sep 2024 15:07:00 +0000
The default wayland-protocols has been updated to the latest version. * gnu/packages/freedesktop.scm (wayland-protocols-next): Delete variable. * gnu/packages/kde-plasma.scm (kwin)[native-inputs]: Remove wayland-protocols-next; add wayland-protocols. Change-Id: I7620db01317c08ae6bce029dff4d482a7f868f5f --- gnu/packages/freedesktop.scm | 13 ------------- gnu/packages/kde-plasma.scm | 2 +- 2 files changed, 1 insertion(+), 14 deletions(-) diff --git a/gnu/packages/freedesktop.scm b/gnu/packages/freedesktop.scm index de83ed95d6..d5b31bf837 100644 --- a/gnu/packages/freedesktop.scm +++ b/gnu/packages/freedesktop.scm @@ -1395,19 +1395,6 @@ (define-public wayland-protocols . "https://wayland.freedesktop.org/releases.html"))) (license license:expat))) -(define-public wayland-protocols-next - (package (inherit wayland-protocols) - (name "wayland-protocols-next") - (version "1.36") - (source (origin - (method url-fetch) - (uri (string-append "https://gitlab.freedesktop.org/wayland/" - "wayland-protocols/-/releases/" version "/downloads/" - "wayland-protocols-" version ".tar.xz")) - (sha256 - (base32 - "14kyxywpfkgpjpkrybs28q1s2prnz30k1b4zap5a3ybrbvh4vzbi")))))) - (define-public wayland-utils (package (name "wayland-utils") diff --git a/gnu/packages/kde-plasma.scm b/gnu/packages/kde-plasma.scm index 5e9b9688d1..7a35209da8 100644 --- a/gnu/packages/kde-plasma.scm +++ b/gnu/packages/kde-plasma.scm @@ -1451,7 +1451,7 @@ (define-public kwin mesa-utils pkg-config qttools - wayland-protocols-next + wayland-protocols xorg-server-for-tests python-minimal ;; for QtWaylandScanner -- 2.45.2
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 06 Sep 2024 15:08:02 GMT) Full text and rfc822 format available.Message #14 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: 73071 <at> debbugs.gnu.org Cc: John Kehayias <john.kehayias <at> protonmail.com>, Ludovic Courtès <ludo <at> gnu.org>, nathan <nathan_mail <at> nborghese.com>, aurtzy <at> gmail.com, efraim <at> flashner.co.il Subject: [PATCH mesa-updates 4/8] gnu: vulkan-headers: Hard-code libvulkan.so file name. Date: Fri, 06 Sep 2024 15:07:13 +0000
From: nathan <nathan_mail <at> nborghese.com> * gnu/packages/vulkan.scm (vulkan-headers): Rename to… (vulkan-headers/no-loader): … this. (vulkan-headers): New variable. (vulkan-loader): Depend on ‘vulkan-headers/no-loader’. Change-Id: Ic674a4d965d8049e388d75137111ed0253ca3b18 Co-authored-by: Ludovic Courtès <ludo <at> gnu.org> Signed-off-by: John Kehayias <john.kehayias <at> protonmail.com> --- gnu/packages/vulkan.scm | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/gnu/packages/vulkan.scm b/gnu/packages/vulkan.scm index 1b69da1a4d..e76455a835 100644 --- a/gnu/packages/vulkan.scm +++ b/gnu/packages/vulkan.scm @@ -299,7 +299,8 @@ (define-public vkbasalt (license (list license:bsd-3 ; src/reshade/LICENSE.md license:zlib)))) ; LICENSE -(define-public vulkan-headers +;; vulkan-headers, but without the path to vulkan-loader patched in. +(define-public vulkan-headers/no-loader (package (name "vulkan-headers") (version "1.3.280.0") @@ -316,6 +317,7 @@ (define-public vulkan-headers (build-system cmake-build-system) (arguments `(#:tests? #f)) ; No tests. + (properties '((hidden? . #t))) (home-page "https://github.com/KhronosGroup/Vulkan-Headers") (synopsis "Vulkan Header files and API registry") @@ -323,6 +325,25 @@ (define-public vulkan-headers "Vulkan-Headers contains header files and API registry for Vulkan.") (license (list license:asl2.0)))) ;LICENSE.txt +(define-public vulkan-headers + (package + (inherit vulkan-headers/no-loader) + (arguments + (substitute-keyword-arguments (package-arguments vulkan-headers/no-loader) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (add-after 'unpack 'patch-libvulkan-file-name + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "include/vulkan/vulkan.hpp" + (("dlopen\\( \"libvulkan.so") + (string-append "dlopen(\"" + (search-input-file + inputs "/lib/libvulkan.so")))))))))) + (inputs + (modify-inputs (package-inputs vulkan-headers/no-loader) + (prepend vulkan-loader))) + (properties '()))) + (define-public vulkan-loader (package (name "vulkan-loader") @@ -383,7 +404,7 @@ (define-public vulkan-loader python wayland)) (inputs - (list vulkan-headers libxrandr)) + (list vulkan-headers/no-loader libxrandr)) (native-search-paths (list (search-path-specification (variable "XDG_DATA_DIRS") -- 2.45.2
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 06 Sep 2024 15:08:02 GMT) Full text and rfc822 format available.Message #17 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: 73071 <at> debbugs.gnu.org Cc: John Kehayias <john.kehayias <at> protonmail.com>, Ludovic Courtès <ludo <at> gnu.org>, nathan <nathan_mail <at> nborghese.com>, aurtzy <at> gmail.com, efraim <at> flashner.co.il Subject: [PATCH mesa-updates 5/8] gnu: volk: Hard-code path of vulkan-loader for dynamic loading Date: Fri, 06 Sep 2024 15:07:31 +0000
From: nathan <nathan_mail <at> nborghese.com> Until now, we’d get: $ guix shell vulkan-tools -- vulkaninfo ERROR at /tmp/guix-build-vulkan-tools-1.3.280.0.drv-0/source/vulkaninfo/./vulkaninfo.h:412: Failed to initialize: Vulkan loader is not installed, not found, or failed to load. This patch fixes it and potentially for other programs as well. * gnu/packages/vulkan.scm (volk)[arguments]: use gexp. <#:phases>: Patch dlopen with libvulkan.so. [input]: Add vulkan-loader. Change-Id: I5ef0eb13d35e517b8947faddace641882a775b80 Co-authored-by: Ludovic Courtès <ludo <at> gnu.org> Signed-off-by: John Kehayias <john.kehayias <at> protonmail.com> --- gnu/packages/vulkan.scm | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/gnu/packages/vulkan.scm b/gnu/packages/vulkan.scm index e76455a835..dd5b51c7fe 100644 --- a/gnu/packages/vulkan.scm +++ b/gnu/packages/vulkan.scm @@ -654,9 +654,19 @@ (define-public volk "0x4jhc8n9c4k8svmmcaxxs613xbsav7wam94gacddlm738cwp13v")))) (build-system cmake-build-system) (arguments - '(#:tests? #f ;no test - #:configure-flags '("-DVOLK_INSTALL=ON" "-DVOLK_PULL_IN_VULKAN=ON"))) - (inputs (list vulkan-headers)) + (list + #:tests? #f ;no test + #:configure-flags #~(list "-DVOLK_INSTALL=ON" "-DVOLK_PULL_IN_VULKAN=ON") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-loader-path + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "volk.c" + (("dlopen\\(\"libvulkan.so") + (string-append "dlopen(\"" + (search-input-file + inputs "/lib/libvulkan.so"))))))))) + (inputs (list vulkan-headers vulkan-loader)) (synopsis "Meta loader for Vulkan API") (description "Volk is a meta-loader for Vulkan. It allows you to dynamically load -- 2.45.2
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 06 Sep 2024 15:08:03 GMT) Full text and rfc822 format available.Message #20 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: 73071 <at> debbugs.gnu.org Cc: John Kehayias <john.kehayias <at> protonmail.com>, aurtzy <at> gmail.com, efraim <at> flashner.co.il Subject: [PATCH mesa-updates 6/8] gnu: llvm-for-mesa: Update to llvm-18. Date: Fri, 06 Sep 2024 15:07:41 +0000
* gnu/packages/llvm.scm (llvm-for-mesa): Update to llvm-18. * gnu/packages/gl.scm (mesa)[inputs]: Always use llvm-for-mesa (remove llvm-18 for aarch64 to use llvm-for-mesa). (mesa-opencl)[native-inputs]: Remove clang-15. Add clang-18. Change-Id: I767d40d62a827864d3d109c44f82a43302875eb8 --- gnu/packages/gl.scm | 8 ++++---- gnu/packages/llvm.scm | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm index 849ca076dc..ab53b1761a 100644 --- a/gnu/packages/gl.scm +++ b/gnu/packages/gl.scm @@ -323,15 +323,15 @@ (define-public mesa (inputs (append (if (target-aarch64?) - (list clang-18 - llvm-18) - (list llvm-for-mesa)) + (list clang-18) + '()) (list elfutils ;libelf required for r600 when using llvm expat (force libva-without-mesa) libxml2 libxrandr libxvmc + llvm-for-mesa vulkan-loader wayland wayland-protocols @@ -602,7 +602,7 @@ (define-public mesa-opencl (if (target-aarch64?) (package-native-inputs mesa) (modify-inputs (package-native-inputs mesa) - (prepend clang-15)))))) + (prepend clang-18)))))) (define-public mesa-opencl-icd (package/inherit mesa-opencl diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm index fd2e815fe0..7fcb15891d 100644 --- a/gnu/packages/llvm.scm +++ b/gnu/packages/llvm.scm @@ -2152,7 +2152,7 @@ (define-public emacs-clang-rename (define-public llvm-for-mesa ;; Note: update the 'clang' input of mesa-opencl when bumping this. - (let ((base-llvm llvm-15)) + (let ((base-llvm llvm-18)) (package (inherit base-llvm) (name "llvm-for-mesa") -- 2.45.2
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 06 Sep 2024 15:09:01 GMT) Full text and rfc822 format available.Message #23 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: 73071 <at> debbugs.gnu.org Cc: John Kehayias <john.kehayias <at> protonmail.com>, aurtzy <at> gmail.com, efraim <at> flashner.co.il Subject: [PATCH mesa-updates 7/8] gnu: llvm-for-mesa: Build all targets. Date: Fri, 06 Sep 2024 15:07:59 +0000
This change is needed for updating mesa to 24.2.1. Otherwise, mesa fails to build. For example, linking intel_clc fails with errors of libclang-cpp.so having undefined references to various LLVM targets. It is possible that just some LLVM targets could be built or a modified version of the clang input for mesa (now required) could be used to try to reduce the closure size as before. * gnu/packages/llvm.scm (llvm-for-mesa)[arguments]: Don't set the LLVM_TARGETS_TO_BUILD configure flag. Also, don't remove it from the inherited configure-flags. Fix indentation. Change-Id: I4a2b7239e6ea77b0d3bce10bdf945691faa84994 --- gnu/packages/llvm.scm | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm index 7fcb15891d..800fe29599 100644 --- a/gnu/packages/llvm.scm +++ b/gnu/packages/llvm.scm @@ -22,7 +22,7 @@ ;;; Copyright © 2021 Lars-Dominik Braun <lars <at> 6xq.net> ;;; Copyright © 2021, 2022 Guillaume Le Vaillant <glv <at> posteo.net> ;;; Copyright © 2022, 2024 Greg Hogan <code <at> greghogan.com> -;;; Copyright © 2022 John Kehayias <john.kehayias <at> protonmail.com> +;;; Copyright © 2022, 2024 John Kehayias <john.kehayias <at> protonmail.com> ;;; Copyright © 2022 Clément Lassieur <clement <at> lassieur.org> ;;; Copyright © 2022 Zhu Zihao <all_but_last <at> 163.com> ;;; Copyright © 2023 Hilton Chain <hako <at> ultrarare.space> @@ -2166,21 +2166,18 @@ (define-public llvm-for-mesa ,@modules)) ((#:configure-flags cf ''()) #~(cons* - ;; AMDGPU is needed by the vulkan drivers. - #$(string-append "-DLLVM_TARGETS_TO_BUILD=" - (system->llvm-target) ";AMDGPU") - #$@(if (%current-target-system) - '("-DBUILD_SHARED_LIBS:BOOL=TRUE" - "-DCMAKE_BUILD_WITH_INSTALL_RPATH=TRUE") + #$@(if (%current-target-system) + '("-DBUILD_SHARED_LIBS:BOOL=TRUE" + "-DCMAKE_BUILD_WITH_INSTALL_RPATH=TRUE") '()) - ;; Skipping tools and utils decreases the output by ~100 MiB. - "-DLLVM_BUILD_TOOLS=NO" - (remove - (cut string-match - #$(if (%current-target-system) - "-DLLVM_(LINK_LLVM_DYLIB|TARGETS_TO_BUILD|INSTALL_UTILS).*" - "-DLLVM_(TARGETS_TO_BUILD|INSTALL_UTILS).*") <>) - #$cf))) + ;; Skipping tools and utils decreases the output by ~100 MiB. + "-DLLVM_BUILD_TOOLS=NO" + (remove + (cut string-match + #$(if (%current-target-system) + "-DLLVM_(LINK_LLVM_DYLIB|INSTALL_UTILS).*" + "-DLLVM_INSTALL_UTILS.*") <>) + #$cf))) ((#:phases phases '%standard-phases) #~(modify-phases #$phases #$@(if (%current-target-system) -- 2.45.2
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 06 Sep 2024 15:09:02 GMT) Full text and rfc822 format available.Message #26 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: 73071 <at> debbugs.gnu.org Cc: John Kehayias <john.kehayias <at> protonmail.com>, aurtzy <at> gmail.com, efraim <at> flashner.co.il Subject: [PATCH mesa-updates 8/8] gnu: mesa: Update to 24.2.2. Date: Fri, 06 Sep 2024 15:08:08 +0000
Note the clang input for mesa was in inputs for aarch64-linux but more generally in native-inputs for mesa-opencl. Moved to native-inputs for all (mesa does not retain a reference to clang). * gnu/packages/gl.scm (mesa): Update to 24.2.2. [inputs]: Move clang-18 when building for aarch64-linux to ... [native-inputs]: ... here for all architectures. Add python-ply, and python-pyyaml. Use libclc for all architectures. (mesa-opencl)[inputs, native-inputs]: Remove fields. * gnu/packages/python-xyz.scm (python-pyyaml, python-ply): Add a comment about being dependencies of mesa. Change-Id: Ie262e6ea5a31fda0e410277256c203ea3caed96b --- gnu/packages/gl.scm | 49 ++++++++++++++----------------------- gnu/packages/python-xyz.scm | 2 ++ 2 files changed, 21 insertions(+), 30 deletions(-) diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm index ab53b1761a..ab18a3e5a7 100644 --- a/gnu/packages/gl.scm +++ b/gnu/packages/gl.scm @@ -15,7 +15,7 @@ ;;; Copyright © 2020, 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer <at> gmail.com> ;;; Copyright © 2020 Kei Kebreau <kkebreau <at> posteo.net> ;;; Copyright © 2021 Ivan Gankevich <i.gankevich <at> spbu.ru> -;;; Copyright © 2021, 2022, 2023 John Kehayias <john.kehayias <at> protonmail.com> +;;; Copyright © 2021-2024 John Kehayias <john.kehayias <at> protonmail.com> ;;; Copyright © 2022 Petr Hodina <phodina <at> protonmail.com> ;;; Copyright © 2023 Kaelyn Takata <kaelyn.alexi <at> protonmail.com> ;;; Copyright © 2023, 2024 Zheng Junjie <873216071 <at> qq.com> @@ -298,7 +298,7 @@ (define libva-without-mesa (define-public mesa (package (name "mesa") - (version "24.0.4") + (version "24.2.2") (source (origin (method url-fetch) @@ -308,7 +308,7 @@ (define-public mesa "mesa-" version ".tar.xz"))) (sha256 (base32 - "1w25lwdrb0ffrx2fjk9izbvpcgf9ypfc7v32zybwvjwql0qbvzlh")))) + "00hxi7wjp368kh5qq2v25nyzjrf0grsx55w55fg4bgpd0hqps1zx")))) (build-system meson-build-system) (propagated-inputs ;; The following are in the Requires.private field of gl.pc. @@ -321,35 +321,32 @@ (define-public mesa libxxf86vm xorgproto)) (inputs - (append - (if (target-aarch64?) - (list clang-18) - '()) - (list elfutils ;libelf required for r600 when using llvm - expat - (force libva-without-mesa) - libxml2 - libxrandr - libxvmc - llvm-for-mesa - vulkan-loader - wayland - wayland-protocols - `(,zstd "lib")))) + (list elfutils ;libelf required for r600 when using llvm + expat + (force libva-without-mesa) + libxml2 + libxrandr + libxvmc + llvm-for-mesa + vulkan-loader + wayland + wayland-protocols + `(,zstd "lib"))) (native-inputs (append (list bison + clang-18 flex gettext-minimal glslang + libclc pkg-config python-libxml2 ;for OpenGL ES 1.1 and 2.0 support python-mako + python-ply + python-pyyaml python-wrapper (@ (gnu packages base) which)) - (if (target-aarch64?) - (list libclc) - '()) (if (%current-target-system) (list cmake-minimal-cross pkg-config-for-build @@ -594,15 +591,7 @@ (define-public mesa-opencl (arguments (substitute-keyword-arguments (package-arguments mesa) ((#:configure-flags flags) - #~(cons "-Dgallium-opencl=standalone" #$flags)))) - (inputs - (modify-inputs (package-inputs mesa) - (prepend libclc))) - (native-inputs - (if (target-aarch64?) - (package-native-inputs mesa) - (modify-inputs (package-native-inputs mesa) - (prepend clang-18)))))) + #~(cons "-Dgallium-opencl=standalone" #$flags)))))) (define-public mesa-opencl-icd (package/inherit mesa-opencl diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 21e04e75e9..416db71d68 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -6133,6 +6133,7 @@ (define-public python-itsdangerous environments and back.") (license license:bsd-3))) +;; WARNING: This package is a dependency of mesa. (define-public python-pyyaml (package (name "python-pyyaml") @@ -20995,6 +20996,7 @@ (define-public python-pika network support library.") (license license:bsd-3))) +;; WARNING: This package is a dependency of mesa. (define-public python-ply (package (name "python-ply") -- 2.45.2
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 06 Sep 2024 15:14:02 GMT) Full text and rfc822 format available.Message #29 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: 73071 <at> debbugs.gnu.org Cc: John Kehayias <john.kehayias <at> protonmail.com>, aurtzy <at> gmail.com, efraim <at> flashner.co.il Subject: [PATCH mesa-updates 2/8] gnu: wayland-protocols: Update to 1.37. Date: Fri, 06 Sep 2024 15:06:38 +0000
* gnu/packages/freedesktop.scm (wayland-protocols): Update to 1.37. Change-Id: I32837fc9c6609532557c31cf94b0f87e999680d8 --- gnu/packages/freedesktop.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/freedesktop.scm b/gnu/packages/freedesktop.scm index cb1d625d24..de83ed95d6 100644 --- a/gnu/packages/freedesktop.scm +++ b/gnu/packages/freedesktop.scm @@ -1367,7 +1367,7 @@ (define-public wayland (define-public wayland-protocols (package (name "wayland-protocols") - (version "1.32") + (version "1.37") (source (origin (method url-fetch) (uri (string-append "https://gitlab.freedesktop.org/wayland/" @@ -1375,7 +1375,7 @@ (define-public wayland-protocols name "-" version ".tar.xz")) (sha256 (base32 - "04dsn79409mryxs6maq9kfhca97gvl3pr1ggjnv9d0hc6jfpjnbl")))) + "09pk3qhpc29x1a6srpqqw9dcvalg33vfmp14d276is7j4klrn3m7")))) (build-system meson-build-system) (inputs (list wayland)) -- 2.45.2
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Mon, 09 Sep 2024 03:44:01 GMT) Full text and rfc822 format available.Message #32 received at submit <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: guix-patches <at> gnu.org Cc: aurtzy <at> gmail.com, efraim <at> flashner.co.il Subject: Re: [PATCH mesa-updates 0/8] Various updates for mesa to 24.2.2 Date: Mon, 09 Sep 2024 03:43:27 +0000
[Message part 1 (text/plain, inline)]
Just a note that on IRC it was pointed out that we lost the i915 driver in mesa. I adjusted the configure flags to restore some changes that were lost, simplifying the configure-flags a little. That patch is attached and is live on mesa-updates (along with some other changes, but not related directly to this series). On Fri, Sep 06, 2024 at 03:00 PM, John Kehayias wrote: > Hello Guix, > > This is a series of patches to update mesa to the latest, 24.2.2, some > dependencies, and fix a vulkan issue <https://issues.guix.gnu.org/71109>. > Along the way I updated llvm-for-mesa and mesa inputs, which unifies the > changes made to build on aarch64-linux, for instance. Hopefully this doesn't > introduce regressions. To that end, I've pushed this series now to the > mesa-updates branch to see how building on Cuirass goes. (A previous version > was there already, but I have updated/rebased and now finally sending this.) > > Some notes: > > 1. The closure size of mesa has increased, something like from 374 MiB to 542 > MiB, mostly due to itself (not sure why) and then also from llvm. This is > from going from v15 to v18 and as you'll see in a patch I had to enable > building all targets. Possibly this can be alleviated by building a smaller > clang for mesa? > > 2. Previous discussion was about getting NVK (which requires rust) built in > the last mesa update. I'm not sure the current status but will check with > those that were working on it before <https://issues.guix.gnu.org/69637>. I > believe it is no longer experimental, so we should try to include it. > > Hopefully the patch changes and brief comments explain all, but please do > provide any feedback, changes, fixes, etc. The branch has just been rebased > on master but we can rebase as needed or if there are some critical errors on > these patches I missed. > > Thanks! > John > > PS: I guess python-team will get this series as I added two comments (no code > changes) to python packages now needed for mesa. One already has a huge > number of dependents anyway, but good to note I suppose. > > John Kehayias (6): > gnu: libdrm: Update to 2.4.123. > gnu: wayland-protocols: Update to 1.37. > gnu: Remove wayland-protocols-next. > gnu: llvm-for-mesa: Update to llvm-18. > gnu: llvm-for-mesa: Build all targets. > gnu: mesa: Update to 24.2.2. > > nathan (2): > gnu: vulkan-headers: Hard-code libvulkan.so file name. > gnu: volk: Hard-code path of vulkan-loader for dynamic loading > > gnu/packages/freedesktop.scm | 17 ++----------- > gnu/packages/gl.scm | 49 ++++++++++++++---------------------- > gnu/packages/kde-plasma.scm | 2 +- > gnu/packages/llvm.scm | 29 ++++++++++----------- > gnu/packages/python-xyz.scm | 2 ++ > gnu/packages/vulkan.scm | 41 ++++++++++++++++++++++++++---- > gnu/packages/xdisorg.scm | 4 +-- > 7 files changed, 75 insertions(+), 69 deletions(-) > > > base-commit: d4fbd1ab341de85c1e5c77e0f7adc5aae056be15
[0001-gnu-mesa-Update-configure-flags.patch (text/x-patch, attachment)]
john.kehayias <at> protonmail.com, efraim <at> flashner.co.il, guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Mon, 09 Sep 2024 16:17:01 GMT) Full text and rfc822 format available.Message #35 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: aurtzy <aurtzy <at> gmail.com> To: 73071 <at> debbugs.gnu.org Cc: aurtzy <aurtzy <at> gmail.com> Subject: [PATCH mesa-updates] gnu: mesa: Enable NVK driver for x86_64 architecture. Date: Mon, 9 Sep 2024 12:12:11 -0400
* gnu/packages/gl.scm (mesa): Enable NVK vulkan driver for x86_64 architecture. [native-inputs]: Add rust, rust-bindgen-cli, rust-cbindgen-0.26 for x86_64. [arguments]<#:meson>: Use newer version of meson to satisfy NVK build requirements. <#:configure-flags>: Use "auto" for 'vulkan-drivers' flag when target arch is x86_64. <#:phases>: Add phase to patch rust subproject sources when target arch is x86_64. * gnu/packages/crates-io.scm (rust-paste-1, rust-proc-macro2-1, rust-quote-1, rust-syn-2, rust-unicode-ident-1): Add a comment about being dependencies of mesa. Change-Id: I76e3db5072ca3c718155b188ca64b52766d55f36 --- Hi John, Thanks for the CC, and sorry for not submitting a patch sooner! Since last, I have managed to find a better solution to the issue with substituting rust dependency sources. Briefly on what I have so far: this makes use of writing wrap files with just the "directory" property, having meson fall back to using a local directory that sources are copied to. Doing this resulted in an odd behavior with the overlay directories (i.e. important extra files in subprojects/packagefiles) where they don't seem to be automatically copied as expected when falling back to local files; however, a simple copy resolves it, although I thought it would still be good to note and add a comment about. I initially made the wrap-file-writing a build utility procedure 'patch-wrap-file' (which can be seen my personal config [1]) as it seemed like it could be useful for other meson packages, but for this patch I've inlined it since I'm not confident in its applicability across different projects. I'd be happy to hear thoughts about it if it might be useful, though. [1] https://github.com/aurtzy/guix-config/blob/5cf4c9e277f4ab3a8f1ef87ec5ac47a686da0ad2/my-guix/build/utils.scm#L27 Cheers, aurtzy gnu/packages/crates-io.scm | 5 +++ gnu/packages/gl.scm | 64 ++++++++++++++++++++++++++++++++++++-- 2 files changed, 67 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 0cdb071ea0..2a40062500 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -51869,6 +51869,7 @@ (define-public rust-password-hash-0.2 ("rust-subtle" ,rust-subtle-2) ("rust-rand-core" ,rust-rand-core-0.6)))))) +;; WARNING: This package is a dependency of mesa. (define-public rust-paste-1 (package (name "rust-paste") @@ -56703,6 +56704,7 @@ (define-public rust-proc-macro-nested-0.1 "Support for nested proc-macro-hack invocations.") (license (list license:expat license:asl2.0)))) +;; WARNING: This package is a dependency of mesa. (define-public rust-proc-macro2-1 (package (name "rust-proc-macro2") @@ -60144,6 +60146,7 @@ (define-public rust-quinn-udp-0.1 ("rust-tokio" ,rust-tokio-1) ("rust-tracing" ,rust-tracing-0.1)))))) +;; WARNING: This package is a dependency of mesa. (define-public rust-quote-1 (package (name "rust-quote") @@ -76939,6 +76942,7 @@ (define-public rust-symphonia-utils-xiph-0.4 codecs and formats.") (license license:mpl2.0))) +;; WARNING: This package is a dependency of mesa. (define-public rust-syn-2 (package (name "rust-syn") @@ -86599,6 +86603,7 @@ (define-public rust-unicode-id-0.3 according to Unicode Standard Annex #31.") (license (list license:expat license:asl2.0)))) +;; WARNING: This package is a dependency of mesa. (define-public rust-unicode-ident-1 (package (name "rust-unicode-ident") diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm index c417f11571..3939f1ba1f 100644 --- a/gnu/packages/gl.scm +++ b/gnu/packages/gl.scm @@ -21,6 +21,7 @@ ;;; Copyright © 2023, 2024 Zheng Junjie <873216071 <at> qq.com> ;;; Copyright © 2024 Liliana Marie Prikler <liliana.prikler <at> gmail.com> ;;; Copyright © 2024 Artyom V. Poptsov <poptsov.artyom <at> gmail.com> +;;; Copyright © 2024 aurtzy <aurtzy <at> gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -41,6 +42,7 @@ (define-module (gnu packages gl) #:use-module (gnu packages) #:use-module (gnu packages autotools) #:use-module (gnu packages bison) + #:use-module (gnu packages build-tools) #:use-module (gnu packages check) #:use-module (gnu packages compression) #:use-module (gnu packages documentation) @@ -56,6 +58,7 @@ (define-module (gnu packages gl) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) #:use-module (gnu packages python-xyz) + #:use-module (gnu packages rust) #:use-module (gnu packages tls) #:use-module (gnu packages video) #:use-module (gnu packages vulkan) @@ -75,7 +78,8 @@ (define-module (gnu packages gl) #:use-module (guix gexp) #:use-module (guix utils) #:use-module (ice-9 match) - #:use-module ((srfi srfi-1) #:hide (zip))) + #:use-module ((srfi srfi-1) #:hide (zip)) + #:use-module (srfi srfi-26)) (define-public glu (package @@ -352,10 +356,19 @@ (define-public mesa pkg-config-for-build wayland wayland-protocols) + '()) + (if (target-x86-64?) + ;; NVK dependencies + (list rust + (module-ref (resolve-interface '(gnu packages rust-apps)) + 'rust-bindgen-cli) + (module-ref (resolve-interface '(gnu packages rust-apps)) + 'rust-cbindgen-0.26)) '()))) (outputs '("out" "bin")) (arguments (list + #:meson meson-1.5 #:configure-flags #~(list #$@(cond @@ -387,7 +400,7 @@ (define-public mesa "-Dshared-glapi=enabled" #$@(cond - ((or (target-x86-32?) (target-x86-64?)) + ((target-x86-32?) ;; This doesn't include nouveau (which is in "auto") as it needs ;; rust. ;; TODO: Enable nouveau/NVK. @@ -481,6 +494,53 @@ (define-public mesa (("'lp_test_arit', ") "")))) (_ '((display "No tests to disable on this architecture.\n")))))) + #$@(if (target-x86-64?) + #~((add-after 'unpack 'patch-subproject-sources + (lambda _ + ;; Patch each relevant subproject source URL in wrapfiles to + ;; use the store, which avoids an attempt to download them + ;; mid-build. + (for-each + (match-lambda + ((name source) + (let ((wrap-file (string-append + "subprojects/" name ".wrap")) + (subproject-dest (string-append + "subprojects/" name)) + (overlay-dir (string-append + "subprojects/packagefiles/" name))) + (copy-recursively source subproject-dest) + ;; Normally when the patch_directory wrap file property + ;; is specified, meson automatically copies from + ;; packagefiles, but this is not the case here (only + ;; happens when downloading source?) so we manually copy + ;; overlay-dir to subproject-dest. + (when (file-exists? overlay-dir) + (copy-recursively overlay-dir subproject-dest)) + (call-with-output-file wrap-file + (lambda (port) + (format port "[wrap-file] +directory = ~a +" + name)))))) + '#+(map (lambda (pkg) + (let ((name (package-upstream-name* pkg)) + (version (package-version pkg))) + (list (package-upstream-name* pkg) + (file-append pkg + "/share/cargo/src/" + name "-" version)))) + (let ((from-crates-io + (cut module-ref + (resolve-interface + '(gnu packages crates-io)) + <>))) + (list (from-crates-io 'rust-syn-2) + (from-crates-io 'rust-unicode-ident-1) + (from-crates-io 'rust-quote-1) + (from-crates-io 'rust-proc-macro2-1) + (from-crates-io 'rust-paste-1)))))))) + #~()) (add-before 'configure 'fix-dlopen-libnames (lambda* (#:key inputs #:allow-other-keys) (let ((out #$output)) base-commit: c1ca70a98024a1e9dd6fedded1d31ad763b8b282 -- 2.45.2
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Mon, 16 Sep 2024 03:00:03 GMT) Full text and rfc822 format available.Message #38 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: aurtzy <aurtzy <at> gmail.com> Cc: 73071 <at> debbugs.gnu.org, Efraim Flashner <efraim <at> flashner.co.il> Subject: Re: [bug#73071] [PATCH mesa-updates] gnu: mesa: Enable NVK driver for x86_64 architecture. Date: Mon, 16 Sep 2024 02:59:29 +0000
Hi aurtzy! On Mon, Sep 09, 2024 at 12:12 PM, aurtzy wrote: > * gnu/packages/gl.scm (mesa): Enable NVK vulkan driver for x86_64 > architecture. > [native-inputs]: Add rust, rust-bindgen-cli, rust-cbindgen-0.26 for x86_64. > [arguments]<#:meson>: Use newer version of meson to satisfy NVK build > requirements. > <#:configure-flags>: Use "auto" for 'vulkan-drivers' flag when target arch is > x86_64. > <#:phases>: Add phase to patch rust subproject sources when target arch is > x86_64. > * gnu/packages/crates-io.scm (rust-paste-1, rust-proc-macro2-1, rust-quote-1, > rust-syn-2, rust-unicode-ident-1): Add a comment about being dependencies of > mesa. > > Change-Id: I76e3db5072ca3c718155b188ca64b52766d55f36 > --- > > Hi John, > > Thanks for the CC, and sorry for not submitting a patch sooner! > No problem, I let things go for a bit too, thanks for this work! > Since last, I have managed to find a better solution to the issue with > substituting rust dependency sources. Briefly on what I have so far: this > makes use of writing wrap files with just the "directory" property, having > meson fall back to using a local directory that sources are copied to. Doing > this resulted in an odd behavior with the overlay directories (i.e. important > extra files in subprojects/packagefiles) where they don't seem to be > automatically copied as expected when falling back to local files; however, a > simple copy resolves it, although I thought it would still be good to note and > add a comment about. > > I initially made the wrap-file-writing a build utility procedure > 'patch-wrap-file' (which can be seen my personal config [1]) as it seemed like > it could be useful for other meson packages, but for this patch I've inlined > it since I'm not confident in its applicability across different projects. > I'd be happy to hear thoughts about it if it might be useful, though. > > [1] <https://github.com/aurtzy/guix-config/blob/5cf4c9e277f4ab3a8f1ef87ec5ac47a686da0ad2/my-guix/build/utils.scm#L27> > Very nice! Yes, more utilities to help with unbundling essentially will be helpful. I don't know if I ever wrote a wrap file or just patched the directory bit into the meson file directly. I would have to look this over, but a utility function (or via keyword argument in meson-build-system?) would be great. As for the main patch: I've built locally and see nouveau as a vulkan driver on x86_64 but not i686. That's about all I can test though. The change to #:meson means other archs will rebuild too, but I don't know if they got far anyway (so we can cancel old derivations). Perhaps a new mesa point release will be out this week? Then I could bump the version, rebase, and rebuild with this patch. Thoughts? Other than that, I made a minor tweak to the changelog (remove first line, name the phase) locally, but have not done a rebase/push on mesa-updates. Let me give it a few days for other comments and if there are any other rebuilds to go with it. Thanks again! John > Cheers, > > aurtzy > > gnu/packages/crates-io.scm | 5 +++ > gnu/packages/gl.scm | 64 ++++++++++++++++++++++++++++++++++++-- > 2 files changed, 67 insertions(+), 2 deletions(-) > > diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm > index 0cdb071ea0..2a40062500 100644 > --- a/gnu/packages/crates-io.scm > +++ b/gnu/packages/crates-io.scm > @@ -51869,6 +51869,7 @@ (define-public rust-password-hash-0.2 > ("rust-subtle" ,rust-subtle-2) > ("rust-rand-core" ,rust-rand-core-0.6)))))) > > +;; WARNING: This package is a dependency of mesa. > (define-public rust-paste-1 > (package > (name "rust-paste") > @@ -56703,6 +56704,7 @@ (define-public rust-proc-macro-nested-0.1 > "Support for nested proc-macro-hack invocations.") > (license (list license:expat license:asl2.0)))) > > +;; WARNING: This package is a dependency of mesa. > (define-public rust-proc-macro2-1 > (package > (name "rust-proc-macro2") > @@ -60144,6 +60146,7 @@ (define-public rust-quinn-udp-0.1 > ("rust-tokio" ,rust-tokio-1) > ("rust-tracing" ,rust-tracing-0.1)))))) > > +;; WARNING: This package is a dependency of mesa. > (define-public rust-quote-1 > (package > (name "rust-quote") > @@ -76939,6 +76942,7 @@ (define-public rust-symphonia-utils-xiph-0.4 > codecs and formats.") > (license license:mpl2.0))) > > +;; WARNING: This package is a dependency of mesa. > (define-public rust-syn-2 > (package > (name "rust-syn") > @@ -86599,6 +86603,7 @@ (define-public rust-unicode-id-0.3 > according to Unicode Standard Annex #31.") > (license (list license:expat license:asl2.0)))) > > +;; WARNING: This package is a dependency of mesa. > (define-public rust-unicode-ident-1 > (package > (name "rust-unicode-ident") > diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm > index c417f11571..3939f1ba1f 100644 > --- a/gnu/packages/gl.scm > +++ b/gnu/packages/gl.scm > @@ -21,6 +21,7 @@ > ;;; Copyright © 2023, 2024 Zheng Junjie <873216071 <at> qq.com> > ;;; Copyright © 2024 Liliana Marie Prikler <liliana.prikler <at> gmail.com> > ;;; Copyright © 2024 Artyom V. Poptsov <poptsov.artyom <at> gmail.com> > +;;; Copyright © 2024 aurtzy <aurtzy <at> gmail.com> > ;;; > ;;; This file is part of GNU Guix. > ;;; > @@ -41,6 +42,7 @@ (define-module (gnu packages gl) > #:use-module (gnu packages) > #:use-module (gnu packages autotools) > #:use-module (gnu packages bison) > + #:use-module (gnu packages build-tools) > #:use-module (gnu packages check) > #:use-module (gnu packages compression) > #:use-module (gnu packages documentation) > @@ -56,6 +58,7 @@ (define-module (gnu packages gl) > #:use-module (gnu packages pkg-config) > #:use-module (gnu packages python) > #:use-module (gnu packages python-xyz) > + #:use-module (gnu packages rust) > #:use-module (gnu packages tls) > #:use-module (gnu packages video) > #:use-module (gnu packages vulkan) > @@ -75,7 +78,8 @@ (define-module (gnu packages gl) > #:use-module (guix gexp) > #:use-module (guix utils) > #:use-module (ice-9 match) > - #:use-module ((srfi srfi-1) #:hide (zip))) > + #:use-module ((srfi srfi-1) #:hide (zip)) > + #:use-module (srfi srfi-26)) > > (define-public glu > (package > @@ -352,10 +356,19 @@ (define-public mesa > pkg-config-for-build > wayland > wayland-protocols) > + '()) > + (if (target-x86-64?) > + ;; NVK dependencies > + (list rust > + (module-ref (resolve-interface '(gnu packages rust-apps)) > + 'rust-bindgen-cli) > + (module-ref (resolve-interface '(gnu packages rust-apps)) > + 'rust-cbindgen-0.26)) > '()))) > (outputs '("out" "bin")) > (arguments > (list > + #:meson meson-1.5 > #:configure-flags > #~(list > #$@(cond > @@ -387,7 +400,7 @@ (define-public mesa > "-Dshared-glapi=enabled" > > #$@(cond > - ((or (target-x86-32?) (target-x86-64?)) > + ((target-x86-32?) > ;; This doesn't include nouveau (which is in "auto") as it needs > ;; rust. > ;; TODO: Enable nouveau/NVK. > @@ -481,6 +494,53 @@ (define-public mesa > (("'lp_test_arit', ") "")))) > (_ > '((display "No tests to disable on this architecture.\n")))))) > + #$@(if (target-x86-64?) > + #~((add-after 'unpack 'patch-subproject-sources > + (lambda _ > + ;; Patch each relevant subproject source URL in wrapfiles to > + ;; use the store, which avoids an attempt to download them > + ;; mid-build. > + (for-each > + (match-lambda > + ((name source) > + (let ((wrap-file (string-append > + "subprojects/" name ".wrap")) > + (subproject-dest (string-append > + "subprojects/" name)) > + (overlay-dir (string-append > + "subprojects/packagefiles/" name))) > + (copy-recursively source subproject-dest) > + ;; Normally when the patch_directory wrap file property > + ;; is specified, meson automatically copies from > + ;; packagefiles, but this is not the case here (only > + ;; happens when downloading source?) so we manually copy > + ;; overlay-dir to subproject-dest. > + (when (file-exists? overlay-dir) > + (copy-recursively overlay-dir subproject-dest)) > + (call-with-output-file wrap-file > + (lambda (port) > + (format port "[wrap-file] > +directory = ~a > +" > + name)))))) > + '#+(map (lambda (pkg) > + (let ((name (package-upstream-name* pkg)) > + (version (package-version pkg))) > + (list (package-upstream-name* pkg) > + (file-append pkg > + "/share/cargo/src/" > + name "-" version)))) > + (let ((from-crates-io > + (cut module-ref > + (resolve-interface > + '(gnu packages crates-io)) > + <>))) > + (list (from-crates-io 'rust-syn-2) > + (from-crates-io 'rust-unicode-ident-1) > + (from-crates-io 'rust-quote-1) > + (from-crates-io 'rust-proc-macro2-1) > + (from-crates-io 'rust-paste-1)))))))) > + #~()) > (add-before 'configure 'fix-dlopen-libnames > (lambda* (#:key inputs #:allow-other-keys) > (let ((out #$output)) > > base-commit: c1ca70a98024a1e9dd6fedded1d31ad763b8b282
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Tue, 17 Sep 2024 01:52:01 GMT) Full text and rfc822 format available.Message #41 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: aurtzy <aurtzy <at> gmail.com> To: 73071 <at> debbugs.gnu.org Cc: John Kehayias <john.kehayias <at> protonmail.com>, aurtzy <aurtzy <at> gmail.com> Subject: Re: [PATCH mesa-updates 0/8] Various updates for mesa to 24.2.2 Date: Mon, 16 Sep 2024 21:50:08 -0400
[Message part 1 (text/plain, inline)]
Hi, I have an additional question/concern that's come up, but to address your comments first: On 9/15/24 22:59, John Kehayias wrote: >> Since last, I have managed to find a better solution to the issue with >> substituting rust dependency sources. Briefly on what I have so far: this >> makes use of writing wrap files with just the "directory" property, having >> meson fall back to using a local directory that sources are copied to. Doing >> this resulted in an odd behavior with the overlay directories (i.e. important >> extra files in subprojects/packagefiles) where they don't seem to be >> automatically copied as expected when falling back to local files; however, a >> simple copy resolves it, although I thought it would still be good to note and >> add a comment about. >> >> I initially made the wrap-file-writing a build utility procedure >> 'patch-wrap-file' (which can be seen my personal config [1]) as it seemed like >> it could be useful for other meson packages, but for this patch I've inlined >> it since I'm not confident in its applicability across different projects. >> I'd be happy to hear thoughts about it if it might be useful, though. >> >> [1]<https://github.com/aurtzy/guix-config/blob/5cf4c9e277f4ab3a8f1ef87ec5ac47a686da0ad2/my-guix/build/utils.scm#L27> >> > Very nice! Yes, more utilities to help with unbundling essentially > will be helpful. I don't know if I ever wrote a wrap file or just > patched the directory bit into the meson file directly. I would have > to look this over, but a utility function (or via keyword argument in > meson-build-system?) would be great. Okay! I'll have a look at the keyword argument approach as well and see if I can make a proposal for changes and further comments sometime soon. > As for the main patch: I've built locally and see nouveau as a vulkan > driver on x86_64 but not i686. That's about all I can test though. The > change to #:meson means other archs will rebuild too, but I don't know > if they got far anyway (so we can cancel old derivations). Perhaps a > new mesa point release will be out this week? Then I could bump the > version, rebase, and rebuild with this patch. Thoughts? I didn't consider this when writing the patch, but would it be a good idea to only use meson-1.5 for x86_64? We could avoid rebuilds that way. Looks like a new mesa release is planned for the 18th [1]. > Other than that, I made a minor tweak to the changelog (remove first > line, name the phase) locally, but have not done a rebase/push on > mesa-updates. Let me give it a few days for other comments and if > there are any other rebuilds to go with it. Regarding my concern (unrelated to NVK): I've had issues with a nonfree application segfaulting which I narrowed down to a mesa commit from a few months ago [2] [3] and hit a dead end with (until today). It's only this single program which I had ever noticed the issue with so I pushed it aside, but it just occurred to me that this seems like a change that could affect other cases my daily driving has not covered. Further investigation today has revealed that adding libglvnd as an input to mesa fixes this, although from what I can tell reading past discussions on adding it, it seems like a complicated issue [4]. Thoughts about this situation? [1] https://docs.mesa3d.org/release-calendar.html#calendar [2] https://gitlab.freedesktop.org/mesa/mesa/-/issues/11666 [3] https://gitlab.freedesktop.org/mesa/mesa/-/commit/50fc7cc290db49288b318c116c6fdc3daaf801e9 [4] https://issues.guix.gnu.org/49339#3 Cheers, aurtzy
[Message part 2 (text/html, inline)]
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Wed, 18 Sep 2024 00:38:01 GMT) Full text and rfc822 format available.Message #44 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: The Man <squishypinkelephant <at> gmail.com> To: 73071 <at> debbugs.gnu.org Subject: [PATCH mesa-updates 0/8] Various updates for mesa to 24.2.2 Date: Tue, 17 Sep 2024 19:35:51 -0500
[Message part 1 (text/plain, inline)]
Hello, In the interest of creating a future where mesa properly works alongside libglvnd i think there's a few options: - simply adding "-Dglvnd=true" to mesa configure-flags and tediously adding libglvnd to the inputs of every package that links to LibGL, as well as patching anything problematic as mentioned in https://issues.guix.gnu.org/49339#8 - create an abomination, the ONE MESA TO RULE THEM ALL. an example follows: (define-public mesa/new (package (inherit mesa) (arguments (substitute-keyword-arguments (package-arguments mesa) ((#:configure-flags flags ''()) #~(append #$flags (list "-Dglvnd=true"))) ((#:phases phases ''()) (with-imported-modules '((guix build union)) #~(modify-phases #$phases (add-before 'validate-runpath 'unionize (lambda _ ;; unionize with libglvnd, fixing all problems (use-modules (ice-9 match) (guix build union)) (union-build (string-append #$output "/tmp") '#$(list (this-package-input "libglvnd")) #:create-all-directories? #t) (copy-recursively (string-append #$output "/tmp") #$output) (delete-file-recursively (string-append #$output "/tmp")) ;; leftovers from building with old mesa. ;; some packages still link to these. ;; remove for rebuilding after applying graft? (symlink (string-append #$output "/lib/libEGL.so.1") (string-append #$output "/lib/libEGL.so.1.0.0")) (symlink (string-append #$output "/lib/libGLESv1_CM.so.1") (string-append #$output "/lib/libGLESv1_CM.so.1.1.0")) (symlink (string-append #$output "/lib/libGLESv2.so.2") (string-append #$output "/lib/libGLESv2.so.2.0.0")) (symlink (string-append #$output "/lib/libGL.so.1") (string-append #$output "/lib/libGL.so.1.2.0")))) (add-after 'install 'fix-paths (lambda _ (substitute* (string-append #$output "/share/glvnd/egl_vendor.d/50_mesa.json") (("libEGL_mesa") (string-append #$output "/lib/libEGL_mesa"))))) (add-after 'fix-paths 'add-external-egl (lambda _ (mkdir-p (string-append #$output "/share/egl/egl_external_platform.d"))))))))) (native-search-paths (append (package-native-search-paths mesa) (list (search-path-specification (variable "__EGL_VENDOR_LIBRARY_DIRS") (files '("share/glvnd/egl_vendor.d"))) (search-path-specification (variable "GBM_BACKENDS_PATH") (files '("lib"))) (search-path-specification (variable "XDG_DATA_DIRS") (files '("share"))) (search-path-specification (variable "__EGL_EXTERNAL_PLATFORM_CONFIG_DIRS") (files '("share/egl/egl_external_platform.d")))))) (inputs (modify-inputs (package-inputs mesa) (prepend libglvnd))))) Using this to graft over mesa is a filthy answer to the "GL problem". no rebuilding necessary, it seems to "just work". Other distributions have settled on packaging mesa build for working with libglvnd and most software seems to expect such. Perhaps there's another solution?
[Message part 2 (text/html, inline)]
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 20 Sep 2024 01:47:02 GMT) Full text and rfc822 format available.Message #47 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: aurtzy <aurtzy <at> gmail.com> Cc: 73071 <at> debbugs.gnu.org Subject: Re: [bug#73071] [PATCH mesa-updates 0/8] Various updates for mesa to 24.2.2 Date: Fri, 20 Sep 2024 01:46:25 +0000
Hello! On Mon, Sep 16, 2024 at 09:50 PM, aurtzy wrote: > I didn't consider this when writing the patch, but would it be a good idea to only use meson-1.5 for x86_64? We could > avoid rebuilds that way. > > Looks like a new mesa release is planned for the 18th [1]. > Ah, thanks, never saw the calendar before. I'm going to build the newest release locally, rebase, and push with your patch and this update. From what I can tell, non x86 archs have stalled for over a week; not sure if a new update really sets them behind or what is happening. > Other than that, I made a minor tweak to the changelog (remove first > line, name the phase) locally, but have not done a rebase/push on > mesa-updates. Let me give it a few days for other comments and if > there are any other rebuilds to go with it. > > Regarding my concern (unrelated to NVK): I've had issues with a nonfree application segfaulting which I narrowed down > to a mesa commit from a few months ago [2] [3] and hit a dead end with (until today). It's only this single program which > I had ever noticed the issue with so I pushed it aside, but it just occurred to me that this seems like a change that could > affect other cases my daily driving has not covered. > > Further investigation today has revealed that adding libglvnd as an input to mesa fixes this, although from what I can > tell reading past discussions on adding it, it seems like a complicated issue [4]. Thoughts about this situation? > Yeah, we should tackle libglvnd in a separate issue. I'm guessing the main benefit is for Guix on foreign distros? It is easy enough to add the input and mesa build with libglvnd support, but as you see in the thread, there are some other changes needed. Nothing too bad it seems, just hasn't been tackled. Patches/testing welcome :) > [1] https://docs.mesa3d.org/release-calendar.html#calendar > > [2] https://gitlab.freedesktop.org/mesa/mesa/-/issues/11666 > > [3] https://gitlab.freedesktop.org/mesa/mesa/-/commit/50fc7cc290db49288b318c116c6fdc3daaf801e9 > > [4] https://issues.guix.gnu.org/49339#3 > > Cheers, > > aurtzy Thanks again! John
guix-patches <at> gnu.org
:bug#73071
; Package guix-patches
.
(Fri, 20 Sep 2024 01:53:01 GMT) Full text and rfc822 format available.Message #50 received at 73071 <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: The Man <squishypinkelephant <at> gmail.com> Cc: 73071 <at> debbugs.gnu.org Subject: Re: [bug#73071] [PATCH mesa-updates 0/8] Various updates for mesa to 24.2.2 Date: Fri, 20 Sep 2024 01:51:34 +0000
Hello The Man :) A note that your email went to no one; the debbugs number address is not an alias for anyone. I happen to see your message via the issues web interface. I would suggest adding in cc's here to whoever you intended. On Tue, Sep 17, 2024 at 07:35 PM, The Man wrote: > Hello, In the interest of creating a future where mesa properly works alongside libglvnd i think there's a few options: > > - simply adding "-Dglvnd=true" to mesa configure-flags and tediously adding libglvnd to the inputs of every package > that links to LibGL, as well as patching anything problematic as mentioned in https://issues.guix.gnu.org/49339#8 > This didn't seem so tidious but a countable number of packages. The building and testing will take more time but it didn't seem too bad at the time at least. > - create an abomination, the ONE MESA TO RULE THEM ALL. an example follows: > This looks the same basically as just propagating libglvnd from mesa, but I didn't look too carefully or try it. In any event, we should handle this in a separate issue, get some input, and then we can do this on a branch. My instinct is to go with what was started in the linked issue above; add libglvnd to mesa (propagated?) and fix failing packages assuming it isn't all 4000 or whatever (pretty sure it is not). > (define-public mesa/new > (package > (inherit mesa) > (arguments > (substitute-keyword-arguments (package-arguments mesa) > ((#:configure-flags flags ''()) > #~(append #$flags > (list "-Dglvnd=true"))) > ((#:phases phases ''()) > (with-imported-modules '((guix build union)) > #~(modify-phases #$phases > (add-before 'validate-runpath 'unionize > (lambda _ ;; unionize with libglvnd, fixing all problems > (use-modules (ice-9 match) > (guix build union)) > (union-build (string-append #$output "/tmp") > '#$(list (this-package-input "libglvnd")) > #:create-all-directories? #t) > (copy-recursively (string-append #$output "/tmp") #$output) > (delete-file-recursively (string-append #$output "/tmp")) > ;; leftovers from building with old mesa. > ;; some packages still link to these. > ;; remove for rebuilding after applying graft? > (symlink (string-append #$output "/lib/libEGL.so.1") > (string-append #$output "/lib/libEGL.so.1.0.0")) > (symlink (string-append #$output "/lib/libGLESv1_CM.so.1") > (string-append #$output "/lib/libGLESv1_CM.so.1.1.0")) > (symlink (string-append #$output "/lib/libGLESv2.so.2") > (string-append #$output "/lib/libGLESv2.so.2.0.0")) > (symlink (string-append #$output "/lib/libGL.so.1") > (string-append #$output "/lib/libGL.so.1.2.0")))) > (add-after 'install 'fix-paths > (lambda _ > (substitute* > (string-append #$output "/share/glvnd/egl_vendor.d/50_mesa.json") > (("libEGL_mesa") > (string-append #$output "/lib/libEGL_mesa"))))) > (add-after 'fix-paths 'add-external-egl > (lambda _ > (mkdir-p (string-append #$output "/share/egl/egl_external_platform.d"))))))))) > (native-search-paths (append (package-native-search-paths mesa) > (list > (search-path-specification > (variable "__EGL_VENDOR_LIBRARY_DIRS") > (files '("share/glvnd/egl_vendor.d"))) > (search-path-specification > (variable "GBM_BACKENDS_PATH") > (files '("lib"))) > (search-path-specification > (variable "XDG_DATA_DIRS") > (files '("share"))) > (search-path-specification > (variable "__EGL_EXTERNAL_PLATFORM_CONFIG_DIRS") > (files '("share/egl/egl_external_platform.d")))))) > (inputs (modify-inputs (package-inputs mesa) > (prepend libglvnd))))) > > Using this to graft over mesa is a filthy answer to the "GL problem". no rebuilding necessary, it seems to "just work". > > Other distributions have settled on packaging mesa build for working with libglvnd and most software seems to expect > such. > Perhaps there's another solution? It is unclear to me in Guix what this all means. I think it would mostly be helpful on foreign distros (so libglvnd can load host's GL stuff) but I don't know. Or perhaps for non-free related stuff (which wouldn't be part of Guix directly in any event). Thanks for the input! John
John Kehayias <john.kehayias <at> protonmail.com>
:John Kehayias <john.kehayias <at> protonmail.com>
:Message #55 received at 73071-done <at> debbugs.gnu.org (full text, mbox):
From: John Kehayias <john.kehayias <at> protonmail.com> To: aurtzy <aurtzy <at> gmail.com> Cc: 73071-done <at> debbugs.gnu.org Subject: Re: [bug#73071] [PATCH mesa-updates 0/8] Various updates for mesa to 24.2.2 Date: Tue, 05 Nov 2024 18:51:42 +0000
On Fri, Sep 20, 2024 at 01:46 AM, John Kehayias wrote: > Hello! > > On Mon, Sep 16, 2024 at 09:50 PM, aurtzy wrote: > >> I didn't consider this when writing the patch, but would it be a >> good idea to only use meson-1.5 for x86_64? We could >> avoid rebuilds that way. >> >> Looks like a new mesa release is planned for the 18th [1]. >> > > Ah, thanks, never saw the calendar before. I'm going to build the newest > release locally, rebase, and push with your patch and this update. From > what I can tell, non x86 archs have stalled for over a week; not sure if > a new update really sets them behind or what is happening. > >> Other than that, I made a minor tweak to the changelog (remove first >> line, name the phase) locally, but have not done a rebase/push on >> mesa-updates. Let me give it a few days for other comments and if >> there are any other rebuilds to go with it. >> >> Regarding my concern (unrelated to NVK): I've had issues with a >> nonfree application segfaulting which I narrowed down >> to a mesa commit from a few months ago [2] [3] and hit a dead end >> with (until today). It's only this single program which >> I had ever noticed the issue with so I pushed it aside, but it just >> occurred to me that this seems like a change that could >> affect other cases my daily driving has not covered. >> >> Further investigation today has revealed that adding libglvnd as an >> input to mesa fixes this, although from what I can >> tell reading past discussions on adding it, it seems like a >> complicated issue [4]. Thoughts about this situation? >> > > Yeah, we should tackle libglvnd in a separate issue. I'm guessing the > main benefit is for Guix on foreign distros? It is easy enough to add > the input and mesa build with libglvnd support, but as you see in the > thread, there are some other changes needed. Nothing too bad it seems, > just hasn't been tackled. Patches/testing welcome :) > >> [1] <https://docs.mesa3d.org/release-calendar.html#calendar> >> >> [2] <https://gitlab.freedesktop.org/mesa/mesa/-/issues/11666> >> >> [3] >> <https://gitlab.freedesktop.org/mesa/mesa/-/commit/50fc7cc290db49288b318c116c6fdc3daaf801e9> >> >> [4] <https://issues.guix.gnu.org/49339#3> >> >> Cheers, >> >> aurtzy > > Thanks again! > John Merged the mesa-updates branch with latest mesa commit 40b6729fd78ea53ac339257aea798d625e16894d. Closing. Thanks aurtzy!
Debbugs Internal Request <help-debbugs <at> gnu.org>
to internal_control <at> debbugs.gnu.org
.
(Wed, 04 Dec 2024 12:24:10 GMT) Full text and rfc822 format available.
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.