[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
11/72: gnu: texlive-latex-bin: Create symlinks for "latex" variants.
From: |
guix-commits |
Subject: |
11/72: gnu: texlive-latex-bin: Create symlinks for "latex" variants. |
Date: |
Mon, 3 Jun 2024 08:59:42 -0400 (EDT) |
ngz pushed a commit to branch tex-team
in repository guix.
commit 26fbfe7f9597657ef995b916dc0853e3bb9ae267
Author: Nicolas Goaziou <mail@nicolasgoaziou.fr>
AuthorDate: Thu May 30 23:45:32 2024 +0200
gnu: texlive-latex-bin: Create symlinks for "latex" variants.
* gnu/packages/tex.scm (texlive-latex-bin)[arguments]<#:phases>: Create
symlinks for "latex" variants.
* gnu/packages/tex.scm (texlive-bin)[arguments]<#:phases>: Remove symlink
creation.
Change-Id: Ib4f1b05082572e8ccb7f5dd5531ed30cf404ce29
---
gnu/packages/tex.scm | 43 +++++++++++++++++++++++++++----------------
1 file changed, 27 insertions(+), 16 deletions(-)
diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm
index da1a282008..56c23c619f 100644
--- a/gnu/packages/tex.scm
+++ b/gnu/packages/tex.scm
@@ -781,23 +781,20 @@ and should be preferred to it whenever a package would
otherwise depend on
(("/usr/include /usr/local/include")
(string-append #$(this-package-input "texlive-libkpathsea")
"/include"))))))
- (add-after 'install 'maybe-create-symlinks
- ;; Create symbolic links for the latex variants. We link lualatex
- ;; to luahbtex; see issue #51252 for details.
+ (add-after 'install 'maybe-clear-symlinks
+ ;; XXX: No matter the combination of configure flags, process
+ ;; insists on creating those dangling links, resulting in an error
+ ;; during `validate-runpath' phase.
;;
- ;; Make it conditional so packages inheriting from this one do not
- ;; need to remove this phase.
+ ;; Make it specific to TEXLIVE-BIN package by verifying the
+ ;; existence of "tex" binary so that packages inheriting from this
+ ;; one do not need to remove the phase.
(lambda _
- (with-directory-excursion (string-append #$output "/bin/")
- (when (file-exists? "tex") ;for TEXLIVE-BIN only
- (for-each symlink
- '("pdftex" "pdftex" "luahbtex")
- '("latex" "pdflatex" "lualatex"))
- ;; XXX: No matter the combination of configure flags,
- ;; process insists on creating those dangling links,
- ;; resulting in an error during `validate-runpath' phase.
- (for-each delete-file
- '("pbibtex" "pdvitype" "ppltotf" "ptftopl"))))))
+ (let ((bin (string-append #$output "/bin/")))
+ (when (file-exists? (string-append bin "tex"))
+ (with-directory-excursion bin
+ (for-each delete-file
+ '("pbibtex" "pdvitype" "ppltotf" "ptftopl")))))))
(add-after 'install 'remove-documentation
;; Documentation is provided by specific TeX Live packages, in
;; a dedicated "doc" output. Ignore documentation generated when
@@ -46001,7 +45998,21 @@ formats.")
(arguments
(list
#:texlive-latex-bin? #f
- #:create-formats #~(list "dvilualatex" "latex" "lualatex" "pdflatex")))
+ #:create-formats #~(list "dvilualatex" "latex" "lualatex" "pdflatex")
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-after 'install 'symlink-binaries
+ ;; Create symbolic links for the latex variants. We link lualatex
+ ;; to luahbtex; see issue #51252 for details.
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((pdftex (search-input-file inputs "bin/pdftex"))
+ (luahbtex (search-input-file inputs "bin/luahbtex"))
+ (bin (string-append #$output "/bin")))
+ (mkdir-p bin)
+ (with-directory-excursion bin
+ (symlink pdftex "latex")
+ (symlink pdftex "pdflatex")
+ (symlink luahbtex "lualatex"))))))))
(propagated-inputs
(list texlive-atbegshi
texlive-atveryend
- 01/72: gnu: texlive-libkpathsea: Fix TEXMFCACHE location., (continued)
- 01/72: gnu: texlive-libkpathsea: Fix TEXMFCACHE location., guix-commits, 2024/06/03
- 02/72: gnu: texlive-libkpathsea: Remove duplicate documentation., guix-commits, 2024/06/03
- 03/72: gnu: Add texlive-source., guix-commits, 2024/06/03
- 05/72: gnu: texlive-libkpathsea: Better default values in "texmf.cnf"., guix-commits, 2024/06/03
- 04/72: gnu: texlive-libkpathsea: Use TEXLIVE-SOURCE., guix-commits, 2024/06/03
- 06/72: gnu: texlive-luatex: Set proper default values for "texmfcnf.lua"., guix-commits, 2024/06/03
- 07/72: gnu: texlive-context: Fix "context" call., guix-commits, 2024/06/03
- 08/72: gnu: Add texlive-libptexenc., guix-commits, 2024/06/03
- 09/72: gnu: texlive-bin: Minimize build surface., guix-commits, 2024/06/03
- 10/72: gnu: tex.scm: Remove completed TODO., guix-commits, 2024/06/03
- 11/72: gnu: texlive-latex-bin: Create symlinks for "latex" variants.,
guix-commits <=
- 12/72: gnu: Add texlive-mfware-bin., guix-commits, 2024/06/03
- 13/72: gnu: Add texlive-omegaware-bin., guix-commits, 2024/06/03
- 15/72: gnu: Add texlive-texware-bin., guix-commits, 2024/06/03
- 17/72: gnu: Add texlive-uptex-bin., guix-commits, 2024/06/03
- 16/72: gnu: Add texlive-patgen-bin., guix-commits, 2024/06/03
- 14/72: gnu: Add texlive-fontware-bin., guix-commits, 2024/06/03
- 19/72: gnu: Add texlive-bibtex-bin., guix-commits, 2024/06/03
- 18/72: gnu: Add texlive-ptex-bin., guix-commits, 2024/06/03
- 21/72: gnu: Add texlive-dvipdfmx-bin., guix-commits, 2024/06/03
- 20/72: gnu: Add texlive-dvicopy-bin., guix-commits, 2024/06/03