gnu: mesa: Update to 22.1.7.

* gnu/packages/gl.scm (mesa): Update to 22.1.7.
[source]: Fix indentation.  Remove patch, implementing it as a...
[configure-flags]: Remove '-Ddri-drivers=...' flag, no longer supported.
[phases]{disable-failing-test} ... substitution instead.
[propagated-inputs]: Move comment above.
[inputs]: Remove extraneous append and sort.
[native-inputs]: Likewise.
[configure-flags]: Break long lines.
* gnu/packages/patches/mesa-skip-tests.patch: Delete file.
* gnu/local.mk (dist_patch_DATA): De-register it.
This commit is contained in:
Maxim Cournoyer 2022-08-22 16:11:24 -04:00
parent f4f9ee8261
commit 9b2a3e023f
No known key found for this signature in database
GPG key ID: 1260E46482E63562
3 changed files with 58 additions and 70 deletions

View file

@ -1491,7 +1491,6 @@ dist_patch_DATA = \
%D%/packages/patches/libsigrokdecode-python3.9-fix.patch \ %D%/packages/patches/libsigrokdecode-python3.9-fix.patch \
%D%/packages/patches/mercurial-hg-extension-path.patch \ %D%/packages/patches/mercurial-hg-extension-path.patch \
%D%/packages/patches/mesa-opencl-all-targets.patch \ %D%/packages/patches/mesa-opencl-all-targets.patch \
%D%/packages/patches/mesa-skip-tests.patch \
%D%/packages/patches/meson-allow-dirs-outside-of-prefix.patch \ %D%/packages/patches/meson-allow-dirs-outside-of-prefix.patch \
%D%/packages/patches/mhash-keygen-test-segfault.patch \ %D%/packages/patches/mhash-keygen-test-segfault.patch \
%D%/packages/patches/mia-fix-boost-headers.patch \ %D%/packages/patches/mia-fix-boost-headers.patch \

View file

