gnu: texlive-xmltex: Fix build.

* gnu/packages/tex.scm (texlive-xmltex): Remove SIMPLE-TEXLIVE-PACKAGE
call.
[arguments]: Remove unnecessary #:TEX-DIRECTORY keyword.
[native-inputs]: Add TEXLIVE-XMLTEXCONFIG.
This commit is contained in:
Nicolas Goaziou 2023-05-15 22:27:56 +02:00
parent 6c281dfe81
commit a447eb3cc8
No known key found for this signature in database
GPG key ID: DA00B4F048E92F2D

View file

@ -3726,72 +3726,82 @@ (define-public texlive-xmltexconfig
(license license:public-domain))) (license license:public-domain)))
(define-public texlive-xmltex (define-public texlive-xmltex
(let ((template (simple-texlive-package (package
"texlive-xmltex" (name "texlive-xmltex")
(list (version (number->string %texlive-revision))
"/doc/otherformats/xmltex/" (source (texlive-origin
"/tex/xmltex/") name version
(base32 (list "doc/otherformats/xmltex/base/"
"023gv9axq05vwqz50fnkig24dzahwlc4raks2s8xc4pzrv2dv1zy")))) "tex/xmltex/base/")
(package (base32
(inherit template) "1rqwsapba8zs2ijjs7lpzksm20jqb8zbmanpw7wmdp2rq26ahylh")))
(arguments (outputs '("out" "doc"))
(substitute-keyword-arguments (package-arguments template) (build-system texlive-build-system)
((#:tex-directory _ #t) (arguments
"tex/xmltex/base") (list
((#:phases phases '%standard-phases) #:phases
`(modify-phases ,phases #~(modify-phases %standard-phases
(add-before 'install 'generate-formats (add-before 'install 'generate-formats
(lambda* (#:key inputs #:allow-other-keys) (lambda _
(mkdir "web2c") (let ((web2c (string-append (getcwd) "/web2c")))
(for-each (lambda (f) (mkdir "web2c")
(copy-file f (basename f))) (with-directory-excursion "tex/xmltex/base/"
(find-files "tex" "\\.(ini|tex)$")) (invoke "fmtutil-sys"
(invoke "fmtutil-sys" "--byfmt" "xmltex" "--byfmt" "xmltex"
"--fmtdir=web2c") (string-append"--fmtdir=" web2c))
(invoke "fmtutil-sys" "--byfmt" "pdfxmltex" (invoke "fmtutil-sys"
"--fmtdir=web2c"))) "--byfmt" "pdfxmltex"
(add-after 'install 'install-formats-and-wrappers (string-append "--fmtdir=" web2c))))))
(lambda* (#:key inputs outputs #:allow-other-keys) (add-after 'install 'install-formats-and-wrappers
(let* ((out (assoc-ref outputs "out")) (lambda* (#:key inputs #:allow-other-keys)
(texlive-bin (assoc-ref inputs "texlive-bin")) (let ((pdftex (search-input-file inputs "/bin/pdftex"))
(pdftex (string-append texlive-bin "/bin/pdftex")) (web2c (string-append #$output "/share/texmf-dist/web2c")))
(web2c (string-append out "/share/texmf-dist/web2c"))) (mkdir-p web2c)
(mkdir-p web2c) (copy-recursively "web2c" web2c)
(copy-recursively "web2c" web2c) (for-each delete-file (find-files web2c "\\.log$"))
;; Create convenience command wrappers. ;; Create convenience command wrappers.
(mkdir-p (string-append out "/bin")) (mkdir-p (string-append #$output "/bin"))
(symlink pdftex (string-append out "/bin/xmltex")) (symlink pdftex (string-append #$output "/bin/xmltex"))
(symlink pdftex (string-append out "/bin/pdfxmltex")) (symlink pdftex (string-append #$output "/bin/pdfxmltex"))))))))
#t))))))) (native-inputs
(propagated-inputs (list texlive-tex-ini-files
;; The following fonts are propagated as a texlive-updmap.cfg as the font texlive-xmltexconfig))
;; maps need to be recreated for the fonts to be usable. They are (propagated-inputs
;; required by xmltex through mlnames.sty and unicode.sty. (list (texlive-updmap.cfg
`(("texlive" ,(texlive-updmap.cfg (list texlive-amsfonts
(list texlive-babel
texlive-amsfonts texlive-courier
texlive-babel texlive-helvetic
texlive-courier texlive-hyperref
texlive-helvetic texlive-latex-fonts
texlive-hyperref texlive-stmaryrd
texlive-symbol texlive-symbol
texlive-tipa texlive-times
texlive-times texlive-tipa
texlive-zapfding texlive-wasy
;; The following fonts, while not required, are used if texlive-zapfding))
;; available: texlive-atbegshi
texlive-stmaryrd texlive-atveryend
texlive-wasy))))) texlive-babel
(native-inputs texlive-cm
(list texlive-tex-ini-files)) texlive-dehyph
(home-page "https://www.ctan.org/pkg/xmltex/") texlive-everyshi
(synopsis "Support for parsing XML documents") texlive-firstaid
(description "The package provides an implementation of a parser for texlive-hyph-utf8
documents matching the XML 1.0 and XML Namespace Recommendations. Element and texlive-hyphen-base
attribute names, as well as character data, may use any characters allowed in texlive-l3backend
XML, using UTF-8 or a suitable 8-bit encoding.") texlive-l3kernel
(license license:lppl1.0+)))) ;per xmltex/base/readme.txt texlive-l3packages
texlive-tex-ini-files
texlive-xmltexconfig))
(home-page "https://ctan.org/pkg/xmltex")
(synopsis "Support for parsing XML documents")
(description
"The package provides an implementation of a parser for documents
matching the XML 1.0 and XML Namespace Recommendations. Element and attribute
names, as well as character data, may use any characters allowed in XML, using
UTF-8 or a suitable 8-bit encoding.")
(license license:lppl1.0+))) ;per xmltex/base/readme.txt
(define-public texlive-hyperref (define-public texlive-hyperref
(let ((template (simple-texlive-package (let ((template (simple-texlive-package