[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
05/15: gnu: texlive-union: Fix font map generation.
From: |
guix-commits |
Subject: |
05/15: gnu: texlive-union: Fix font map generation. |
Date: |
Thu, 5 Sep 2019 16:26:25 -0400 (EDT) |
rekado pushed a commit to branch wip-texlive
in repository guix.
commit ea53b85fbb367e6fc4ab4b59e5273086c2c81d2a
Author: Ricardo Wurmus <address@hidden>
Date: Thu Sep 5 21:14:09 2019 +0200
gnu: texlive-union: Fix font map generation.
* gnu/packages/tex.scm (texlive-union)[arguments]: Exclude sed and coreutils
from union; add sed to the PATH; run updmap-sys twice; delete ls-R to avoid
lookup failures.
---
gnu/packages/tex.scm | 42 +++++++++++++++++++++++++++++++-----------
1 file changed, 31 insertions(+), 11 deletions(-)
diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm
index 9676132..35f04d1 100644
--- a/gnu/packages/tex.scm
+++ b/gnu/packages/tex.scm
@@ -3567,7 +3567,10 @@ standard LaTeX packages."
;; the updmap.cfg file)
(match (filter (match-lambda
((name . _)
- (not (member name '("bash" "updmap.cfg")))))
+ (not (member name '("bash"
+ "coreutils"
+ "sed"
+ "updmap.cfg")))))
%build-inputs)
(((names . directories) ...)
(union-build (assoc-ref %outputs "out")
@@ -3587,6 +3590,7 @@ standard LaTeX packages."
(setenv "PATH" (string-append
(assoc-ref %build-inputs "bash") "/bin:"
(assoc-ref %build-inputs "coreutils") "/bin:"
+ (assoc-ref %build-inputs "sed") "/bin:"
(string-append out "/bin")))
(for-each
(cut wrap-program <>
@@ -3595,16 +3599,32 @@ standard LaTeX packages."
(find-files (string-append out "/bin") ".*"))
;; Remove invalid maps from config file.
- (let ((port (open-pipe* OPEN_WRITE "updmap-sys"
- "--syncwithtrees"
- "--nohash"
- (assoc-ref %build-inputs
"updmap.cfg"))))
- (display "Y\n" port)
- (when (not (zero? (status:exit-val (close-pipe port))))
- (error "failed to filter updmap.cfg")))
- ;; Generate maps.
- (invoke "updmap-sys" "--force"
- (string-append out
"/share/texmf-config/web2c/updmap.cfg"))
+ (let ((web2c (string-append out "/share/texmf-config/web2c/"))
+ (maproot (string-append out
"/share/texmf-dist/fonts/map/")))
+ (mkdir-p web2c)
+ (copy-file
+ (assoc-ref %build-inputs "updmap.cfg")
+ (string-append web2c "updmap.cfg"))
+ (make-file-writable (string-append web2c "updmap.cfg"))
+
+ (let* ((port (open-pipe* OPEN_WRITE "updmap-sys"
+ "--syncwithtrees"
+ "--nohash"
+ (string-append "--cnffile=" web2c
"updmap.cfg"))))
+ (display "Y\n" port)
+ (when (not (zero? (status:exit-val (close-pipe port))))
+ (error "failed to filter updmap.cfg")))
+ ;; Generate maps.
+ (invoke "updmap-sys"
+ (string-append "--cnffile=" web2c "updmap.cfg")
+ (string-append "--dvipdfmxoutputdir="
+ maproot "dvipdfmx/updmap/")
+ (string-append "--dvipsoutputdir="
+ maproot "dvips/updmap/")
+ (string-append "--pdftexoutputdir="
+ maproot "pdftex/updmap/"))
+ ;; Having this file breaks all file lookups later.
+ (delete-file (string-append out "/share/texmf-dist/ls-R")))
#t))))
(inputs
`(("bash" ,bash)
- branch wip-texlive created (now 65a3324), guix-commits, 2019/09/05
- 03/15: gnu: texlive-fonts-iwona: Use double spacing in description., guix-commits, 2019/09/05
- 02/15: gnu: Add texlive-xcolor., guix-commits, 2019/09/05
- 05/15: gnu: texlive-union: Fix font map generation.,
guix-commits <=
- 09/15: gnu: Add texlive-iftex., guix-commits, 2019/09/05
- 12/15: gnu: Add texlive-standalone., guix-commits, 2019/09/05
- 04/15: gnu: vigra-c: Update to 0.0.0-1.66ff4fa., guix-commits, 2019/09/05
- 06/15: gnu: Add texlive-ydoc., guix-commits, 2019/09/05
- 08/15: gnu: Add texlive-pst-text., guix-commits, 2019/09/05
- 07/15: gnu: Add texlive-pstricks., guix-commits, 2019/09/05
- 01/15: gnu: texlive-latex-base: Ensure that extra sources are installed., guix-commits, 2019/09/05
- 10/15: gnu: Add texlive-tools., guix-commits, 2019/09/05
- 13/15: gnu: Add texlive-siunitx., guix-commits, 2019/09/05
- 14/15: gnu: Add texlive-booktabs., guix-commits, 2019/09/05