gnu: ungoogled-chromium: Generalize OpenJPEG substitution.

* gnu/packages/chromium.scm (ungoogled-chromium)[arguments]: Don't hard code
openjpeg version.
This commit is contained in:
Marius Bakke 2022-09-17 18:00:27 +02:00
parent 1a8d063a44
commit 503fb0dcb4
No known key found for this signature in database
GPG key ID: A2A06DF2A33A54FA

View file

@ -613,11 +613,12 @@ (define-public ungoogled-chromium
#~(modify-phases %standard-phases
(add-after 'unpack 'patch-stuff
(lambda* (#:key inputs #:allow-other-keys)
(let ((openjpeg (search-input-directory
inputs "include/openjpeg-2.4")))
(let* ((libopenjp2 (search-input-file inputs "lib/libopenjp2.so"))
(openjpeg (dirname (dirname libopenjp2))))
(substitute* "third_party/pdfium/BUILD.gn"
;; This include path is added by Debians openjpeg patch.
(("/usr/include/openjpeg-2.4") openjpeg))
(("/usr/include/openjpeg-")
(string-append openjpeg "/include/openjpeg-")))
;; Adjust minizip header inclusions.
(substitute* (find-files "third_party/tflite_support\