summary refs log tree commit diff
path: root/gnu/packages/tex.scm
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/tex.scm')
-rw-r--r--gnu/packages/tex.scm253
1 files changed, 252 insertions, 1 deletions
diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm
index 40accf642d..b40e72c582 100644
--- a/gnu/packages/tex.scm
+++ b/gnu/packages/tex.scm
@@ -6,7 +6,7 @@
 ;;; Copyright © 2016, 2018, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2016 Federico Beffa <beffa@fbengineering.ch>
 ;;; Copyright © 2016 Thomas Danckaert <post@thomasdanckaert.be>
-;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021, 2022 Ricardo Wurmus <rekado@elephly.net>
+;;; Copyright © 2016-2023 Ricardo Wurmus <rekado@elephly.net>
 ;;; Copyright © 2017 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2017, 2020, 2021 Marius Bakke <marius@gnu.org>
 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
@@ -24,6 +24,7 @@
 ;;; Copyright © 2022 Fabio Natali <me@fabionatali.com>
 ;;; Copyright © 2022 Philip McGrath <philip@philipmcgrath.com>
 ;;; Copyright © 2023 Thomas Albers Raviola <thomas@thomaslabs.org>
+;;; Copyright © 2023 John Kehayias <john.kehayias@protonmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -740,6 +741,37 @@ the autogenerated files @file{language.dat} and @file{language.def} (and
 default versions of those), etc.")
     (license license:knuth)))
 
