guix: Add guard to texlive-configuration profile hook.
It is possible to generate a profile where this hook will crash, as the texmf.cnf file does not exist to be patched by substitute*. A simple example is the profile just containing texlive-fonts-txfonts. * guix/profiles.scm (texlive-configuration): Check that the texmf.cnf file exists before trying to change it.
This commit is contained in:
parent
6654f8c144
commit
cf22e99f02
|
@ -1363,12 +1363,15 @@ MANIFEST."
|
|||
(manifest-entries manifest))
|
||||
#:create-all-directories? #t
|
||||
#:log-port (%make-void-port "w"))
|
||||
(substitute* (string-append #$output
|
||||
"/share/texmf-dist/web2c/texmf.cnf")
|
||||
(("^TEXMFROOT = .*")
|
||||
(string-append "TEXMFROOT = " #$output "/share\n"))
|
||||
(("^TEXMF = .*")
|
||||
"TEXMF = $TEXMFROOT/share/texmf-dist\n"))
|
||||
(let ((texmf.cnf (string-append
|
||||
#$output
|
||||
"/share/texmf-dist/web2c/texmf.cnf")))
|
||||
(when (file-exists? texmf.cnf)
|
||||
(substitute* texmf.cnf
|
||||
(("^TEXMFROOT = .*")
|
||||
(string-append "TEXMFROOT = " #$output "/share\n"))
|
||||
(("^TEXMF = .*")
|
||||
"TEXMF = $TEXMFROOT/share/texmf-dist\n"))))
|
||||
#t)))
|
||||
|
||||
(with-monad %store-monad
|
||||
|
|
Loading…
Reference in New Issue