aboutsummaryrefslogtreecommitdiff
path: root/guix/profiles.scm
diff options
context:
space:
mode:
authorLiliana Marie Prikler <liliana.prikler@gmail.com>2023-08-19 20:15:57 +0200
committerLiliana Marie Prikler <liliana.prikler@gmail.com>2023-08-19 20:15:57 +0200
commitf62efeff76021d205d081aaf68034a234195ae0f (patch)
tree934f969584794fba16a20b36916a8c8fd7f79fd7 /guix/profiles.scm
parent4eca7833ef0b16fb3cdda138e3ee1e5824c36e41 (diff)
parentb6b8e5004de56a55186b215b3263b39f34e8ce1d (diff)
downloadguix-f62efeff76021d205d081aaf68034a234195ae0f.tar
guix-f62efeff76021d205d081aaf68034a234195ae0f.tar.gz
Merge branch 'master' into gnome-team
Diffstat (limited to 'guix/profiles.scm')
-rw-r--r--guix/profiles.scm18
1 files changed, 14 insertions, 4 deletions
diff --git a/guix/profiles.scm b/guix/profiles.scm
index 4835def536..6fa68fc6ac 100644
--- a/guix/profiles.scm
+++ b/guix/profiles.scm
@@ -1787,6 +1787,11 @@ MANIFEST."
(cons (gexp-input thing output)
(append-map entry->texlive-input deps))
'()))))
+ (define texlive-scripts-entry?
+ (match-lambda
+ (($ <manifest-entry> name version output thing deps)
+ (or (string=? "texlive-scripts" name)
+ (any texlive-scripts-entry? deps)))))
(define texlive-inputs
(append-map entry->texlive-input (manifest-entries manifest)))
(define texlive-scripts
@@ -1815,9 +1820,12 @@ MANIFEST."
#:create-all-directories? #t
#:log-port (%make-void-port "w"))
- ;; Clear files that are going to be regenerated.
+ ;; Clear files that are going to be regenerated, or copied from
+ ;; a different place, in order to prevent failures during profile
+ ;; generation.
(with-directory-excursion "/tmp/texlive/share/texmf-dist"
- (for-each delete-file
+ (for-each (lambda (file)
+ (when (file-exists? file) (delete-file file)))
(list "fonts/map/dvipdfmx/updmap/kanjix.map"
"fonts/map/dvips/updmap/builtin35.map"
"fonts/map/dvips/updmap/download35.map"
@@ -1884,9 +1892,11 @@ MANIFEST."
(copy-recursively a b)
(invoke mktexlsr b)
(install-file (string-append b "/ls-R") a))))))
-
(with-monad %store-monad
- (if (pair? texlive-inputs)
+ ;; `texlive-scripts' brings essential files to generate font maps.
+ ;; Therefore, it must be present in the profile. This check prevents
+ ;; incomplete modular TeX Live installations to generate errors.
+ (if (any texlive-scripts-entry? (manifest-entries manifest))
(gexp->derivation "texlive-font-maps" build
#:substitutable? #f
#:local-build? #t