+(define-public texlive-dvipdfmx
+  (let ((template (simple-texlive-package
+                   "texlive-dvipdfmx"
+                   (list "doc/dvipdfm/"
+                         "doc/dvipdfmx/"
+                         "doc/man/man1/"
+                         "dvipdfmx/"
+                         "fonts/cmap/dvipdfmx/"
+                         "fonts/map/dvipdfmx/")
+                   (base32
+                    "04x93w777l9qzdzglwanb14k8cmq74kjcsgyanvp3bsmnn5zfrgz")
+                   #:trivial? #t)))
+    (package
+      (inherit template)
+      (source
+       (origin
+         (inherit (package-source template))
+         ;; This map file is supposed to be generated in a profile hook.
+         (snippet '(delete-file "fonts/map/dvipdfmx/updmap/kanjix.map"))))
+      (propagated-inputs (list texlive-glyphlist))
+      (home-page "https://www.tug.org/texlive/")
+      (synopsis "Extended version of dvipdfm")
+      (description
+       "Dvipdfmx (formerly dvipdfm-cjk) is a development of dvipdfm created to
+support multi-byte character encodings and large character sets for East Asian
+languages.  Dvipdfmx, if \"called\" with the name dvipdfm, operates in a
+\"dvipdfm compatibility\" mode, so that users of the both packages need only
+keep one executable.  A secondary design goal is to support as many \"PDF\"
+features as does pdfTeX.")
+      (license license:gpl3+))))
+
 (define-public texlive-dvips
   (package
     (inherit (simple-texlive-package
@@ -1623,6 +1655,60 @@ described in the TeXbook, together with various supporting files (some also
 discussed in the book).")
     (license license:knuth)))
 
+(define-public texlive-halloweenmath
+  (let ((template (simple-texlive-package
+                   "texlive-halloweenmath"
+                   (list "doc/latex/halloweenmath/"
+                         "source/latex/halloweenmath/"
+                         "tex/latex/halloweenmath/")
+                   (base32
+                    "1xq72k1p820b5q3haxf936g69p6gv34hr30870l96jnxa3ad7y05"))))
+    (package
+      (inherit template)
+      (outputs '("out" "doc"))
+      (arguments
+       (substitute-keyword-arguments (package-arguments template)
+         ((#:tex-directory _ #t) "latex/halloweenmath")
+         ((#:build-targets _ '()) '(list "halloweenmath.ins"))
+         ((#:phases phases)
+          #~(modify-phases #$phases
+              (add-after 'unpack 'chdir
+                (lambda _ (chdir "source/latex/halloweenmath/")))
+              (add-after 'chdir 'non-interactive-build
+                ;; When it realizes it cannot employ the usedir directive, the
+                ;; build process stops and waits for an input before inserting
+                ;; generated files in the working directory.  Do not ask for
+                ;; an input.
+                (lambda _
+                  (substitute* "halloweenmath.ins"
+                    (("\\Ask.*") "")
+                    (("\\(your .*? will be ignored\\).*") ""))))
+              (replace 'copy-files
+                (lambda* (#:key inputs #:allow-other-keys)
+                  (let ((origin (assoc-ref inputs "source"))
+                        (source (string-append #$output
+                                               "/share/texmf-dist/source"))
+                        (doc (string-append #$output:doc
+                                            "/share/texmf-dist/doc")))
+                    (copy-recursively (string-append origin "/source") source)
+                    (copy-recursively (string-append origin "/doc") doc))))))))
+      (native-inputs
+       (list texlive-bin
+             texlive-kpathsea
+             (texlive-updmap.cfg)))     ;for psfonts.map
+      (propagated-inputs
+       (list texlive-amsmath texlive-pict2e))
+      (home-page "https://ctan.org/pkg/halloweenmath")
+      (synopsis "Scary and creepy math symbols with AMS-LaTeX integration")
+      (description
+       "The package defines a handful of commands for typesetting mathematical
+symbols of various kinds, ranging from large operators to extensible
+arrow-like relations and growing arrow-like math accents that all draw from
+the classic Halloween-related iconography (pumpkins, witches, ghosts, cats,
+and so on) while being, at the same time, seamlessly integrated within the
+rest of the mathematics produced by (AmS-)LaTeX.")
+      (license license:lppl1.3+))))
+
 (define-public texlive-hardwrap
   (package
     (inherit (simple-texlive-package
@@ -3212,6 +3298,22 @@ verbatim mode; build \"example\" environments (showing both result and
 verbatim source).")
     (license license:lppl1.0+)))
 
+(define-public texlive-glyphlist
+  (package
+    (inherit (simple-texlive-package
+              "texlive-glyphlist"
+              (list "fonts/map/glyphlist/")
+              (base32
+               "12nmmyh77vr2622lzi11nm1z1k2bxs7jz018yl4rwjlpg0sxg1ja")
+              #:trivial? #t))
+    (home-page "https://www.tug.org/texlive/")
+    (synopsis "Adobe glyph list and TeX extensions")
+    (description
+     "This package provides a map between traditional Adobe glyph names and
+Unicode points; it is maintained by Adobe.  The additional
+@file{texglyphlist.txt} is maintained as part of lcdf-typetools.")
+    (license license:asl2.0)))
+
 (define-public texlive-graphics-def
   (package
     (inherit (simple-texlive-package
@@ -4391,6 +4493,55 @@ T2* and X2 encodings. These encodings cover (between them) pretty much every
 language that is written in a Cyrillic alphabet.")
     (license license:lppl1.3c+)))
 
+(define-public texlive-pict2e
+  (let ((template (simple-texlive-package
+                   "texlive-pict2e"
+                   (list "doc/latex/pict2e/"
+                         "source/latex/pict2e/"
+                         "tex/latex/pict2e/")
+                   (base32
+                    "0pazv1khsgjhxc673qrhjrbzlkgmcj53qccb9hw7ygdajxrjc2ba"))))
+    (package
+      (inherit template)
+      (arguments
+       (substitute-keyword-arguments (package-arguments template)
+         ((#:tex-directory _ #t) "latex/pict2e")
+         ((#:build-targets _ '()) '(list "pict2e.ins"))
+         ((#:phases phases)
+          #~(modify-phases #$phases
+              (add-after 'unpack 'chdir
+                (lambda _ (chdir "source/latex/pict2e/")))
+              (add-after 'build 'build-doc
+                (lambda _
+                  (copy-file "p2e-drivers.dtx" "build/p2e-drivers.dtx")
+                  (with-directory-excursion "build"
+                    (invoke "pdflatex" "p2e-drivers.dtx")
+                    (delete-file "p2e-drivers.dtx")
+                    ;; texlive.tlpbd expects a "pict2e.cfg" configuration file
+                    ;; instead of "pict2e-example.cfg".  Please it.
+                    (rename-file "pict2e-example.cfg" "pict2e.cfg"))))
+              (replace 'copy-files
+                (lambda* (#:key inputs #:allow-other-keys)
+                  (let ((origin (assoc-ref inputs "source"))
+                        (source (string-append #$output
+                                               "/share/texmf-dist/source"))
+                        (doc (string-append #$output:doc
+                                            "/share/texmf-dist/doc")))
+                    (copy-recursively (string-append origin "/source") source)
+                    (copy-recursively (string-append origin "/doc") doc))))))))
+      (home-page "https://ctan.org/pkg/pict2e")
+      (native-inputs
+       (list (texlive-updmap.cfg)))
+      (synopsis "New implementation of picture commands")
+      (description
+       "This package extends the existing LaTeX @code{picture} environment,
+using the familiar technique (the @code{graphics} and @code{color} packages)
+of driver files (at present, drivers for dvips, pdfTeX, LuaTeX, XeTeX, VTeX,
+dvipdfm, and dvipdfmx are available).  The package documentation has a fair
+number of examples of use, showing where things are improved by comparison
+with the LaTeX @code{picture} environment.")
+      (license license:lppl1.3+))))
+
 (define-public texlive-psnfss
   (let ((template (simple-texlive-package
                    "texlive-psnfss"
@@ -5016,6 +5167,44 @@ corresponding italics: light, regular, medium, bold, ...")
     (license (list license:lppl
                    license:silofl1.1))))
 
+(define-public texlive-firstaid
+  (let ((template (simple-texlive-package
+                   "texlive-firstaid"
+                   (list "/doc/latex/firstaid/"
+                         "/source/latex/firstaid/"
+                         "/tex/latex/firstaid/")
+                   (base32
+                    "1ahn47kz8a2qdmzdfdgjanf6h5bn8f2rzp1zvwgjpk1plcix8k90"))))
+    (package
+      (inherit template)
+      (arguments
+       (substitute-keyword-arguments (package-arguments template)
+         ((#:tex-directory _ #t) "tex/latex/firstaid")
+         ((#:build-targets _ '()) '(list "firstaid.ins"))
+         ((#:phases phases)
+          #~(modify-phases #$phases
+              (add-after 'unpack 'chdir
+                (lambda _ (chdir "source/latex/firstaid/")))
+              (replace 'copy-files
+                (lambda* (#:key inputs #:allow-other-keys)
+                  (let ((origin (assoc-ref inputs "source"))
+                        (source (string-append #$output
+                                               "/share/texmf-dist/source"))
+                        (doc (string-append #$output:doc
+                                            "/share/texmf-dist/doc")))
+                    (copy-recursively (string-append origin "/source") source)
+                    (copy-recursively (string-append origin "/doc") doc))))))))
+      (home-page "https://ctan.org/macros/latex/required/firstaid")
+      (synopsis
+       "First aid for external LaTeX files and packages that need updating")
+      (description
+       "This package contains some first aid for LaTeX packages or classes
+that require updates because of internal changes to the LaTeX kernel that are
+not yet reflected in the package's or class's code.  The file
+@file{latex2e-first-aid-for-external-files.ltx} provided by this package is
+meant to be loaded during format generation and not by the user.")
+      (license license:lppl1.3c))))
+
 (define-public texlive-latex-ifplatform
   (package
     (name "texlive-latex-ifplatform")
@@ -11269,6 +11458,24 @@ family and SGML-based languages.  Xindy is highly configurable, both in markup
 terms and in terms of the collating order of the text being processed.")
     (license license:gpl2+)))
 
+(define-public texlive-nth
+  (package
+    (inherit (simple-texlive-package
+              "texlive-nth"
+              (list "tex/generic/nth/")
+              (base32
+               "0716sd99xjdkplm7jdmg4lx8lpfnnx6mxjp1l1sp2bfqcg73p4hm")
+              #:trivial? #t))
+    (home-page "https://ctan.org/macros/generic/misc/nth.sty")
+    (synopsis "Generate English ordinal numbers")
+    (description
+     "The command @code{\\nth{<number>}} generates English ordinal numbers of
+the form 1st, 2nd, 3rd, 4th, etc.  LaTeX package options may specify that the
+ordinal mark be superscripted, and that negative numbers may be treated; Plain
+TeX users have no access to package options, so need to redefine macros for
+these changes.")
+    (license license:public-domain)))
+
 (define-public texlive-fmtcount
   (package
     (inherit (simple-texlive-package
@@ -12307,6 +12514,50 @@ interest.  Since most such counters are simply incremented when they are
 changed, the recorded value will usually be the maximum value.")
     (license license:lppl1.3c+)))
 
+(define-public texlive-xetex
+  (package
+    (inherit (simple-texlive-package
+              "texlive-xetex"
+              (list "/doc/man/man1/xetex.1"
+                    "/doc/man/man1/xelatex.1"
+                    "/doc/xetex/base/"
+                    "/fonts/misc/xetex/fontmapping/base/"
+                    "/tex/xelatex/xetexconfig/")
+              (base32
+               "1gmgagvsv2qknrjzjk840ca3wging8wfc20rgq7bnhphm9n87m6q")
+              #:trivial? #t))
+    (propagated-inputs
+     (list texlive-generic-atbegshi
+           texlive-latex-atveryend
+           texlive-babel
+           texlive-cm
+           texlive-dvipdfmx
+           texlive-etex
+           texlive-everyshi
+           texlive-firstaid
+           texlive-hyphen-base
+           texlive-latex-base
+           texlive-fonts-latex
+           texlive-latex-l3backend
+           texlive-latex-l3kernel
+           texlive-latex-l3packages
+           texlive-lm
+           texlive-tex-ini-files
+           texlive-tex-plain
+           texlive-unicode-data))
+    (home-page "https://www.tug.org/texlive/")
+    (synopsis "Extended variant of TeX for use with Unicode sources")
+    (description
+     "XeTeX is a TeX typesetting engine using Unicode and supporting modern font
+technologies such as OpenType, TrueType or Apple Advanced Typography (AAT),
+including OpenType mathematics fonts.  XeTeX supports many extensions that
+reflect its origins in linguistic research; it also supports micro-typography
+(as available in pdfTeX).  XeTeX was developed by the SIL (the first version
+was specifically developed for those studying linguistics, and using Macintosh
+computers).  XeTeX's immediate output is an extended variant of DVI format,
+which is ordinarily processed by a tightly bound processor (called
+@code{xdvipdfmx}), that produces PDF.")
+    (license license:x11)))
 ;;;
 ;;; Avoid adding new packages to the end of this file. To reduce the chances
 ;;; of a merge conflict, place them above by existing packages with similar