diff options
author | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2023-07-17 12:08:05 +0200 |
---|---|---|
committer | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2023-07-18 18:18:25 +0200 |
commit | 6f48c2b28a73d4e255ab652685d6dff6992ba8ad (patch) | |
tree | 1707333aadf5210d95f8ffa560867e3f7665afc0 | |
parent | 1dc79714296c5931c61ae0a70b786ce3b7591e28 (diff) | |
download | guix-6f48c2b28a73d4e255ab652685d6dff6992ba8ad.tar.gz guix-6f48c2b28a73d4e255ab652685d6dff6992ba8ad.zip |
gnu: texlive-xindy: Fix package.
This change reverts 81718f27fd0153c8637b0ce13fe5540c0085988c.
* gnu/packages/tex.scm (texlive-xindy)[build-system]: Use GNU-BUILD-SYSTEM.
[arguments]: Derive from texlive-libkpathsea's. Add a custom install phase.
-rw-r--r-- | gnu/packages/tex.scm | 61 |
1 files changed, 36 insertions, 25 deletions
diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index aeb7c5ccfa..6b1c45a699 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -22442,40 +22442,51 @@ handle complex tests.") (define-public texlive-xindy (package + ;; Texmf tree in TeX Live is incomplete, as it doesn't include + ;; "xindy.mem", so it is not possible to use `texlive-origin'. This file + ;; isn't build by default by `texlive-bin' either. Build it specially + ;; from `texlive-bin' source instead. + (inherit texlive-libkpathsea) (name "texlive-xindy") (version (number->string %texlive-revision)) - (source (texlive-origin - name version - (list "doc/man/man1/tex2xindy.1" - "doc/man/man1/tex2xindy.man1.pdf" - "doc/man/man1/texindy.1" - "doc/man/man1/texindy.man1.pdf" - "doc/man/man1/xindy.1" - "doc/man/man1/xindy.man1.pdf" - "doc/xindy/" - "scripts/xindy/" - "xindy/") - (base32 - "12j2bi0wwp1hyxr1427hhigqmhsd1fyg90bvghxkm1qck85r24vf"))) (outputs '("out" "doc")) - (build-system texlive-build-system) + (build-system gnu-build-system) (arguments - (list - #:link-scripts #~(list "texindy.pl" "xindy.pl") - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'patch-inputs - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "scripts/xindy/" + (substitute-keyword-arguments (package-arguments texlive-libkpathsea) + ((#:out-of-source? _ #t) #t) + ((#:configure-flags flags) + #~(cons "--enable-xindy" (delete "--enable-kpathsea" #$flags))) + ((#:phases _) + #~(modify-phases %standard-phases + (replace 'install + (lambda _ + (with-directory-excursion "utils/xindy/" + (invoke "make") + (mkdir-p (string-append #$output "/bin")) + (invoke "make" "install") + (let ((out (string-append #$output "/share")) + (doc (string-append #$output:doc "/share/texmf-dist"))) + (mkdir-p doc) + (with-directory-excursion doc + (rename-file (string-append out "/texmf-dist/doc") "doc") + (rename-file (string-append out "/man") "doc/man")))))) + (add-after 'install 'patch-clisp-location + (lambda* (#:key inputs #:allow-other-keys) ;; The scripts are encoded in ISO-8859-1 (or iso-latin-1). (with-fluids ((%default-port-encoding "ISO-8859-1")) - (substitute* (list "texindy.pl" "xindy.pl") + (substitute* (find-files #$output "xindy\\.pl$") (("our \\$clisp = .*") (format #f "our $clisp = ~s;~%" - (search-input-file inputs "/bin/clisp"))) - (("/usr/bin/env perl") - (search-input-file inputs "/bin/perl")))))))))) + (search-input-file inputs "/bin/clisp"))))))))))) + (native-inputs + (list clisp + (texlive-updmap.cfg + (list texlive-cbfonts-fd + texlive-cyrillic + texlive-greek-fontenc + texlive-lh)))) (inputs (list clisp perl)) + (native-search-paths '()) (home-page "https://ctan.org/pkg/xindy") (synopsis "General-purpose index processor") (description |