From 92744e9f54db9931253e17245d2c3841c6ac6369 Mon Sep 17 00:00:00 2001 From: John Kehayias Date: Sat, 31 Jul 2021 13:57:37 -0400 Subject: [PATCH] gnu: mesa: fix mesa-opencl and mesa-opencl-icd 21.1.6 * gnu/packages/gl.scm (mesa-opencl): Restore LLVM targets to meson.build * gnu/packages/gl.scm (mesa-opencl-icd): Restore LLVM targets to meson.build --- gnu/packages/gl.scm | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm index e316352377..cdd98dd8fd 100644 --- a/gnu/packages/gl.scm +++ b/gnu/packages/gl.scm @@ -474,7 +474,16 @@ from software emulation to complete hardware acceleration for modern GPUs.") (arguments (substitute-keyword-arguments (package-arguments mesa) ((#:configure-flags flags) - `(cons "-Dgallium-opencl=standalone" ,flags)))) + `(cons "-Dgallium-opencl=standalone" ,flags)) + ((#:phases phases) + `(modify-phases ,phases + (add-after 'unpack 'enable-llvm-platforms + (lambda* (#:key inputs #:allow-other-keys) + ;; Restore all LLVM targets in order to build with our LLVM + ;; as a shared library. + (substitute* "meson.build" + (("'linker', 'coverage', 'instrumentation', 'ipo', 'irreader',") + "'all-targets', 'linker', 'coverage', 'instrumentation', 'ipo', 'irreader',")))))))) (inputs `(("libclc" ,libclc) ,@(package-inputs mesa))) @@ -492,6 +501,13 @@ from software emulation to complete hardware acceleration for modern GPUs.") ,(delete "-Dgallium-opencl=standalone" flags))) ((#:phases phases) `(modify-phases ,phases + (add-after 'unpack 'enable-llvm-platforms + (lambda* (#:key inputs #:allow-other-keys) + ;; Restore all LLVM targets in order to build with our LLVM + ;; as a shared library. + (substitute* "meson.build" + (("'linker', 'coverage', 'instrumentation', 'ipo', 'irreader',") + "'all-targets', 'linker', 'coverage', 'instrumentation', 'ipo', 'irreader',")))) (add-after 'install 'mesa-icd-absolute-path (lambda _ ;; Use absolute path for OpenCL platform library. -- 2.32.0