@ -268,73 +268,72 @@ (define libva-without-mesa
(define-public mesa (define-public mesa
(package (package
(name "mesa") (name "mesa")
(version "22.1.2") (version "22.1.7")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
(uri (list (string-append "https://mesa.freedesktop.org/archive/" (uri (list (string-append "https://mesa.freedesktop.org/archive/"
"mesa-" version ".tar.xz") "mesa-" version ".tar.xz")
(string-append "ftp://ftp.freedesktop.org/pub/mesa/" (string-append "ftp://ftp.freedesktop.org/pub/mesa/"
"mesa-" version ".tar.xz") "mesa-" version ".tar.xz")
(string-append "ftp://ftp.freedesktop.org/pub/mesa/" (string-append "ftp://ftp.freedesktop.org/pub/mesa/"
version "/mesa-" version ".tar.xz"))) version "/mesa-" version ".tar.xz")))
(sha256 (sha256
(base32 (base32
"1smrvvh8l7xcccwfbccx9k0ihzh1whrnnwsmqb7i0gba99mj4w89")) "12ax6lmshc8aqzw5ca7ab7f7z64n9nyzci4r1s6y1l0iryr8x0ys"))))
(patches
(search-patches "mesa-skip-tests.patch"))))
(build-system meson-build-system) (build-system meson-build-system)
(propagated-inputs (propagated-inputs
(list ;; The following are in the Requires.private field of gl.pc. ;; The following are in the Requires.private field of gl.pc.
libdrm (list libdrm
libvdpau libvdpau
libx11 libx11
libxdamage libxdamage
libxfixes libxfixes
libxshmfence libxshmfence
libxxf86vm libxxf86vm
xorgproto)) xorgproto))
(inputs (inputs
(append (list expat (list elfutils ;libelf required for r600 when using llvm
elfutils ;libelf required for r600 when using llvm expat
(force libva-without-mesa) (force libva-without-mesa)
libxml2 libxml2
libxrandr libxrandr
libxvmc libxvmc
wayland ;; Note: update the 'clang' input of mesa-opencl when bumping this.
wayland-protocols) llvm
;; TODO: Resort alphabetically. wayland
;; Note: update the 'clang' input of mesa-opencl when bumping this. wayland-protocols))
(list llvm)))
(native-inputs (native-inputs
(append (list bison (list bison
flex flex
gettext-minimal gettext-minimal
pkg-config glslang
python-wrapper pkg-config
python-libxml2 ;for OpenGL ES 1.1 and 2.0 support python-libxml2 ;for OpenGL ES 1.1 and 2.0 support
python-mako python-mako
(@ (gnu packages base) which)) python-wrapper
;; TODO: Resort alphabetically. (@ (gnu packages base) which)))
(list glslang)))
(outputs '("out" "bin")) (outputs '("out" "bin"))
(arguments (arguments
`(#:configure-flags `(#:configure-flags
'(,@(match (%current-system) '(,@(match (%current-system)
("aarch64-linux" ("aarch64-linux"
;; TODO: Fix svga driver for non-Intel architectures. ;; TODO: Fix svga driver for non-Intel architectures.
'("-Dgallium-drivers=etnaviv,freedreno,kmsro,lima,nouveau,panfrost,r300,r600,swrast,tegra,v3d,vc4,virgl")) '("-Dgallium-drivers=etnaviv,freedreno,kmsro,lima,nouveau,\
panfrost,r300,r600,swrast,tegra,v3d,vc4,virgl"))
("armhf-linux" ("armhf-linux"
;; Freedreno FTBFS when built on a 64-bit machine. ;; Freedreno FTBFS when built on a 64-bit machine.
'("-Dgallium-drivers=etnaviv,kmsro,lima,nouveau,panfrost,r300,r600,swrast,tegra,v3d,vc4,virgl")) '("-Dgallium-drivers=etnaviv,kmsro,lima,nouveau,panfrost,\
((or "powerpc64le-linux" "powerpc-linux") r300,r600,swrast,tegra,v3d,vc4,virgl"))
((or "powerpc64le-linux" "powerpc-linux" "riscv64-linux")
'("-Dgallium-drivers=nouveau,r300,r600,radeonsi,swrast,virgl")) '("-Dgallium-drivers=nouveau,r300,r600,radeonsi,swrast,virgl"))
(_ (_
'("-Dgallium-drivers=auto"))) '("-Dgallium-drivers=iris,nouveau,r300,r600,radeonsi,\
svga,swrast,virgl")))
;; Enable various optional features. TODO: opencl requires libclc, ;; Enable various optional features. TODO: opencl requires libclc,
;; omx requires libomxil-bellagio ;; omx requires libomxil-bellagio
"-Dplatforms=x11,wayland" "-Dplatforms=x11,wayland"
"-Dglx=dri" ;Thread Local Storage, improves performance "-Dglx=dri" ;Thread Local Storage, improves performance
;; "-Dopencl=true" ;; "-Dopencl=true"
;; "-Domx=true" ;; "-Domx=true"
"-Dosmesa=true" "-Dosmesa=true"
@ -347,10 +346,14 @@ (define-public mesa
;; Explicitly enable Vulkan on some architectures. ;; Explicitly enable Vulkan on some architectures.
,@(match (%current-system) ,@(match (%current-system)
((or "i686-linux" "x86_64-linux")
'("-Dvulkan-drivers=intel,amd"))
((or "powerpc64le-linux" "powerpc-linux") ((or "powerpc64le-linux" "powerpc-linux")
'("-Dvulkan-drivers=amd,swrast")) '("-Dvulkan-drivers=amd,swrast"))
("aarch64-linux" ("aarch64-linux"
'("-Dvulkan-drivers=freedreno,amd,broadcom,swrast")) '("-Dvulkan-drivers=freedreno,amd,broadcom,swrast"))
("riscv64-linux"
'("-Dvulkan-drivers=amd,swrast"))
(_ (_
'("-Dvulkan-drivers=auto"))) '("-Dvulkan-drivers=auto")))
@ -360,8 +363,7 @@ (define-public mesa
;; Also enable the tests. ;; Also enable the tests.
"-Dbuild-tests=true" "-Dbuild-tests=true"
;; Enable LLVM; default is x86/x86_64 only. "-Dllvm=enabled") ; default is x86/x86_64 only
"-Dllvm=enabled")
;; XXX: 'debugoptimized' causes LTO link failures on some drivers. The ;; XXX: 'debugoptimized' causes LTO link failures on some drivers. The
;; documentation recommends using 'release' for performance anyway. ;; documentation recommends using 'release' for performance anyway.
@ -409,6 +411,11 @@ (define-public mesa
;; This test times out and receives SIGTERM. ;; This test times out and receives SIGTERM.
(substitute* "src/amd/common/meson.build" (substitute* "src/amd/common/meson.build"
(("and not with_platform_windows") "and with_platform_windows")))) (("and not with_platform_windows") "and with_platform_windows"))))
("i686-linux"
;; This test is known to fail on i686 (see:
;; https://gitlab.freedesktop.org/mesa/mesa/-/issues/4091).
`((substitute* "src/util/meson.build"
((".*'tests/u_debug_stack_test.cpp',.*") ""))))
("aarch64-linux" ("aarch64-linux"
;; The ir3_disasm test segfaults. ;; The ir3_disasm test segfaults.
;; The simplest way to skip it is to run a different test instead. ;; The simplest way to skip it is to run a different test instead.

View file

@ -1,18 +0,0 @@
This test fails on i686-linux. I couldn't come up with a regex that
could be used to disable it just on i686-linux, so we disable it
completely with this patch:
https://gitlab.freedesktop.org/mesa/mesa/-/issues/4091
diff --git a/src/util/meson.build b/src/util/meson.build
index 2a1028f0d3a..0d31f38b671 100644
--- a/src/util/meson.build
+++ b/src/util/meson.build
@@ -330,7 +330,6 @@ if with_tests
'tests/set_test.cpp',
'tests/sparse_array_test.cpp',
'tests/u_atomic_test.cpp',
- 'tests/u_debug_stack_test.cpp',
'tests/u_printf_test.cpp',
'tests/u_qsort_test.cpp',
'tests/vector_test.cpp',