mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-28 15:22:18 -05:00
profiles: texlive-configuration: Handle updmap.cfg conflict.
The profile hook would fail when preparing an environment for a package using texlive-union, because the union already had a updmap.cfg file. Reported-by: Lars-Dominik Braun <ldb@leibniz-psychology.org>. * guix/profiles.scm (texlive-configuration): Delete updmap.cfg if it exists.
This commit is contained in:
parent
0f116d7f90
commit
56e4d7204b
1 changed files with 11 additions and 4 deletions
|
@ -1712,11 +1712,18 @@ (define build
|
||||||
(setenv "TEXMF" (string-append #$output "/share/texmf-dist"))
|
(setenv "TEXMF" (string-append #$output "/share/texmf-dist"))
|
||||||
|
|
||||||
;; Remove invalid maps from config file.
|
;; Remove invalid maps from config file.
|
||||||
(let ((web2c (string-append #$output "/share/texmf-config/web2c/"))
|
(let* ((web2c (string-append #$output "/share/texmf-config/web2c/"))
|
||||||
(maproot (string-append #$output "/share/texmf-dist/fonts/map/")))
|
(maproot (string-append #$output "/share/texmf-dist/fonts/map/"))
|
||||||
|
(updmap.cfg (string-append web2c "updmap.cfg")))
|
||||||
(mkdir-p web2c)
|
(mkdir-p web2c)
|
||||||
(copy-file #$updmap.cfg (string-append web2c "updmap.cfg"))
|
|
||||||
(make-file-writable (string-append web2c "updmap.cfg"))
|
;; Some profiles may already have this file, which prevents us
|
||||||
|
;; from copying it. Since we need to generate it from scratch
|
||||||
|
;; anyway, we delete it here.
|
||||||
|
(when (file-exists? updmap.cfg)
|
||||||
|
(delete-file updmap.cfg))
|
||||||
|
(copy-file #$updmap.cfg updmap.cfg)
|
||||||
|
(make-file-writable updmap.cfg)
|
||||||
(let* ((port (open-pipe* OPEN_WRITE
|
(let* ((port (open-pipe* OPEN_WRITE
|
||||||
#$(file-append texlive-bin "/bin/updmap-sys")
|
#$(file-append texlive-bin "/bin/updmap-sys")
|
||||||
"--syncwithtrees"
|
"--syncwithtrees"
|
||||||
|
|
Loading…
Reference in a new issue