You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

7310 lines
320 KiB

;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013, 2014, 2015, 2016 Andreas Enge <andreas@enge.fr>
;;; Copyright © 2014 Eric Bavier <bavier@member.fsf.org>
;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
;;; Copyright © 2016 Roel Janssen <roel@gnu.org>
;;; Copyright © 2016, 2018, 2019, 2020 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 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2017 Leo Famulari <leo@famulari.name>
;;; Copyright © 2017, 2020 Marius Bakke <mbakke@fastmail.com>
;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2018 Danny Milosavljevic <dannym+a@scratchpost.org>
;;; Copyright © 2018, 2020 Arun Isaac <arunisaac@systemreboot.net>
;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (gnu packages tex)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix build-system gnu)
#:use-module (guix build-system perl)
#:use-module (guix build-system python)
#:use-module (guix build-system qt)
#:use-module (guix build-system trivial)
#:use-module (guix build-system texlive)
#:use-module (guix utils)
#:use-module (guix git-download)
#:use-module (guix svn-download)
#:use-module (gnu packages)
#:use-module (gnu packages algebra)
#:use-module (gnu packages autotools)
#:use-module (gnu packages bash)
#:use-module (gnu packages boost)
#:use-module (gnu packages compression)
#:use-module (gnu packages fontutils)
#:use-module (gnu packages gd)
#:use-module (gnu packages ghostscript)
#:use-module (gnu packages graphviz)
#:use-module (gnu packages gtk)
#:use-module (gnu packages icu4c)
#:use-module (gnu packages image)
#:use-module (gnu packages libreoffice)
#:use-module (gnu packages lua)
#:use-module (gnu packages multiprecision)
#:use-module (gnu packages pdf)
#:use-module (gnu packages perl)
#:use-module (gnu packages perl-check)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages python)
#:use-module (gnu packages python-xyz)
#:use-module (gnu packages qt)
#:use-module (gnu packages ruby)
#:use-module (gnu packages shells)
#:use-module (gnu packages base)
#:use-module (gnu packages gawk)
#:use-module (gnu packages web)
#:use-module (gnu packages xml)
#:use-module (gnu packages xorg)
#:use-module (gnu packages xdisorg)
#:use-module (gnu packages texinfo)
#:use-module (ice-9 ftw)
#:use-module (ice-9 match)
#:use-module ((srfi srfi-1) #:hide (zip)))
(define* (simple-texlive-package name locations hash
#:key trivial?)
"Return a template for a simple TeX Live package with the given NAME,
downloading from a list of LOCATIONS in the TeX Live repository, and expecting
the provided output HASH. If TRIVIAL? is provided, all files will simply be
copied to their outputs; otherwise the TEXLIVE-BUILD-SYSTEM is used."
(define with-documentation?
(and trivial?
(any (lambda (location)
(string-prefix? "/doc" location))
locations)))
(package
(name name)
(version (number->string %texlive-revision))
(source (texlive-origin name version
locations hash))
(outputs (if with-documentation?
'("out" "doc")
'("out")))
(build-system (if trivial?
gnu-build-system
texlive-build-system))
(arguments
(let ((copy-files
`(lambda* (#:key outputs inputs #:allow-other-keys)
(let (,@(if with-documentation?
`((doc (string-append (assoc-ref outputs "doc")
"/share/texmf-dist/")))
'())
(out (string-append (assoc-ref outputs "out")
"/share/texmf-dist/")))
,@(if with-documentation?
'((mkdir-p doc)
(copy-recursively
(string-append (assoc-ref inputs "source") "/doc")
(string-append doc "/doc")))
'())
(mkdir-p out)
(copy-recursively (assoc-ref inputs "source") out)
,@(if with-documentation?
'((delete-file-recursively (string-append out "/doc")))
'())
#t))))
(if trivial?
`(#:tests? #f
#:phases
(modify-phases %standard-phases
(delete 'configure)
(replace 'build (const #t))
(replace 'install ,copy-files)))
`(#:phases
(modify-phases %standard-phases
(add-after 'install 'copy-files ,copy-files))))))
(home-page #f)
(synopsis #f)
(description #f)
(license #f)))
(define hyph-utf8-scripts
(origin
(method svn-fetch)
(uri (texlive-ref "generic" "hyph-utf8"))
(file-name (string-append "hyph-utf8-scripts-"
(number->string %texlive-revision)
"-checkout"))
(sha256
(base32
"0lk7shx768sxvgr85y8bnmmnj8x4bbkgpxrz3z8jp8avi33prw83"))))
(define (texlive-hyphen-package name code locations hash)
"Return a TeX Live hyphenation package with the given NAME, using source
files from LOCATIONS with expected checksum HASH. CODE is not currently in use."
(let ((parent (simple-texlive-package
name locations hash #:trivial? #t)))
(package
(inherit parent)
(arguments
(substitute-keyword-arguments (package-arguments parent)
((#:phases phases)
`(modify-phases ,phases
(replace 'build
(lambda* (#:key inputs outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(root (string-append out "/share/texmf-dist"))
(patterns
(string-append root "/tex/generic/hyph-utf8/patterns/txt/"))
(loaders
(string-append root "/tex/generic/hyph-utf8/loadhyph"))
(ptex
(string-append root "/tex/generic/hyph-utf8/patterns/ptex"))
(quote
(string-append root "/tex/generic/hyph-utf8/patterns/quote")))
(mkdir "scripts")
(copy-recursively
(assoc-ref inputs "hyph-utf8-scripts") "scripts")
;; Prepare target directories
(mkdir-p patterns)
(mkdir-p loaders)
(mkdir-p ptex)
(mkdir-p quote)
;; Generate plain patterns
(with-directory-excursion "scripts"
(substitute* "lib/tex/hyphen/path.rb"
(("^([[:blank:]]+)TeXROOT = .*" _ indent)
(string-append indent "TeXROOT = \""
(getcwd) "/..\"\n")))
(substitute* "generate-plain-patterns.rb"
;; Ruby 2 does not need this.
(("require 'unicode'") "")
;; Write directly to the output directory
(("File\\.join\\(PATH::TXT")
(string-append "File.join(\"" patterns "\""))
(("File\\.join\\(PATH::QUOTE")
(string-append "File.join(\"" quote "\"")))
(invoke "ruby" "generate-plain-patterns.rb")
;; Build pattern loaders
(substitute* "generate-pattern-loaders.rb"
(("File\\.join\\(PATH::LOADER")
(string-append "File.join(\"" loaders "\"")))
(invoke "ruby" "generate-pattern-loaders.rb")
;; Build ptex patterns
(substitute* "generate-ptex-patterns.rb"
(("File\\.join\\(PATH::PTEX")
(string-append "File.join(\"" ptex "\"")))
(invoke "ruby" "generate-ptex-patterns.rb")))))))))
(native-inputs
`(("ruby" ,ruby)
("ruby-hydra" ,ruby-hydra)
("hyph-utf8-scripts" ,hyph-utf8-scripts)))
(home-page "https://ctan.org/pkg/hyph-utf8"))))
(define texlive-extra-src
(origin
(method url-fetch)
(uri "ftp://tug.org/historic/systems/texlive/2019/texlive-20190410-extra.tar.xz")
(sha256 (base32
"13ncf2an4nlqv18lki6y2p6pcsgs1i54zqkhfwprax5j53bk70j8"))))
(define texlive-texmf-src
(origin
(method url-fetch)
(uri "ftp://tug.org/historic/systems/texlive/2019/texlive-20190410-texmf.tar.xz")
(sha256 (base32
"00n4qh9fj8v9zzy3y488hpfq1g3dnnh72y4yjsaikfcqpi59gv62"))))
(define-public texlive-bin
(package
(name "texlive-bin")
(version "20190410")
(source
(origin
(method url-fetch)
(uri (string-append "ftp://tug.org/historic/systems/texlive/2019/"
"texlive-" version "-source.tar.xz"))
(sha256
(base32
"1dfps39q6bdr1zsbp9p74mvalmy3bycihv19sb9c6kg30kprz8nj"))
(patches
(let ((arch-patch
(lambda (name revision hash)
(origin
(method url-fetch)
(uri (string-append "https://git.archlinux.org/svntogit/packages.git"
"/plain/trunk/" name "?h=packages/texlive-bin"
"&id=" revision))
(file-name (string-append "texlive-bin-" name))
(sha256 (base32 hash)))))
(arch-revision "49d7fe25e5ea63f136ebc20270c1d8fc9b00041c"))
(list
(arch-patch "pdftex-poppler0.76.patch" arch-revision
"03vc88dz37mjjyaspzv0fik2fp5gp8qv82114869akd1dhszbaax")
(search-patch "texlive-bin-poppler-0.83.patch")
(arch-patch "texlive-poppler-0.84.patch" arch-revision
"1ia6cr99krk4ipx4hdi2qdb98bh2h26mckjlpxdzrjnfhlnghksa")
(search-patch "texlive-bin-poppler-0.86.patch"))))
(modules '((guix build utils)
(ice-9 ftw)))
(snippet
'(begin
(with-directory-excursion "libs"
(let ((preserved-directories '("." ".." "lua53" "luajit")))
;; Delete bundled software, except Lua which cannot easily be
;; used as an external dependency.
(for-each delete-file-recursively
(scandir "."
(lambda (file)
(and (not (member file preserved-directories))
(eq? 'directory (stat:type (stat file)))))))))
;; TODO: Unbundle stuff in texk/dvisvgm/dvisvgm-src/libs too.
#t))))
(build-system gnu-build-system)
(inputs
`(("texlive-extra-src" ,texlive-extra-src)
("texlive-scripts"
,(origin
(method svn-fetch)
(uri (svn-reference
(url (string-append "svn://www.tug.org/texlive/tags/"
%texlive-tag "/Master/texmf-dist/"
"/scripts/texlive"))
(revision %texlive-revision)))
(file-name (string-append "texlive-scripts-"
(number->string %texlive-revision)
"-checkout"))
(sha256
(base32
"1cj04svl8bpfwjr4gqfcc04rmklz3aggrxvgj7q5bxrh7c7g18xh"))))
("cairo" ,cairo)
("fontconfig" ,fontconfig)
("fontforge" ,fontforge)
("freetype" ,freetype)
("gd" ,gd)
("gmp" ,gmp)
("ghostscript" ,ghostscript)
("graphite2" ,graphite2)
("harfbuzz" ,harfbuzz)
("icu4c" ,icu4c)
("libpaper" ,libpaper)
("libpng" ,libpng)
("libxaw" ,libxaw)
("libxt" ,libxt)
("mpfr" ,mpfr)
("perl" ,perl)
("pixman" ,pixman)
("poppler" ,poppler)
("potrace" ,potrace)
("python" ,python-2) ; incompatible with Python 3 (print syntax)
("ruby" ,ruby)
("tcsh" ,tcsh)
("teckit" ,teckit)
("zlib" ,zlib)
("zziplib" ,zziplib)))
(native-inputs
`(("pkg-config" ,pkg-config)))
(arguments
`(#:out-of-source? #t
#:configure-flags
'("--disable-static"
"--disable-native-texlive-build"
"--with-system-cairo"
"--with-system-freetype2"
"--with-system-gd"
"--with-system-gmp"
"--with-system-graphite2"
"--with-system-harfbuzz"
"--with-system-icu"
"--with-system-libgs"
"--with-system-libpaper"
"--with-system-libpng"
"--with-system-mpfr"
"--with-system-pixman"
"--with-system-poppler"
"--with-system-potrace"
"--with-system-teckit"
"--with-system-xpdf"
"--with-system-zlib"
"--with-system-zziplib")
;; Disable tests on mips64/aarch64 to cope with a failure of luajiterr.test.
;; XXX FIXME fix luajit properly on mips64 and aarch64.
#:tests? ,(let ((s (or (%current-target-system)
(%current-system))))
(not (or (string-prefix? "aarch64" s)
(string-prefix? "mips64" s))))
#:phases
(modify-phases %standard-phases
(add-after 'unpack 'configure-ghostscript-executable
;; ps2eps.pl uses the "gswin32c" ghostscript executable on Windows,
;; and the "gs" ghostscript executable on Unix. It detects Unix by
;; checking for the existence of the /usr/bin directory. Since
;; Guix System does not have /usr/bin, it is also detected as Windows.
(lambda* (#:key inputs #:allow-other-keys)
(substitute* "utils/ps2eps/ps2eps-src/bin/ps2eps.pl"
(("gswin32c") "gs"))
(substitute* "texk/texlive/linked_scripts/epstopdf/epstopdf.pl"
(("\"gs\"")
(string-append "\"" (assoc-ref inputs "ghostscript") "/bin/gs\"")))
#t))
(add-after 'unpack 'use-code-for-new-poppler
(lambda _
(copy-file "texk/web2c/pdftexdir/pdftoepdf-poppler0.76.0.cc"
"texk/web2c/pdftexdir/pdftoepdf.cc")
(copy-file "texk/web2c/pdftexdir/pdftosrc-poppler0.76.0.cc"
"texk/web2c/pdftexdir/pdftosrc.cc")
#t))
(add-after 'unpack 'patch-dvisvgm-build-files
(lambda _
;; XXX: Ghostscript is detected, but HAVE_LIBGS is never set, so
;; the appropriate linker flags are not added.
(substitute* "texk/dvisvgm/configure"
(("^have_libgs=yes" all)
(string-append all "\nHAVE_LIBGS=1")))
#t))
(add-after 'unpack 'disable-failing-test
(lambda _
;; FIXME: This test fails on 32-bit architectures since Glibc 2.28:
;; <https://bugzilla.redhat.com/show_bug.cgi?id=1631847>.
(substitute* "texk/web2c/omegafonts/check.test"
(("^\\./omfonts -ofm2opl \\$srcdir/tests/check tests/xcheck \\|\\| exit 1")
"./omfonts -ofm2opl $srcdir/tests/check tests/xcheck || exit 77"))
#t))
(add-after 'install 'postint
(lambda* (#:key inputs outputs #:allow-other-keys #:rest args)
(let* ((out (assoc-ref outputs "out"))
(share (string-append out "/share"))
(texlive-extra (assoc-ref inputs "texlive-extra-src"))
(unpack (assoc-ref %standard-phases 'unpack))
(patch-source-shebangs
(assoc-ref %standard-phases 'patch-source-shebangs)))
(substitute* (string-append share "/texmf-dist/web2c/texmf.cnf")
;; Don't truncate lines.
(("^error_line = .*$") "error_line = 254\n")
(("^half_error_line = .*$") "half_error_line = 238\n")
(("^max_print_line = .*$") "max_print_line = 1000\n"))
;; Create symbolic links for the latex variants and their
;; man pages.
(with-directory-excursion (string-append out "/bin/")
(for-each symlink
'("pdftex" "pdftex" "xetex" "luatex")
'("latex" "pdflatex" "xelatex" "lualatex")))
(with-directory-excursion (string-append share "/man/man1/")
(symlink "luatex.1" "lualatex.1"))
;; Unpack texlive-extra and install tlpkg.
(mkdir "texlive-extra")
(with-directory-excursion "texlive-extra"
(apply unpack (list #:source texlive-extra))
(apply patch-source-shebangs (list #:source texlive-extra))
(invoke "mv" "tlpkg" share))
(let ((scripts (string-append share "/texmf-dist/scripts/texlive/")))
(mkdir-p scripts)
(copy-recursively (assoc-ref inputs "texlive-scripts") scripts)
;; Make sure that fmtutil can find its Perl modules.
(substitute* (string-append scripts "fmtutil.pl")
(("\\$TEXMFROOT/") (string-append share "/"))))
;; texlua shebangs are not patched by the patch-source-shebangs
;; phase because the texlua executable does not exist at that
;; time.
(setenv "PATH" (string-append (getenv "PATH") ":" out "/bin"))
(with-directory-excursion out
(patch-source-shebangs))))))))
(native-search-paths
(list (search-path-specification
(variable "TEXMF")
(files '("share/texmf-dist"))
(separator #f))
(search-path-specification
(variable "TEXMFCNF")
(files '("share/texmf-dist/web2c"))
(separator #f))))
(synopsis "TeX Live, a package of the TeX typesetting system")
(description
"TeX Live provides a comprehensive TeX document production system.
It includes all the major TeX-related programs, macro packages, and fonts
that are free software, including support for many languages around the
world.
This package contains the binaries.")
(license (license:fsf-free "https://www.tug.org/texlive/copying.html"))
(home-page "https://www.tug.org/texlive/")))
(define texlive-docstrip
(package
(inherit (simple-texlive-package
"texlive-docstrip"
(list "/tex/latex/base/docstrip.tex")
(base32
"1f9sx1lp7v34zwm186msf03q2h28rrg0lh65z59zc0cvqffs6dvb")
#:trivial? #t))
(home-page "https://www.ctan.org/texlive")
(synopsis "Utility to strip documentation from TeX files.")
(description "This package provides the docstrip utility to strip
documentation from TeX files. It is part of the LaTeX base.")
(license license:lppl1.3+)))
(define-public texlive-unicode-data
(package
(inherit (simple-texlive-package
"texlive-unicode-data"
(list "/tex/generic/unicode-data/"
"/doc/generic/unicode-data/")
(base32
"0zy4v9y667cka5fi4dnc6x500907812y7pcaf63s5qxi8l7khxxy")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/unicode-data")
(synopsis "Unicode data and loaders for TeX")
(description "This bundle provides generic access to Unicode Consortium
data for TeX use. It contains a set of text files provided by the Unicode
Consortium which are currently all from Unicode 8.0.0, with the exception of
@code{MathClass.txt} which is not currently part of the Unicode Character
Database. Accompanying these source data are generic TeX loader files
allowing this data to be used as part of TeX runs, in particular in building
format files. Currently there are two loader files: one for general character
set up and one for initializing XeTeX character classes as has been carried
out to date by @code{unicode-letters.tex}. ")
(license license:lppl1.3c+)))
(define-public texlive-generic-unicode-data
(deprecated-package "texlive-generic-unicode-data" texlive-unicode-data))
(define-public texlive-hyphen-base
(package
(inherit (simple-texlive-package
"texlive-hyphen-base"
(list "/tex/generic/config/language.dat"
"/tex/generic/config/language.dat.lua"
"/tex/generic/config/language.def"
"/tex/generic/config/language.us"
"/tex/generic/config/language.us.def"
"/tex/generic/config/language.us.lua"
"/tex/generic/hyphen/dumyhyph.tex"
"/tex/generic/hyphen/hyphen.tex"
"/tex/generic/hyphen/hypht1.tex"
"/tex/generic/hyphen/zerohyph.tex")
(base32
"0f19nml4hdx9lh7accqdk1b9ismwfm2523l5zsc4kb4arysgcakz")
#:trivial? #t))
(home-page "https://tug.org/texlive/")
(synopsis "Core hyphenation support files")
(description "This package includes Knuth's original @file{hyphen.tex},
@file{zerohyph.tex} to disable hyphenation, @file{language.us} which starts
the autogenerated files @file{language.dat} and @file{language.def} (and
default versions of those), etc.")
(license license:knuth)))
(define-public texlive-dvips
(package
(inherit (simple-texlive-package
"texlive-dvips"
(list "/doc/man/man1/afm2tfm.1"
"/doc/man/man1/dvips.1"
"/dvips/base/"
"/dvips/config/"
"/fonts/enc/dvips/base/"
"/tex/generic/dvips/")
(base32
"1qr7h0ahycmz5wmpv54glfss9jqdmmyymj6kim626d1c8v9bmg86")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/dvips")
(synopsis "DVI to PostScript drivers")
(description "This package provides files needed for converting DVI files
to PostScript.")
(license license:lppl)))
(define-public texlive-tex-ini-files
(package
(inherit (simple-texlive-package
"texlive-tex-ini-files"
(list "/tex/generic/tex-ini-files/")
(base32
"0q1g62jg0qiqslm93ycvm30bw8ydmssjdshzsnzl7n2vpd62qfi2")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/tex-ini-files")
(synopsis "Files for creating TeX formats")
(description "This bundle provides a collection of model \".ini\" files
for creating TeX formats. These files are commonly used to introduced
distribution-dependent variations in formats. They are also used to
allow existing format source files to be used with newer engines, for example
to adapt the plain e-TeX source file to work with XeTeX and LuaTeX.")
(license license:public-domain)))
(define-public texlive-generic-tex-ini-files
(deprecated-package "texlive-generic-tex-ini-files" texlive-tex-ini-files))
(define-public texlive-metafont-base
(package
(name "texlive-metafont-base")
(version (number->string %texlive-revision))
(source (origin
(method svn-fetch)
(uri (svn-reference
(url (string-append "svn://www.tug.org/texlive/tags/"
%texlive-tag "/Master/texmf-dist/"
"/metafont"))
(revision %texlive-revision)))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"1yl4n8cn5xqk2nc22zgzq6ymd7bhm6xx1mz3azip7i3ki4bhb5q5"))))
(build-system gnu-build-system)
(arguments
`(#:tests? #f ; no test target
#:phases
(modify-phases %standard-phases
(delete 'configure)
(replace 'build
(lambda* (#:key inputs #:allow-other-keys)
(let ((cwd (getcwd)))
(setenv "MFINPUTS"
(string-append cwd "/base:"
cwd "/misc:"
cwd "/roex:"
cwd "/feynmf:"
cwd "/mfpic:"
cwd "/config")))
(mkdir "build")
(with-directory-excursion "build"
(invoke "inimf" "mf.mf"))))
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(base (string-append out "/share/texmf-dist/web2c"))
(mf (string-append out "/share/texmf-dist/metafont/base")))
(mkdir-p base)
(mkdir-p mf)
(install-file "build/mf.base" base)
(copy-recursively "base" mf)
#t))))))
(native-inputs
`(("texlive-bin" ,texlive-bin)))
(home-page "https://www.ctan.org/pkg/metafont")
(synopsis "Metafont base files")
(description "This package provides the Metafont base files needed to
build fonts using the Metafont system.")
(license license:knuth)))
(define-public texlive-fontinst
(let ((template (simple-texlive-package
"texlive-fontinst"
(list "/doc/fonts/fontinst/"
"/doc/man/man1/fontinst.1"
"/doc/man/man1/fontinst.man1.pdf"
;; This is used to build parts of
;; /tex/fontinst/{base,misc}/ and
;; /tex/latex/fontinst/fontdoc.sty.
"/source/fontinst/base/"
;; These are not generated.
"/tex/fontinst/base/bbox.sty"
"/tex/fontinst/base/multislot.sty"
"/tex/fontinst/misc/glyphbox.mtx"
"/tex/fontinst/misc/glyphoff.mtx"
"/tex/fontinst/misc/glyphon.mtx"
"/tex/fontinst/misc/kernoff.mtx"
"/tex/fontinst/misc/kernon.mtx"
"/tex/fontinst/latinetx/"
"/tex/fontinst/latinmtx/"
"/tex/fontinst/mathmtx/"
"/tex/fontinst/smblmtx/"
"/scripts/texlive/fontinst.sh")
(base32
"0lprwib7n2ygfxvrw675vhif7ghyip2x6k70kqs9syp8lqxiizf8")
#:trivial? #t)))
(package
(inherit template)
(arguments
(substitute-keyword-arguments (package-arguments template)
((#:modules _ '())
'((guix build gnu-build-system)
(guix build utils)
(ice-9 match)))
((#:phases phases)
`(modify-phases ,phases
(replace 'build
(lambda* (#:key inputs #:allow-other-keys)
(setenv "TEXINPUTS"
(string-append (getcwd) "//:"
(getcwd) "/source/fontinst/base//:"
(assoc-ref inputs "texlive-docstrip") "//"))
(mkdir "build")
(invoke "tex" "-ini" "-interaction=scrollmode"
"-output-directory=build"
"fontinst.ins")))
;; Since we're using docstrip without LaTeX we can't set \UseTDS
;; or \BaseDirectory, so the generated files are just dumped in
;; the "build" directory.
(add-after 'install 'install-generated-files
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(root (string-append out "/share/texmf-dist")))
(for-each (match-lambda
((dir files ...)
(for-each (lambda (file)
(install-file
(string-append "build/" file)
(string-append root dir)))
files)))
'(("/tex/fontinst/base"
"fontinst.sty"
"cfntinst.sty"
"xfntinst.sty"
"finstmsc.sty"
"fontinst.ini")
("/tex/fontinst/misc"
"csc2x.tex"
"csckrn2x.tex"
"osf2x.tex")
("/tex/latex/fontinst"
"fontdoc.sty")))
#t)))))))
(native-inputs
`(("texlive-bin" ,texlive-bin)
("texlive-docstrip" ,texlive-docstrip)))
(home-page "https://www.ctan.org/pkg/fontinst")
(synopsis "Tools for converting and installing fonts for TeX and LaTeX")
(description "This package provides TeX macros for converting Adobe Font
Metric files to TeX metric and virtual font format. Fontinst helps mainly
with the number crunching and shovelling parts of font installation. This
means in practice that it creates a number of files which give the TeX
metrics (and related information) for a font family that TeX needs to do any
typesetting in these fonts.")
(license license:lppl1.1+))))
(define-public texlive-tex-fontinst-base
(deprecated-package "texlive-tex-fontinst-base" texlive-fontinst))
(define-public texlive-fontname
(package
(inherit (simple-texlive-package
"texlive-fontname"
(list "/doc/fonts/fontname/fontname.texi"
"/fonts/map/fontname/")
(base32
"0h5im5rnhycrrkd6z10f17m2caa8lv594wf482b68qjmnxfrqnxj")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/fontname")
(synopsis "Scheme for naming fonts in TeX")
(description "This is Fontname, a naming scheme for (the base part of)
external TeX font filenames. This makes at most eight-character names
from (almost) arbitrarily complex font names, thus helping portability of TeX
documents.")
(license license:public-domain)))
(define-public texlive-cm
(let ((template (simple-texlive-package
"texlive-cm"
(list "/fonts/source/public/cm/"
"/fonts/map/dvips/cm/cmtext-bsr-interpolated.map"
"/doc/fonts/cm/")
(base32
"09mvl94qrwlb9b4pkigi151l256v3djhwl4m5lgvk6yhn5y75zrp")
#:trivial? #t)))
(package
(inherit template)
(arguments
(substitute-keyword-arguments (package-arguments template)
((#:modules modules '())
'((guix build gnu-build-system)
(guix build utils)
(srfi srfi-26)))
((#:phases phases)
`(modify-phases ,phases
(replace 'build
(lambda* (#:key inputs #:allow-other-keys)
(let ((mf (assoc-ref inputs "texlive-metafont-base")))
;; Tell mf where to find mf.base
(setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
;; Tell mf where to look for source files
(setenv "MFINPUTS"
(string-append (getcwd) "/fonts/source/public/cm/:"
mf "/share/texmf-dist/metafont/base")))
(for-each make-file-writable
(cons "fonts/source/public/cm/"
(find-files "fonts/source/public/cm/" ".*")))
(let ((build (string-append (getcwd) "/build"))
(pkdir (string-append (getcwd) "/pk/ljfour/public/cm/dpi600")))
(mkdir-p pkdir)
(mkdir-p build)
(with-directory-excursion "fonts/source/public/cm/"
(for-each (lambda (font)
(format #t "building font ~a\n" font)
(invoke "mf" "-progname=mf"
(string-append "-output-directory=" build)
(string-append "\\"
"mode:=ljfour; "
"mag:=1+0/600; "
"scrollmode; "
"input "
(basename font ".mf")))
(invoke "gftopk"
(string-append build "/"
(basename font ".mf") ".600gf")
(string-append pkdir "/"
(basename font ".mf") ".pk")))
(find-files "." "cm(.*[0-9]+.*|inch)\\.mf$"))))
#t))
(add-after 'install 'install-generated-fonts
(lambda* (#:key inputs outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(fonts (string-append out "/share/texmf-dist/fonts/"))
(pk (string-append fonts "pk"))
(tfm (string-append fonts "tfm/public/cm")))
(for-each (cut install-file <> tfm)
(find-files "build" "\\.*"))
(copy-recursively "pk" pk)
#t)))))))
(native-inputs
`(("texlive-bin" ,texlive-bin)
("texlive-metafont-base" ,texlive-metafont-base)))
(home-page "https://www.ctan.org/pkg/cm")
(synopsis "Computer Modern fonts for TeX")
(description "This package provides the Computer Modern fonts by Donald
Knuth. The Computer Modern font family is a large collection of text,
display, and mathematical fonts in a range of styles, based on Monotype Modern
8A.")
(license license:knuth))))
(define-public texlive-fonts-cm
(deprecated-package "texlive-fonts-cm" texlive-cm))
(define-public texlive-cm-super
(let ((template (simple-texlive-package
"texlive-cm-super"
(list "/doc/fonts/cm-super/"
"/dvips/cm-super/"
"/fonts/afm/public/cm-super/"
"/fonts/enc/dvips/cm-super/"
"/fonts/map/dvips/cm-super/"
"/fonts/map/vtex/cm-super/"
"/fonts/type1/public/cm-super/"
"/tex/latex/cm-super/")
(base32
"1k3afl0x0bqbr5mnawbnp7rr2126dwn0vwnxzibm9ggvzqilnkm6")
#:trivial? #t)))
(package
(inherit template)
(arguments
(substitute-keyword-arguments (package-arguments template)
((#:phases phases)
`(modify-phases ,phases
(delete 'reset-gzip-timestamps)))))
(home-page "https://www.ctan.org/pkg/cm-super")
(synopsis "Computer Modern Super family of fonts")
(description "The CM-Super family provides Adobe Type 1 fonts that replace
the T1/TS1-encoded Computer Modern (EC/TC), T1/TS1-encoded Concrete,
T1/TS1-encoded CM bright and LH Cyrillic fonts (thus supporting all European
languages except Greek), and bringing many ameliorations in typesetting
quality. The fonts exhibit the same metrics as the METAFONT-encoded
originals.")
;; With font exception
(license license:gpl2+))))
(define-public texlive-fonts-cm-super
(deprecated-package "texlive-fonts-cm-super" texlive-cm-super))
(define-public texlive-lm
(package
(inherit (simple-texlive-package
"texlive-lm"
(list "/doc/fonts/lm/"
"/fonts/afm/public/lm/"
"/fonts/enc/dvips/lm/"
"/fonts/map/dvipdfm/lm/"
"/fonts/map/dvips/lm/"
"/fonts/opentype/public/lm/"
"/fonts/tfm/public/lm/"
"/fonts/type1/public/lm/"
"/tex/latex/lm/")
(base32
"0i1hwr8rp0jqyvs4qyplrirscd4w7lsgwsncyv3yzy80bsa56jq5")
#:trivial? #t))
(home-page "http://www.gust.org.pl/projects/e-foundry/latin-modern/")
(synopsis "Latin Modern family of fonts")
(description "The Latin Modern fonts are derived from the famous Computer
Modern fonts designed by Donald E. Knuth and described in Volume E of his
Computers & Typesetting series.")
;; The GUST font license (GFL) is legally identical to the LaTeX Project
;; Public License (LPPL), version 1.3c or later, but comes with an
;; additional but not legally binding clause.
(license license:lppl1.3c+)))
(define-public texlive-fonts-lm
(deprecated-package "texlive-fonts-lm" texlive-lm))
(define-public texlive-fonts-knuth-lib
(package
(name "texlive-fonts-knuth-lib")
(version (number->string %texlive-revision))
(source (origin
(method svn-fetch)
(uri (svn-reference
(url (string-append "svn://www.tug.org/texlive/tags/"
%texlive-tag "/Master/texmf-dist/"
"/fonts/source/public/knuth-lib"))
(revision %texlive-revision)))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"0in9aqyi8jkyf9d16z0li50z5fpwj1iwgwm83gmvwqcf7chfs04y"))))
(build-system gnu-build-system)
(arguments
`(#:modules ((guix build gnu-build-system)
(guix build utils)
(srfi srfi-26))
#:tests? #f ; no tests
#:phases
(modify-phases %standard-phases
(delete 'configure)
(replace 'build
(lambda* (#:key inputs #:allow-other-keys)
(let ((mf (assoc-ref inputs "texlive-metafont-base")))
;; Tell mf where to find mf.base
(setenv "MFBASES"
(string-append mf "/share/texmf-dist/web2c"))
;; Tell mf where to look for source files
(setenv "MFINPUTS"
(string-append (getcwd) ":"
mf "/share/texmf-dist/metafont/base")))
(mkdir "build")
(for-each (lambda (font)
(format #t "building font ~a\n" font)
(invoke "mf" "-progname=mf"
"-output-directory=build"
(string-append "\\"
"mode:=ljfour; "
"mag:=1; "
"batchmode; "
"input " font)))
(find-files "." "(manfnt|logo.+)\\.mf$"))
#t))
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(tfm (string-append
out "/share/texmf-dist/fonts/tfm/public/knuth-lib"))
(mf (string-append
out "/share/texmf-dist/fonts/source/public/knuth-lib")))
(for-each (cut install-file <> tfm)
(find-files "build" "\\.*"))
(for-each (cut install-file <> mf)
(find-files "." "\\.mf"))
#t))))))
(native-inputs
`(("texlive-bin" ,texlive-bin)
("texlive-metafont-base" ,texlive-metafont-base)))
(home-page "https://www.ctan.org/pkg/knuth-lib")
(synopsis "Small library of METAFONT sources")
(description "This is a collection of core TeX and METAFONT macro files
from Donald Knuth, including the plain format, plain base, and the MF logo
fonts.")
(license license:knuth)))
(define-public texlive-fonts-latex
(package
(name "texlive-fonts-latex")
(version (number->string %texlive-revision))
(source (origin
(method svn-fetch)
(uri (svn-reference
(url (string-append "svn://www.tug.org/texlive/tags/"
%texlive-tag "/Master/texmf-dist/"
"/fonts/source/public/latex-fonts"))
(revision %texlive-revision)))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"0ypsm4xv9cw0jckk2qc7gi9hcmhf31mrg56pz3llyx3yd9vq2lps"))))
(build-system gnu-build-system)
(arguments
`(#:modules ((guix build gnu-build-system)
(guix build utils)
(srfi srfi-1)
(srfi srfi-26))
#:tests? #f ; no tests
#:phases
(modify-phases %standard-phases
(delete 'configure)
(replace 'build
(lambda* (#:key inputs #:allow-other-keys)
(let ((mf (assoc-ref inputs "texlive-metafont-base")))
;; Tell mf where to find mf.base
(setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
;; Tell mf where to look for source files
(setenv "MFINPUTS"
(string-append (getcwd) ":"
mf "/share/texmf-dist/metafont/base:"
(assoc-ref inputs "texlive-cm")
"/share/texmf-dist/fonts/source/public/cm")))
(mkdir "build")
(for-each (lambda (font)
(format #t "building font ~a\n" font)
(invoke "mf" "-progname=mf"
"-output-directory=build"
(string-append "\\"
"mode:=ljfour; "
"mag:=1; "
"batchmode; "
"input " font)))
'("icmcsc10" "icmex10" "icmmi8" "icmsy8" "icmtt8"
"ilasy8" "ilcmss8" "ilcmssb8" "ilcmssi8"
"lasy5" "lasy6" "lasy7" "lasy8" "lasy9" "lasy10" "lasyb10"
"lcircle10" "lcirclew10" "lcmss8" "lcmssb8" "lcmssi8"
"line10" "linew10"))
#t))
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(tfm (string-append
out "/share/texmf-dist/fonts/tfm/public/latex-fonts"))
(mf (string-append
out "/share/texmf-dist/fonts/source/public/latex-fonts")))
(for-each (cut install-file <> tfm)
(find-files "build" "\\.*"))
(for-each (cut install-file <> mf)
(find-files "." "\\.mf"))
#t))))))
(native-inputs
`(("texlive-bin" ,texlive-bin)
("texlive-metafont-base" ,texlive-metafont-base)
("texlive-cm" ,texlive-cm)))
(home-page "https://www.ctan.org/pkg/latex-fonts")
(synopsis "Collection of fonts used in LaTeX distributions")
(description "This is a collection of fonts for use with standard LaTeX
packages and classes. It includes invisible fonts (for use with the slides
class), line and circle fonts (for use in the picture environment) and LaTeX
symbol fonts.")
(license license:lppl1.2+)))
(define-public texlive-latex-mflogo
(package
(name "texlive-latex-mflogo")
(version (number->string %texlive-revision))
(source
(origin
(method svn-fetch)
(uri (texlive-ref "latex" "mflogo"))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"15i2ib6nvhf31g1b92c6njf7n0g29znlq7hbfp9ii7qabhcwwvrj"))))
(build-system texlive-build-system)
(arguments '(#:tex-directory "latex/mflogo"))
(home-page "http://www.ctan.org/pkg/mflogo")
(synopsis "LaTeX support for Metafont logo fonts")
(description
"This package provides LaTeX and font definition files to access the
Knuthian mflogo fonts described in The Metafontbook and to typeset Metafont
logos in LaTeX documents.")
(license license:lppl)))
(define-public texlive-mflogo-font
(package
(inherit (simple-texlive-package
"texlive-mflogo-font"
(list "/doc/fonts/mflogo-font/README"
"/fonts/afm/hoekwater/mflogo-font/"
"/fonts/map/dvips/mflogo-font/"
"/fonts/type1/hoekwater/mflogo-font/")
(base32
"094mknjv8ki2pvj1zin0f1z4f1w12g0cfqjiqcsawjsry4yfrmbg")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/mflogo-font")
(synopsis "Metafont logo font")
(description
"These fonts were created in METAFONT by Knuth, for his own publications.
At some stage, the letters P and S were added, so that the METAPOST logo could
also be expressed. The fonts were originally issued (of course) as METAFONT
source; they have since been autotraced and reissued in Adobe Type 1 format by
Taco Hoekwater.")
(license license:knuth)))
(define-public texlive-fonts-mflogo-font
(deprecated-package "texlive-fonts-mflogo-font" texlive-mflogo-font))
(define-public texlive-amsfonts
(let ((template (simple-texlive-package
"texlive-amsfonts"
(list "/source/latex/amsfonts/"
"/fonts/source/public/amsfonts/"
"/fonts/type1/public/amsfonts/"
"/fonts/afm/public/amsfonts/"
"/fonts/map/dvips/amsfonts/"
"/tex/plain/amsfonts/"
"/doc/fonts/amsfonts/")
(base32
"15q70nkjf8wqzbd5ivcdx3i2sdgqxjb38q0qn9a2qw9i0qcnx6zw"))))
(package
(inherit template)
(arguments
(substitute-keyword-arguments (package-arguments template)
((#:build-targets _ #t)
'(list "amsfonts.ins"))
((#:tex-directory _ #t)
"latex/amsfonts")
((#:modules modules '())
`((guix build texlive-build-system)
(guix build utils)
(ice-9 match)
(srfi srfi-1)
(srfi srfi-26)))
((#:phases phases)
`(modify-phases ,phases
(add-before 'build 'build-fonts
(lambda* (#:key inputs #:allow-other-keys)
(let ((mf (assoc-ref inputs "texlive-union"))
(src (string-append (getcwd) "/fonts/source/public/amsfonts/")))
;; Make METAFONT reproducible
(setenv "SOURCE_DATE_EPOCH" "1")
;; Tell mf where to find mf.base
(setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
;; Tell mf where to look for source files
(setenv "MFINPUTS"
(string-append src ":"
src "/cmextra:"
src "/cyrillic:"
src "/dummy:"
src "/symbols:"
mf "/share/texmf-dist/metafont/base:"
(assoc-ref inputs "texlive-cm")
"/share/texmf-dist/fonts/source/public/cm")))
(let ((build (string-append (getcwd) "/build-fonts")))
(mkdir-p build)
(with-directory-excursion "fonts/source/public/amsfonts"
(for-each (lambda (font)
(format #t "building font ~a\n" (basename font ".mf"))
(with-directory-excursion (dirname font)
(invoke "mf" "-progname=mf"
(string-append "-output-directory=" build)
(string-append "\\"
"mode:=ljfour; "
"mag:=1; "
"nonstopmode; "
"input "
(getcwd) "/"
(basename font ".mf")))))
(find-files "." "[0-9]+\\.mf$"))))
;; There are no metafont sources for the Euler fonts, so we
;; convert the afm files instead.
(let ((build (string-append (getcwd) "/build-fonts/euler")))
(mkdir build)
(with-directory-excursion "fonts/afm/public/amsfonts/"
(for-each (lambda (font)
(format #t "converting afm font ~a\n" (basename font ".afm"))
(invoke "afm2tfm" font
(string-append build "/"
(basename font ".tfm"))))
(find-files "." "\\.afm$")))
;; Frustratingly, not all fonts can be created this way. To
;; generate eufm8.tfm, for example, we first scale down
;; eufm10.afm to eufm8.pl, and then generate the tfm file from
;; the pl file.
(setenv "TEXINPUTS"
(string-append build "//:"
(getcwd) "/fonts/afm/public/amsfonts//:"
(getcwd) "/source/latex/amsfonts//:"
(assoc-ref inputs "texlive-union") "//"))
(with-directory-excursion build
(for-each (match-lambda
(((target-base target-size)
(source-base source-size))
(let ((factor (number->string
(truncate/ (* 1000 target-size)
source-size))))
(invoke "tex"
"-interaction=scrollmode"
(string-append "\\input fontinst.sty "
"\\transformfont{" target-base "}"
"{\\scalefont{" factor "}"
"{\\fromafm{" source-base "}}} "
"\\bye")))
(invoke "pltotf"
(string-append target-base ".pl")
(string-append target-base ".tfm"))
(delete-file (string-append target-base ".pl"))))
'((("eufm8" 8) ("eufm10" 10))
(("eufb6" 6) ("eufb7" 7))
(("eufb8" 8) ("eufb10" 10))
(("eufb9" 9) ("eufb10" 10))
(("eufm6" 6) ("eufb7" 7))
(("eufm9" 9) ("eufb10" 10))
(("eurb6" 6) ("eurb7" 7))
(("eurb8" 8) ("eurb10" 10))
(("eurb9" 9) ("eurb10" 10))
(("eurm6" 6) ("eurm7" 7))
(("eurm8" 8) ("eurm10" 10))
(("eurm9" 9) ("eurm10" 10))))))
#t))
(add-after 'install 'install-generated-fonts
(lambda* (#:key inputs outputs #:allow-other-keys)
(copy-recursively "build-fonts"
(string-append
(assoc-ref outputs "out")
"/share/texmf-dist/fonts/tfm/public/amsfonts"))
#t))))))
(native-inputs
`(("texlive-union" ,(texlive-union (list texlive-tex-fontinst-base
texlive-cm
texlive-metafont-base)))))
(home-page "https://www.ctan.org/pkg/amsfonts")
(synopsis "TeX fonts from the American Mathematical Society")
(description
"This package provides an extended set of fonts for use in mathematics,
including: extra mathematical symbols; blackboard bold letters (uppercase
only); fraktur letters; subscript sizes of bold math italic and bold Greek
letters; subscript sizes of large symbols such as sum and product; added sizes
of the Computer Modern small caps font; cyrillic fonts (from the University of
Washington); Euler mathematical fonts. All fonts are provided as Adobe Type 1
files, and all except the Euler fonts are provided as Metafont source. The
distribution also includes the canonical Type 1 versions of the Computer
Modern family of fonts. The Euler fonts are supported by separate packages;
details can be found in the documentation.")
(license license:silofl1.1))))
(define-public texlive-fonts-amsfonts
(deprecated-package "texlive-fonts-amsfonts" texlive-amsfonts))
(define-public texlive-latex-amsfonts
(deprecated-package "texlive-latex-amsfonts" texlive-amsfonts))
(define-public texlive-mkpattern
(package
(inherit (simple-texlive-package
"texlive-mkpattern"
(list "/doc/plain/mkpattern/README"
"/doc/plain/mkpattern/mkpatdoc.tex"
"/doc/plain/mkpattern/mkpatter.pdf"
"/doc/plain/mkpattern/mkpattern-exmpl.tex"
"/tex/plain/mkpattern/mkpatter.tex")
(base32
"0sxnkbcc802jl3fj56x9hvg978bpv15lhrwj0aykb4syq29l47ga")
#:trivial? #t))
(home-page "https://ctan.org/pkg/mkpattern")
(synopsis "Utility for making hyphenation patterns")
(description "Mkpattern is a general purpose program for the generation of
hyphenation patterns, with definition of letter sets and template-like
constructions. It also provides an easy way to handle different input and
output encodings, and features generation of clean UTF-8 patterns.")
(license license:lppl)))
;; This provides etex.src which is needed to build various formats, including
;; luatex.fmt and pdflatex.fmt
(define-public texlive-etex
(let ((template (simple-texlive-package
"texlive-etex"
(list "/doc/etex/base/"
"/doc/man/man1/etex.1"
"/doc/man/man1/etex.man1.pdf"
"/tex/plain/etex/"
"/fonts/source/public/etex/")
(base32
"1qv6vxm5a8pw38gas3i69ivmsn79zj2yq5n5vdmh0rzic5hw2hmc")
#:trivial? #t)))
(package
(inherit template)
(arguments
(substitute-keyword-arguments (package-arguments template)
((#:phases phases)
`(modify-phases ,phases
;; Build tfm font.
(replace 'build
(lambda* (#:key inputs #:allow-other-keys)
(let ((mf (assoc-ref inputs "texlive-metafont-base")))
;; Tell mf where to find mf.base
(setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
;; Tell mf where to look for source files
(setenv "MFINPUTS"
(string-append (getcwd)
"/fonts/source/public/etex/:"
mf "/share/texmf-dist/metafont/base:"
(assoc-ref inputs "texlive-cm")
"/share/texmf-dist/fonts/source/public/cm")))
(invoke "mf" "-progname=mf"
(string-append "\\"
"mode:=ljfour; "
"mag:=1; "
"scrollmode; "
"input xbmc10"))
#t))
(add-after 'install 'install-font
(lambda* (#:key outputs #:allow-other-keys)
(install-file
"xbmc10.tfm"
(string-append (assoc-ref outputs "out")
"/share/texmf-dist/fonts/tfm/public/etex/"))
#t))))))
(native-inputs
`(("texlive-bin" ,texlive-bin)
("texlive-metafont-base" ,texlive-metafont-base)
("texlive-cm" ,texlive-cm)))
(home-page "https://www.ctan.org/pkg/etex")
(synopsis "Extended version of TeX")
(description
"This package provides an extended version of TeX (which is capable of
running as if it were TeX unmodified). E-TeX has been specified by the LaTeX
team as the engine for the development of LaTeX2e; as a result, LaTeX
programmers may assume e-TeX functionality. The pdftex engine directly
incorporates the e-TeX extensions.")
(license license:knuth))))
(define-public texlive-tex-plain
(package
(inherit (simple-texlive-package
"texlive-tex-plain"
(list "/tex/plain/")
(base32
"1m4qpaszwfv7j8a85rlwl7rs4iv5nlj67c1vvn6ysly72h9gjydb")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/plain")
(synopsis "Plain TeX format and supporting files")
(description
"This package contains files used to build the Plain TeX format, as
described in the TeXbook, together with various supporting files (some also
discussed in the book).")
(license license:knuth)))
(define-public texlive-hyphen-afrikaans
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-afrikaans" "af"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-af.tex")
(base32
"1k9k27a27bbrb0gz36191w32l2v6d3zbdh8zhrp4l3ild2pj3n4l")))
(synopsis "Hyphenation patterns for Afrikaans")
(description "The package provides hyphenation patterns for the Afrikaans
language.")
(license license:lppl1.3+)))
(define-public texlive-hyphen-ancientgreek
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-ancientgreek" "grc"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-grc.tex"
"/tex/generic/hyphen/grahyph5.tex"
"/tex/generic/hyphen/ibyhyph.tex")
(base32
"01326lb6z0s8krcfgs8i1pnjfrm4gr33rc53gy80f63qbv4ssxrw")))
(synopsis "Hyphenation patterns for ancient Greek")
(description "The package provides hyphenation patterns for ancient
Greek.")
(license license:lppl1.3+)))
(define-public texlive-hyphen-armenian
(let ((template (texlive-hyphen-package
"texlive-hyphen-armenian" "hy"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-hy.tex")
(base32
"0hzny0npynsb07syxrpbfa5pkpj8r0j51pj64yxyfl1c0bak1fwp"))))
(package
(inherit template)
(synopsis "Hyphenation patterns for Armenian")
(description "The package provides hyphenation patterns for the Armenian
language.")
;; Any version of the LGPL.
(license license:lgpl3+))))
(define-public texlive-hyphen-basque
(let ((template (texlive-hyphen-package
"texlive-hyphen-basque" "eu"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-eu.tex")
(base32
"15w969g1jqzn68l2b2lzf7iv7g3kil02aba3if6cag3qcnq92ra9"))))
(package
(inherit template)
(synopsis "Hyphenation patterns for Basque")
(description "The package provides hyphenation patterns for the Basque
language.")
;; Similar to Unicode license.
(license (license:fsf-free
"/tex/generic/hyph-utf8/patterns/tex/hyph-eu.tex")))))
(define-public texlive-hyphen-belarusian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-belarusian" "be"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-be.tex")
(base32
"0ppm12wndaxv9da62dwkbnk7w9nijikn6jkc97m76xis338g2h02")))
(synopsis "Hyphenation patterns for Belarusian")
(description "The package provides hyphenation patterns for the Belarusian
language.")
(license license:expat)))
(define-public texlive-hyphen-bulgarian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-bulgarian" "bg"
(list "/doc/generic/hyph-utf8/bg/azbukaExtended.pdf"
"/doc/generic/hyph-utf8/bg/azbukaExtended.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-bg.tex")
(base32
"0ngrgw2rmipxss76rgfk62x9nnsgwmaxxna2jqxxhybai3q39mx5")))
(synopsis "Hyphenation patterns for Bulgarian")
(description "The package provides hyphenation patterns for the Bulgarian
language in T2A and UTF-8 encodings.")
(license (license:non-copyleft
"file:///tex/generic/hyph-utf8/patterns/tex/hyph-bg.tex"
"Ancestral BSD variant"))))
(define-public texlive-hyphen-catalan
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-catalan" "ca"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-ca.tex")
(base32
"10zzlfz5v8d9csg85ibpp2vfvmpqa56vbl85qy5gws099vygpayg")))
(synopsis "Hyphenation patterns for Catalan")
(description "The package provides hyphenation patterns for Catalan in
T1/EC and UTF-8 encodings.")
(license license:lppl1.0+)))
(define-public texlive-hyphen-chinese
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-chinese" "zh-latn-pinyin"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-zh-latn-pinyin.tex")
(base32
"1j68mry2zy91m1kbzwhin5q2jajf6xh48npdds8wvp1sqmzih2a3")))
(synopsis "Hyphenation patterns for unaccented Chinese pinyin")
(description "The package provides hyphenation patterns for unaccented
Chinese pinyin T1/EC and UTF-8 encodings.")
(license license:gpl2+)))
(define-public texlive-hyphen-churchslavonic
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-churchslavonic" "cu"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-cu.tex")
(base32
"0fhbwaapq2213msbhgr0d1lw06ihmrqirxj092mn73d8ynl13qlh")))
(synopsis "Hyphenation patterns for Church Slavonic")
(description "The package provides hyphenation patterns for Church
Slavonic in UTF-8 encoding.")
(license license:expat)))
(define-public texlive-hyphen-coptic
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-coptic" "cop"
(list "/tex/generic/hyph-utf8/patterns/tex-8bit/copthyph.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-cop.tex")
(base32
"1jlxxvyfa2aljizaa3qlcxyhqsrb4dawv3q3fbyp2lxz6ag9fy6m")))
(synopsis "Hyphenation patterns for Coptic")
(description "The package provides hyphenation patterns for Coptic in
UTF-8 encoding as well as in ASCII-based encoding for 8-bit engines.")
;; No explicit license declaration, so we use the project license.
(license license:lppl)))
(define-public texlive-hyphen-croatian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-croatian" "hr"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-hr.tex")
(base32
"12n9r2winai15jc622sqdwclgcs1s68r6vcf7ic8vvq0x9qhwc5v")))
(synopsis "Hyphenation patterns for Croatian")
(description "The package provides hyphenation patterns for Croatian in
T1/EC and UTF-8 encodings.")
(license license:lppl1.0+)))
(define-public texlive-hyphen-czech
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-czech" "cs"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-cs.tex")
(base32
"1q37s6p8yfyi3rp1azbz421lg4lr4aiki8m631i4x9rmps89m8iq")))
(synopsis "Hyphenation patterns for Czech")
(description "The package provides hyphenation patterns for Czech in T1/EC
and UTF-8 encodings.")
(license license:gpl2+)))
(define-public texlive-hyphen-danish
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-danish" "da"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-da.tex")
(base32
"1vj8nip64rzcrcg3skm4vqad1ggqwgan74znrdns610wjcm1z9qd")))
(synopsis "Hyphenation patterns for Danish")
(description "The package provides hyphenation patterns for Danish in
T1/EC and UTF-8 encodings.")
;; Either LPPL 1.3 or later, or Expat
(license (list license:lppl1.3+ license:expat))))
(define-public texlive-hyphen-dutch
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-dutch" "nl"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-nl.tex")
(base32
"1bg9g790ksq5cn8qihai6pacmkp9vpf35h4771z361nvwa40l8yk")))
(synopsis "Hyphenation patterns for Dutch")
(description "The package provides hyphenation patterns for Dutch in T1/EC
and UTF-8 encodings.")
(license license:lppl1.0+)))
(define-public texlive-hyphen-english
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-english" '("en-gb" "en-us")
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-en-gb.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-en-us.tex")
(base32
"08b3jihjaamcl1pvffi0s47nwavkm66l9mrrmby3l32dfpkprrc5")))
(synopsis "Hyphenation patterns for American and British English")
(description "The package provides additional hyphenation patterns for
American and British English in ASCII encoding.")
(license (license:non-copyleft
"file:///tex/generic/hyph-utf8/patterns/tex/hyph-en-us.tex"
"FSF all permissive license"))))
(define-public texlive-hyphen-esperanto
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-esperanto" "eo"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-eo.tex")
(base32
"1503kzn9bk4mm4ba35cka2hm8rz0v3j5l30v5rrsd4rqgpibcgic")))
(synopsis "Hyphenation patterns for Esperanto")
(description "The package provides hyphenation patterns for Esperanto ISO
Latin 3 and UTF-8 encodings.")
(license license:lppl1.0+)))
(define-public texlive-hyphen-estonian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-estonian" "et"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-et.tex")
(base32
"1rdas2450ib02rwy65i69l86nyc9h15bl07xbbwhmhxfnj8zj4v8")))
(synopsis "Hyphenation patterns for Estonian")
(description "The package provides hyphenation patterns for Estonian in
T1/EC and UTF-8 encodings.")
;; Dual licensed under either license.
(license (list license:lppl1.3+ license:expat))))
(define-public texlive-hyphen-ethiopic
(let ((template (texlive-hyphen-package
"texlive-hyphen-ethiopic" "mul-ethi"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-mul-ethi.tex")
(base32
"1b93fc6j4aybh0pgq23hsn1njm6asf7sfz803fbj3ai0whsxd10l"))))
(package
(inherit template)
(synopsis "Hyphenation patterns for Ethiopic scripts")
(description "The package provides hyphenation patterns for languages
written using the Ethiopic script for Unicode engines. They are not supposed
to be linguistically relevant in all cases and should, for proper typography,
be replaced by files tailored to individual languages.")
(license license:expat))))
(define-public texlive-hyphen-finnish
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-finnish" "fi"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-fi.tex")
(base32
"1f72b4ydb4zddvw2i004948khmwzigxkdkwfym5v1kkq0183sfpj")))
(synopsis "Hyphenation patterns for Finnish")
(description "The package provides hyphenation patterns for Finnish in
T1/EC and UTF-8 encodings.")
(license license:public-domain)))
(define-public texlive-hyphen-french
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-french" "fr"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-fr.tex")
(base32
"0jc3kqys6cxjw8x8pzjln7z78l8s7f5rlyrkv7dzr1kiwnwilk9d")))
(synopsis "Hyphenation patterns for French")
(description "The package provides hyphenation patterns for French in
T1/EC and UTF-8 encodings.")
(license license:expat)))
(define-public texlive-hyphen-friulan
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-friulan" "fur"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-fur.tex")
(base32
"1dlnh8slpf50mryxv7zzbx08xp54zkdfs1j7y37ipwbrajvd740f")))
(synopsis "Hyphenation patterns for Friulan")
(description "The package provides hyphenation patterns for Friulan in
ASCII encodings.")
(license license:lppl1.3+)))
(define-public texlive-hyphen-galician
(let ((template (texlive-hyphen-package
"texlive-hyphen-galician" "gl"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-gl.tex")
(base32
"13zx2r3nrxdr025g2lxrph0ga6wf7cs8dxixn4fhbl6xr1cx028g"))))
(package
(inherit template)
(synopsis "Hyphenation patterns for Galician")
(description "The package provides hyphenation patterns for Galician in
T1/EC and UTF-8 encodings.")
(license license:lppl1.3))))
(define-public texlive-hyphen-georgian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-georgian" "ka"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-ka.tex")
(base32
"0l0hk7ka04fr8x11nnw95x151cxyycy0fph772m3a3p8qk4x9wp7")))
(synopsis "Hyphenation patterns for Georgian")
(description "The package provides hyphenation patterns for Georgian in
T8M, T8K, and UTF-8 encodings.")
(license license:lppl1.3+)))
(define-public texlive-hyphen-german
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-german" '("de-1901" "de-1996" "de-ch-1901")
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-de-1901.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-de-1996.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-de-ch-1901.tex"
"/tex/generic/dehyph/dehyphn.tex"
"/tex/generic/dehyph/dehypht.tex"
"/tex/generic/dehyph/dehyphtex.tex"
"/tex/generic/dehyph/README")
(base32
"0wp5by5kkf4ac6li5mbppqzw11500wa7f22p5vpz3m1kwd15zavw")))
(synopsis "Hyphenation patterns for German")
(description "This package provides hyphenation patterns for German in
T1/EC and UTF-8 encodings, for traditional and reformed spelling, including
Swiss German.")
;; The patterns are released under the Expat license; the dehyph* files
;; are released under the LPPL version 1 or later.
(license (list license:expat license:lppl1.0+))))
(define-public texlive-hyphen-greek
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-greek" '("el-monoton" "el-polyton")
(list "/doc/generic/elhyphen/"
"/tex/generic/hyph-utf8/patterns/tex/hyph-el-monoton.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-el-polyton.tex"
"/tex/generic/hyphen/grmhyph5.tex"
"/tex/generic/hyphen/grphyph5.tex")
(base32
"1qyr6m1nh6d4wj68616cfxv4wjpiy1w2rlldxlx2ajzba381w3hf")))
(synopsis "Hyphenation patterns for Greek")
(description "This package provides hyphenation patterns for Modern Greek
in monotonic and polytonic spelling in LGR and UTF-8 encodings.")
(license license:lppl)))
(define-public texlive-hyphen-hungarian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-hungarian" "hu"
(list "/doc/generic/huhyphen/"
"/doc/generic/hyph-utf8/hu/"
"/tex/generic/hyph-utf8/patterns/tex/hyph-hu.tex")
(base32
"1j1b8kksg9r8nmjyjvvz8fr3hgcrjj6jlybf9p06nwrrwm2r8j8f")))
(synopsis "Hyphenation patterns for Hungarian")
(description "This package provides hyphenation patterns for Hungarian in
T1/EC and UTF-8 encodings.")
;; Any of these licenses
(license (list license:gpl2 license:lgpl2.1+ license:mpl1.1))))
(define-public texlive-hyphen-icelandic
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-icelandic" "is"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-is.tex")
(base32
"1m9xj41csj3ldym09d82zjbd3345sg2z10d8pxpvhgibf97mb66h")))
(synopsis "Hyphenation patterns for Icelandic")
(description "This package provides hyphenation patterns for Icelandic in
T1/EC and UTF-8 encodings.")
(license license:lppl1.2+)))
(define-public texlive-hyphen-indic
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-indic"
'("as" "bn" "gu" "hi" "kn" "ml" "mr" "or" "pa" "ta" "te")
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-as.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-bn.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-gu.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-hi.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-kn.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-ml.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-mr.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-or.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-pa.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-ta.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-te.tex")
(base32
"02d2kcd3lpk95fykjwhzw9s2a1s2w1skz8h2mmszrz979d1xzhpm")))
(synopsis "Indic hyphenation patterns")
(description "This package provides hyphenation patterns for Assamese,
Bengali, Gujarati, Hindi, Kannada, Malayalam, Marathi, Oriya, Panjabi, Tamil
and Telugu for Unicode engines.")
(license license:expat)))
(define-public texlive-hyphen-indonesian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-indonesian" "id"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-id.tex")
(base32
"1r62w02rf0i4z0jgij54d16qjbj0zyfwm9dwdkqka76jrivij83q")))
(synopsis "Indonesian hyphenation patterns")
(description "This package provides hyphenation patterns for
Indonesian (Bahasa Indonesia) in ASCII encoding. They are probably also
usable for Malay (Bahasa Melayu).")
(license license:gpl2)))
(define-public texlive-hyphen-interlingua
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-interlingua" "ia"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-ia.tex")
(base32
"0a9na20vjnzhgjbicaxay0jk4rm5zg1rjyiswr377mjhd9mx5cg3")))
(synopsis "Interlingua hyphenation patterns")
(description "This package provides hyphenation patterns for Interlingua
in ASCII encoding.")
(license license:lppl1.3+)))
(define-public texlive-hyphen-irish
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-irish" "ga"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-ga.tex")
(base32
"1h1l9jzkpsb91nyhz6s6c9jfrbz8jx5ip8vyq3dkz0rl6g960i6b")))
(synopsis "Irish hyphenation patterns")
(description "This package provides hyphenation patterns for
Irish (Gaeilge) in T1/EC and UTF-8 encodings.")
;; Either of these licenses
(license (list license:gpl2+ license:expat))))
(define-public texlive-hyphen-italian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-italian" "it"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-it.tex")
(base32
"03c7jiqslfxvl3gbdx79hggbvrfi2l4z2bnwxc0na8f8lkp1m787")))
(synopsis "Italian hyphenation patterns")
(description "This package provides hyphenation patterns for Italian in
ASCII encoding. Compliant with the Recommendation UNI 6461 on hyphenation
issued by the Italian Standards Institution (Ente Nazionale di Unificazione
UNI).")
(license license:lppl1.3+)))
(define-public texlive-hyphen-kurmanji
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-kurmanji" "kmr"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-kmr.tex")
(base32
"01ylbsi5wymrdrxr9b28nmjmcj72mdhqr657lwsb6m9aj33c9ql6")))
(synopsis "Kurmanji hyphenation patterns")
(description "This package provides hyphenation patterns for
Kurmanji (Northern Kurdish) as spoken in Turkey and by the Kurdish diaspora in
Europe, in T1/EC and UTF-8 encodings.")
(license license:lppl1.3)))
(define-public texlive-hyphen-latin
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-latin" '("la-x-classic" "la-x-liturgic" "la")
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-la-x-classic.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-la-x-liturgic.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-la.tex")
(base32
"0rxg8a4s5cpj8vlkz5a74a036axda5jqgvr3f9aj2cc2x9f2f3w9")))
(synopsis "Liturgical Latin hyphenation patterns")
(description "This package provides hyphenation patterns for Latin in
T1/EC and UTF-8 encodings, mainly in modern spelling (u when u is needed and v
when v is needed), medieval spelling with the ligatures @code{\\ae} and
@code{\\oe} and the (uncial) lowercase 'v' written as a 'u' is also supported.
Apparently there is no conflict between the patterns of modern Latin and those
of medieval Latin. It also includes hyphenation patterns for the Classical
Latin in T1/EC and UTF-8 encodings. Classical Latin hyphenation patterns are
different from those of 'plain' Latin, the latter being more adapted to modern
Latin. It also provides hyphenation patterns for the Liturgical Latin in
T1/EC and UTF-8 encodings.")
;; Either of these licenses
(license (list license:lppl1.0+ license:expat))))
(define-public texlive-hyphen-latvian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-latvian" "lv"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-lv.tex")
(base32
"00jf8xma4ldz0zpqwma97k9q3j0mqx7qdj6b7baph3n5xgc24aaw")))
(synopsis "Latvian hyphenation patterns")
(description "This package provides hyphenation patterns for Latvian in
L7X and UTF-8 encodings.")
;; Either of these licenses.
(license (list license:gpl2 license:lgpl2.1))))
(define-public texlive-hyphen-lithuanian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-lithuanian" "lt"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-lt.tex")
(base32
"1kfq7j2ajg6nj952s1ygd520sj9z9kl0bqvd291a36ni2b1frzgd")))
(synopsis "Lithuanian hyphenation patterns")
(description "This package provides hyphenation patterns for Lithuanian in
L7X and UTF-8 encodings.")
;; "Do ... whatever ... as long as you respect the copyright"; as part of
;; the hyph-utf8 package we choose the LPPL license.
(license license:lppl)))
(define-public texlive-hyphen-mongolian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-mongolian" '("mn-cyrl-x-lmc" "mn-cyrl")
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-mn-cyrl-x-lmc.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-mn-cyrl.tex")
(base32
"1y1b91ihrdl9bad3rxlsfjpd9wmyd5zzgci3qv9w8qqk33jxhwya")))
(synopsis "Mongolian hyphenation patterns in Cyrillic script")
(description "This package provides hyphenation patterns for Mongolian in
T2A, LMC and UTF-8 encodings.")
;; Either of these licenses
(license (list license:lppl1.3+ license:expat))))
(define-public texlive-hyphen-norwegian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-norwegian" '("nb" "nn" "no")
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-nb.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-nn.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-no.tex")
(base32
"08gbwj64p4fckm199k52yp5lx65h9f4wwdkvl4pv4aa7k370jq9y")))
(synopsis "Norwegian Bokmal and Nynorsk hyphenation patterns")
(description "This package provides hyphenation patterns for Norwegian
Bokmal and Nynorsk in T1/EC and UTF-8 encodings.")
(license (license:non-copyleft
"/tex/generic/hyph-utf8/patterns/tex/hyph-no.tex"
"FSF All permissive license"))))
(define-public texlive-hyphen-occitan
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-occitan" "oc"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-oc.tex")
(base32
"0vhjbq2nr58vhqwwky3cwx4dqiwjmmfwp81rb65mfpf0m8yypdfg")))
(synopsis "Occitan hyphenation patterns")
(description "This package provides hyphenation patterns for Occitan in
T1/EC and UTF-8 encodings. They are supposed to be valid for all the Occitan
variants spoken and written in the wide area called 'Occitanie' by the French.
It ranges from the Val d'Aran within Catalunya, to the South Western Italian
Alps encompassing the southern half of the French pentagon.")
(license license:lppl1.0+)))
(define-public texlive-hyphen-pali
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-pali" "pi"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-pi.tex")
(base32
"1fak853s4ijdqgrnhwymaq1lh8jab3qfyxapdmf6qpg6bqd20kxq")))
(synopsis "Panjabi hyphenation patterns")
(description "This package provides hyphenation patterns for Panjabi in
T1/EC encoding.")
;; Can be used with either license.
(license (list license:expat license:lgpl3+ license:gpl3+))))
(define-public texlive-hyphen-piedmontese
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-piedmontese" "pms"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-pms.tex")
(base32
"0xva3l2gwzkqw1sz64k5g5iprhdyr27w1mv8rxp8x62i5y3aqr1k")))
(synopsis "Piedmontese hyphenation patterns")
(description "This package provides hyphenation patterns for Piedmontese
in ASCII encoding. Compliant with 'Gramatica dla lengua piemonteisa' by
Camillo Brero.")
(license license:lppl1.3+)))
(define-public texlive-hyphen-polish
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-polish" "pl"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-pl.tex")
(base32
"1c22g99isxapv4xjrmsw24hhp1xb83wbgcxyd8j24mxdnizywxzm")))
(synopsis "Polish hyphenation patterns")
(description "This package provides hyphenation patterns for Polish in QX
and UTF-8 encodings.")
;; No differing license declared, so we choose the project license.
(license license:lppl)))
(define-public texlive-hyphen-portuguese
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-portuguese" "pt"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-pt.tex")
(base32
"00rkjy4p7893zs940bq3s4hp7al0skgxqggj5qfax0bx8karf30b")))
(synopsis "Portuguese hyphenation patterns")
(description "This package provides hyphenation patterns for Portuguese in
T1/EC and UTF-8 encodings.")
(license license:bsd-3)))
(define-public texlive-hyphen-romanian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-romanian" "ro"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-ro.tex")
(base32
"1ykb5v7ip6p3n34wq8qypfyrap4gg946by5rsl6ab0k5gv6ypsbf")))
(synopsis "Romanian hyphenation patterns")
(description "This package provides hyphenation patterns for Romanian in
T1/EC and UTF-8 encodings.")
;; No differing license declared, so we choose the project license.
(license license:lppl)))
(define-public texlive-hyphen-romansh
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-romansh" "rm"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-rm.tex")
(base32
"0a1q9p6sp5n6a9w6xhwk03vmkrrmnh2md7g1k4qhnf0dc4h7dy9r")))
(synopsis "Romansh hyphenation patterns")
(description "This package provides hyphenation patterns for Romansh in
ASCII encodings. They are supposed to comply with the rules indicated by the
Lia Rumantscha (Romansh language society).")
(license license:lppl1.3+)))
(define-public texlive-hyphen-russian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-russian" "ru"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-ru.tex")
(base32
"00sy7qh5f8ryxw36fwbyd1yi2hxhv7hmk99yp7dwh73n4mxv6lpl")))
(synopsis "Russian hyphenation patterns")
(description "This package provides hyphenation patterns for Russian in
T2A and UTF-8 encodings.")
(license license:lppl1.2+)))
(define-public texlive-hyphen-sanskrit
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-sanskrit" "sa"
(list "/doc/generic/hyph-utf8/sa/hyphenmin.txt"
"/tex/generic/hyph-utf8/patterns/tex/hyph-sa.tex")
(base32
"0gi2qk0wf388h9n25gzhv0cdz67ph83wal8h3iz2sqnpdjsw8kpc")))
(synopsis "Sanskrit hyphenation patterns")
(description "This package provides hyphenation patterns for Sanskrit and
Prakrit in longdesc transliteration, and in Devanagari, Bengali, Kannada,
Malayalam longdesc and Telugu scripts for Unicode engines.")
;; "You may freely use, copy, modify and/or distribute this file."
(license (license:non-copyleft
"file:///tex/generic/hyph-utf8/patterns/tex/hyph-sa.tex"))))
(define-public texlive-hyphen-serbian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-serbian" '("sh-cyrl" "sh-latn" "sr-cyrl")
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-sh-cyrl.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-sh-latn.tex"
"/tex/generic/hyph-utf8/patterns/tex/hyph-sr-cyrl.tex")
(base32
"0pwc9z0m5y6acq1vqm0da9akg156jbhxzvsfp2f8bsz5b99y5z45")))
(synopsis "Serbian hyphenation patterns")
(description "This package provides hyphenation patterns for Serbian in
T1/EC, T2A and UTF-8 encodings.")
;; Any version of the GPL.
(license license:gpl3+)))
(define-public texlive-hyphen-slovak
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-slovak" "sk"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-sk.tex")
(base32
"0ppp53bbclp5c8wvx748krvrp5y5053khgkjnnv966a90fvp3vgd")))
(synopsis "Slovak hyphenation patterns")
(description "This package provides hyphenation patterns for Slovak in
T1/EC and UTF-8 encodings.")
(license license:gpl2+)))
(define-public texlive-hyphen-slovenian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-slovenian" "sl"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-sl.tex")
(base32
"02n8l9yf4hqyhbpsc1n6b2mggy09z6lq4dcb8ndiwawb6h0mp7s4")))
(synopsis "Slovenian hyphenation patterns")
(description "This package provides hyphenation patterns for Slovenian in
T1/EC and UTF-8 encodings.")
;; Either license
(license (list license:lppl1.0+ license:expat))))
(define-public texlive-hyphen-spanish
(package
;; The source files "eshyph-make.lua" and "eshyph.src" are provided to
;; generate obsolete hyphenation patterns, which aren't included in a
;; default TeX Live distribution, so we don't include them either.
(inherit (texlive-hyphen-package
"texlive-hyphen-spanish" "es"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-es.tex")
(base32
"1h3yg9vcq0lf7hxv0ahkqmyg269dxjs8m2mz8sgz5l1fxmvahvaj")))
(synopsis "Hyphenation patterns for Spanish")
(description "The package provides hyphenation patterns for Spanish in
T1/EC and UTF-8 encodings.")
(license license:expat)))
(define-public texlive-hyphen-swedish
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-swedish" "sv"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-sv.tex")
(base32
"1n7incy7n24pix1q2i8c3h7i78zpql5ayhskavlmy6mhd7ayncaw")))
(synopsis "Swedish hyphenation patterns")
(description "This package provides hyphenation patterns for Swedish in
T1/EC and UTF-8 encodings.")
(license license:lppl1.2+)))
(define-public texlive-hyphen-thai
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-thai" "th"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-th.tex")
(base32
"00gxcs4jfqifd5cnrjipn77m73fmpw2qms4lp216jj3kz4a7h9kf")))
(synopsis "Thai hyphenation patterns")
(description "This package provides hyphenation patterns for Thai in LTH
and UTF-8 encodings.")
(license license:lppl1.3+)))
(define-public texlive-hyphen-turkish
(let ((template (texlive-hyphen-package
"texlive-hyphen-turkish" "tr"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-tr.tex")
(base32
"04sihjgpm31i5bi67rrfp15w3imn7hxwwk70v0vhx053ghxy72vh"))))
(package
(inherit template)
(synopsis "Hyphenation patterns for Turkish")
(description "The package provides hyphenation patterns for Turkish in
T1/EC and UTF-8 encodings. The patterns for Turkish were first produced for
the Ottoman Texts Project in 1987 and were suitable for both Modern Turkish
and Ottoman Turkish in Latin script, however the required character set didn't
fit into EC encoding, so support for Ottoman Turkish had to be dropped to keep
compatibility with 8-bit engines.")
(license license:lppl1.0+))))
(define-public texlive-hyphen-turkmen
(let ((template (texlive-hyphen-package
"texlive-hyphen-turkmen" "tk"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-tk.tex")
(base32
"0g5ip2lw9g47s61mv3cypswc6qm7zy9c4iqq4h19ysvds81adzkr"))))
(package
(inherit template)
(synopsis "Hyphenation patterns for Turkmen")
(description "The package provides hyphenation patterns for Turkmen in
T1/EC and UTF-8 encodings.")
(license license:expat))))
(define-public texlive-hyphen-ukrainian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-ukrainian" "uk"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-uk.tex")
(base32
"0fbfhx1fmbshxr4ihsjaqgx251h69h7i288p8gh3w6ysgxr53p60")))
(synopsis "Ukrainian hyphenation patterns")
(description "This package provides hyphenation patterns for Ukrainian in
T2A and UTF-8 encodings.")
;; No version specified
(license license:lppl)))
(define-public texlive-hyphen-uppersorbian
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-uppersorbian" "hsb"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-hsb.tex")
(base32
"0x0051wph3sqmzzw6prvjy6bp7gn02rbmys1bmbc210jk3pkylfj")))
(synopsis "Upper Sorbian hyphenation patterns")
(description "This package provides hyphenation patterns for Upper Sorbian
in T1/EC and UTF-8 encodings.")
(license license:lppl1.3a+)))
(define-public texlive-hyphen-welsh
(package
(inherit (texlive-hyphen-package
"texlive-hyphen-welsh" "cy"
(list "/tex/generic/hyph-utf8/patterns/tex/hyph-cy.tex")
(base32
"1bpxp3jiifdw7waw2idz5j9xgi3526nkxm8mbmsspr4mlf2xyr76")))
(synopsis "Welsh hyphenation patterns")
(description "This package provides hyphenation patterns for Welsh in
T1/EC and UTF-8 encodings.")
;; Either license
(license (list license:lppl1.0+ license:expat))))
(define-public texlive-hyph-utf8
(package
(inherit (simple-texlive-package
"texlive-hyph-utf8"
(list "/source/generic/hyph-utf8/"
"/source/luatex/hyph-utf8/"
"/doc/luatex/hyph-utf8/"
"/tex/luatex/hyph-utf8/etex.src"
;; Used to extract luatex-hyphen.lua
"/tex/latex/base/docstrip.tex"
;; Documentation; we can't use the whole directory because
;; it includes files from other packages.
"/doc/generic/hyph-utf8/CHANGES"
"/doc/generic/hyph-utf8/HISTORY"
"/doc/generic/hyph-utf8/hyph-utf8.pdf"
"/doc/generic/hyph-utf8/hyph-utf8.tex"
"/doc/generic/hyph-utf8/hyphenation-distribution.pdf"
"/doc/generic/hyph-utf8/hyphenation-distribution.tex"
"/doc/generic/hyph-utf8/img/miktex-languages.png"
"/doc/generic/hyph-utf8/img/texlive-collection.png")
(base32
"1bar5mc808ch20anhqrdxcwiych359qsvr7mggxpg2l2kq5xdyq0")))
(outputs '("out" "doc"))
(build-system gnu-build-system)
(arguments
`(#:tests? #f ; there are none
#:modules ((guix build gnu-build-system)
(guix build utils)
(ice-9 match))
#:make-flags
(list "-C" "source/luatex/hyph-utf8/"
(string-append "DO_TEX = tex --interaction=nonstopmode '&tex' $<")
(string-append "RUNDIR =" (assoc-ref %outputs "out") "/share/texmf-dist/tex/luatex/hyph-utf8/")
(string-append "DOCDIR =" (assoc-ref %outputs "doc") "/share/texmf-dist/doc/luatex/hyph-utf8/")
;; hyphen.cfg is neither included nor generated, so let's only build the lua file.
(string-append "UNPACKED = $(NAME).lua"))
#:phases
(modify-phases %standard-phases
;; TeX isn't usable at this point, so we first need to generate the
;; tex.fmt.
(replace 'configure
(lambda* (#:key inputs outputs #:allow-other-keys)
;; Target directories must exist.
(mkdir-p (string-append (assoc-ref %outputs "out")
"/share/texmf-dist/tex/luatex/hyph-utf8/"))
(mkdir-p (string-append (assoc-ref %outputs "doc")
"/share/texmf-dist/doc/luatex/hyph-utf8/"))
;; We cannot build the documentation because that requires a
;; fully functional pdflatex, which depends on this package.
(substitute* "source/luatex/hyph-utf8/Makefile"
(("all: .*") "all: $(RUNFILES)\n"))
;; Find required fonts for building tex.fmt
(setenv "TFMFONTS"
(string-append (assoc-ref inputs "texlive-cm")
"/share/texmf-dist/fonts/tfm/public/cm:"
(assoc-ref inputs "texlive-fonts-knuth-lib")
"/share/texmf-dist/fonts/tfm/public/knuth-lib"))
;; ...and find all tex files in this environment.
(setenv "TEXINPUTS"
(string-append
(getcwd) ":"
(string-join
(map (match-lambda ((_ . dir) dir)) inputs)
"//:")))
;; Generate tex.fmt.
(let ((where "source/luatex/hyph-utf8"))
(mkdir-p where)
(with-directory-excursion where
(invoke "tex" "-ini"
(string-append (assoc-ref inputs "texlive-tex-plain")
"/share/texmf-dist/tex/plain/config/tex.ini"))))))
(add-before 'build 'build-loaders-and-converters
(lambda* (#:key outputs #:allow-other-keys)
(let* ((root (string-append (assoc-ref outputs "out")
"/share/texmf-dist"))
(conv
(string-append root
"/tex/generic/hyph-utf8/conversions")))
;; Build converters
(mkdir-p conv)
(with-directory-excursion "source/generic/hyph-utf8"
(substitute* "generate-converters.rb"
(("\\$path_root=File.*")
(string-append "$path_root=\"" root "\"\n"))
;; Avoid error with newer Ruby.
(("#1\\{%") "#1{%%"))
(invoke "ruby" "generate-converters.rb"))
#t)))
(replace 'install
(lambda* (#:key source outputs #:allow-other-keys)
(let ((doc (assoc-ref outputs "doc"))
(out (assoc-ref outputs "out")))
(mkdir-p doc)
(copy-recursively
(string-append source "/doc")
(string-append doc "/doc"))
(install-file
(string-append source "/tex/luatex/hyph-utf8/etex.src")
(string-append out "/share/texmf-dist/tex/luatex/hyph-utf8/")))
#t)))))
(native-inputs
`(("ruby" ,ruby)
("texlive-bin" ,texlive-bin)
;; The following packages are needed for build "tex.fmt", which we need
;; for a working "tex".
("texlive-tex-plain" ,texlive-tex-plain)
("texlive-cm" ,texlive-cm)
("texlive-fonts-knuth-lib" ,texlive-fonts-knuth-lib)
("texlive-hyphen-base" ,texlive-hyphen-base)))
(home-page "https://ctan.org/pkg/hyph-utf8")
(synopsis "Hyphenation patterns expressed in UTF-8")
(description "Modern native UTF-8 engines such as XeTeX and LuaTeX need
hyphenation patterns in UTF-8 format, whereas older systems require
hyphenation patterns in the 8-bit encoding of the font in use (such encodings
are codified in the LaTeX scheme with names like OT1, T2A, TS1, OML, LY1,
etc). The present package offers a collection of conversions of existing
patterns to UTF-8 format, together with converters for use with 8-bit fonts in
older systems. Since hyphenation patterns for Knuthian-style TeX systems are
only read at iniTeX time, it is hoped that the UTF-8 patterns, with their
converters, will completely supplant the older patterns.")
;; Individual files each have their own license. Most of these files are
;; independent hyphenation patterns.
(license (list license:lppl1.0+
license:lppl1.2+
license:lppl1.3
license:lppl1.3+
license:lppl1.3a+
license:lgpl2.1
license:lgpl2.1+
license:lgpl3+
license:gpl2+
license:gpl3+
license:mpl1.1
license:asl2.0
license:expat
license:bsd-3
license:cc0
license:public-domain
license:wtfpl2))))
(define-public texlive-generic-hyph-utf8
(deprecated-package "texlive-generic-hyph-utf8" texlive-hyph-utf8))
(define-public texlive-dehyph-exptl
(package
(inherit (simple-texlive-package
"texlive-dehyph-exptl"
(list "/tex/generic/dehyph-exptl/"
"/doc/generic/dehyph-exptl/")
(base32
"1fnqc63gz8gvdyfz45bx8dxn1r1rwrypahs3bqd2vlc8ff76xp86")
#:trivial? #t))
(propagated-inputs
`(("texlive-hyphen-base" ,texlive-hyphen-base)
("texlive-hyph-utf8" ,texlive-hyph-utf8)))
(home-page "http://projekte.dante.de/Trennmuster/WebHome")
(synopsis "Hyphenation patterns for German")
(description "The package provides experimental hyphenation patterns for
the German language, covering both traditional and reformed orthography. The
patterns can be used with packages Babel and hyphsubst from the Oberdiek
bundle.")
;; Hyphenation patterns are under the Expat license; documentation is
;; under LPPL.
(license (list license:expat license:lppl))))
(define-public texlive-generic-dehyph-exptl
(deprecated-package "texlive-generic-dehyph-exptl" texlive-dehyph-exptl))
(define-public texlive-ukrhyph
(package
(inherit (simple-texlive-package
"texlive-ukrhyph"
(list "/doc/generic/ukrhyph/"
"/tex/generic/ukrhyph/")
(base32
"01ma274sixcrbpb7fpqkxwfvrnzfj2srv9b4a42rfnph1pdql74z")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/ukrhyph")
(synopsis "Hyphenation patterns for Ukrainian")
(description "The package provides a range of hyphenation patterns for
Ukrainian, depending on the encoding of the output font including the standard
T2A.")
(license license:lppl)))
(define-public texlive-ruhyphen
(let ((template (simple-texlive-package
"texlive-ruhyphen"
(list "/source/generic/ruhyphen/"
"/tex/generic/ruhyphen/")
(base32
"18n1bqhh8jv765vz3a3fjwffy7m71vhwx9yq8zl0p5j7p72q9qcn")
#:trivial? #t)))
(package
(inherit template)
(arguments
(substitute-keyword-arguments (package-arguments template)
((#:phases phases)
`(modify-phases ,phases
(replace 'build
(lambda _
(let ((cwd (getcwd)))
;; Remove generated files.
(for-each delete-file
(find-files "tex/generic/ruhyphen/"
"^cyry.*.tex$"))
(substitute* "source/generic/ruhyphen/Makefile"
(("./mkcyryo") (string-append cwd "/source/generic/ruhyphen/mkcyryo")))
(with-directory-excursion "tex/generic/ruhyphen"
(invoke "make" "-f"
(string-append cwd "/source/generic/ruhyphen/Makefile"))))))))))
(native-inputs
`(("coreutils" ,coreutils)
("gawk" ,gawk)
("sed" ,sed)
("grep" ,grep)
("perl" ,perl)))
(home-page "https://www.ctan.org/pkg/ruhyphen")
(synopsis "Hyphenation patterns for Russian")
(description "The package provides a collection of Russian hyphenation
patterns supporting a number of Cyrillic font encodings, including T2,
UCY (Omega Unicode Cyrillic), LCY, LWN (OT2), and koi8-r.")
(license license:lppl))))
(define-public texlive-kpathsea
(package
(inherit (simple-texlive-package
"texlive-kpathsea"
(list "/web2c/amiga-pl.tcx"
"/web2c/cp1250cs.tcx"
"/web2c/cp1250pl.tcx"
"/web2c/cp1250t1.tcx"
"/web2c/cp227.tcx"
"/web2c/cp852-cs.tcx"
"/web2c/cp852-pl.tcx"
"/web2c/cp8bit.tcx"
"/web2c/empty.tcx"
"/web2c/fmtutil.cnf"
"/web2c/il1-t1.tcx"
"/web2c/il2-cs.tcx"
"/web2c/il2-pl.tcx"
"/web2c/il2-t1.tcx"
"/web2c/kam-cs.tcx"
"/web2c/kam-t1.tcx"
"/web2c/macce-pl.tcx"
"/web2c/macce-t1.tcx"
"/web2c/maz-pl.tcx"
"/web2c/mktex.cnf"
"/web2c/mktex.opt"
"/web2c/mktexdir"
"/web2c/mktexdir.opt"
"/web2c/mktexnam"
"/web2c/mktexnam.opt"
"/web2c/mktexupd"
"/web2c/natural.tcx"
"/web2c/tcvn-t5.tcx"
"/web2c/viscii-t5.tcx")
(base32
"191i8n3g46p53bb9dkx2ggwpzy7skgg0pbklsrpx8x4ayd86wcaf")
#:trivial? #t))
(home-page "https://www.tug.org/texlive/")
(synopsis "Files related to the path searching library for TeX")
(description "Kpathsea is a library and utility programs which provide
path searching facilities for TeX file types, including the self-locating
feature required for movable installations, layered on top of a general search
mechanism. This package provides supporting files.")
(license license:lgpl3+)))
(define-public texlive-latexconfig
(package
(inherit (simple-texlive-package
"texlive-latexconfig"
(list "/tex/latex/latexconfig/")
(base32
"1wa7yhdpnz1nyidwgli68fyr33jn951bnniqrih5lj98k09rqc3h")
#:trivial? #t))
(home-page "https://www.tug.org/")
(synopsis "Configuration files for LaTeX-related formats")
(description "The package provides configuration files for LaTeX-related
formats.")
(license license:lppl)))
(define-public texlive-latex-base
(let ((template (simple-texlive-package
"texlive-latex-base"
(list "/doc/latex/base/"
"/source/latex/base/"
;; Almost all files in /tex/latex/base are generated, but
;; these are not:
"/tex/latex/base/idx.tex"
"/tex/latex/base/lablst.tex"
"/tex/latex/base/ltnews.cls"
"/tex/latex/base/ltxcheck.tex"
"/tex/latex/base/ltxguide.cls"
"/tex/latex/base/minimal.cls"
"/tex/latex/base/sample2e.tex"
"/tex/latex/base/small2e.tex"
"/tex/latex/base/testpage.tex"
"/tex/latex/base/texsys.cfg")
(base32
"0m0gjb4hbsf2iqkkx3px4f28r2scjvsjv4zb2whkbnb44apyw1f0")
#:trivial? #t)))
(package
(inherit template)
(arguments
(substitute-keyword-arguments (package-arguments template)
((#:modules modules '())
'((guix build gnu-build-system)
(guix build utils)
(ice-9 match)
(srfi srfi-26)))
((#:phases phases)
`(modify-phases ,phases
;; The literal tab in the dtx file is translated to the string
;; "^^I" in the generated Lua file, which causes a syntax error.
(add-after 'unpack 'fix-lua-sources
(lambda _
(substitute* "source/latex/base/ltluatex.dtx"
((" ") " "))
#t))
(replace 'build
(lambda* (#:key inputs #:allow-other-keys)
;; Find required fonts
(setenv "TFMFONTS"
(string-join
(map (match-lambda
((pkg-name . dir)
(string-append
(assoc-ref inputs pkg-name)
"/share/texmf-dist/fonts/tfm/public"
dir)))
'(("texlive-etex" . "/etex")
("texlive-cm" . "/cm")
("texlive-fonts-latex" . "/latex-fonts")
("texlive-fonts-knuth-lib" . "/knuth-lib")))
":"))
(let ((cwd (getcwd)))
(setenv "TEXINPUTS"
(string-append
cwd "//:"
cwd "/source/latex/base//:"
cwd "/build:"
(string-join
(map (match-lambda ((_ . dir) dir)) inputs)
"//:"))))
;; This is the actual build step.
(mkdir "build")
(invoke "tex" "-ini" "-interaction=scrollmode"
"-output-directory=build" "unpack.ins")
;; XXX: We can't build all formats at this point, nor are they
;; part of the LaTeX base, so we disable them. Actually, we
;; should be running this all in a profile hook, so that only
;; selected formats and hyphenation patterns are included, but it
;; takes long and TeX Live isn't designed to be modular like
;; that. Everything operates on a shared directory, which we
;; would only have at profile generation time.
(let ((disabled-formats
'("aleph aleph" "lamed aleph" "uptex uptex" "euptex euptex"
"eptex eptex" "ptex ptex" "pdfxmltex pdftex" "platex eptex"
"csplain pdftex" "mf mf-nowin" "mex pdftex" "pdfmex pdftex"
"luacsplain luatex"
"cont-en xetex" "cont-en pdftex" "pdfcsplain xetex"
"pdfcsplain pdftex" "pdfcsplain luatex" "cslatex pdftex"
"mptopdf pdftex" "uplatex euptex" "jadetex pdftex"
"amstex pdftex" "pdfcslatex pdftex" "lollipop tex"
"xmltex pdftex" "pdfjadetex pdftex" "eplain pdftex"
"texsis pdftex" "mltex pdftex" "utf8mex pdftex")))
(mkdir "web2c")
(install-file (string-append
(assoc-ref inputs "texlive-kpathsea")
"/share/texmf-dist/web2c/fmtutil.cnf")
"web2c")
(make-file-writable "web2c/fmtutil.cnf")
(substitute* "web2c/fmtutil.cnf"
(((string-append "^(" (string-join disabled-formats "|") ")") m)
(string-append "#! " m))))
(invoke "fmtutil-sys" "--all"
"--fmtdir=web2c"
(string-append "--cnffile=web2c/fmtutil.cnf"))
;; We don't actually want to install it.
(delete-file "web2c/fmtutil.cnf")
#t))
(add-after 'install 'install-more
(lambda* (#:key inputs outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(root (string-append out "/share/texmf-dist"))
(target (string-append root "/tex/latex/base"))
(web2c (string-append root "/web2c"))
(makeindex (string-append root "/makeindex/latex")))
(for-each delete-file (find-files "." "\\.(log|aux)$"))
;; The usedir directive in docstrip.ins is ignored, so these
;; two files end up in the wrong place. Move them.
(mkdir-p makeindex)
(for-each (lambda (file)
(install-file file makeindex)
(delete-file file))
'("build/gglo.ist"
"build/gind.ist"))
(for-each (cut install-file <> target)
(find-files "build" ".*"))
(for-each (cut install-file <> web2c)
(find-files "web2c" ".*"))
#t)))))))
(native-inputs
`(("texlive-bin" ,texlive-bin)
("texlive-tex-ini-files" ,texlive-tex-ini-files)
("texlive-tex-plain" ,texlive-tex-plain)
("texlive-kpathsea" ,texlive-kpathsea)
("texlive-cm" ,texlive-cm)
("texlive-fonts-latex" ,texlive-fonts-latex)
("texlive-fonts-knuth-lib" ,texlive-fonts-knuth-lib)
("texlive-luatexconfig"
,(texlive-origin
"texlive-luatexconfig" (number->string %texlive-revision)
(list "/tex/generic/config/luatex-unicode-letters.tex"
"/tex/generic/config/luatexiniconfig.tex"
"/web2c/texmfcnf.lua")
(base32
"1gi87wy12r8w8fhx9ajcid382dmqzf6b9070b5nndvbbjrvhwf23")))))
(propagated-inputs
`(("texlive-dehyph-exptl" ,texlive-dehyph-exptl)
("texlive-etex" ,texlive-etex)
("texlive-hyph-utf8" ,texlive-hyph-utf8)
("texlive-hyphen-base" ,texlive-hyphen-base)
("texlive-hyphen-afrikaans" ,texlive-hyphen-afrikaans)
("texlive-hyphen-ancientgreek" ,texlive-hyphen-ancientgreek)
("texlive-hyphen-armenian" ,texlive-hyphen-armenian)
("texlive-hyphen-basque" ,texlive-hyphen-basque)
("texlive-hyphen-belarusian" ,texlive-hyphen-belarusian)
("texlive-hyphen-bulgarian" ,texlive-hyphen-bulgarian)
("texlive-hyphen-catalan" ,texlive-hyphen-catalan)
("texlive-hyphen-chinese" ,texlive-hyphen-chinese)
("texlive-hyphen-churchslavonic" ,texlive-hyphen-churchslavonic)
("texlive-hyphen-coptic" ,texlive-hyphen-coptic)
("texlive-hyphen-croatian" ,texlive-hyphen-croatian)
("texlive-hyphen-czech" ,texlive-hyphen-czech)
("texlive-hyphen-danish" ,texlive-hyphen-danish)
("texlive-hyphen-dutch" ,texlive-hyphen-dutch)
("texlive-hyphen-english" ,texlive-hyphen-english)
("texlive-hyphen-esperanto" ,texlive-hyphen-esperanto)
("texlive-hyphen-estonian" ,texlive-hyphen-estonian)
("texlive-hyphen-ethiopic" ,texlive-hyphen-ethiopic)
("texlive-hyphen-finnish" ,texlive-hyphen-finnish)
("texlive-hyphen-french" ,texlive-hyphen-french)
("texlive-hyphen-friulan" ,texlive-hyphen-friulan)
("texlive-hyphen-galician" ,texlive-hyphen-galician)
("texlive-hyphen-georgian" ,texlive-hyphen-georgian)
("texlive-hyphen-german" ,texlive-hyphen-german)
("texlive-hyphen-greek" ,texlive-hyphen-greek)
("texlive-hyphen-hungarian" ,texlive-hyphen-hungarian)
("texlive-hyphen-icelandic" ,texlive-hyphen-icelandic)
("texlive-hyphen-indic" ,texlive-hyphen-indic)
("texlive-hyphen-indonesian" ,texlive-hyphen-indonesian)
("texlive-hyphen-interlingua" ,texlive-hyphen-interlingua)
("texlive-hyphen-irish" ,texlive-hyphen-irish)
("texlive-hyphen-italian" ,texlive-hyphen-italian)
("texlive-hyphen-kurmanji" ,texlive-hyphen-kurmanji)
("texlive-hyphen-latin" ,texlive-hyphen-latin)
("texlive-hyphen-latvian" ,texlive-hyphen-latvian)
("texlive-hyphen-lithuanian" ,texlive-hyphen-lithuanian)
("texlive-hyphen-mongolian" ,texlive-hyphen-mongolian)
("texlive-hyphen-norwegian" ,texlive-hyphen-norwegian)
("texlive-hyphen-occitan" ,texlive-hyphen-occitan)
("texlive-hyphen-pali" ,texlive-hyphen-pali)
("texlive-hyphen-piedmontese" ,texlive-hyphen-piedmontese)
("texlive-hyphen-polish" ,texlive-hyphen-polish)
("texlive-hyphen-portuguese" ,texlive-hyphen-portuguese)
("texlive-hyphen-romanian" ,texlive-hyphen-romanian)
("texlive-hyphen-romansh" ,texlive-hyphen-romansh)
("texlive-hyphen-russian" ,texlive-hyphen-russian)
("texlive-hyphen-sanskrit" ,texlive-hyphen-sanskrit)
("texlive-hyphen-serbian" ,texlive-hyphen-serbian)
("texlive-hyphen-slovak" ,texlive-hyphen-slovak)
("texlive-hyphen-slovenian" ,texlive-hyphen-slovenian)
("texlive-hyphen-spanish" ,texlive-hyphen-spanish)
("texlive-hyphen-swedish" ,texlive-hyphen-swedish)
("texlive-hyphen-thai" ,texlive-hyphen-thai)
("texlive-hyphen-turkish" ,texlive-hyphen-turkish)
("texlive-hyphen-turkmen" ,texlive-hyphen-turkmen)
("texlive-hyphen-ukrainian" ,texlive-hyphen-ukrainian)
("texlive-hyphen-uppersorbian" ,texlive-hyphen-uppersorbian)
("texlive-hyphen-welsh" ,texlive-hyphen-welsh)
("texlive-unicode-data" ,texlive-unicode-data)
("texlive-ukrhyph" ,texlive-ukrhyph)
("texlive-ruhyphen" ,texlive-ruhyphen)
("texlive-latexconfig" ,texlive-latexconfig)))
(home-page "https://www.ctan.org/pkg/latex-base")
(synopsis "Base sources of LaTeX")
(description
"This bundle comprises the source of LaTeX itself, together with several
packages which are considered \"part of the kernel\". This bundle, together
with the required packages, constitutes what every LaTeX distribution should
contain.")
(license license:lppl1.3c+))))
(define-public texlive-latex-filecontents
(package
(name "texlive-latex-filecontents")
(version (number->string %texlive-revision))
(source (origin
(method svn-fetch)
(uri (texlive-ref "latex" "filecontents"))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"1h78zw0vhldx478zs4v86ajg7vpkysd1kg3npc480qqls3q6ba40"))))
(build-system texlive-build-system)
(arguments '(#:tex-directory "latex/filecontents"))
(home-page "https://www.ctan.org/pkg/filecontents")
(synopsis "Extended filecontents and filecontents* environments")
(description
"LaTeX2e's @code{filecontents} and @code{filecontents*} environments
enable a LaTeX source file to generate external files as it runs through
LaTeX. However, there are two limitations of these environments: they refuse
to overwrite existing files, and they can only be used in the preamble of a
document. The filecontents package removes these limitations, letting you
overwrite existing files and letting you use @code{filecontents} /
@code{filecontents*} anywhere.")
(license license:lppl1.3c+)))
(define-public texlive-generic-ifxetex
(package
(name "texlive-generic-ifxetex")
(version (number->string %texlive-revision))
(source (origin
(method svn-fetch)
(uri (texlive-ref "generic" "ifxetex"))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"0w2xj7n0szavj329kds09q626szkc378p3w0sk022q0ln4ksz86d"))))
(build-system texlive-build-system)
(arguments
'(#:tex-directory "generic/ifxetex"
#:tex-format "xelatex"))
(inputs
`(("texlive-latex-filecontents" ,texlive-latex-filecontents)))
(home-page "https://www.ctan.org/pkg/ifxetex")
(synopsis "Am I running under XeTeX?")
(description
"This is a simple package which provides an @code{\\ifxetex} conditional,
so that other code can determine that it is running under XeTeX. The package
requires the e-TeX extensions to the TeX primitive set.")
(license license:lppl1.3c+)))
(define-public texlive-epsf
(package
(inherit (simple-texlive-package
"texlive-epsf"
(list "/doc/generic/epsf/"
"/tex/generic/epsf/")
(base32
"03jcf0kqh47is965d2590miwj7d5kif3c4mgsnvkyl664jzjkh92")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/epsf")
(synopsis "Simple macros for EPS inclusion")
(description
"This package provides the original (and now obsolescent) graphics
inclusion macros for use with dvips, still widely used by Plain TeX users (in
particular). For LaTeX users, the package is nowadays (rather strongly)
deprecated in favour of the more sophisticated standard LaTeX latex-graphics
bundle of packages. (The latex-graphics bundle is also available to Plain TeX
users, via its Plain TeX version.)")
(license license:public-domain)))
(define-public texlive-generic-epsf
(deprecated-package "texlive-generic-epsf" texlive-epsf))
(define-public texlive-latex-fancyvrb
(package
(inherit (simple-texlive-package
"texlive-latex-fancyvrb"
(list "/doc/latex/fancyvrb/README"
"/tex/latex/fancyvrb/")
(base32
"1dwkcradz9nwpjwmv1sjzn77lvw25ypr0rrgmf1kd8pd2mw7dxcn")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/fancyvrb")
(synopsis "Sophisticated verbatim text")
(description
"This package provides tools for the flexible handling of verbatim text
including: verbatim commands in footnotes; a variety of verbatim environments
with many parameters; ability to define new customized verbatim environments;
save and restore verbatim text and environments; write and read files in
verbatim mode; build \"example\" environments (showing both result and
verbatim source).")
(license license:lppl1.0+)))
(define-public texlive-graphics-def
(package
(inherit (simple-texlive-package
"texlive-graphics-def"
(list "/doc/latex/graphics-def/README.md"
"/tex/latex/graphics-def/")
(base32
"0zrbn9cwfnnrrl3b2zsd74ldksp9jwpvjh7z93ild1m75crpb39a")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/latex-graphics")
(synopsis "Color and graphics option files")
(description
"This bundle is a combined distribution consisting of @file{dvips.def},
@file{pdftex.def}, @file{luatex.def}, @file{xetex.def}, @file{dvipdfmx.def},
and @file{dvisvgm.def} driver option files for the LaTeX graphics and color
packages.")
(license license:lppl1.3c+)))
(define-public texlive-graphics-cfg
(package
(inherit (simple-texlive-package
"texlive-graphics-cfg"
(list "/doc/latex/graphics-cfg/README.md"
"/tex/latex/graphics-cfg/")
(base32
"00n63adb2laf43lzix39xl68aq0k5k80mmrw602w99w5n7f96gsf")
#:trivial? #t))
(home-page "https://www.ctan.org/pkg/latex-graphics")
(synopsis "Sample configuration files for LaTeX color and graphics")
(description
"This bundle includes @file{color.cfg} and @file{graphics.cfg} files that
set default \"driver\" options for the color and graphics packages.")
(license license:public-domain)))
(define-public texlive-latex-graphics
(package
(name "texlive-latex-graphics")
(version (number->string %texlive-revision))
(source (origin
(method svn-fetch)
(uri (texlive-ref "latex" "graphics"))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"0nlfhn55ax89rcvpkrl9570671b62kcr4c9l5ch3w5zw9vmi00dz"))))
(build-system texlive-build-system)
(arguments '(#:tex-directory "latex/graphics"))
(propagated-inputs
`(("texlive-graphics-cfg" ,texlive-graphics-cfg)
("texlive-graphics-def" ,texlive-graphics-def)))
(home-page "https://www.ctan.org/pkg/latex-graphics")
(synopsis "LaTeX standard graphics bundle")
(description
"This is a collection of LaTeX packages for producing color, including
graphics (e.g. PostScript) files, and rotation and scaling of text in LaTeX
documents. It comprises the packages color, graphics, graphicx, trig, epsfig,
keyval, and lscape.")
(license license:lppl1.3c+)))
(define-public texlive-xcolor
(let ((template (simple-texlive-package
"texlive-xcolor"
(list "/doc/latex/xcolor/"
"/source/latex/xcolor/")
(base32
"12q6spmpxg30alhvarjmxzigmz7lazapbrb0mc4vhbn6n1sdz7pp"))))
(package
(inherit template)
(arguments
(substitute-keyword-arguments (package-arguments template)
((#:tex-directory _ #t)
"latex/xcolor")
((#:phases phases)
`(modify-phases ,phases
(add-after 'unpack 'chdir
(lambda _ (chdir "source/latex/xcolor") #t))
(add-after 'install 'move-files
(lambda* (#:key outputs #:allow-other-keys)
(let ((share (string-append (assoc-ref outputs "out")
"/share/texmf-dist")))
(mkdir-p (string-append share "/dvips/xcolor"))
(rename-file (string-append share "/tex/latex/xcolor/xcolor.pro")
(string-append share "/dvips/xcolor/xcolor.pro"))
#t)))))))
(home-page "https://www.ctan.org/pkg/xcolor")
(synopsis "Driver-independent color extensions for LaTeX and pdfLaTeX")
(description
"The package starts from the basic facilities of the colorcolor package,
and provides easy driver-independent access to several kinds of color tints,
shades, tones, and mixes of arbitrary colors. It allows a user to select a
document-wide target color model and offers complete tools for conversion
between eight color models. Additionally, there is a command for alternating
row colors plus repeated non-aligned material (like horizontal lines) in
tables.")
(license license:lppl1.2+))))
(define-public texlive-latex-xcolor
(deprecated-package "texlive-latex-xcolor" texlive-xcolor))
(define-public texlive-latex-hyperref
(package
(name "texlive-latex-hyperref")
(version "6.84a2")
;; The sources in the TeX Live SVN repository do not contain hluatex.dtx,
;; so we fetch the release from GitHub.
(source (origin
(method url-fetch)
(uri (string-append "https://github.com/ho-tex/hyperref/"
"archive/release-" version ".tar.gz"))
(file-name (string-append name "-" version ".tar.gz"))
(sha256
(base32
"1d3rmjgzh0025a1dza55zb6nzzlgd1y9snwx45wq1c1vf42m79h2"))))
(build-system texlive-build-system)
(arguments '(#:tex-directory "latex/hyperref"))
(propagated-inputs
`(("texlive-latex-oberdiek" ,texlive-latex-oberdiek) ; for ltxcmds.sty
("texlive-latex-url" ,texlive-latex-url)))
(home-page "https://www.ctan.org/pkg/hyperref")
(synopsis "Extensive support for hypertext in LaTeX")
(description
"The @code{hyperref} package is used to handle cross-referencing commands
in LaTeX to produce hypertext links in the document. The package provides
backends for the @code{\\special} set defined for HyperTeX DVI processors; for
embedded @code{pdfmark} commands for processing by Acrobat
Distiller (@code{dvips} and Y&Y's @code{dvipsone}); for Y&Y's @code{dviwindo};
for PDF control within pdfTeX and @code{dvipdfm}; for TeX4ht; and for VTeX's
pdf and HTML backends. The package is distributed with the @code{backref} and
@code{nameref} packages, which make use of the facilities of @code{hyperref}.")
(license license:lppl1.3+)))
(define-public texlive-latex-oberdiek
(package
(name "texlive-latex-oberdiek")
(version (number->string %texlive-revision))
(source (origin
(method svn-fetch)
(uri (texlive-ref "latex" "oberdiek"))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"0pi2d6gsddcs9wprdbar46s91kdc5fxl1m79g7xrbccsx8s9xbml"))))
(build-system texlive-build-system)
(arguments
'(#:tex-directory "latex/oberdiek"
#:build-targets '("oberdiek.ins")
#:phases
(modify-phases %standard-phases
;; "ifpdf.ins" is not generated, so we need to process the dtx file.
(add-after 'unpack 'do-not-process-ifpdf.ins
(lambda _
(substitute* "oberdiek.ins"
(("ifpdf.ins") "ifpdf.dtx"))
#t)))))
(propagated-inputs
`(("texlive-generic-ifxetex" ,texlive-generic-ifxetex)))
(home-page "https://www.ctan.org/pkg/oberdiek")
(synopsis "Bundle of packages submitted by Heiko Oberdiek")
(description
"The bundle comprises various LaTeX packages, providing among others:
better accessibility support for PDF files; extensible chemists reaction
arrows; record information about document class(es) used; and many more.")
(license license:lppl1.3+)))
(define-public texlive-latex-tools
(package
(name "texlive-latex-tools")
(version (number->string %texlive-revision))
(source (origin
(method svn-fetch)
(uri (texlive-ref "latex" "tools"))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"1wqvn4z0s92h5iqzrvxw7hinzp95avjk9v8lnqbqr4kz6nv4xb9l"))))
(build-system