diff options
author | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2023-05-19 23:27:38 +0200 |
---|---|---|
committer | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2023-07-18 18:12:39 +0200 |
commit | 31cd9a50402ac64e83fce35a7c789613d6ad156a (patch) | |
tree | 07aa727a7803dc4725c61d141b6e45f5e924efc9 /guix | |
parent | c09a05d06cda29ee13047b5e2e969d778494b49b (diff) |
guix: import: Handle native inputs in texlive importer.
* guix/import/texlive.scm (tlpdb->package): Add TEXLIVE-METAFONT as a native
input whenever font metrics are to be generated.
* tests/texlive.scm (%fake-tlpdb): Add test data.
("texlive->guix-package, with METAFONT files"): New test.
Diffstat (limited to 'guix')
-rw-r--r-- | guix/import/texlive.scm | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/guix/import/texlive.scm b/guix/import/texlive.scm index 33a0e7d1d9..fd772d3133 100644 --- a/guix/import/texlive.scm +++ b/guix/import/texlive.scm @@ -315,6 +315,21 @@ of those files are returned that are unexpectedly installed." '((outputs '("out" "doc"))) '()) (build-system texlive-build-system) + ;; Texlive build system generates font metrics whenever a font metrics + ;; file has the same base name as a Metafont file. + ,@(or (and-let* ((runfiles (assoc-ref data 'runfiles)) + (metrics + (filter-map (lambda (f) + (and (string-suffix? ".tfm" f) + (basename f ".tfm"))) + runfiles)) + ((not (null? metrics))) + ((any (lambda (f) + (and (string-suffix? ".mf" f) + (member (basename f ".mf") metrics))) + runfiles))) + '((native-inputs (list texlive-metafont)))) + '()) ,@(match filtered-depends (() '()) (inputs |