guix_mirror_bot pushed a commit to branch mesa-updates
in repository guix.
commit 549e6db6f10f25ed694fc1b8f353f5bafd15e980
Author: Alvin Hsu <[email protected]>
AuthorDate: Tue Aug 26 20:51:52 2025 -0400
gnu: mesa: Update to 25.3.6.
* gnu/packages/rust-crates.scm (mesa-cargo-inputs): Delete variable.
(lookup-cargo-inputs): [mesa]: New entry.
* gnu/packages/gl.scm (mesa): Update to 25.3.6.
[arguments]<#:phases>: Remove redundant 'patch-subproject-sources phase.
When building with rust add a phase to make the build system use the
packaged rust crates.
[inputs]: Re-add cargo inputs here.
[native-inputs]: Refer to rust-bindgen-cli and rust-cbindgen directly.
Remove rust-cbindgen-0.26, add rust-cbindgen.
Co-authored-by: Efraim Flashner <[email protected]>
Change-Id: Ie05b762dbfcc14691edc4c2dad222c9c9a174da2
Signed-off-by: John Kehayias <[email protected]>
---
gnu/packages/gl.scm | 109 +++++++++++++++++++++----------------------
gnu/packages/rust-crates.scm | 87 +++++++++++++++++++++++++++++-----
2 files changed, 129 insertions(+), 67 deletions(-)
diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm
index 4101edf60b..92f04cc96c 100644
--- a/gnu/packages/gl.scm
+++ b/gnu/packages/gl.scm
@@ -5,7 +5,7 @@
;;; Copyright © 2014, 2015, 2016, 2017 Mark H Weaver <[email protected]>
;;; Copyright © 2016 Nikita <[email protected]>
;;; Copyright © 2016, 2017, 2018, 2020, 2021 Ricardo Wurmus
<[email protected]>
-;;; Copyright © 2017-2019, 2021, 2023-2025 Efraim Flashner
<[email protected]>
+;;; Copyright © 2017-2019, 2021, 2023-2026 Efraim Flashner
<[email protected]>
;;; Copyright © 2017 Arun Isaac <[email protected]>
;;; Copyright © 2017, 2018, 2019 Rutger Helling <[email protected]>
;;; Copyright © 2018–2021 Tobias Geerinckx-Rice <[email protected]>
@@ -22,7 +22,7 @@
;;; Copyright © 2024 Liliana Marie Prikler <[email protected]>
;;; Copyright © 2024 Artyom V. Poptsov <[email protected]>
;;; Copyright © 2024 Arnaud Lechevallier <[email protected]>
-;;; Copyright © 2024 aurtzy <[email protected]>
+;;; Copyright © 2024-2025 Alvin Hsu <[email protected]>
;;; Copyright © 2025 Sughosha <[email protected]>
;;;
;;; This file is part of GNU Guix.
@@ -74,6 +74,7 @@
#:use-module (guix hg-download)
#:use-module (gnu packages cmake)
#:use-module (guix build-system gnu)
+ #:use-module (guix build-system cargo)
#:use-module (guix build-system cmake)
#:use-module (guix build-system meson)
#:use-module (guix build-system python)
@@ -315,7 +316,7 @@ also known as DXTn or DXTC) for Mesa.")
(define-public mesa
(package
(name "mesa")
- (version "25.2.3")
+ (version "25.3.6")
(source
(origin
(method url-fetch)
@@ -324,8 +325,7 @@ also known as DXTn or DXTC) for Mesa.")
(string-append "ftp://ftp.freedesktop.org/pub/mesa/"
"mesa-" version ".tar.xz")))
(sha256
- (base32
- "1y5lj9zy2hfvx9ji1rvsjapmzap7mpp5i3pf2yfcpmpica2v5mpj"))))
+ (base32 "01pjp30lqlbn09w2vcmf843iwks9nyflncjqv77ffr1vmkz7w8ar"))))
(build-system meson-build-system)
(propagated-inputs
;; The following are in the Requires.private field of gl.pc.
@@ -338,17 +338,22 @@ also known as DXTn or DXTC) for Mesa.")
libxxf86vm
xorgproto))
(inputs
- (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")))
+ (cons* 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")
+ ;; Rust isn't needed for all architectures.
+ (if (target-x86-64?)
+ ;; NVK dependencies
+ (cargo-inputs 'mesa)
+ '())))
(native-inputs
(append
(list bison
@@ -374,13 +379,12 @@ also known as DXTn or DXTC) for Mesa.")
wayland
wayland-protocols)
'())
+ ;; Rust isn't needed for all architectures.
(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))
+ rust-bindgen-cli
+ rust-cbindgen)
'())))
(outputs '("out" "bin"))
(arguments
@@ -449,9 +453,13 @@
panfrost,r300,r600,svga,softpipe,llvmpipe,tegra,v3d,vc4,virgl,zink"))
#:build-type "release"
#:modules '((ice-9 match)
+ (ice-9 ftw)
(srfi srfi-1)
(guix build utils)
+ ((guix build cargo-build-system) #:prefix cargo:)
(guix build meson-build-system))
+ #:imported-modules (append %cargo-build-system-modules
+ %meson-build-system-modules)
#:phases
#~(modify-phases %standard-phases
#$@(if (%current-target-system)
@@ -467,6 +475,32 @@
panfrost,r300,r600,svga,softpipe,llvmpipe,tegra,v3d,vc4,virgl,zink"))
(search-input-file
native-inputs "/bin/cmake")))))
#~())
+ #$@(if (this-package-native-input "rust")
+ #~((add-after 'unpack 'prepare-rust-crates
+ (lambda args
+ (apply (assoc-ref cargo:%standard-phases
+ 'prepare-rust-crates)
+ args)
+ ;; Use /tmp/rust-crates as the source.
+ (substitute* (find-files "subprojects" "-rs\\.wrap$")
+ (("source_url = (.*)" _ url)
+ (let ((split-url (string-split url #\/)))
+ (string-append
+ "source_url = file:///tmp/rust-crates/rust-"
+ (string-join
+ (string-split (list-ref split-url 6) #\_) "-")
+ "-" (list-ref split-url 7) ".tar.gz\n"))))
+ ;; "Download" the packages.
+ ;; once-cell-1.8.0 was yanked by upstream
+ (delete-file "subprojects/once_cell-1-rs.wrap")
+ (for-each
+ (lambda (wrapper)
+ (invoke "meson" "subprojects" "download"
+ (string-drop-right wrapper 5)))
+ (scandir "subprojects"
+ (lambda (file)
+ (string-suffix? "-rs.wrap" file)))))))
+ #~())
(add-after 'unpack 'disable-failing-test
(lambda _
;; Disable the intel vulkan (anv_state_pool) tests, as they may
@@ -509,41 +543,6 @@
panfrost,r300,r600,svga,softpipe,llvmpipe,tegra,v3d,vc4,virgl,zink"))
(("'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)))
- (mkdir-p subproject-dest)
- (invoke "tar" "xf" source "-C" subproject-dest
- "--strip-components=1")
- ;; 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))))))
- '#+(module-ref (resolve-interface
- '(gnu packages rust-crates))
- 'mesa-cargo-inputs)))))
- #~())
(add-after 'unpack 'set-home-directory
;; Build tries to use a shader cache (non-fatal error).
(lambda _ (setenv "HOME" "/tmp")))
diff --git a/gnu/packages/rust-crates.scm b/gnu/packages/rust-crates.scm
index f1f31de11f..ec02d6d94a 100644
--- a/gnu/packages/rust-crates.scm
+++ b/gnu/packages/rust-crates.scm
@@ -10697,6 +10697,10 @@
(crate-source "hashbrown" "0.14.0"
"0yj3nf0w30pf30w503kgaw4sbjnh62l5cbmc7dd0mnczzywh2qic"))
+(define rust-hashbrown-0.14.1
+ (crate-source "hashbrown" "0.14.1"
+ "04hdcir5sqgw9318c3sjnhf3jid1mq5ipy0ma2pawpgm28madzbx"))
+
(define rust-hashbrown-0.14.5
(crate-source "hashbrown" "0.14.5"
"1wa1vy1xs3mp11bn3z9dv0jricgr6a2j0zkf1g19yz3vw4il89z5"))
@@ -11762,6 +11766,10 @@
(crate-source "indexmap" "2.0.1"
"0kmi1dhkmnv937mbkzlqq9kmkdr8k5030vfk19bi8jcxy4x7q8md"))
+(define rust-indexmap-2.2.6
+ (crate-source "indexmap" "2.2.6"
+ "09hgwi2ig0wyj5rjziia76zmhgfj95k0jb4ic3iiawm4vlavg3qn"))
+
(define rust-indexmap-2.10.0
(crate-source "indexmap" "2.10.0"
"0qd6g26gxzl6dbf132w48fa8rr95glly3jhbk90i29726d9xhk7y"))
@@ -13074,6 +13082,10 @@
(crate-source "libc" "0.2.162"
"1633a00yyx45kzx9r54fndvr8njsjqyr7zl12mzgsmgyczg8glhq"))
+(define rust-libc-0.2.168
+ (crate-source "libc" "0.2.168"
+ "0vab4inpw0dz78nii02hsxp1skqn06xzh64psw8wl1h63scb5bjs"))
+
(define rust-libc-0.2.169
(crate-source "libc" "0.2.169"
"02m253hs8gw0m1n8iyrsc4n15yzbqwhddi7w1l0ds7i92kdsiaxm"))
@@ -17007,14 +17019,18 @@
(crate-source "password-hash" "0.5.0"
"0ri1mim11zk0a9s40zdi288dfqvmdiryc7lw8vl46b59ifa08vrl"))
-(define rust-paste-0.1.18
- (crate-source "paste" "0.1.18"
- "10587zrlmzhq66yhd0z36fzglf32m1nlhi9bxxm6dgl0gp3j1jj5"))
+(define rust-paste-1.0.14
+ (crate-source "paste" "1.0.14"
+ "0k7d54zz8zrz0623l3xhvws61z5q2wd3hkwim6gylk8212placfy"))
(define rust-paste-1.0.15
(crate-source "paste" "1.0.15"
"02pxffpdqkapy292harq6asfjvadgp1s005fip9ljfsn9fvxgh2p"))
+(define rust-paste-0.1.18
+ (crate-source "paste" "0.1.18"
+ "10587zrlmzhq66yhd0z36fzglf32m1nlhi9bxxm6dgl0gp3j1jj5"))
+
(define rust-paste-impl-0.1.18
(crate-source "paste-impl" "0.1.18"
"1dlqzk05cx74522s4iyhyzzhszig4n401pp6r1qg6zmr02r7snnr"))
@@ -19014,6 +19030,10 @@
(crate-source "quote" "1.0.33"
"1biw54hbbr12wdwjac55z1m2x2rylciw83qnjn564a3096jgqrsj"))
+(define rust-quote-1.0.35
+ (crate-source "quote" "1.0.35"
+ "1vv8r2ncaz4pqdr78x7f138ka595sp2ncr1sa2plm4zxbsmwj7i9"))
+
(define rust-quote-1.0.36
(crate-source "quote" "1.0.36"
"19xcmh445bg6simirnnd4fvkmp6v2qiwxh5f6rw4a70h76pnm9qg"))
@@ -19808,6 +19828,10 @@
(crate-source "relative-path" "2.0.1"
"1c4jm6x0p88722c77xx53mb7zcs4xznp9d3whdsbmn1248qhm95w"))
+(define rust-remain-0.2.12
+ (crate-source "remain" "0.2.12"
+ "157pzbzkwrj1m111ns3mmr3yla4qnrd0qiij0m6jgb8c4c8y1m8s"))
+
(define rust-remoteprocess-0.5.0
(crate-source "remoteprocess" "0.5.0"
"087z016qvypalbqjgdxmri97vsrqg4k1kpmc8b5d5hdgqxq4f6g6"))
@@ -23994,6 +24018,10 @@
(crate-source "thiserror" "1.0.69"
"0lizjay08agcr5hs9yfzzj6axs53a2rgx070a1dsi3jpkcrzbamn"))
+(define rust-thiserror-2.0.11
+ (crate-source "thiserror" "2.0.11"
+ "1z0649rpa8c2smzx129bz4qvxmdihj30r2km6vfpcv9yny2g4lnl"))
+
(define rust-thiserror-2.0.18
(crate-source "thiserror" "2.0.18"
"1i7vcmw9900bvsmay7mww04ahahab7wmr8s925xc083rpjybb222"))
@@ -24042,6 +24070,10 @@
(crate-source "thiserror-impl" "2.0.6"
"04k3dz901mymm06j3x6f65hpbsqlk6g51fmiky9g2kqgnk550myn"))
+(define rust-thiserror-impl-2.0.11
+ (crate-source "thiserror-impl" "2.0.11"
+ "1hkkn7p2y4cxbffcrprybkj0qy1rl1r6waxmxqvr764axaxc3br6"))
+
(define rust-thiserror-impl-2.0.12
(crate-source "thiserror-impl" "2.0.12"
"07bsn7shydaidvyyrm7jz29vp78vrxr9cr9044rfmn078lmz8z3z"))
@@ -25579,6 +25611,10 @@
(crate-source "ubyte" "0.10.4"
"1spj3k9sx6xvfn7am9vm1b463hsr79nyvj8asi2grqhyrvvdw87p"))
+(define rust-ucd-trie-0.1.6
+ (crate-source "ucd-trie" "0.1.6"
+ "1ff4yfksirqs37ybin9aw71aa5gva00hw7jdxbw8w668zy964r7d"))
+
(define rust-ucd-trie-0.1.7
(crate-source "ucd-trie" "0.1.7"
"0wc9p07sqwz320848i52nvyjvpsxkx3kv5bfbmm6s35809fdk5i8"))
@@ -29203,6 +29239,10 @@
(crate-source "zerocopy" "0.7.35"
"1w36q7b9il2flg0qskapgi9ymgg7p985vniqd09vi0mwib8lz6qv"))
+(define rust-zerocopy-0.8.13
+ (crate-source "zerocopy" "0.8.13"
+ "07g29nsr3hvf2vyh9wk39l3yg144hprjx7aykvkd5gzka6s4m4b7"))
+
(define rust-zerocopy-0.8.24
(crate-source "zerocopy" "0.8.24"
"0yb8hyzfnwzr2wg4p7cnqmjps8fsw8xqnprafgpmfs8qisigx1i5"))
@@ -29243,6 +29283,10 @@
(crate-source "zerocopy-derive" "0.7.35"
"0gnf2ap2y92nwdalzz3x7142f2b83sni66l39vxp2ijd6j080kzs"))
+(define rust-zerocopy-derive-0.8.13
+ (crate-source "zerocopy-derive" "0.8.13"
+ "0pgjqk2w5wrw752wfsxgf7rwqjlk1r4vq5iky2fjijh38cxdg23r"))
+
(define rust-zerocopy-derive-0.8.24
(crate-source "zerocopy-derive" "0.8.24"
"1gk9047pbq1yjj2jyiv0s37nqc53maqbmhcsjp6lhi2w7kvai5m9"))
@@ -29657,15 +29701,6 @@
;;; Cargo inputs.
;;;
-;; TODO: Maintain this automatically too.
-(define-public mesa-cargo-inputs
- `(("paste" ,rust-paste-1.0.15)
- ("proc-macro2" ,rust-proc-macro2-1.0.94)
- ("quote" ,rust-quote-1.0.40)
- ("rustc-hash" ,rust-rustc-hash-2.1.1)
- ("syn" ,rust-syn-2.0.100)
- ("unicode-ident" ,rust-unicode-ident-1.0.18)))
-
(define-cargo-inputs lookup-cargo-inputs
(aardvark-dns =>
(list rust-addr2line-0.24.2
@@ -47175,6 +47210,34 @@
rust-zstd-0.13.3
rust-zstd-safe-7.2.4
rust-zstd-sys-2.0.16+zstd.1.5.7))
+ (mesa => ; TODO: Maintain this automatically.
+ (list rust-bitflags-2.9.1
+ rust-cfg-if-1.0.0
+ rust-equivalent-1.0.1
+ rust-errno-0.3.12
+ rust-hashbrown-0.14.1
+ rust-indexmap-2.2.6
+ rust-libc-0.2.168
+ rust-log-0.4.27
+ ;rust-once-cell-1.8.0 ; Unavailable upstream.
+ rust-paste-1.0.14
+ rust-pest-2.8.0
+ rust-pest-derive-2.8.0
+ rust-pest-generator-2.8.0
+ rust-pest-meta-2.8.0
+ rust-proc-macro2-1.0.86
+ rust-quote-1.0.35
+ rust-remain-0.2.12
+ rust-roxmltree-0.20.0
+ rust-rustc-hash-2.1.1
+ rust-rustix-1.0.7
+ rust-syn-2.0.87
+ rust-thiserror-2.0.11
+ rust-thiserror-impl-2.0.11
+ rust-ucd-trie-0.1.6
+ rust-unicode-ident-1.0.12-unpatched
+ rust-zerocopy-0.8.13
+ rust-zerocopy-derive-0.8.13))
(mollysocket =>
(list rust-ahash-0.8.12
rust-aho-corasick-1.1.3