me
/
guix
Archived
1
0
Fork 0

gnu: Mesa: Fix substitutions for absolute library references.

* gnu/packages/gl.scm (mesa)[arguments]: In the 'fix-dlopen-libnames' phase,
adjust substitutions so that they patch the correct files.
master
Marius Bakke 2020-05-22 19:51:01 +02:00 committed by Marius Bakke
parent 577041e60b
commit 5a746104e3
No known key found for this signature in database
GPG Key ID: A2A06DF2A33A54FA
1 changed files with 6 additions and 6 deletions

View File

@ -357,16 +357,16 @@ also known as DXTn or DXTC) for Mesa.")
(("'u_format_test',") ""))
#t)))
'())
(add-before
'configure 'fix-dlopen-libnames
(add-before 'configure 'fix-dlopen-libnames
(lambda* (#:key inputs outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
;; Remain agnostic to .so.X.Y.Z versions while doing
;; the substitutions so we're future-safe.
(substitute* "src/glx/dri_common.c"
(("dlopen\\(\"libGL\\.so")
(string-append "dlopen(\"" out "/lib/libGL.so")))
(substitute* "src/egl/drivers/dri2/egl_dri2.c"
(substitute* "src/glx/meson.build"
(("-DGL_LIB_NAME=\"lib@0@\\.so\\.@1@\"")
(string-append "-DGL_LIB_NAME=\"" out
"/lib/lib@0@.so.@1@\"")))
(substitute* "src/gbm/backends/dri/gbm_dri.c"
(("\"libglapi\\.so")
(string-append "\"" out "/lib/libglapi.so")))
(substitute* "src/gbm/main/backend.c"