gnu: Add texlive-hyphen-coptic.
[jackhill/guix/guix.git] / gnu / packages / tex.scm
CommitLineData
eb0119ef 1;;; GNU Guix --- Functional package management for GNU
4a6635f3 2;;; Copyright © 2013, 2014, 2015, 2016 Andreas Enge <andreas@enge.fr>
42e1394b 3;;; Copyright © 2014 Eric Bavier <bavier@member.fsf.org>
d2e84281 4;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
4791876c 5;;; Copyright © 2016 Roel Janssen <roel@gnu.org>
e5a03489 6;;; Copyright © 2016, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
2d634d9b 7;;; Copyright © 2016 Federico Beffa <beffa@fbengineering.ch>
bd917486 8;;; Copyright © 2016 Thomas Danckaert <post@thomasdanckaert.be>
d68c8017 9;;; Copyright © 2016, 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
149f6688 10;;; Copyright © 2017 Leo Famulari <leo@famulari.name>
594156ec 11;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com>
585be42f 12;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
ec40a050 13;;; Copyright © 2018 Danny Milosavljevic <dannym+a@scratchpost.org>
a9fda571 14;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
eb0119ef
AE
15;;;
16;;; This file is part of GNU Guix.
17;;;
18;;; GNU Guix is free software; you can redistribute it and/or modify it
19;;; under the terms of the GNU General Public License as published by
20;;; the Free Software Foundation; either version 3 of the License, or (at
21;;; your option) any later version.
22;;;
23;;; GNU Guix is distributed in the hope that it will be useful, but
24;;; WITHOUT ANY WARRANTY; without even the implied warranty of
25;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
26;;; GNU General Public License for more details.
27;;;
28;;; You should have received a copy of the GNU General Public License
29;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
30
8f9ac901 31(define-module (gnu packages tex)
b5b73a82 32 #:use-module ((guix licenses) #:prefix license:)
eb0119ef
AE
33 #:use-module (guix packages)
34 #:use-module (guix download)
ec40a050 35 #:use-module (guix build-system cmake)
eb0119ef 36 #:use-module (guix build-system gnu)
ebcf74da 37 #:use-module (guix build-system perl)
0aa34e82 38 #:use-module (guix build-system trivial)
205794c8 39 #:use-module (guix build-system texlive)
6b5eb840 40 #:use-module (guix utils)
83457fe0 41 #:use-module (guix git-download)
9d913b25 42 #:use-module (guix svn-download)
eb0119ef 43 #:use-module (gnu packages)
ec40a050 44 #:use-module (gnu packages algebra)
83457fe0 45 #:use-module (gnu packages autotools)
0aa34e82 46 #:use-module (gnu packages bash)
ec40a050 47 #:use-module (gnu packages boost)
eb0119ef 48 #:use-module (gnu packages compression)
a86177d6 49 #:use-module (gnu packages fontutils)
fd89b36b 50 #:use-module (gnu packages gd)
eb0119ef 51 #:use-module (gnu packages ghostscript)
769bb5e5 52 #:use-module (gnu packages graphviz)
fd89b36b 53 #:use-module (gnu packages gtk)
eb0119ef 54 #:use-module (gnu packages icu4c)
e55354b8 55 #:use-module (gnu packages image)
ec40a050 56 #:use-module (gnu packages libreoffice)
0aa34e82 57 #:use-module (gnu packages lua)
0256c746 58 #:use-module (gnu packages multiprecision)
eb0119ef
AE
59 #:use-module (gnu packages pdf)
60 #:use-module (gnu packages perl)
5ccde207 61 #:use-module (gnu packages perl-check)
eb0119ef
AE
62 #:use-module (gnu packages pkg-config)
63 #:use-module (gnu packages python)
5327e912 64 #:use-module (gnu packages python-xyz)
4791876c 65 #:use-module (gnu packages qt)
b32c8549 66 #:use-module (gnu packages ruby)
b7194849 67 #:use-module (gnu packages shells)
ce0614dd 68 #:use-module (gnu packages base)
d4000680
RW
69 #:use-module (gnu packages web)
70 #:use-module (gnu packages xml)
c0589f75 71 #:use-module (gnu packages xorg)
ece9b417 72 #:use-module (gnu packages xdisorg)
6b5eb840
AE
73 #:autoload (gnu packages texinfo) (texinfo)
74 #:use-module (ice-9 ftw)
cb7bc20a 75 #:use-module (ice-9 match)
e93f472d 76 #:use-module ((srfi srfi-1) #:hide (zip)))
eb0119ef 77
8ab600f8
RW
78(define* (simple-texlive-package name locations hash
79 #:key trivial?)
80 "Return a template for a simple TeX Live package with the given NAME,
81downloading from a list of LOCATIONS in the TeX Live repository, and expecting
82the provided output HASH. If TRIVIAL? is provided, all files will simply be
83copied to their outputs; otherwise the TEXLIVE-BUILD-SYSTEM is used."
84 (define with-documentation?
85 (and trivial?
86 (any (lambda (location)
87 (string-prefix? "/doc" location))
88 locations)))
89 (package
90 (name name)
91 (version (number->string %texlive-revision))
92 (source (texlive-origin name version
93 locations hash))
94 (outputs (if with-documentation?
95 '("out" "doc")
96 '("out")))
97 (build-system (if trivial?
98 gnu-build-system
99 texlive-build-system))
100 (arguments
101 (let ((copy-files
102 `(lambda* (#:key outputs inputs #:allow-other-keys)
103 (let (,@(if with-documentation?
104 `((doc (string-append (assoc-ref outputs "doc")
105 "/share/texmf-dist/")))
106 '())
107 (out (string-append (assoc-ref outputs "out")
108 "/share/texmf-dist/")))
109 ,@(if with-documentation?
110 '((mkdir-p doc)
111 (copy-recursively
112 (string-append (assoc-ref inputs "source") "/doc")
113 (string-append doc "/doc")))
114 '())
115 (mkdir-p out)
116 (copy-recursively (assoc-ref inputs "source") out)
117 ,@(if with-documentation?
118 '((delete-file-recursively (string-append out "/doc")))
119 '())
120 #t))))
121 (if trivial?
122 `(#:tests? #f
123 #:phases
124 (modify-phases %standard-phases
125 (delete 'configure)
126 (replace 'build (const #t))
127 (replace 'install ,copy-files)))
128 `(#:phases
129 (modify-phases %standard-phases
130 (add-after 'install 'copy-files ,copy-files))))))
131 (home-page #f)
132 (synopsis #f)
133 (description #f)
134 (license #f)))
135
28e521e9
RW
136(define hyph-utf8-scripts
137 (origin
138 (method svn-fetch)
139 (uri (texlive-ref "generic" "hyph-utf8"))
140 (file-name (string-append "hyph-utf8-scripts-"
141 (number->string %texlive-revision)
142 "-checkout"))
143 (sha256
144 (base32
145 "1ix8h637hwhz4vrdhilf84kzzdza0wi8fp26nh7iws0bq08sl517"))))
146
cf4c07b9
RW
147(define (texlive-hyphen-package name code locations hash)
148 (let ((parent (simple-texlive-package
149 name locations hash #:trivial? #t)))
150 (package
151 (inherit parent)
152 (arguments
153 (substitute-keyword-arguments (package-arguments parent)
154 ((#:modules _ '())
155 '((guix build gnu-build-system)
156 (guix build utils)
157 (ice-9 match)))
158 ((#:phases phases)
159 `(modify-phases ,phases
160 (replace 'build
161 (lambda* (#:key inputs outputs #:allow-other-keys)
162 (let* ((out (assoc-ref outputs "out"))
163 (root (string-append out "/share/texmf-dist"))
164 (patterns
165 (string-append root "/tex/generic/hyph-utf8/patterns/txt/"))
166 (loaders
167 (string-append root "/tex/generic/hyph-utf8/loadhyph"))
168 (ptex
169 (string-append root "/tex/generic/hyph-utf8/patterns/ptex"))
170 (filter-expression
171 (match ',code
172 ((? string?)
173 (format #f "\nlanguages.select!{|l| l.code == \"~a\"}\n" ',code))
174 ((a b ...)
175 (format #f "\nlanguages.select!{|l| [~{\"~a\",~}].include? l.code }\n" ',code)))))
176 (mkdir "scripts")
177 (copy-recursively
178 (assoc-ref inputs "hyph-utf8-scripts") "scripts")
179
180 ;; Prepare target directories
181 (mkdir-p patterns)
182 (mkdir-p loaders)
183 (mkdir-p ptex)
184
185 ;; Generate plain patterns
186 (with-directory-excursion "scripts"
187 (substitute* "languages.rb"
188 (("../../../tex/generic/") "../tex/generic/"))
189 (substitute* "generate-plain-patterns.rb"
190 ;; Ruby 2 does not need this.
191 (("require 'unicode'") "")
192 (("Unicode.upcase\\(ch\\)") "ch.upcase")
193 ;; Write directly to the output directory
194 (("\\$path_root=File.*")
195 (string-append "$path_root=\"" out "/share/texmf-dist/\"\n"))
196 ;; Create quote directory when needed
197 (("f = File.open\\(\"#\\{\\$path_quote\\}" m)
198 (string-append "require 'fileutils'; FileUtils.mkdir_p $path_quote;" m))
199 ;; Only generate patterns for this language.
200 (("languages =.*" m)
201 (string-append m filter-expression)))
202 (invoke "ruby" "generate-plain-patterns.rb")
203
204 ;; Build pattern loaders
205 (substitute* "generate-pattern-loaders.rb"
206 (("\\$path_tex_generic=File.*")
207 (string-append "$path_tex_generic=\"" root "/tex/generic\"\n"))
208 ;; Only generate loader for this language.
209 (("languages =.*" m)
210 (string-append m filter-expression)))
211 (invoke "ruby" "generate-pattern-loaders.rb")
212
213 ;; Build ptex patterns
214 (substitute* "generate-ptex-patterns.rb"
215 (("\\$path_root=File.*")
216 (string-append "$path_root=\"" root "\"\n"))
217 ;; Only generate ptex patterns for this language.
218 (("languages =.*" m)
219 (string-append m filter-expression)))
220 (invoke "ruby" "generate-ptex-patterns.rb")))))))))
221 (native-inputs
222 `(("ruby" ,ruby)
223 ("hyph-utf8-scripts" ,hyph-utf8-scripts)))
224 (home-page "https://ctan.org/pkg/hyph-utf8"))))
225
eb0119ef
AE
226(define texlive-extra-src
227 (origin
228 (method url-fetch)
3e1ebaab 229 (uri "ftp://tug.org/historic/systems/texlive/2018/texlive-20180414-extra.tar.xz")
eb0119ef 230 (sha256 (base32
3e1ebaab 231 "0a83kymxc8zmlxjb0y1gf6mx7qnf0hxffwkivwh5yh138y2rfhsv"))))
eb0119ef
AE
232
233(define texlive-texmf-src
234 (origin
235 (method url-fetch)
3e1ebaab 236 (uri "ftp://tug.org/historic/systems/texlive/2018/texlive-20180414-texmf.tar.xz")
eb0119ef 237 (sha256 (base32
3e1ebaab 238 "1b8zigzg8raxkhhzphcmynf84rbdbj2ym2qkz24v8n0qx82zmqms"))))
eb0119ef 239
3abe72bd 240(define-public texlive-bin
eb0119ef 241 (package
0aa34e82 242 (name "texlive-bin")
3e1ebaab 243 (version "20180414")
0aa34e82
AE
244 (source
245 (origin
3e1ebaab
RW
246 (method url-fetch)
247 (uri (string-append "ftp://tug.org/historic/systems/texlive/2018/"
149f6688 248 "texlive-" version "-source.tar.xz"))
3e1ebaab
RW
249 (sha256
250 (base32
251 "0khyi6h015r2zfqgg0a44a2j7vmr1cy42knw7jbss237yvakc07y"))
594156ec 252 (patches
0fa50555
MB
253 (let ((arch-patch
254 (lambda (name revision hash)
255 (origin
256 (method url-fetch)
257 (uri (string-append "https://git.archlinux.org/svntogit/packages.git"
258 "/plain/trunk/" name "?h=packages/texlive-bin"
259 "&id=" revision))
260 (file-name (string-append "texlive-bin-" name))
261 (sha256 (base32 hash)))))
262 (arch-revision "e1975bce0b9d270d7c9773c5beb7e87d61ee8f57"))
263 (append (search-patches "texlive-bin-CVE-2018-17407.patch"
264 "texlive-bin-luatex-poppler-compat.patch")
265 (list
266 (arch-patch "pdftex-poppler0.72.patch" arch-revision
267 "0p46b6xxxg2s3hx67r0wpz16g3qygx65hpc581xs3jz5pvsiq3y7")
268 (arch-patch "xetex-poppler-fixes.patch" arch-revision
269 "1jj1p5zkjljb7id9pjv29cw0cf8mwrgrh4ackgzz9c200vaqpsvx")))))))
eb0119ef 270 (build-system gnu-build-system)
0aa34e82
AE
271 (inputs
272 `(("texlive-extra-src" ,texlive-extra-src)
273 ("cairo" ,cairo)
274 ("fontconfig" ,fontconfig)
275 ("fontforge" ,fontforge)
276 ("freetype" ,freetype)
277 ("gd" ,gd)
0256c746 278 ("gmp" ,gmp)
0aa34e82
AE
279 ("ghostscript" ,ghostscript)
280 ("graphite2" ,graphite2)
281 ("harfbuzz" ,harfbuzz)
282 ("icu4c" ,icu4c)
283 ("libpaper" ,libpaper)
284 ("libpng" ,libpng)
285 ("libxaw" ,libxaw)
286 ("libxt" ,libxt)
0256c746 287 ("mpfr" ,mpfr)
0aa34e82
AE
288 ("perl" ,perl)
289 ("pixman" ,pixman)
290 ("poppler" ,poppler)
291 ("potrace" ,potrace)
292 ("python" ,python-2) ; incompatible with Python 3 (print syntax)
293 ("ruby" ,ruby)
294 ("tcsh" ,tcsh)
295 ("teckit" ,teckit)
296 ("zlib" ,zlib)
297 ("zziplib" ,zziplib)))
c4c4cc05 298 (native-inputs
e9a6d225 299 `(("pkg-config" ,pkg-config)))
eb0119ef
AE
300 (arguments
301 `(#:out-of-source? #t
302 #:configure-flags
303 `("--disable-native-texlive-build"
594156ec
MB
304 ;; XXX: This is needed because recent Poppler requires C++11 or later.
305 ;; Remove after switch to GCC >= 6.
306 "CXXFLAGS=-std=gnu++11"
fd89b36b 307 "--with-system-cairo"
eb0119ef 308 "--with-system-freetype2"
fd89b36b 309 "--with-system-gd"
0256c746 310 "--with-system-gmp"
be2c88ca 311 "--with-system-graphite2"
c70cf7eb 312 "--with-system-harfbuzz"
eb0119ef
AE
313 "--with-system-icu"
314 "--with-system-libgs"
609578a7 315 "--with-system-libpaper"
eb0119ef 316 "--with-system-libpng"
0256c746 317 "--with-system-mpfr"
fd89b36b 318 "--with-system-pixman"
eb0119ef 319 "--with-system-poppler"
75916982 320 "--with-system-potrace"
eb0119ef
AE
321 "--with-system-teckit"
322 "--with-system-xpdf"
323 "--with-system-zlib"
324 "--with-system-zziplib")
2f4640e3 325
7683bf11
EB
326 ;; Disable tests on mips64/aarch64 to cope with a failure of luajiterr.test.
327 ;; XXX FIXME fix luajit properly on mips64 and aarch64.
328 #:tests? ,(let ((s (or (%current-target-system)
329 (%current-system))))
330 (not (or (string-prefix? "aarch64" s)
331 (string-prefix? "mips64" s))))
eb0119ef 332 #:phases
3e1ebaab 333 (modify-phases %standard-phases
f1728d43 334 (add-after 'unpack 'configure-ghostscript-executable
3e1ebaab
RW
335 ;; ps2eps.pl uses the "gswin32c" ghostscript executable on Windows,
336 ;; and the "gs" ghostscript executable on Unix. It detects Unix by
337 ;; checking for the existence of the /usr/bin directory. Since
59e80445 338 ;; Guix System does not have /usr/bin, it is also detected as Windows.
f1728d43 339 (lambda* (#:key inputs #:allow-other-keys)
3e1ebaab
RW
340 (substitute* "utils/ps2eps/ps2eps-src/bin/ps2eps.pl"
341 (("gswin32c") "gs"))
f1728d43
RW
342 (substitute* "texk/texlive/linked_scripts/epstopdf/epstopdf.pl"
343 (("\"gs\"")
344 (string-append "\"" (assoc-ref inputs "ghostscript") "/bin/gs\"")))
345 #t))
346 (add-after 'unpack 'use-code-for-new-poppler
347 (lambda _
0fa50555 348 (copy-file "texk/web2c/pdftexdir/pdftoepdf-poppler0.72.0.cc"
f1728d43 349 "texk/web2c/pdftexdir/pdftoepdf.cc")
0fa50555 350 (copy-file "texk/web2c/pdftexdir/pdftosrc-poppler0.72.0.cc"
f1728d43 351 "texk/web2c/pdftexdir/pdftosrc.cc")
3e1ebaab 352 #t))
be200ef3
MB
353 (add-after 'unpack 'disable-failing-test
354 (lambda _
355 ;; FIXME: This test fails on 32-bit architectures since Glibc 2.28:
356 ;; <https://bugzilla.redhat.com/show_bug.cgi?id=1631847>.
357 (substitute* "texk/web2c/omegafonts/check.test"
21f7d88e 358 (("^\\./omfonts -ofm2opl \\$srcdir/tests/check tests/xcheck \\|\\| exit 1")
be200ef3
MB
359 "./omfonts -ofm2opl $srcdir/tests/check tests/xcheck || exit 77"))
360 #t))
3e1ebaab
RW
361 (add-after 'install 'postint
362 (lambda* (#:key inputs outputs #:allow-other-keys #:rest args)
363 (let* ((out (assoc-ref outputs "out"))
364 (share (string-append out "/share"))
365 (texlive-extra (assoc-ref inputs "texlive-extra-src"))
366 (unpack (assoc-ref %standard-phases 'unpack))
367 (patch-source-shebangs
368 (assoc-ref %standard-phases 'patch-source-shebangs)))
1574932d
RW
369 (substitute* (string-append share "/texmf-dist/web2c/texmf.cnf")
370 ;; Don't truncate lines.
371 (("^error_line = .*$") "error_line = 254\n")
372 (("^half_error_line = .*$") "half_error_line = 238\n")
373 (("^max_print_line = .*$") "max_print_line = 1000\n"))
3e1ebaab
RW
374 ;; Create symbolic links for the latex variants and their
375 ;; man pages.
376 (with-directory-excursion (string-append out "/bin/")
377 (for-each symlink
378 '("pdftex" "pdftex" "xetex" "luatex")
379 '("latex" "pdflatex" "xelatex" "lualatex")))
380 (with-directory-excursion (string-append share "/man/man1/")
381 (symlink "luatex.1" "lualatex.1"))
382 ;; Unpack texlive-extra and install tlpkg.
383 (mkdir "texlive-extra")
384 (with-directory-excursion "texlive-extra"
385 (apply unpack (list #:source texlive-extra))
386 (apply patch-source-shebangs (list #:source texlive-extra))
387 (invoke "mv" "tlpkg" share))
388 ;; texlua shebangs are not patched by the patch-source-shebangs
389 ;; phase because the texlua executable does not exist at that
390 ;; time.
391 (setenv "PATH" (string-append (getenv "PATH") ":" out "/bin"))
392 (with-directory-excursion out
393 (patch-source-shebangs))))))))
a1b4d62c
RW
394 (native-search-paths
395 (list (search-path-specification
396 (variable "TEXMF")
397 (files '("share/texmf-dist"))
398 (separator #f))
399 (search-path-specification
400 (variable "TEXMFCNF")
401 (files '("share/texmf-dist/web2c"))
402 (separator #f))))
0aa34e82
AE
403 (synopsis "TeX Live, a package of the TeX typesetting system")
404 (description
405 "TeX Live provides a comprehensive TeX document production system.
406It includes all the major TeX-related programs, macro packages, and fonts
407that are free software, including support for many languages around the
408world.
409
410This package contains the binaries.")
132e14b4
EF
411 (license (license:fsf-free "https://www.tug.org/texlive/copying.html"))
412 (home-page "https://www.tug.org/texlive/")))
0aa34e82 413
2cece695
RW
414\f
415(define-public texlive-unicode-data
416 (package
417 (inherit (simple-texlive-package
418 "texlive-unicode-data"
419 (list "/tex/generic/unicode-data/"
420 "/doc/generic/unicode-data/")
421 (base32
422 "1j63kz29arfiydb8r1a53q1r4zyk1yjbcq0w9i93zddczgqzgbfb")
423 #:trivial? #t))
424 (home-page "https://www.ctan.org/pkg/unicode-data")
425 (synopsis "Unicode data and loaders for TeX")
426 (description "This bundle provides generic access to Unicode Consortium
427data for TeX use. It contains a set of text files provided by the Unicode
428Consortium which are currently all from Unicode 8.0.0, with the exception of
429@code{MathClass.txt} which is not currently part of the Unicode Character
430Database. Accompanying these source data are generic TeX loader files
431allowing this data to be used as part of TeX runs, in particular in building
432format files. Currently there are two loader files: one for general character
433set up and one for initializing XeTeX character classes as has been carried
434out to date by @code{unicode-letters.tex}. ")
435 (license license:lppl1.3c+)))
436
437(define-public texlive-generic-unicode-data
438 (deprecated-package "texlive-generic-unicode-data" texlive-unicode-data))
439
92b4a48c
RW
440(define-public texlive-hyphen-base
441 (package
442 (inherit (simple-texlive-package
443 "texlive-hyphen-base"
444 (list "/tex/generic/config/language.dat"
445 "/tex/generic/config/language.dat.lua"
446 "/tex/generic/config/language.def"
447 "/tex/generic/config/language.us"
448 "/tex/generic/config/language.us.def"
449 "/tex/generic/config/language.us.lua"
450 "/tex/generic/hyphen/dumyhyph.tex"
451 "/tex/generic/hyphen/hyphen.tex"
452 "/tex/generic/hyphen/hypht1.tex"
453 "/tex/generic/hyphen/zerohyph.tex")
454 (base32
455 "002g5zhzbj3ikgg8zidagdp605ac9f4qmfl148mp0mbpz1svk0ni")
456 #:trivial? #t))
457 (home-page "https://tug.org/texlive/")
458 (synopsis "Core hyphenation support files")
459 (description "This package includes Knuth's original @file{hyphen.tex},
460@file{zerohyph.tex} to disable hyphenation, @file{language.us} which starts
461the autogenerated files @file{language.dat} and @file{language.def} (and
462default versions of those), etc.")
463 (license license:knuth)))
464
659fda6c
RW
465;; TODO: This package should not exist. There should not be a single package
466;; containing all of /dvips. These really belong to different packages.
9d913b25
RW
467(define-public texlive-dvips
468 (package
659fda6c
RW
469 (inherit (simple-texlive-package
470 "texlive-dvips"
471 (list "/fonts/map/dvips/"
472 "/fonts/enc/dvips/base/"
473 "/dvips/")
474 (base32
475 "1di07wx8wjczddmagq5z082l2has3inzk5jwkqh4i6wv1qdfqpp6")
476 #:trivial? #t))
b8d8806b 477 (home-page "https://www.ctan.org/pkg/dvips")
9d913b25
RW
478 (synopsis "DVI to PostScript drivers")
479 (description "This package provides files needed for converting DVI files
480to PostScript.")
481 ;; Various free software licenses apply to individual files.
482 (license (list license:lppl1.3c+
483 license:expat
484 license:lgpl3+))))
485
b8df0d1b 486(define-public texlive-tex-ini-files
453aae66 487 (package
b8df0d1b
RW
488 (inherit (simple-texlive-package
489 "texlive-tex-ini-files"
490 (list "/tex/generic/tex-ini-files/")
491 (base32
492 "0q1g62jg0qiqslm93ycvm30bw8ydmssjdshzsnzl7n2vpd62qfi2")
493 #:trivial? #t))
b8d8806b 494 (home-page "https://www.ctan.org/pkg/tex-ini-files")
453aae66
RW
495 (synopsis "Files for creating TeX formats")
496 (description "This bundle provides a collection of model \".ini\" files
497for creating TeX formats. These files are commonly used to introduced
498distribution-dependent variations in formats. They are also used to
499allow existing format source files to be used with newer engines, for example
500to adapt the plain e-TeX source file to work with XeTeX and LuaTeX.")
501 (license license:public-domain)))
502
b8df0d1b
RW
503(define-public texlive-generic-tex-ini-files
504 (deprecated-package "texlive-generic-tex-ini-files" texlive-tex-ini-files))
505
8ada0f0b
RW
506(define-public texlive-metafont-base
507 (package
508 (name "texlive-metafont-base")
509 (version (number->string %texlive-revision))
510 (source (origin
511 (method svn-fetch)
512 (uri (svn-reference
513 (url (string-append "svn://www.tug.org/texlive/tags/"
514 %texlive-tag "/Master/texmf-dist/"
515 "/metafont"))
516 (revision %texlive-revision)))
1dec413a 517 (file-name (string-append name "-" version "-checkout"))
8ada0f0b
RW
518 (sha256
519 (base32
520 "1yl4n8cn5xqk2nc22zgzq6ymd7bhm6xx1mz3azip7i3ki4bhb5q5"))))
521 (build-system gnu-build-system)
522 (arguments
523 `(#:tests? #f ; no test target
524 #:phases
525 (modify-phases %standard-phases
526 (delete 'configure)
527 (replace 'build
528 (lambda* (#:key inputs #:allow-other-keys)
529 (let ((cwd (getcwd)))
530 (setenv "MFINPUTS"
531 (string-append cwd "/base:"
532 cwd "/misc:"
533 cwd "/roex:"
534 cwd "/feynmf:"
535 cwd "/mfpic:"
536 cwd "/config")))
537 (mkdir "build")
538 (with-directory-excursion "build"
3730a107 539 (invoke "inimf" "mf.mf"))))
8ada0f0b
RW
540 (replace 'install
541 (lambda* (#:key outputs #:allow-other-keys)
542 (let* ((out (assoc-ref outputs "out"))
543 (base (string-append out "/share/texmf-dist/web2c"))
544 (mf (string-append out "/share/texmf-dist/metafont/base")))
545 (mkdir-p base)
546 (mkdir-p mf)
547 (install-file "build/mf.base" base)
548 (copy-recursively "base" mf)
549 #t))))))
550 (native-inputs
551 `(("texlive-bin" ,texlive-bin)))
b8d8806b 552 (home-page "https://www.ctan.org/pkg/metafont")
8ada0f0b
RW
553 (synopsis "Metafont base files")
554 (description "This package provides the Metafont base files needed to
555build fonts using the Metafont system.")
556 (license license:knuth)))
557
513fff4c
RW
558(define-public texlive-tex-fontinst-base
559 (package
560 (name "texlive-tex-fontinst-base")
561 (version (number->string %texlive-revision))
562 (source (origin
563 (method svn-fetch)
564 (uri (svn-reference
565 (url (string-append "svn://www.tug.org/texlive/tags/"
566 %texlive-tag "/Master/texmf-dist/"
567 "/tex/fontinst/base"))
568 (revision %texlive-revision)))
569 (file-name (string-append name "-" version "-checkout"))
570 (sha256
571 (base32
572 "12gnb8hc45p47pqn31msvi4mpr3wxbbbf2k4xhmshjqykwzlx508"))))
573 (build-system trivial-build-system)
574 (arguments
575 `(#:modules ((guix build utils))
576 #:builder
577 (begin
578 (use-modules (guix build utils))
579 (let ((target (string-append (assoc-ref %outputs "out")
580 "/share/texmf-dist/tex/fontinst/base")))
581 (mkdir-p target)
582 (copy-recursively (assoc-ref %build-inputs "source") target)
583 #t))))
584 (home-page "https://www.ctan.org/pkg/fontinst")
585 (synopsis "Tools for converting and installing fonts for TeX and LaTeX")
586 (description "This package provides TeX macros for converting Adobe Font
587Metric files to TeX metric and virtual font format. Fontinst helps mainly
588with the number crunching and shovelling parts of font installation. This
589means in practice that it creates a number of files which give the TeX
590metrics (and related information) for a font family that TeX needs to do any
591typesetting in these fonts.")
592 (license license:lppl1.1+)))
593
dea67d8a
RW
594(define-public texlive-fontname
595 (package
596 (name "texlive-fontname")
597 (version (number->string %texlive-revision))
598 (source (origin
599 (method svn-fetch)
600 (uri (svn-reference
601 (url (string-append "svn://www.tug.org/texlive/tags/"
602 %texlive-tag "/Master/texmf-dist/"
603 "/fonts/map/fontname"))
604 (revision %texlive-revision)))
b8e213cb 605 (file-name (string-append name "-" version "-checkout"))
dea67d8a
RW
606 (sha256
607 (base32
d4d9a1ec 608 "05rbn7z30xawd3n6w7c3ijp2yc67ga220jgqmkla9pd9wx185rzq"))))
dea67d8a
RW
609 (build-system trivial-build-system)
610 (arguments
611 `(#:modules ((guix build utils))
612 #:builder
613 (begin
614 (use-modules (guix build utils))
615 (let ((target (string-append (assoc-ref %outputs "out")
616 "/share/texmf-dist/fonts/map/fontname")))
617 (mkdir-p target)
618 (copy-recursively (assoc-ref %build-inputs "source") target)
619 #t))))
620 (home-page "https://www.ctan.org/pkg/fontname")
621 (synopsis "Scheme for naming fonts in TeX")
622 (description "This is Fontname, a naming scheme for (the base part of)
623external TeX font filenames. This makes at most eight-character names
624from (almost) arbitrarily complex font names, thus helping portability of TeX
625documents.")
626 (license license:public-domain)))
627
3c4f1ec7
RW
628(define-public texlive-fonts-cm
629 (package
2b63e54b
RW
630 (inherit (simple-texlive-package
631 "texlive-fonts-cm"
632 (list "/fonts/source/public/cm/"
633 "/fonts/map/dvips/cm/cmtext-bsr-interpolated.map"
634 "/doc/fonts/cm/README"
635 "/doc/fonts/cm/README-cmps.txt")
636 (base32
637 "1h0q71paqmg1xjg6k35ni2i6m93kmlq9rdwm913xg9n4qngywl18")))
638 (outputs '("out" "doc"))
3c4f1ec7
RW
639 (build-system gnu-build-system)
640 (arguments
641 `(#:modules ((guix build gnu-build-system)
642 (guix build utils)
643 (srfi srfi-1)
644 (srfi srfi-26))
645 #:tests? #f ; no tests
646 #:phases
647 (modify-phases %standard-phases
648 (delete 'configure)
649 (replace 'build
650 (lambda* (#:key inputs #:allow-other-keys)
651 (let ((mf (assoc-ref inputs "texlive-metafont-base")))
652 ;; Tell mf where to find mf.base
653 (setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
654 ;; Tell mf where to look for source files
655 (setenv "MFINPUTS"
2b63e54b 656 (string-append (getcwd) "/fonts/source/public/cm/:"
3c4f1ec7 657 mf "/share/texmf-dist/metafont/base")))
2b63e54b
RW
658 (for-each make-file-writable
659 (cons "fonts/source/public/cm/"
660 (find-files "fonts/source/public/cm/" ".*")))
661 (let ((build (string-append (getcwd) "/build"))
662 (pkdir (string-append (getcwd) "/pk/ljfour/public/cm/dpi600")))
663 (mkdir-p pkdir)
664 (mkdir-p build)
665 (with-directory-excursion "fonts/source/public/cm/"
666 (for-each (lambda (font)
667 (format #t "building font ~a\n" font)
668 (invoke "mf" "-progname=mf"
669 (string-append "-output-directory=" build)
670 (string-append "\\"
671 "mode:=ljfour; "
672 "mag:=1+0/600; "
673 "scrollmode; "
674 "input "
675 (basename font ".mf")))
676 (invoke "gftopk"
677 (string-append build "/"
678 (basename font ".mf") ".600gf")
679 (string-append pkdir "/"
680 (basename font ".mf") ".pk")))
681 (find-files "." "cm(.*[0-9]+.*|inch)\\.mf$"))))
ff440d62 682 #t))
3c4f1ec7 683 (replace 'install
6534e885 684 (lambda* (#:key inputs outputs #:allow-other-keys)
2b63e54b
RW
685 (let* ((out (assoc-ref outputs "out"))
686 (doc (assoc-ref outputs "doc"))
687 (source (assoc-ref inputs "source"))
688 (fonts (string-append out "/share/texmf-dist/fonts/"))
689 (pk (string-append fonts "pk"))
690 (tfm (string-append fonts "tfm/public/cm"))
691 (mf (string-append fonts "source/public/cm")))
3c4f1ec7
RW
692 (for-each (cut install-file <> tfm)
693 (find-files "build" "\\.*"))
694 (for-each (cut install-file <> mf)
695 (find-files "." "\\.mf"))
26a05061 696 (copy-recursively "pk" pk)
2b63e54b
RW
697 (copy-recursively
698 (string-append source "/doc")
699 (string-append doc "/doc"))
700 (install-file
701 (string-append source "/fonts/map/dvips/cm/cmtext-bsr-interpolated.map")
702 (string-append fonts "/map/dvips/cm/cmtext-bsr-interpolated.map"))
3c4f1ec7
RW
703 #t))))))
704 (native-inputs
705 `(("texlive-bin" ,texlive-bin)
0512ae30 706 ("texlive-metafont-base" ,texlive-metafont-base)))
b8d8806b 707 (home-page "https://www.ctan.org/pkg/cm")
3c4f1ec7
RW
708 (synopsis "Computer Modern fonts for TeX")
709 (description "This package provides the Computer Modern fonts by Donald
710Knuth. The Computer Modern font family is a large collection of text,
711display, and mathematical fonts in a range of styles, based on Monotype Modern
7128A.")
713 (license license:knuth)))
714
4e9242aa
RW
715(define-public texlive-fonts-cm-super
716 (package
717 (name "texlive-fonts-cm-super")
718 (version (number->string %texlive-revision))
719 (source (origin
720 (method svn-fetch)
721 (uri (svn-reference
722 (url (string-append "svn://www.tug.org/texlive/tags/"
723 %texlive-tag "/Master/texmf-dist/"
724 "/tex/latex/cm-super"))
725 (revision %texlive-revision)))
726 (file-name (string-append name "-" version "-checkout"))
727 (sha256
728 (base32
729 "0ybb4gi2rblzpb6wfzm2wk7dj3y2jnmkzsla7mz7g3zc12y4r2b9"))))
730 (build-system trivial-build-system)
731 (arguments
732 `(#:modules ((guix build utils)
733 (ice-9 match))
734 #:builder
735 (begin
736 (use-modules (guix build utils)
737 (ice-9 match))
738 (let ((root (string-append (assoc-ref %outputs "out")
739 "/share/texmf-dist/"))
740 (pkgs '(("source" . "tex/latex/cm-super")
741 ("cm-super-afm" . "fonts/afm/public/cm-super")
742 ("cm-super-type1" . "fonts/type1/public/cm-super")
743 ("cm-super-enc" . "fonts/enc/dvips/cm-super")
744 ("cm-super-map" . "fonts/map/dvips/cm-super")
745 ("cm-super-vtex" . "fonts/map/vtex/cm-super"))))
746 (for-each (match-lambda
747 ((pkg . dir)
748 (let ((target (string-append root dir)))
749 (mkdir-p target)
750 (copy-recursively (assoc-ref %build-inputs pkg)
751 target))))
752 pkgs)
753 #t))))
754 (native-inputs
755 `(("cm-super-vtex"
756 ,(origin
757 (method svn-fetch)
758 (uri (svn-reference
759 (url (string-append "svn://www.tug.org/texlive/tags/"
760 %texlive-tag "/Master/texmf-dist/"
761 "/fonts/map/vtex/cm-super"))
762 (revision %texlive-revision)))
763 (file-name (string-append name "-map-vtex-" version "-checkout"))
764 (sha256
765 (base32
766 "14c9allsgfv6za9wznz4cxqxwz5nsmj8rnwvxams8fhs5rvglxqi"))))
767 ("cm-super-afm"
768 ,(origin
769 (method svn-fetch)
770 (uri (svn-reference
771 (url (string-append "svn://www.tug.org/texlive/tags/"
772 %texlive-tag "/Master/texmf-dist/"
773 "/fonts/afm/public/cm-super"))
774 (revision %texlive-revision)))
775 (file-name (string-append name "-afm-" version "-checkout"))
776 (sha256
777 (base32
778 "048ih65f2nghdabdar2p957c4s2spgllmy2gxdscddwqpnmd26yn"))))
779 ("cm-super-type1"
780 ,(origin
781 (method svn-fetch)
782 (uri (svn-reference
783 (url (string-append "svn://www.tug.org/texlive/tags/"
784 %texlive-tag "/Master/texmf-dist/"
785 "/fonts/type1/public/cm-super"))
786 (revision %texlive-revision)))
787 (file-name (string-append name "-type1-" version "-checkout"))
788 (sha256
789 (base32
790 "1140swk3w2ka0y4zdsq6pdifrdanb281q71p5gngbbjxdxjxf4qx"))))
791 ("cm-super-map"
792 ,(origin
793 (method svn-fetch)
794 (uri (svn-reference
795 (url (string-append "svn://www.tug.org/texlive/tags/"
796 %texlive-tag "/Master/texmf-dist/"
797 "/fonts/map/dvips/cm-super"))
798 (revision %texlive-revision)))
799 (file-name (string-append name "-map-" version "-checkout"))
800 (sha256
801 (base32
802 "10r6xqbwf9wk3ylg7givwyrw1952zydc6p7fw29zjf8ijl0lndim"))))
803 ("cm-super-enc"
804 ,(origin
805 (method svn-fetch)
806 (uri (svn-reference
807 (url (string-append "svn://www.tug.org/texlive/tags/"
808 %texlive-tag "/Master/texmf-dist/"
809 "/fonts/enc/dvips/cm-super"))
810 (revision %texlive-revision)))
811 (file-name (string-append name "-enc-" version "-checkout"))
812 (sha256
813 (base32
814 "1pgksy96gfgyjxfhs2k04bgg7nr7i128y01kjcahr7n38080h4ij"))))))
815 (home-page "https://www.ctan.org/pkg/cm-super")
816 (synopsis "Computer Modern Super family of fonts")
817 (description "The CM-Super family provides Adobe Type 1 fonts that replace
818the T1/TS1-encoded Computer Modern (EC/TC), T1/TS1-encoded Concrete,
819T1/TS1-encoded CM bright and LH Cyrillic fonts (thus supporting all European
820languages except Greek), and bringing many ameliorations in typesetting
821quality. The fonts exhibit the same metrics as the METAFONT-encoded
822originals.")
823 ;; With font exception
824 (license license:gpl2+)))
825
c2a1fe4a
RW
826(define-public texlive-fonts-lm
827 (package
828 (name "texlive-fonts-lm")
829 (version "2.004")
830 (source (origin
831 (method url-fetch)
832 (uri (string-append "http://www.gust.org.pl/projects/e-foundry/"
833 "latin-modern/download/lm" version "bas.zip"))
834 (sha256
835 (base32
836 "0z2s253y751m2ci5aw8nq0sf2kyg9hpimv2gyixkch9d07m2b9wp"))))
837 (build-system trivial-build-system)
838 (arguments
839 `(#:modules ((guix build utils))
840 #:builder
841 (begin
842 (use-modules (guix build utils))
843 (let ((root (string-append (assoc-ref %outputs "out")
844 "/share/texmf-dist/")))
845 (mkdir-p root)
846 (with-directory-excursion root
847 (invoke (string-append (assoc-ref %build-inputs "unzip")
848 "/bin/unzip")
849 (assoc-ref %build-inputs "source")))
850 #t))))
851 (native-inputs
852 `(("unzip" ,unzip)))
853 (home-page "http://www.gust.org.pl/projects/e-foundry/latin-modern/")
854 (synopsis "Latin Modern family of fonts")
855 (description "The Latin Modern fonts are derived from the famous Computer
856Modern fonts designed by Donald E. Knuth and described in Volume E of his
857Computers & Typesetting series.")
858 ;; The GUST font license (GFL) is legally identical to the LaTeX Project
859 ;; Public License (LPPL), version 1.3c or later, but comes with an
860 ;; additional but not legally binding clause.
861 (license license:lppl1.3c+)))
862
5ebba61a
RW
863(define-public texlive-fonts-knuth-lib
864 (package
865 (name "texlive-fonts-knuth-lib")
866 (version (number->string %texlive-revision))
867 (source (origin
868 (method svn-fetch)
869 (uri (svn-reference
870 (url (string-append "svn://www.tug.org/texlive/tags/"
871 %texlive-tag "/Master/texmf-dist/"
872 "/fonts/source/public/knuth-lib"))
873 (revision %texlive-revision)))
6b286e42 874 (file-name (string-append name "-" version "-checkout"))
5ebba61a
RW
875 (sha256
876 (base32
877 "0in9aqyi8jkyf9d16z0li50z5fpwj1iwgwm83gmvwqcf7chfs04y"))))
878 (build-system gnu-build-system)
879 (arguments
880 `(#:modules ((guix build gnu-build-system)
881 (guix build utils)
882 (srfi srfi-26))
883 #:tests? #f ; no tests
884 #:phases
885 (modify-phases %standard-phases
886 (delete 'configure)
887 (replace 'build
888 (lambda* (#:key inputs #:allow-other-keys)
889 (let ((mf (assoc-ref inputs "texlive-metafont-base")))
890 ;; Tell mf where to find mf.base
891 (setenv "MFBASES"
892 (string-append mf "/share/texmf-dist/web2c"))
893 ;; Tell mf where to look for source files
894 (setenv "MFINPUTS"
895 (string-append (getcwd) ":"
896 mf "/share/texmf-dist/metafont/base")))
897 (mkdir "build")
96f5377d
RW
898 (for-each (lambda (font)
899 (format #t "building font ~a\n" font)
900 (invoke "mf" "-progname=mf"
901 "-output-directory=build"
902 (string-append "\\"
903 "mode:=ljfour; "
904 "mag:=1; "
905 "batchmode; "
906 "input " font)))
907 (find-files "." "(manfnt|logo.+)\\.mf$"))
908 #t))
5ebba61a
RW
909 (replace 'install
910 (lambda* (#:key outputs #:allow-other-keys)
911 (let* ((out (assoc-ref outputs "out"))
912 (tfm (string-append
913 out "/share/texmf-dist/fonts/tfm/public/knuth-lib"))
914 (mf (string-append
915 out "/share/texmf-dist/fonts/source/public/knuth-lib")))
916 (for-each (cut install-file <> tfm)
917 (find-files "build" "\\.*"))
918 (for-each (cut install-file <> mf)
919 (find-files "." "\\.mf"))
920 #t))))))
921 (native-inputs
922 `(("texlive-bin" ,texlive-bin)
923 ("texlive-metafont-base" ,texlive-metafont-base)))
924 (home-page "https://www.ctan.org/pkg/knuth-lib")
925 (synopsis "Small library of METAFONT sources")
926 (description "This is a collection of core TeX and METAFONT macro files
927from Donald Knuth, including the plain format, plain base, and the MF logo
928fonts.")
929 (license license:knuth)))
930
a00d5933
RW
931(define-public texlive-fonts-latex
932 (package
933 (name "texlive-fonts-latex")
934 (version (number->string %texlive-revision))
935 (source (origin
936 (method svn-fetch)
937 (uri (svn-reference
938 (url (string-append "svn://www.tug.org/texlive/tags/"
939 %texlive-tag "/Master/texmf-dist/"
940 "/fonts/source/public/latex-fonts"))
941 (revision %texlive-revision)))
a4550e7d 942 (file-name (string-append name "-" version "-checkout"))
a00d5933
RW
943 (sha256
944 (base32
945 "0ypsm4xv9cw0jckk2qc7gi9hcmhf31mrg56pz3llyx3yd9vq2lps"))))
946 (build-system gnu-build-system)
947 (arguments
948 `(#:modules ((guix build gnu-build-system)
949 (guix build utils)
950 (srfi srfi-1)
951 (srfi srfi-26))
952 #:tests? #f ; no tests
953 #:phases
954 (modify-phases %standard-phases
955 (delete 'configure)
956 (replace 'build
957 (lambda* (#:key inputs #:allow-other-keys)
958 (let ((mf (assoc-ref inputs "texlive-metafont-base")))
959 ;; Tell mf where to find mf.base
960 (setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
961 ;; Tell mf where to look for source files
962 (setenv "MFINPUTS"
963 (string-append (getcwd) ":"
964 mf "/share/texmf-dist/metafont/base:"
965 (assoc-ref inputs "texlive-fonts-cm")
966 "/share/texmf-dist/fonts/source/public/cm")))
967 (mkdir "build")
806faaab
MW
968 (for-each (lambda (font)
969 (format #t "building font ~a\n" font)
970 (invoke "mf" "-progname=mf"
971 "-output-directory=build"
972 (string-append "\\"
973 "mode:=ljfour; "
974 "mag:=1; "
975 "batchmode; "
976 "input " font)))
977 '("icmcsc10" "icmex10" "icmmi8" "icmsy8" "icmtt8"
978 "ilasy8" "ilcmss8" "ilcmssb8" "ilcmssi8"
979 "lasy5" "lasy6" "lasy7" "lasy8" "lasy9" "lasy10" "lasyb10"
980 "lcircle10" "lcirclew10" "lcmss8" "lcmssb8" "lcmssi8"
981 "line10" "linew10"))
982 #t))
a00d5933
RW
983 (replace 'install
984 (lambda* (#:key outputs #:allow-other-keys)
985 (let* ((out (assoc-ref outputs "out"))
986 (tfm (string-append
987 out "/share/texmf-dist/fonts/tfm/public/latex-fonts"))
988 (mf (string-append
989 out "/share/texmf-dist/fonts/source/public/latex-fonts")))
990 (for-each (cut install-file <> tfm)
991 (find-files "build" "\\.*"))
992 (for-each (cut install-file <> mf)
993 (find-files "." "\\.mf"))
994 #t))))))
995 (native-inputs
996 `(("texlive-bin" ,texlive-bin)
997 ("texlive-metafont-base" ,texlive-metafont-base)
998 ("texlive-fonts-cm" ,texlive-fonts-cm)))
b8d8806b 999 (home-page "https://www.ctan.org/pkg/latex-fonts")
a00d5933
RW
1000 (synopsis "Collection of fonts used in LaTeX distributions")
1001 (description "This is a collection of fonts for use with standard LaTeX
1002packages and classes. It includes invisible fonts (for use with the slides
1003class), line and circle fonts (for use in the picture environment) and LaTeX
1004symbol fonts.")
1005 (license license:lppl1.2+)))
1006
6072f82a
RW
1007(define-public texlive-latex-mflogo
1008 (package
1009 (name "texlive-latex-mflogo")
1010 (version (number->string %texlive-revision))
1011 (source
1012 (origin
1013 (method svn-fetch)
1014 (uri (texlive-ref "latex" "mflogo"))
1015 (sha256
1016 (base32
1017 "15i2ib6nvhf31g1b92c6njf7n0g29znlq7hbfp9ii7qabhcwwvrj"))))
1018 (build-system texlive-build-system)
1019 (arguments '(#:tex-directory "latex/mflogo"))
1020 (home-page "http://www.ctan.org/pkg/mflogo")
1021 (synopsis "LaTeX support for Metafont logo fonts")
1022 (description
1023 "This package provides LaTeX and font definition files to access the
1024Knuthian mflogo fonts described in The Metafontbook and to typeset Metafont
1025logos in LaTeX documents.")
1026 (license license:lppl)))
1027
01cf8c89
RW
1028(define-public texlive-fonts-mflogo-font
1029 (package
1030 (name "texlive-fonts-mflogo-font")
1031 (version (number->string %texlive-revision))
1032 (source (origin
1033 (method svn-fetch)
1034 (uri (svn-reference
1035 (url (string-append "svn://www.tug.org/texlive/tags/"
1036 %texlive-tag "/Master/texmf-dist/"
1037 "/fonts/type1/hoekwater/mflogo-font"))
1038 (revision %texlive-revision)))
1039 (file-name (string-append name "-" version "-checkout"))
1040 (sha256
1041 (base32
1042 "09fsxfpiyxjljkrb52b197728bjnkcnv3bdwm4hl6hf23mbmqadf"))))
1043 (build-system trivial-build-system)
1044 (arguments
1045 `(#:modules ((guix build utils)
1046 (ice-9 match))
1047 #:builder
1048 (begin
1049 (use-modules (guix build utils)
1050 (ice-9 match))
1051 (let ((root (string-append (assoc-ref %outputs "out")
1052 "/share/texmf-dist/"))
1053 (pkgs '(("source" . "fonts/type1/hoekwater/mflogo-font")
1054 ("afm" . "fonts/afm/hoekwater/mflogo-font")
1055 ("fonts-map" . "fonts/map/dvips/mflogo-font"))))
1056 (for-each (match-lambda
1057 ((pkg . dir)
1058 (let ((target (string-append root dir)))
1059 (mkdir-p target)
1060 (copy-recursively (assoc-ref %build-inputs pkg)
1061 target))))
1062 pkgs)
1063 #t))))
1064 (native-inputs
1065 `(("afm"
1066 ,(origin
1067 (method svn-fetch)
1068 (uri (svn-reference
1069 (url (string-append "svn://www.tug.org/texlive/tags/"
1070 %texlive-tag "/Master/texmf-dist/"
1071 "/fonts/afm/hoekwater/mflogo-font"))
1072 (revision %texlive-revision)))
1073 (file-name (string-append name "-afm-" version "-checkout"))
1074 (sha256
1075 (base32
1076 "0bx1mfhhzsk9gj1pha36q2rk0jd0y285qm62zgvdvzzzlfnk8sdb"))))
1077 ("fonts-map"
1078 ,(origin
1079 (method svn-fetch)
1080 (uri (svn-reference
1081 (url (string-append "svn://www.tug.org/texlive/tags/"
1082 %texlive-tag "/Master/texmf-dist/"
1083 "/fonts/map/dvips/mflogo-font/"))
1084 (revision %texlive-revision)))
1085 (file-name (string-append name "-fonts-map-" version "-checkout"))
1086 (sha256
1087 (base32
1088 "044xrrpl8hnvj55cx2ql1ib1bcyr33nzanx5nkwxpai7fb7pg4y6"))))))
1089 (home-page "https://www.ctan.org/pkg/mflogo-font")
1090 (synopsis "Metafont logo font")
1091 (description
1092 "These fonts were created in METAFONT by Knuth, for his own publications.
1093At some stage, the letters P and S were added, so that the METAPOST logo could
1094also be expressed. The fonts were originally issued (of course) as METAFONT
1095source; they have since been autotraced and reissued in Adobe Type 1 format by
1096Taco Hoekwater.")
1097 (license license:knuth)))
1098
98b4aca1
RW
1099(define-public texlive-fonts-amsfonts
1100 (package
1101 (name "texlive-fonts-amsfonts")
1102 (version (number->string %texlive-revision))
1103 (source (origin
1104 (method svn-fetch)
1105 (uri (svn-reference
1106 (url (string-append "svn://www.tug.org/texlive/tags/"
1107 %texlive-tag "/Master/texmf-dist/"
1108 "/fonts/source/public/amsfonts"))
1109 (revision %texlive-revision)))
5fe9233e 1110 (file-name (string-append name "-" version "-checkout"))
98b4aca1
RW
1111 (sha256
1112 (base32
1113 "07h20rvpbdb4k72hzmjkyb29426zr9wxsfp6yd4ajbbpd3vx8grb"))))
1114 (build-system gnu-build-system)
1115 (arguments
1116 `(#:modules ((guix build gnu-build-system)
1117 (guix build utils)
fe2bfabe 1118 (ice-9 match)
98b4aca1
RW
1119 (srfi srfi-1)
1120 (srfi srfi-26))
1121 #:tests? #f ; no tests
1122 #:phases
1123 (modify-phases %standard-phases
1124 (delete 'configure)
1125 (replace 'build
1126 (lambda* (#:key inputs #:allow-other-keys)
fe2bfabe 1127 (let ((mf (assoc-ref inputs "texlive-union"))
98b4aca1 1128 (cwd (getcwd)))
db6609bd
DM
1129 ;; Make METAFONT reproducible
1130 (setenv "SOURCE_DATE_EPOCH" "1")
98b4aca1
RW
1131 ;; Tell mf where to find mf.base
1132 (setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
1133 ;; Tell mf where to look for source files
1134 (setenv "MFINPUTS"
1135 (string-append cwd ":"
1136 cwd "/cmextra:"
1137 cwd "/cyrillic:"
1138 cwd "/dummy:"
1139 cwd "/symbols:"
1140 mf "/share/texmf-dist/metafont/base:"
1141 (assoc-ref inputs "texlive-fonts-cm")
1142 "/share/texmf-dist/fonts/source/public/cm")))
1143 (mkdir "build")
2762023a
MW
1144 (for-each (lambda (font)
1145 (format #t "building font ~a\n" (basename font ".mf"))
1146 (with-directory-excursion (dirname font)
1147 (invoke "mf" "-progname=mf"
1148 "-output-directory=../build"
1149 (string-append "\\"
1150 "mode:=ljfour; "
1151 "mag:=1; "
1152 "nonstopmode; "
1153 "input "
1154 (getcwd) "/"
1155 (basename font ".mf")))))
1156 (find-files "." "[0-9]+\\.mf$"))
fe2bfabe
RW
1157
1158 ;; There are no metafont sources for the Euler fonts, so we
1159 ;; convert the afm files instead.
1160 (mkdir "build/euler")
1161 (for-each (lambda (font)
1162 (format #t "converting afm font ~a\n" (basename font ".afm"))
1163 (invoke "afm2tfm" font
1164 (string-append "build/euler/"
1165 (basename font ".tfm"))))
1166 (find-files (assoc-ref inputs "amsfonts-afm")
1167 "\\.afm$"))
1168
1169 ;; Frustratingly, not all fonts can be created this way. To
1170 ;; generate eufm8.tfm, for example, we first scale down
1171 ;; eufm10.afm to eufm8.pl, and then generate the tfm file from
1172 ;; the pl file.
1173 (with-directory-excursion "build/euler"
1174 (setenv "TEXINPUTS"
1175 (string-append (getcwd) "//:"
1176 (assoc-ref inputs "amsfonts-afm") "//:"
1177 (assoc-ref inputs "texlive-union") "//"))
1178 (for-each (match-lambda
1179 (((target-base target-size)
1180 (source-base source-size))
1181 (let ((factor (number->string
1182 (truncate/ (* 1000 target-size)
1183 source-size))))
1184 (invoke "tex"
1185 "-interaction=scrollmode"
1186 (string-append "\\input fontinst.sty "
1187 "\\transformfont{" target-base "}"
1188 "{\\scalefont{" factor "}"
1189 "{\\fromafm{" source-base "}}} "
1190 "\\bye")))
1191 (invoke "pltotf"
1192 (string-append target-base ".pl")
1193 (string-append target-base ".tfm"))
1194 (delete-file (string-append target-base ".pl"))))
1195
1196 '((("eufm8" 8) ("eufm10" 10))
1197
1198 (("eufb6" 6) ("eufb7" 7))
1199 (("eufb8" 8) ("eufb10" 10))
1200 (("eufb9" 9) ("eufb10" 10))
1201
1202 (("eufm6" 6) ("eufb7" 7))
1203 (("eufm9" 9) ("eufb10" 10))
1204
1205 (("eurb6" 6) ("eurb7" 7))
1206 (("eurb8" 8) ("eurb10" 10))
1207 (("eurb9" 9) ("eurb10" 10))
1208
1209 (("eurm6" 6) ("eurm7" 7))
1210 (("eurm8" 8) ("eurm10" 10))
1211 (("eurm9" 9) ("eurm10" 10)))))
2762023a 1212 #t))
98b4aca1 1213 (replace 'install
24d0c4d0 1214 (lambda* (#:key inputs outputs #:allow-other-keys)
fe2bfabe
RW
1215 (let* ((out (assoc-ref outputs "out"))
1216 (root (string-append out "/share/texmf-dist/fonts/"))
1217 (pkgs '(("amsfonts-afm" . "afm/public/amsfonts")
1218 ("amsfonts-type1" . "type1/public/amsfonts")
1219 ("amsfonts-map" . "map/dvips/amsfonts"))))
1220 (for-each (match-lambda
1221 ((pkg . dir)
1222 (let ((target (string-append root dir)))
1223 (mkdir-p target)
1224 (copy-recursively (assoc-ref inputs pkg)
1225 target))))
1226 pkgs)
1227 (copy-recursively (assoc-ref inputs "amsfonts-plain")
1228 (string-append out "/share/texmf-dist/tex/plain/amsfonts"))
1229 (let* ((tfm (string-append root "tfm/public/amsfonts"))
1230 (mf (string-append root "source/public/amsfonts")))
1231 (copy-recursively "build" tfm)
1232 (for-each (cut install-file <> mf)
1233 (find-files "." "\\.mf"))
1234 #t)))))))
98b4aca1 1235 (native-inputs
fe2bfabe
RW
1236 `(("texlive-union" ,(texlive-union (list texlive-tex-fontinst-base
1237 texlive-fonts-cm
1238 texlive-metafont-base)))
1239 ("amsfonts-plain"
1240 ,(origin
1241 (method svn-fetch)
1242 (uri (svn-reference
1243 (url (string-append "svn://www.tug.org/texlive/tags/"
1244 %texlive-tag "/Master/texmf-dist/"
1245 "/tex/plain/amsfonts"))
1246 (revision %texlive-revision)))
1247 (file-name (string-append name "-plain-" version "-checkout"))
1248 (sha256
1249 (base32
1250 "1hi8c9rkfb6395sxf7fhkr91xygfg8am1hqij9g3h2c7qx3714qp"))))
1251 ("amsfonts-map"
1252 ,(origin
1253 (method svn-fetch)
1254 (uri (svn-reference
1255 (url (string-append "svn://www.tug.org/texlive/tags/"
1256 %texlive-tag "/Master/texmf-dist/"
1257 "/fonts/map/dvips/amsfonts"))
1258 (revision %texlive-revision)))
1259 (file-name (string-append name "-map-" version "-checkout"))
1260 (sha256
1261 (base32
1262 "1lrj3bd9ybj4aawzlygc6qvakbrwc5s0mc5n9rpic331frv3axfs"))))
24d0c4d0
RW
1263 ("amsfonts-type1"
1264 ,(origin
1265 (method svn-fetch)
1266 (uri (svn-reference
1267 (url (string-append "svn://www.tug.org/texlive/tags/"
1268 %texlive-tag "/Master/texmf-dist/"
1269 "/fonts/type1/public/amsfonts"))
1270 (revision %texlive-revision)))
1271 (file-name (string-append name "-type1-" version "-checkout"))
1272 (sha256
1273 (base32
fe2bfabe
RW
1274 "1zfz33vn6gm19njy74n8wmn7sljrimfhwns5z8qqhxqfh1g4qip2"))))
1275 ("amsfonts-afm"
1276 ,(origin
1277 (method svn-fetch)
1278 (uri (svn-reference
1279 (url (string-append "svn://www.tug.org/texlive/tags/"
1280 %texlive-tag "/Master/texmf-dist/"
1281 "/fonts/afm/public/amsfonts"))
1282 (revision %texlive-revision)))
1283 (file-name (string-append name "-afm-" version "-checkout"))
1284 (sha256
1285 (base32
1286 "1fifzkaihmjgchnk7dmw0c23k0cz999dxnc78ivmqvgi1dhx0iv8"))))))
b8d8806b 1287 (home-page "https://www.ctan.org/pkg/amsfonts")
98b4aca1
RW
1288 (synopsis "TeX fonts from the American Mathematical Society")
1289 (description
1290 "This package provides an extended set of fonts for use in mathematics,
1291including: extra mathematical symbols; blackboard bold letters (uppercase
1292only); fraktur letters; subscript sizes of bold math italic and bold Greek
1293letters; subscript sizes of large symbols such as sum and product; added sizes
1294of the Computer Modern small caps font; cyrillic fonts (from the University of
1295Washington); Euler mathematical fonts. All fonts are provided as Adobe Type 1
1296files, and all except the Euler fonts are provided as Metafont source. The
1297distribution also includes the canonical Type 1 versions of the Computer
1298Modern family of fonts. The Euler fonts are supported by separate packages;
1299details can be found in the documentation.")
1300 (license license:silofl1.1)))
1301
137f9cbc
RW
1302(define-public texlive-latex-amsfonts
1303 (package
1304 (name "texlive-latex-amsfonts")
1305 (version (number->string %texlive-revision))
1306 (source (origin
1307 (method svn-fetch)
1308 (uri (texlive-ref "latex" "amsfonts"))
9700a0d0 1309 (file-name (string-append name "-" version "-checkout"))
137f9cbc
RW
1310 (sha256
1311 (base32
1312 "0slzfv5h2m03b2xvm2sasznz4azh6rgi069z161dja3l8rln79hm"))))
1313 (build-system texlive-build-system)
1314 (arguments '(#:tex-directory "latex/amsfonts"))
1315 (native-inputs
1316 `(("texlive-fonts-cm" ,texlive-fonts-cm)
1317 ("texlive-metafont-base" ,texlive-metafont-base)))
b8d8806b 1318 (home-page "https://www.ctan.org/pkg/amsfonts")
137f9cbc
RW
1319 (synopsis "TeX fonts from the American Mathematical Society")
1320 (description
1321 "This package provides basic LaTeX support for the symbol fonts provides
1322by the amsfonts package. It provides @code{amsfonts.sty}, with names of
1323individual symbols defined in @code{amssymb.sty}.")
1324 (license license:silofl1.1)))
1325
e4c5481d
RW
1326(define-public texlive-mkpattern
1327 (package
1328 (inherit (simple-texlive-package
1329 "texlive-mkpattern"
1330 (list "/doc/plain/mkpattern/README"
1331 "/doc/plain/mkpattern/mkpatdoc.tex"
1332 "/doc/plain/mkpattern/mkpatter.pdf"
1333 "/doc/plain/mkpattern/mkpattern-exmpl.tex"
1334 "/tex/plain/mkpattern/mkpatter.tex")
1335 (base32
1336 "0sxnkbcc802jl3fj56x9hvg978bpv15lhrwj0aykb4syq29l47ga")
1337 #:trivial? #t))
1338 (home-page "https://ctan.org/pkg/mkpattern")
1339 (synopsis "Utility for making hyphenation patterns")
1340 (description "Mkpattern is a general purpose program for the generation of
1341hyphenation patterns, with definition of letter sets and template-like
1342constructions. It also provides an easy way to handle different input and
1343output encodings, and features generation of clean UTF-8 patterns.")
1344 (license license:lppl)))
1345
566e95f7
RW
1346;; This provides etex.src which is needed to build various formats, including
1347;; luatex.fmt and pdflatex.fmt
1348(define-public texlive-tex-plain
1349 (package
1350 (name "texlive-tex-plain")
1351 (version (number->string %texlive-revision))
1352 (source (origin
1353 (method svn-fetch)
1354 (uri (svn-reference
1355 (url (string-append "svn://www.tug.org/texlive/tags/"
1356 %texlive-tag "/Master/texmf-dist/"
1357 "/tex/plain"))
1358 (revision %texlive-revision)))
b63aefe5 1359 (file-name (string-append name "-" version "-checkout"))
566e95f7
RW
1360 (sha256
1361 (base32
d4d9a1ec 1362 "1xknlb3gcw6jjqh97bhghxi594bzpj1zfzzfsrr9pvr9s1bx7dnf"))))
566e95f7
RW
1363 (build-system trivial-build-system)
1364 (arguments
1365 `(#:modules ((guix build utils))
1366 #:builder
1367 (begin
1368 (use-modules (guix build utils))
1369 (let ((target (string-append (assoc-ref %outputs "out")
1370 "/share/texmf-dist/tex/plain")))
1371 (mkdir-p target)
1372 (copy-recursively (assoc-ref %build-inputs "source") target)
1373 #t))))
1374 (home-page "https://www.ctan.org/pkg/plain")
1375 (synopsis "Plain TeX format and supporting files")
1376 (description
1377 "Contains files used to build the Plain TeX format, as described in the
1378TeXbook, together with various supporting files (some also discussed in the
1379book).")
1380 (license license:knuth)))
1381
df73a3d3
RW
1382(define-public texlive-hyphen-afrikaans
1383 (package
1384 (inherit (texlive-hyphen-package
1385 "texlive-hyphen-afrikaans" "af"
1386 (list "/tex/generic/hyph-utf8/patterns/tex/hyph-af.tex")
1387 (base32
1388 "1vb3jccqnn1pm0680yqx52kvz595fmxnwa0cbf8qman6zglsssiw")))
1389 (synopsis "Hyphenation patterns for Afrikaans")
1390 (description "The package provides hyphenation patterns for the Afrikaans
1391language.")
1392 (license license:lppl1.3+)))
1393
619ca023
RW
1394(define-public texlive-hyphen-ancientgreek
1395 (package
1396 (inherit (texlive-hyphen-package
1397 "texlive-hyphen-ancientgreek" "grc"
1398 (list "/tex/generic/hyph-utf8/patterns/tex/hyph-grc.tex"
1399 "/tex/generic/hyphen/grahyph5.tex"
1400 "/tex/generic/hyphen/ibyhyph.tex")
1401 (base32
1402 "0kwrqsz7wdr1d9kylzwp60ka3wfbj8iad029k5h6y94nb86mf7zv")))
1403 (synopsis "Hyphenation patterns for ancient Greek")
1404 (description "The package provides hyphenation patterns for ancient
1405Greek.")
1406 (license license:lppl1.3+)))
1407
a361f412
RW
1408(define-public texlive-hyphen-armenian
1409 (let ((template (texlive-hyphen-package
1410 "texlive-hyphen-armenian" "hy"
1411 (list "/source/generic/hyph-utf8/languages/hy/generate_patterns_hy.rb")
1412 (base32
1413 "0z666y580w1kpxssdanz67ykq257lf11a1mnp1jrn08zijvfrw9c"))))
1414 (package
1415 (inherit template)
1416 (arguments
1417 (substitute-keyword-arguments (package-arguments template)
1418 ((#:phases phases)
1419 `(modify-phases ,phases
1420 (add-before 'build 'build-patterns
1421 (lambda _
1422 (let ((target (string-append (getcwd)
1423 "/tex/generic/hyph-utf8/patterns/tex")))
1424 (mkdir-p target)
1425 (with-directory-excursion "source/generic/hyph-utf8/languages/hy/"
1426 (substitute* "generate_patterns_hy.rb"
1427 (("\\$file = File.new.*")
1428 (string-append "$file = File.new(\"" target
1429 "/hyph-hy.tex\",\"w\")\n")))
1430 (invoke "ruby" "generate_patterns_hy.rb"))
1431 #t)))
1432 (add-after 'install 'install-hyph-hy.tex
1433 (lambda* (#:key inputs outputs #:allow-other-keys)
1434 (let* ((out (assoc-ref outputs "out"))
1435 (target (string-append out "/share/texmf-dist/tex")))
1436 (copy-recursively "tex" target)
1437 #t)))))))
1438 (synopsis "Hyphenation patterns for Armenian")
1439 (description "The package provides hyphenation patterns for the Armenian
1440language.")
1441 ;; Any version of the LGPL.
1442 (license license:lgpl3+))))
1443
0ddbc25c
RW
1444(define-public texlive-hyphen-basque
1445 (let ((template (texlive-hyphen-package
1446 "texlive-hyphen-basque" "eu"
1447 (list "/source/generic/hyph-utf8/languages/eu/generate_patterns_eu.rb")
1448 (base32
1449 "1yhsbzf1g9dm70jfixsz51hsfvn26cwfkfxvhg7xv2piynr4v51l"))))
1450 (package
1451 (inherit template)
1452 (arguments
1453 (substitute-keyword-arguments (package-arguments template)
1454 ((#:phases phases)
1455 `(modify-phases ,phases
1456 (add-before 'build 'build-patterns
1457 (lambda _
1458 (let ((target (string-append (getcwd)
1459 "/tex/generic/hyph-utf8/patterns/tex")))
1460 (mkdir-p target)
1461 (with-directory-excursion "source/generic/hyph-utf8/languages/eu/"
1462 (substitute* "generate_patterns_eu.rb"
1463 (("\\$file = File.new.*")
1464 (string-append "$file = File.new(\"" target
1465 "/hyph-eu.tex\",\"w\")\n")))
1466 (invoke "ruby" "generate_patterns_eu.rb"))
1467 #t)))
1468 (add-after 'install 'install-hyph-eu.tex
1469 (lambda* (#:key inputs outputs #:allow-other-keys)
1470 (let* ((out (assoc-ref outputs "out"))
1471 (target (string-append out "/share/texmf-dist/tex")))
1472 (copy-recursively "tex" target)
1473 #t)))))))
1474 (synopsis "Hyphenation patterns for Basque")
1475 (description "The package provides hyphenation patterns for the Basque
1476language.")
1477 ;; "Free for any purpose".
1478 (license (license:fsf-free
1479 "/source/generic/hyph-utf8/languages/eu/generate_patterns_eu.rb")))))
1480
92266796
RW
1481(define-public texlive-hyphen-belarusian
1482 (package
1483 (inherit (texlive-hyphen-package
1484 "texlive-hyphen-belarusian" "be"
1485 (list "/tex/generic/hyph-utf8/patterns/tex/hyph-be.tex")
1486 (base32
1487 "1xvffph824rg43gi2xs3ny9gzlp708fyxj9zfhckmg8pzh9vv3n6")))
1488 (synopsis "Hyphenation patterns for Belarusian")
1489 (description "The package provides hyphenation patterns for the Belarusian
1490language.")
1491 (license license:expat)))
1492
7ffc3105
RW
1493(define-public texlive-hyphen-bulgarian
1494 (package
1495 (inherit (texlive-hyphen-package
1496 "texlive-hyphen-bulgarian" "bg"
1497 (list "/doc/generic/hyph-utf8/bg/azbukaExtended.pdf"
1498 "/doc/generic/hyph-utf8/bg/azbukaExtended.tex"
1499 "/tex/generic/hyph-utf8/patterns/tex/hyph-bg.tex")
1500 (base32
1501 "06dxkk9azsggbri04i6g62lswygzadsx3rpqvbyzvbxc5wxz1dj1")))
1502 (synopsis "Hyphenation patterns for Bulgarian")
1503 (description "The package provides hyphenation patterns for the Bulgarian
1504language in T2A and UTF-8 encodings.")
1505 (license (license:non-copyleft
1506 "file:///tex/generic/hyph-utf8/patterns/tex/hyph-bg.tex"
1507 "Ancestral BSD variant"))))
1508
cbc7e109
RW
1509(define-public texlive-hyphen-catalan
1510 (package
1511 (inherit (texlive-hyphen-package
1512 "texlive-hyphen-catalan" "ca"
1513 (list "/tex/generic/hyph-utf8/patterns/tex/hyph-ca.tex")
1514 (base32
1515 "0cisx76jpw8kpd3an37m9h8ppiysnizgfzl48y9d9n3fvx8jyykb")))
1516 (synopsis "Hyphenation patterns for Catalan")
1517 (description "The package provides hyphenation patterns for Catalan in
1518T1/EC and UTF-8 encodings.")
1519 (license license:lppl1.0+)))
1520
9ebce8fc
RW
1521(define-public texlive-hyphen-chinese
1522 (package
1523 (inherit (texlive-hyphen-package
1524 "texlive-hyphen-chinese" "zh-latn-pinyin"
1525 (list "/tex/generic/hyph-utf8/patterns/tex/hyph-zh-latn-pinyin.tex")
1526 (base32
1527 "07gbrn5fcl5d3hyg1zpai3zp1ggl73cmvpalwvh7ah313f57gjkk")))
1528 (synopsis "Hyphenation patterns for unaccented Chinese pinyin")
1529 (description "The package provides hyphenation patterns for unaccented
1530Chinese pinyin T1/EC and UTF-8 encodings.")
1531 (license license:gpl2+)))
0ddbc25c 1532
beed8377
RW
1533(define-public texlive-hyphen-churchslavonic
1534 (package
1535 (inherit (texlive-hyphen-package
1536 "texlive-hyphen-churchslavonic" "cu"
1537 (list "/tex/generic/hyph-utf8/patterns/tex/hyph-cu.tex")
1538 (base32
1539 "0xkqlz3ixyl4fxsnzrbxqrb82p0n67rhgpddbiyv3qwfnbr2b5a4")))
1540 (synopsis "Hyphenation patterns for Church Slavonic")
1541 (description "The package provides hyphenation patterns for Church
1542Slavonic in UTF-8 encoding.")
1543 (license license:expat)))
1544
1b1d8577
RW
1545(define-public texlive-hyphen-coptic
1546 (package
1547 (inherit (texlive-hyphen-package
1548 "texlive-hyphen-coptic" "cop"
1549 (list "/tex/generic/hyph-utf8/patterns/tex-8bit/copthyph.tex"
1550 "/tex/generic/hyph-utf8/patterns/tex/hyph-cop.tex")
1551 (base32
1552 "07i03jpdfy4ip7zbg4gnk4hk8zwj8rlni9dgrb1p8mfw2w19d80c")))
1553 (synopsis "Hyphenation patterns for Coptic")
1554 (description "The package provides hyphenation patterns for Coptic in
1555UTF-8 encoding as well as in ASCII-based encoding for 8-bit engines.")
1556 ;; No explicit license declaration, so we use the project license.
1557 (license license:lppl)))
1558
5153431c
RW
1559(define-public texlive-hyph-utf8
1560 (package
1561 (inherit (simple-texlive-package
1562 "texlive-hyph-utf8"
1563 (list "/source/generic/hyph-utf8/"
1564 "/source/luatex/hyph-utf8/"
1565 "/doc/luatex/hyph-utf8/"
1566 "/tex/luatex/hyph-utf8/etex.src"
1567 ;; Used to extract luatex-hyphen.lua
1568 "/tex/latex/base/docstrip.tex"
1569
1570 ;; Documentation; we can't use the whole directory because
1571 ;; it includes files from other packages.
1572 "/doc/generic/hyph-utf8/CHANGES"
1573 "/doc/generic/hyph-utf8/HISTORY"
1574 "/doc/generic/hyph-utf8/hyph-utf8.pdf"
1575 "/doc/generic/hyph-utf8/hyph-utf8.tex"
1576 "/doc/generic/hyph-utf8/hyphenation-distribution.pdf"
1577 "/doc/generic/hyph-utf8/hyphenation-distribution.tex"
1578 "/doc/generic/hyph-utf8/img/miktex-languages.png"
1579 "/doc/generic/hyph-utf8/img/texlive-collection.png")
1580 (base32
1581 "10y8svgk68sivmgzrv8gv137r7kv49cs256cq2wja9ms437pxvbj")))
1582 (outputs '("out" "doc"))
1583 (build-system gnu-build-system)
1584 (arguments
1585 `(#:tests? #f ; there are none
1586 #:modules ((guix build gnu-build-system)
1587 (guix build utils)
1588 (ice-9 match))
1589 #:make-flags
1590 (list "-C" "source/luatex/hyph-utf8/"
1591 (string-append "DO_TEX = tex --interaction=nonstopmode '&tex' $<")
1592 (string-append "RUNDIR =" (assoc-ref %outputs "out") "/share/texmf-dist/tex/luatex/hyph-utf8/")
1593 (string-append "DOCDIR =" (assoc-ref %outputs "doc") "/share/texmf-dist/doc/luatex/hyph-utf8/")
1594 ;; hyphen.cfg is neither included nor generated, so let's only build the lua file.
1595 (string-append "UNPACKED = $(NAME).lua"))
1596 #:phases
1597 (modify-phases %standard-phases
1598 ;; TeX isn't usable at this point, so we first need to generate the
1599 ;; tex.fmt.
1600 (replace 'configure
1601 (lambda* (#:key inputs outputs #:allow-other-keys)
1602 ;; Target directories must exist.
1603 (mkdir-p (string-append (assoc-ref %outputs "out")
1604 "/share/texmf-dist/tex/luatex/hyph-utf8/"))
1605 (mkdir-p (string-append (assoc-ref %outputs "doc")
1606 "/share/texmf-dist/doc/luatex/hyph-utf8/"))
1607
1608 ;; We cannot build the documentation because that requires a
1609 ;; fully functional pdflatex, which depends on this package.
1610 (substitute* "source/luatex/hyph-utf8/Makefile"
1611 (("all: .*") "all: $(RUNFILES)\n"))
1612
1613 ;; Find required fonts for building tex.fmt
1614 (setenv "TFMFONTS"
1615 (string-append (assoc-ref inputs "texlive-fonts-cm")
1616 "/share/texmf-dist/fonts/tfm/public/cm:"
1617 (assoc-ref inputs "texlive-fonts-knuth-lib")
1618 "/share/texmf-dist/fonts/tfm/public/knuth-lib"))
1619 ;; ...and find all tex files in this environment.
1620 (setenv "TEXINPUTS"
1621 (string-append
1622 (getcwd) ":"
1623 (string-join
1624 (map (match-lambda ((_ . dir) dir)) inputs)
1625 "//:")))
1626
1627 ;; Generate tex.fmt.
1628 (let ((where "source/luatex/hyph-utf8"))
1629 (mkdir-p where)
1630 (with-directory-excursion where
1631 (invoke "tex" "-ini"
1632 (string-append (assoc-ref inputs "texlive-tex-plain")
1633 "/share/texmf-dist/tex/plain/config/tex.ini"))))))
1634 (add-before 'build 'build-loaders-and-converters
1635 (lambda* (#:key outputs #:allow-other-keys)
1636 (let* ((root (string-append (assoc-ref outputs "out")
1637 "/share/texmf-dist"))
1638 (conv
1639 (string-append root
1640 "/tex/generic/hyph-utf8/conversions")))
1641
1642 ;; Build converters
1643 (mkdir-p conv)
1644 (with-directory-excursion "source/generic/hyph-utf8"
1645 (substitute* "generate-converters.rb"
1646 (("\\$path_root=File.*")
1647 (string-append "$path_root=\"" root "\"\n"))
1648 ;; Avoid error with newer Ruby.
1649 (("#1\\{%") "#1{%%"))
1650 (invoke "ruby" "generate-converters.rb"))
1651 #t)))
1652 (replace 'install
1653 (lambda* (#:key source outputs #:allow-other-keys)
1654 (let ((doc (assoc-ref outputs "doc"))
1655 (out (assoc-ref outputs "out")))
1656 (mkdir-p doc)
1657 (copy-recursively
1658 (string-append source "/doc")
1659 (string-append doc "/doc"))
1660 (install-file
1661 (string-append source "/tex/luatex/hyph-utf8/etex.src")
1662 (string-append out "/share/texmf-dist/tex/luatex/hyph-utf8/")))
1663 #t)))))
1664 (native-inputs
1665 `(("ruby" ,ruby)
1666 ("texlive-bin" ,texlive-bin)
1667 ;; The following packages are needed for build "tex.fmt", which we need
1668 ;; for a working "tex".
1669 ("texlive-tex-plain" ,texlive-tex-plain)
1670 ("texlive-fonts-cm" ,texlive-fonts-cm)
1671 ("texlive-fonts-knuth-lib" ,texlive-fonts-knuth-lib)
1672 ("texlive-hyphen-base" ,texlive-hyphen-base)))
1673 (home-page "https://ctan.org/pkg/hyph-utf8")
1674 (synopsis "Hyphenation patterns expressed in UTF-8")
1675 (description "Modern native UTF-8 engines such as XeTeX and LuaTeX need
1676hyphenation patterns in UTF-8 format, whereas older systems require
1677hyphenation patterns in the 8-bit encoding of the font in use (such encodings
1678are codified in the LaTeX scheme with names like OT1, T2A, TS1, OML, LY1,
1679etc). The present package offers a collection of conversions of existing
1680patterns to UTF-8 format, together with converters for use with 8-bit fonts in
1681older systems. Since hyphenation patterns for Knuthian-style TeX systems are
1682only read at iniTeX time, it is hoped that the UTF-8 patterns, with their
1683converters, will completely supplant the older patterns.")
1684 ;; Individual files each have their own license. Most of these files are
1685 ;; independent hyphenation patterns.
1686 (license (list license:lppl1.0+
1687 license:lppl1.2+
1688 license:lppl1.3
1689 license:lppl1.3+
1690 license:lppl1.3a+
1691 license:lgpl2.1
1692 license:lgpl2.1+
1693 license:lgpl3+
1694 license:gpl2+
1695 license:gpl3+
1696 license:mpl1.1
1697 license:asl2.0
1698 license:expat
1699 license:bsd-3
1700 license:cc0
1701 license:public-domain
1702 license:wtfpl2))))
1703
1704(define-public texlive-generic-hyph-utf8
1705 (deprecated-package "texlive-generic-hyph-utf8" texlive-hyph-utf8))
1706
e68c7091
RW
1707(define-public texlive-dehyph-exptl
1708 (package
1709 (inherit (simple-texlive-package
1710 "texlive-dehyph-exptl"
1711 (list "/tex/generic/dehyph-exptl/"
1712 "/doc/generic/dehyph-exptl/")
1713 (base32
1714 "1w2danvvy2f52hcb4acvjks53kcanwxr9s990fap6mj279hpgmh2")
1715 #:trivial? #t))
1716 (propagated-inputs
1717 `(("texlive-hyphen-base" ,texlive-hyphen-base)
1718 ("texlive-hyph-utf8" ,texlive-hyph-utf8)))
1719 (home-page "http://projekte.dante.de/Trennmuster/WebHome")
1720 (synopsis "Hyphenation patterns for German")
1721 (description "The package provides experimental hyphenation patterns for
1722the German language, covering both traditional and reformed orthography. The
1723patterns can be used with packages Babel and hyphsubst from the Oberdiek
1724bundle.")
1725 ;; Hyphenation patterns are under the Expat license; documentation is
1726 ;; under LPPL.
1727 (license (list license:expat license:lppl))))
1728
1729(define-public texlive-generic-dehyph-exptl
1730 (deprecated-package "texlive-generic-dehyph-exptl" texlive-dehyph-exptl))
1731
010f476f
RW
1732(define-public texlive-latex-base
1733 (let ((texlive-dir
1734 (lambda (dir hash)
1735 (origin
1736 (method svn-fetch)
1737 (uri (svn-reference
1738 (url (string-append "svn://www.tug.org/texlive/tags/"
1739 %texlive-tag "/Master/texmf-dist/"
1740 dir))
1741 (revision %texlive-revision)))
8d514ae7
EF
1742 (file-name (string-append "texlive-generic-"
1743 (last (string-split
1744 (string-drop-right dir 1) #\/))
1745 "-" (number->string %texlive-revision)
1746 "-checkout"))
010f476f
RW
1747 (sha256 (base32 hash))))))
1748 (package
1749 (name "texlive-latex-base")
1750 (version (number->string %texlive-revision))
1751 (source (origin
1752 (method svn-fetch)
1753 (uri (texlive-ref "latex" "base"))
8d514ae7 1754 (file-name (string-append name "-" version "-checkout"))
010f476f
RW
1755 (sha256
1756 (base32
d4d9a1ec 1757 "17bqrzzjz16k52sc7ydl4vw7ddy2z3g0p1xsk2c35h1ynq9h3wwm"))))
010f476f
RW
1758 (build-system gnu-build-system)
1759 (arguments
1760 `(#:modules ((guix build gnu-build-system)
1761 (guix build utils)
1762 (ice-9 match)
1763 (srfi srfi-1)
1764 (srfi srfi-26))
1765 #:tests? #f ; no tests
1766 #:phases
1767 (modify-phases %standard-phases
1768 (delete 'configure)
1769 (replace 'build
1770 (lambda* (#:key inputs #:allow-other-keys)
1771 ;; Find required fonts
1772 (setenv "TFMFONTS"
1773 (string-append (assoc-ref inputs "texlive-fonts-cm")
1774 "/share/texmf-dist/fonts/tfm/public/cm:"
1775 (assoc-ref inputs "texlive-fonts-latex")
1776 "/share/texmf-dist/fonts/tfm/public/latex-fonts:"
1777 (assoc-ref inputs "texlive-fonts-knuth-lib")
1778 "/share/texmf-dist/fonts/tfm/public/knuth-lib"))
1779 (setenv "TEXINPUTS"
1780 (string-append
1781 (getcwd) ":"
1782 (getcwd) "/build:"
1783 (string-join
6858ade2
RW
1784 (map (match-lambda ((_ . dir) dir)) inputs)
1785 "//:")))
010f476f
RW
1786
1787 ;; Create an empty texsys.cfg, because latex.ltx wants to include
1788 ;; it. This file must exist and it's fine if it's empty.
1789 (with-output-to-file "texsys.cfg"
1790 (lambda _ (format #t "%")))
1791
1792 (mkdir "build")
1793 (mkdir "web2c")
4f2f53f9
MW
1794 (invoke "luatex" "-ini" "-interaction=batchmode"
1795 "-output-directory=build" "unpack.ins")
1796 (invoke "tex" "-ini" "-interaction=batchmode"
1797 "-output-directory=web2c" "tex.ini")
1798 ;; LaTeX, pdfetex/pdftex, and XeTeX require e-TeX, which
1799 ;; is enabled only in extended mode (activated with a
1800 ;; leading asterisk). We should not use luatex here,
1801 ;; because that would make the generated format files
1802 ;; incompatible with any other TeX engine.
1803 (for-each (lambda (format)
1804 (invoke "latex" "-ini" "-interaction=batchmode"
1805 "-output-directory=web2c"
1806 "-translate-file=cp227.tcx"
1807 (string-append "*" format ".ini")))
1808 '("latex"
1809 "pdflatex"
1810 "pdfetex"))
1811 (for-each (lambda (format)
1812 (invoke format "-ini" "-interaction=batchmode"
1813 "-output-directory=web2c"
1814 (string-append "*" format ".ini")))
1815 '("xetex"
1816 "xelatex"))
1817 (for-each (lambda (format)
1818 (invoke "luatex" "-ini" "-interaction=batchmode"
1819 "-output-directory=web2c"
1820 (string-append format ".ini")))
1821 '("dviluatex" "dvilualatex" "luatex" "lualatex"))
1822 #t))
010f476f 1823 (replace 'install
756fc3e1 1824 (lambda* (#:key inputs outputs #:allow-other-keys)
010f476f
RW
1825 (let* ((out (assoc-ref outputs "out"))
1826 (target (string-append
1827 out "/share/texmf-dist/tex/latex/base"))
1828 (web2c (string-append
756fc3e1
PN
1829 out "/share/texmf-dist/web2c"))
1830 (support-files (assoc-ref inputs "texlive-latex-base-support-files")))
010f476f
RW
1831 (mkdir-p target)
1832 (mkdir-p web2c)
1833 (for-each delete-file (find-files "." "\\.(log|aux)$"))
1834 (for-each (cut install-file <> target)
1835 (find-files "build" ".*"))
1836 (for-each (cut install-file <> web2c)
1837 (find-files "web2c" ".*"))
bd6e2385
RW
1838 ;; pdftex is really just the same as pdfetex, but since it
1839 ;; doesn't have its own format file, we need to copy it.
1840 (copy-file "web2c/pdfetex.fmt"
1841 (string-append web2c "/pdftex.fmt"))
756fc3e1
PN
1842 ;; "source" is missing the support files as per doc/latex/base/manifest.txt.
1843 ;; FIXME: We are probably not packaging this right.
1844 (for-each (lambda (file)
1845 (install-file
1846 (string-append support-files "/" file)
1847 target))
1848 '("ltxguide.cls" "ltnews.cls" "minimal.cls" "idx.tex"
1849 "lablst.tex" "testpage.tex" "ltxcheck.tex"))
d68c8017
RW
1850 ;; Install configurations
1851 (copy-recursively
1852 (assoc-ref inputs "texlive-latex-latexconfig")
1853 (string-append out "/share/texmf-dist/tex/latex/latexconfig"))
1854 (copy-recursively
1855 (assoc-ref inputs "texlive-generic-config")
1856 (string-append out "/share/texmf-dist/tex/generic/config"))
1857 (copy-recursively
1858 (assoc-ref inputs "texlive-generic-hyphen")
1859 (string-append out "/share/texmf-dist/tex/generic/hyphen"))
1860 (copy-recursively
1861 (assoc-ref inputs "texlive-generic-ruhyphen")
1862 (string-append out "/share/texmf-dist/tex/generic/ruhyphen"))
1863 (copy-recursively
1864 (assoc-ref inputs "texlive-generic-ukrhyph")
1865 (string-append out "/share/texmf-dist/tex/generic/ukrhyph"))
010f476f
RW
1866 #t))))))
1867 (native-inputs
1868 `(("texlive-bin" ,texlive-bin)
1869 ("texlive-generic-unicode-data" ,texlive-generic-unicode-data)
1870 ("texlive-generic-dehyph-exptl" ,texlive-generic-dehyph-exptl)
1871 ("texlive-generic-tex-ini-files" ,texlive-generic-tex-ini-files)
1872 ("texlive-latex-latexconfig"
1873 ,(texlive-dir "tex/latex/latexconfig/"
1874 "1zb3j49cj8p75yph6c8iysjp7qbdvghwf0mn9j0l7qq3qkbz2xaf"))
010f476f
RW
1875 ("texlive-generic-hyphen"
1876 ,(texlive-dir "tex/generic/hyphen/"
1877 "0xim36wybw2625yd0zwlp9m2c2xrcybw58gl4rih9nkph0wqwwhd"))
1878 ("texlive-generic-ruhyphen"
1879 ,(texlive-dir "tex/generic/ruhyphen/"
1880 "14rjkpl4zkjqs13rcf9kcd24mn2kx7i1jbdwxq8ds94bi66ylzsd"))
1881 ("texlive-generic-ukrhyph"
1882 ,(texlive-dir "tex/generic/ukrhyph/"
1883 "1cfwdg2rhbayl3w0x1xqd36d45zbc96f029myp13s7cb6kbmbppv"))
1884 ("texlive-generic-config"
1885 ,(texlive-dir "tex/generic/config/"
d4d9a1ec 1886 "1v90iihy112q93zdpblpdk8zv8rf99fgslsg06s1sxm27zjm9nap"))
756fc3e1
PN
1887 ("texlive-latex-base-support-files"
1888 ,(origin
1889 (method svn-fetch)
1890 (uri (svn-reference
1891 (url (string-append "svn://www.tug.org/texlive/tags/"
1892 %texlive-tag "/Master/texmf-dist/"
1893 "/tex/latex/base"))
1894 (revision %texlive-revision)))
1895 (file-name (string-append name "-" version "-checkout"))
1896 (sha256
1897 (base32
d4d9a1ec 1898 "18wy8dlcw8adl6jzqwbg54pdwlhs8hilnfvqbw6ikj6y3zhqkj7q"))))
010f476f
RW
1899 ("texlive-tex-plain" ,texlive-tex-plain)
1900 ("texlive-fonts-cm" ,texlive-fonts-cm)
1901 ("texlive-fonts-latex" ,texlive-fonts-latex)
1902 ("texlive-fonts-knuth-lib" ,texlive-fonts-knuth-lib)))
d68c8017
RW
1903 (propagated-inputs
1904 `(("texlive-generic-hyph-utf8" ,texlive-generic-hyph-utf8)))
b8d8806b 1905 (home-page "https://www.ctan.org/pkg/latex-base")
010f476f
RW
1906 (synopsis "Base sources of LaTeX")
1907 (description
1908 "This bundle comprises the source of LaTeX itself, together with several
1909packages which are considered \"part of the kernel\". This bundle, together
1910with the required packages, constitutes what every LaTeX distribution should
1911contain.")
1912 (license license:lppl1.3c+))))
1913
3e485ed2
RW
1914(define-public texlive-latex-filecontents
1915 (package
1916 (name "texlive-latex-filecontents")
1917 (version (number->string %texlive-revision))
1918 (source (origin
1919 (method svn-fetch)
1920 (uri (texlive-ref "latex" "filecontents"))
7e353a77 1921 (file-name (string-append name "-" version "-checkout"))
3e485ed2
RW
1922 (sha256
1923 (base32
1924 "0swkbxv8vg0yizadfnvrwjb4cj0pn34v9wm6v7wqq903fdav7k7q"))))
1925 (build-system texlive-build-system)
1926 (arguments '(#:tex-directory "latex/filecontents"))
b8d8806b 1927 (home-page "https://www.ctan.org/pkg/filecontents")
3e485ed2
RW
1928 (synopsis "Extended filecontents and filecontents* environments")
1929 (description
1930 "LaTeX2e's @code{filecontents} and @code{filecontents*} environments
1931enable a LaTeX source file to generate external files as it runs through
1932LaTeX. However, there are two limitations of these environments: they refuse
1933to overwrite existing files, and they can only be used in the preamble of a
1934document. The filecontents package removes these limitations, letting you
1935overwrite existing files and letting you use @code{filecontents} /
1936@code{filecontents*} anywhere.")
1937 (license license:lppl1.3c+)))
1938
1193aa89
RW
1939(define-public texlive-generic-ifxetex
1940 (package
1941 (name "texlive-generic-ifxetex")
fea8eef3 1942 (version (number->string %texlive-revision))
1193aa89
RW
1943 (source (origin
1944 (method svn-fetch)
1945 (uri (texlive-ref "generic" "ifxetex"))
24dbc602 1946 (file-name (string-append name "-" version "-checkout"))
1193aa89
RW
1947 (sha256
1948 (base32
1949 "0w2xj7n0szavj329kds09q626szkc378p3w0sk022q0ln4ksz86d"))))
1950 (build-system texlive-build-system)
1951 (arguments
1952 '(#:tex-directory "generic/ifxetex"
1953 #:tex-format "xelatex"))
1954 (inputs
1955 `(("texlive-latex-filecontents" ,texlive-latex-filecontents)))
b8d8806b 1956 (home-page "https://www.ctan.org/pkg/ifxetex")
1193aa89
RW
1957 (synopsis "Am I running under XeTeX?")
1958 (description
1959 "This is a simple package which provides an @code{\\ifxetex} conditional,
1960so that other code can determine that it is running under XeTeX. The package
beb476ed 1961requires the e-TeX extensions to the TeX primitive set.")
1193aa89
RW
1962 (license license:lppl1.3c+)))
1963
9186c156
RW
1964(define-public texlive-generic-epsf
1965 (package
1966 (name "texlive-generic-epsf")
1967 (version (number->string %texlive-revision))
1968 (source (origin
1969 (method svn-fetch)
1970 (uri (svn-reference
1971 (url (string-append "svn://www.tug.org/texlive/tags/"
1972 %texlive-tag "/Master/texmf-dist/"
1973 "/tex/generic/epsf"))
1974 (revision %texlive-revision)))
ca61c6b3 1975 (file-name (string-append name "-" version "-checkout"))
9186c156
RW
1976 (sha256
1977 (base32
1978 "14w3j81ympyvg8hkk9i1xgr8a0gfnfsb2ki8qqsk5pa051za1xcy"))))
1979 (build-system trivial-build-system)
1980 (arguments
1981 `(#:modules ((guix build utils))
1982 #:builder
1983 (begin
1984 (use-modules (guix build utils))
1985 (let ((target (string-append (assoc-ref %outputs "out")
1986 "/share/texmf-dist/tex/generic/epfs")))
1987 (mkdir-p target)
1988 (copy-recursively (assoc-ref %build-inputs "source") target)
1989 #t))))
b8d8806b 1990 (home-page "https://www.ctan.org/pkg/epsf")
9186c156
RW
1991 (synopsis "Simple macros for EPS inclusion")
1992 (description
1993 "This package provides the original (and now obsolescent) graphics
1994inclusion macros for use with dvips, still widely used by Plain TeX users (in
1995particular). For LaTeX users, the package is nowadays (rather strongly)
1996deprecated in favour of the more sophisticated standard LaTeX latex-graphics
1997bundle of packages. (The latex-graphics bundle is also available to Plain TeX
1998users, via its Plain TeX version.)")
1999 (license license:public-domain)))
2000
437822a1
RW
2001(define-public texlive-latex-fancyvrb
2002 (package
2003 (name "texlive-latex-fancyvrb")
2004 (version (number->string %texlive-revision))
2005 (source (origin
2006 (method svn-fetch)
2007 (uri (texlive-ref "latex" "fancyvrb"))
88e11022 2008 (file-name (string-append name "-" version "-checkout"))
437822a1
RW
2009 (sha256
2010 (base32
2011 "03l7140y031rr14h02i4z9zqsfvrbn7wzwxbjsrjcgrk6sdr71wv"))))
2012 (build-system texlive-build-system)
2013 (arguments
2014 '(#:tex-directory "latex/fancyvrb"
bae65dc4 2015 #:tex-format "latex"))
b8d8806b 2016 (home-page "https://www.ctan.org/pkg/fancyvrb")
437822a1
RW
2017 (synopsis "Sophisticated verbatim text")
2018 (description
2019 "This package provides tools for the flexible handling of verbatim text
2020including: verbatim commands in footnotes; a variety of verbatim environments
2021with many parameters; ability to define new customized verbatim environments;
2022save and restore verbatim text and environments; write and read files in
2023verbatim mode; build \"example\" environments (showing both result and
2024verbatim source).")
2025 (license license:lppl1.0+)))
2026
4eebd2cd
RW
2027(define-public texlive-latex-graphics
2028 (package
2029 (name "texlive-latex-graphics")
2030 (version (number->string %texlive-revision))
2031 (source (origin
2032 (method svn-fetch)
2033 (uri (texlive-ref "latex" "graphics"))
f7302073 2034 (file-name (string-append name "-" version "-checkout"))
4eebd2cd
RW
2035 (sha256
2036 (base32
d4d9a1ec 2037 "0nlfhn55ax89rcvpkrl9570671b62kcr4c9l5ch3w5zw9vmi00dz"))))
4eebd2cd
RW
2038 (build-system texlive-build-system)
2039 (arguments
2040 '(#:tex-directory "latex/graphics"
2041 #:phases
2042 (modify-phases %standard-phases
2043 (add-after 'install 'install-config
2044 (lambda* (#:key inputs outputs #:allow-other-keys)
2045 (let ((cfg (assoc-ref inputs "graphics-cfg"))
2046 (target (string-append (assoc-ref outputs "out")
2047 "/share/texmf-dist/tex/latex/graphics-cfg")))
2048 (mkdir-p target)
2049 (install-file (string-append cfg "/graphics.cfg") target)
2050 (install-file (string-append cfg "/color.cfg") target)
2051 #t)))
2052 (add-after 'install 'install-defs
2053 (lambda* (#:key inputs outputs #:allow-other-keys)
2054 (let ((def (assoc-ref inputs "graphics-def"))
2055 (target (string-append (assoc-ref outputs "out")
2056 "/share/texmf-dist/tex/latex/graphics-def")))
2057 (mkdir-p target)
2058 (copy-recursively def target)
2059 #t))))))
2060 (native-inputs
2061 `(("graphics-cfg"
2062 ,(origin
2063 (method git-fetch)
2064 (uri (git-reference
2065 (url "https://github.com/latex3/graphics-cfg.git")
2066 (commit "19d1238af17df376cd46333b229579b0f7f3a41f")))
f7302073
EF
2067 (file-name (string-append "graphics-cfg-"
2068 (number->string %texlive-revision)
2069 "-checkout"))
4eebd2cd
RW
2070 (sha256
2071 (base32
2072 "12kbgbm52gmmgn8zajb74s8n5rvnxcfdvs3iyj8vcw5vrsw5i6mh"))))
2073 ("graphics-def"
2074 ,(origin
2075 (method svn-fetch)
2076 (uri (svn-reference
2077 (url (string-append "svn://www.tug.org/texlive/tags/"
2078 %texlive-tag "/Master/texmf-dist/"
2079 "/tex/latex/graphics-def"))
2080 (revision %texlive-revision)))
f7302073
EF
2081 (file-name (string-append "graphics-def-"
2082 (number->string %texlive-revision)
2083 "-checkout"))
4eebd2cd
RW
2084 (sha256
2085 (base32
d4d9a1ec 2086 "17zpcgrfsr29g1dkz9np1qi63kjv7gb12rg979c6dai6qksbr3vq"))))))
b8d8806b 2087 (home-page "https://www.ctan.org/pkg/latex-graphics")
4eebd2cd
RW
2088 (synopsis "LaTeX standard graphics bundle")
2089 (description
2090 "This is a collection of LaTeX packages for producing color, including
2091graphics (e.g. PostScript) files, and rotation and scaling of text in LaTeX
2092documents. It comprises the packages color, graphics, graphicx, trig, epsfig,
2093keyval, and lscape.")
2094 ;; The configuration files are released under CC0.
2095 (license (list license:lppl1.3c+
2096 license:cc0))))
2097
f5a6af42
RW
2098(define-public texlive-latex-xcolor
2099 (package
2100 (name "texlive-latex-xcolor")
2101 (version (number->string %texlive-revision))
2102 (source (origin
2103 (method svn-fetch)
2104 (uri (texlive-ref "latex" "xcolor"))
19389bcd 2105 (file-name (string-append name "-" version "-checkout"))
f5a6af42
RW
2106 (sha256
2107 (base32
2108 "01n613s7bcrd2n4jfawm0k4nn2ny3aaifp2jjfif3lz4sbv31494"))))
2109 (build-system texlive-build-system)
2110 (arguments '(#:tex-directory "latex/xcolor"))
b8d8806b 2111 (home-page "https://www.ctan.org/pkg/xcolor")
f5a6af42
RW
2112 (synopsis "Driver-independent color extensions for LaTeX and pdfLaTeX")
2113 (description
2114 "The package starts from the basic facilities of the colorcolor package,
2115and provides easy driver-independent access to several kinds of color tints,
2116shades, tones, and mixes of arbitrary colors. It allows a user to select a
2117document-wide target color model and offers complete tools for conversion
2118between eight color models. Additionally, there is a command for alternating
2119row colors plus repeated non-aligned material (like horizontal lines) in
2120tables.")
2121 (license license:lppl1.2+)))
2122
4d660fdf
RW
2123(define-public texlive-latex-hyperref
2124 (package
2125 (name "texlive-latex-hyperref")
2126 (version "6.84a2")
2127 ;; The sources in the TeX Live SVN repository do not contain hluatex.dtx,
2128 ;; so we fetch the release from GitHub.
2129 (source (origin
2130 (method url-fetch)
2131 (uri (string-append "https://github.com/ho-tex/hyperref/"
2132 "archive/release-" version ".tar.gz"))
2133 (file-name (string-append name "-" version ".tar.gz"))
2134 (sha256
2135 (base32
2136 "1d3rmjgzh0025a1dza55zb6nzzlgd1y9snwx45wq1c1vf42m79h2"))))
2137 (build-system texlive-build-system)
2138 (arguments '(#:tex-directory "latex/hyperref"))
2a0bcbf4
RW
2139 (propagated-inputs
2140 `(("texlive-latex-oberdiek" ,texlive-latex-oberdiek) ; for ltxcmds.sty
2141 ("texlive-latex-url" ,texlive-latex-url)))
b8d8806b 2142 (home-page "https://www.ctan.org/pkg/hyperref")
4d660fdf
RW
2143 (synopsis "Extensive support for hypertext in LaTeX")
2144 (description
c5a8ecb6
RW
2145 "The @code{hyperref} package is used to handle cross-referencing commands
2146in LaTeX to produce hypertext links in the document. The package provides
2147backends for the @code{\\special} set defined for HyperTeX DVI processors; for
2148embedded @code{pdfmark} commands for processing by Acrobat
2149Distiller (@code{dvips} and Y&Y's @code{dvipsone}); for Y&Y's @code{dviwindo};
2150for PDF control within pdfTeX and @code{dvipdfm}; for TeX4ht; and for VTeX's
2151pdf and HTML backends. The package is distributed with the @code{backref} and
2152@code{nameref} packages, which make use of the facilities of @code{hyperref}.")
4d660fdf
RW
2153 (license license:lppl1.3+)))
2154
c3455b7d
RW
2155(define-public texlive-latex-oberdiek
2156 (package
2157 (name "texlive-latex-oberdiek")
2158 (version (number->string %texlive-revision))
2159 (source (origin
2160 (method svn-fetch)
2161 (uri (texlive-ref "latex" "oberdiek"))
7dea3119 2162 (file-name (string-append name "-" version "-checkout"))
c3455b7d
RW
2163 (sha256
2164 (base32
d4d9a1ec 2165 "1m9fg8ddhpsl1212igr9a9fmj012lv780aghjn6fpidg2wqrffmn"))))
c3455b7d
RW
2166 (build-system texlive-build-system)
2167 (arguments
2168 '(#:tex-directory "latex/oberdiek"
05d28068 2169 #:build-targets '("oberdiek.ins")
c3455b7d
RW
2170 #:phases
2171 (modify-phases %standard-phases
05d28068 2172 ;; "ifpdf.ins" is not generated, so we need to process the dtx file.
c3455b7d
RW
2173 (add-after 'unpack 'do-not-process-ifpdf.ins
2174 (lambda _
2175 (substitute* "oberdiek.ins"
05d28068 2176 (("ifpdf.ins") "ifpdf.dtx"))
c3455b7d 2177 #t)))))
a9cd7b03
RW
2178 (propagated-inputs
2179 `(("texlive-generic-ifxetex" ,texlive-generic-ifxetex)))
b8d8806b 2180 (home-page "https://www.ctan.org/pkg/oberdiek")
c3455b7d
RW
2181 (synopsis "Bundle of packages submitted by Heiko Oberdiek")
2182 (description
2183 "The bundle comprises various LaTeX packages, providing among others:
2184better accessibility support for PDF files; extensible chemists reaction
2185arrows; record information about document class(es) used; and many more.")
2186 (license license:lppl1.3+)))
2187
f2536af2
RW
2188(define-public texlive-latex-tools
2189 (package
2190 (name "texlive-latex-tools")
2191 (version (number->string %texlive-revision))
2192 (source (origin
2193 (method svn-fetch)
2194 (uri (texlive-ref "latex" "tools"))
f8340ab1 2195 (file-name (string-append name "-" version "-checkout"))
f2536af2
RW
2196 (sha256
2197 (base32
d4d9a1ec 2198 "0vj7h1fgf1396h4qjdc2m07y08i54gbbfrxl8y327cn3r1n093s6"))))
f2536af2
RW
2199 (build-system texlive-build-system)
2200 (arguments
2201 '(#:tex-directory "latex/tools"
2202 #:build-targets '("tools.ins")))
b8d8806b 2203 (home-page "https://www.ctan.org/pkg/latex-tools")
f2536af2
RW
2204 (synopsis "LaTeX standard tools bundle")
2205 (description
2206 "This package is a collection of (variously) simple tools provided as
2207part of the LaTeX required tools distribution, comprising the following
2208packages: afterpage, array, bm, calc, dcolumn, delarray, enumerate, fileerr,
2209fontsmpl, ftnright, hhline, indentfirst, layout, longtable, multicol,
2210rawfonts, showkeys, somedefs, tabularx, theorem, trace, varioref, verbatim,
2211xr, and xspace.")
2212 (license license:lppl1.3+)))
2213
35adcc3a
RW
2214(define-public texlive-latex-url
2215 (package
2216 (name "texlive-latex-url")
2217 (version (number->string %texlive-revision))
2218 (source (origin
2219 (method svn-fetch)
2220 (uri (svn-reference
2221 (url (string-append "svn://www.tug.org/texlive/tags/"
2222 %texlive-tag "/Master/texmf-dist/"
2223 "/tex/latex/url"))
2224 (revision %texlive-revision)))
a26207f8 2225 (file-name (string-append name "-" version "-checkout"))
35adcc3a
RW
2226 (sha256
2227 (base32
2228 "184s2543cwia5l7iibhlkl1ffbncfhjpv5p56zq0c15by5sghlac"))))
2229 (build-system trivial-build-system)
2230 (arguments
2231 `(#:modules ((guix build utils))
2232 #:builder
2233 (begin
2234 (use-modules (guix build utils))
2235 (let ((target (string-append (assoc-ref %outputs "out")
2236 "/share/texmf-dist/tex/latex/url")))
2237 (mkdir-p target)
2238 (copy-recursively (assoc-ref %build-inputs "source") target)
2239 #t))))
2240 (home-page "https://www.ctan.org/pkg/url")
2241 (synopsis "Verbatim with URL-sensitive line breaks")
2242 (description "The command @code{\\url} is a form of verbatim command that
2243allows linebreaks at certain characters or combinations of characters, accepts
2244reconfiguration, and can usually be used in the argument to another command.
2245The command is intended for email addresses, hypertext links,
2246directories/paths, etc., which normally have no spaces, so by default the
2247package ignores spaces in its argument. However, a package option allows
2248spaces, which is useful for operating systems where spaces are a common part
2249of file names.")
2250 ;; The license header states that it is under LPPL version 2 or later, but
2251 ;; the latest version is 1.3c.
2252 (license license:lppl1.3c+)))
2253
a5b1ef84
RW
2254(define-public texlive-latex-l3kernel
2255 (package
2256 (name "texlive-latex-l3kernel")
2257 (version (number->string %texlive-revision))
2258 (source (origin
2259 (method svn-fetch)
2260 (uri (texlive-ref "latex" "l3kernel"))
f4a39a5b 2261 (file-name (string-append name "-" version "-checkout"))
a5b1ef84
RW
2262 (sha256
2263 (base32
d4d9a1ec 2264 "0p3fsxap1ilwjz356aq4s5ygwvdscis8bh93g8klf8mhrd8cr2jy"))))
a5b1ef84
RW
2265 (build-system texlive-build-system)
2266 (arguments
2267 '(#:tex-directory "latex/l3kernel"))
b8d8806b 2268 (home-page "https://www.ctan.org/pkg/l3kernel")
a5b1ef84
RW
2269 (synopsis "LaTeX3 programmers’ interface")
2270 (description
2271 "The l3kernel bundle provides an implementation of the LaTeX3
2272programmers’ interface, as a set of packages that run under LaTeX 2e. The
2273interface provides the foundation on which the LaTeX3 kernel and other future
2274code are built: it is an API for TeX programmers. The packages are set up so
2275that the LaTeX3 conventions can be used with regular LaTeX 2e packages.")
2276 (license license:lppl1.3c+)))
2277
cc09d48b
RW
2278(define-public texlive-latex-l3packages
2279 (package
2280 (name "texlive-latex-l3packages")
2281 (version (number->string %texlive-revision))
2282 (source (origin
2283 (method svn-fetch)
2284 (uri (texlive-ref "latex" "l3packages"))
b749aa98 2285 (file-name (string-append name "-" version "-checkout"))
cc09d48b
RW
2286 (sha256
2287 (base32
d4d9a1ec 2288 "0pyx0hffiyss363vv7fkrcdiaf7p099xnq0mngzqc7v8v9q849hs"))))
cc09d48b
RW
2289 (build-system texlive-build-system)
2290 (arguments
2291 '(#:tex-directory "latex/l3packages"
3d4908a7
PN
2292 ;; build-targets must be specified manually since they are in
2293 ;; sub-directories.
2294 #:build-targets '("l3keys2e.ins" "xparse.ins" "xfrac.ins" "xfp.ins" "xtemplate.ins")
cc09d48b
RW
2295 #:phases
2296 (modify-phases %standard-phases
2297 ;; All package sources are in sub-directories, so we need to add them
2298 ;; to TEXINPUTS.
2299 (add-after 'unpack 'set-TEXINPUTS
2300 (lambda _
2301 (let ((cwd (getcwd)))
2302 (setenv "TEXINPUTS"
2303 (string-append cwd "/l3keys2e:"
2304 cwd "/xparse:"
2305 cwd "/xfrac:"
2306 cwd "/xfp:"
3d4908a7
PN
2307 cwd "/xtemplate"
2308 ;; The terminating ":" is required to include the
2309 ;; l3kernel input as well.
2310 ":")))
2311 #t)))
2312 ))
2fea7041 2313 (propagated-inputs
cc09d48b 2314 `(("texlive-latex-l3kernel" ,texlive-latex-l3kernel)))
b8d8806b 2315 (home-page "https://www.ctan.org/pkg/l3packages")
cc09d48b
RW
2316 (synopsis "High-level LaTeX3 concepts")
2317 (description
2318 "This bundle holds prototype implementations of concepts for a LaTeX
2319designer interface, to be used with the experimental LaTeX kernel as
2320programming tools and kernel sup­port. Packages provided in this release are:
2321
2322@enumerate
2323@item l3keys2e, which makes the facilities of the kernel module l3keys
2324 available for use by LaTeX 2e packages;
2325@item xfrac, which provides flexible splitlevel fractions;
2326@item xparse, which provides a high-level interface for declaring document
2327 commands; and
2328@item xtemplate, which provides a means of defining generic functions using a
2329 key-value syntax.
2330@end enumerate\n")
2331 (license license:lppl1.3c+)))
2332
58308491
RW
2333(define-public texlive-latex-fontspec
2334 (package
2335 (name "texlive-latex-fontspec")
2336 (version (number->string %texlive-revision))
2337 (source (origin
2338 (method svn-fetch)
2339 (uri (texlive-ref "latex" "fontspec"))
634a4a7f 2340 (file-name (string-append name "-" version "-checkout"))
58308491
RW
2341 (sha256
2342 (base32
d4d9a1ec 2343 "1p0mkn6iywl0k4m9cx3hnhylpi499inisff3f72pcf349baqsnvq"))))
58308491
RW
2344 (build-system texlive-build-system)
2345 (arguments
9c45beb4
RW
2346 '(#:tex-directory "latex/fontspec"
2347 #:phases
2348 (modify-phases %standard-phases
2349 (add-after 'install 'install-default-fontspec.cfg
2350 (lambda* (#:key outputs #:allow-other-keys)
2351 (with-output-to-file
2352 (string-append (assoc-ref outputs "out")
2353 "/share/texmf-dist/tex/latex/fontspec/fontspec.cfg")
2354 (lambda _
2355 (display "\
2356%%% FONTSPEC.CFG %%%
2357%
2358% This configuration file sets up TeX Ligatures by default for all fonts loaded
2359% with `\\setmainfont` and `\\setsansfont`.
2360%
2361% In addition, `\\setmonofont` has default features to enforce \"monospace\"
2362% settings with regard to space stretchability and shrinkability.
2363
2364\\defaultfontfeatures
2365 [\\rmfamily,\\sffamily]
2366 {Ligatures=TeX}
2367
2368\\defaultfontfeatures
2369 [\\ttfamily]
2370 {WordSpace={1,0,0},
2371 HyphenChar=None,
2372 PunctuationSpace=WordSpace}
2373")))
2374 #t)))))
b80ecc5a
RW
2375 (propagated-inputs
2376 `(("texlive-latex-l3packages" ,texlive-latex-l3packages)))
b8d8806b 2377 (home-page "https://www.ctan.org/pkg/fontspec")
58308491
RW
2378 (synopsis "Advanced font selection in XeLaTeX and LuaLaTeX")
2379 (description
2380 "Fontspec is a package for XeLaTeX and LuaLaTeX. It provides an
2381automatic and unified interface to feature-rich AAT and OpenType fonts through
2382the NFSS in LaTeX running on XeTeX or LuaTeX engines. The package requires
2383the l3kernel and xparse bundles from the LaTeX 3 development team.")
2384 (license license:lppl1.3+)))
2385
e93f472d
RW
2386;; The SVN directory contains little more than a dtx file that generates three
2387;; of the many lua files that should be installed as part of this package.
2388;; This is why we take the release from GitHub instead.
2389(define-public texlive-luatex-lualibs
2390 (package
2391 (name "texlive-luatex-lualibs")
2392 (version "2.5")
2393 (source (origin
2394 (method url-fetch)
2395 (uri (string-append "https://github.com/lualatex/lualibs/"
2396 "releases/download/v"
2397 version "/lualibs.zip"))
01d79c30 2398 (file-name (string-append name "-" version ".zip"))
e93f472d
RW
2399 (sha256
2400 (base32
2401 "1xx9blvrmx9hyhrl345lpai9m6xxnw997261a1ahn1bm5r2j5fqy"))))
2402 (build-system gnu-build-system)
2403 (arguments
2404 `(#:make-flags
2405 (list (string-append "DESTDIR="
2406 (assoc-ref %outputs "out")
2407 "/share/texmf-dist"))
2408 #:phases
2409 (modify-phases %standard-phases
2410 (delete 'configure))))
2411 (native-inputs
2412 `(("texlive-bin" ,texlive-bin)
2413 ("unzip" ,unzip)
2414 ("zip" ,zip)))
2415 (home-page "https://github.com/lualatex/lualibs")
2416 (synopsis "Lua modules for general programming (in the (La)TeX world)")
2417 (description
2418 "Lualibs is a collection of Lua modules useful for general programming.
2419The bundle is based on Lua modules shipped with ConTeXt, and made available in
2420this bundle for use independent of ConTeXt.")
2421 ;; GPL version 2 only
2422 (license license:gpl2)))
2423
769bb5e5
RW
2424(define-public texlive-luatex-luaotfload
2425 (package
2426 (name "texlive-luatex-luaotfload")
2427 (version "2.8-fix-2")
2428 ;; The release tarball does not contain all source files.
2429 (source (origin
2430 (method git-fetch)
2431 (uri (git-reference
2432 (url "https://github.com/lualatex/luaotfload.git")
2433 (commit (string-append "v" version))))
2434 (file-name (git-file-name name version))
2435 (sha256
2436 (base32
2437 "0l5l7iq3dxcxl65qaghcpjg27yd9iw1sxa8pnd7xlvlm09dhfdnf"))))
2438 (build-system gnu-build-system)
2439 (arguments
2440 `(#:make-flags
2441 (list (string-append "DESTDIR="
2442 (assoc-ref %outputs "out")
2443 "/share/texmf-dist")
2444 "all")
2445 #:parallel-build? #f ; not supported
2446 #:phases
2447 (modify-phases %standard-phases
2448 (replace 'configure
2449 (lambda* (#:key inputs #:allow-other-keys)
2450 (substitute* "doc/Makefile"
2451 (("rst2man") "rst2man.py")
2452 ;; Don't build the PDF. This requires more of LaTeX.
2453 (("\\$\\(DOCPDF\\)") ""))
2454
2455 (substitute* "Makefile"
2456 ;; We don't build the PDF, so don't attempt to install it.
2457 (("cp \\$\\(RESOURCES\\) \\$\\(DOCPDF\\)")
2458 "cp $(RESOURCES)")
2459 (("= \\$\\(DOCPDF\\)") "= ")
2460 ;; Fix name of fontloader file
2461 (("^LOADER.*= \\$\\(BUILDDIR\\)/fontloader-\\$\\(shell date \\+%F\\).lua")
2462 "LOADER = $(BUILDDIR)/fontloader.lua"))
2463
2464 (mkdir "build")
2465
2466 ;; Don't download this file.
2467 (copy-file (assoc-ref inputs "glyphlist")
2468 "build/glyphlist.txt")
2469
2470 ;; Don't use git
2471 (let ((notes
2472 `((committer . "Philipp Gesang <phg@phi-gamma.net>")
2473 (description . ,version)
2474 (loader . "fontloader.lua")
2475 (revision . "ad480924393fffa2896156e1a32c22f5c61120dd")
2476 (timestamp . "2019-01-01 00:00:00 +0000"))))
2477 (substitute* "scripts/mkstatus"
2478 (("local notes.*=.*")
2479 (string-append "local notes = {"
2480 (string-join
2481 (map (lambda (entry)
2482 (format "[\"~a\"]=\"~a\","
2483 (symbol->string (car entry))
2484 (cdr entry)))
2485 notes))
2486 "}"))))
2487 #t)))))
2488 (native-inputs
2489 `(("zip" ,zip)
2490 ("unzip" ,unzip)
2491 ("graphviz" ,graphviz)
2492 ("lualatex" ,(texlive-union (list texlive-luatex-lualibs
2493 texlive-context-base)))
2494 ("python-docutils" ,python-docutils)
2495 ("glyphlist"
2496 ,(origin
2497 (method url-fetch)
2498 (uri (string-append "https://raw.githubusercontent.com/adobe-type-tools/"
2499 "agl-aglfn/b2a04cb906f9257cc06a2fe0ad4b3d663bc02136/"
2500 "glyphlist.txt"))
2501 (sha256
2502 (base32 "1s6svfw23rqzdvflv8frgd4xrwvrmsj8szwzqgcd39dp9rpjafjp"))))))
2503 (propagated-inputs
2504 `(("texlive-luatex-lualibs" ,texlive-luatex-lualibs)))
2505 (home-page "https://github.com/lualatex/luaotfload")
2506 (synopsis "OpenType font loader for LuaTeX")
2507 (description
2508 "Luaotfload is an adaptation of the ConTeXt font loading system for the
2509Plain and LaTeX formats. It allows OpenType fonts to be loaded with font
2510features accessible using an extended font request syntax while providing
2511compatibilitywith XeTeX. By indexing metadata in a database it facilitates
2512loading fonts by their proper names instead of file names.")
2513 ;; GPL version 2 only
2514 (license license:gpl2)))
2515
2573163a
RW
2516(define-public texlive-latex-amsmath
2517 (package
2518 (name "texlive-latex-amsmath")
2519 (version (number->string %texlive-revision))
2520 (source (origin
2521 (method svn-fetch)
2522 (uri (texlive-ref "latex" "amsmath"))
320c771a 2523 (file-name (string-append name "-" version "-checkout"))
2573163a
RW
2524 (sha256
2525 (base32
d4d9a1ec 2526 "0arvk7gn32mshnfdad5qkgf3i1arxq77k3vq7wnpm4nwnrzclxal"))))
2573163a
RW
2527 (build-system texlive-build-system)
2528 (arguments '(#:tex-directory "latex/amsmath"))
b8d8806b 2529 (home-page "https://www.ctan.org/pkg/amsmath")
2573163a
RW
2530 (synopsis "AMS mathematical facilities for LaTeX")
2531 (description
2532 "This is the principal package in the AMS-LaTeX distribution. It adapts
2533for use in LaTeX most of the mathematical features found in AMS-TeX; it is
2534highly recommended as an adjunct to serious mathematical typesetting in LaTeX.
2535When amsmath is loaded, AMS-LaTeX packages @code{amsbsyamsbsy} (for bold
2536symbols), @code{amsopnamsopn} (for operator names) and
2537@code{amstextamstext} (for text embedded in mathematics) are also loaded.
2538This package is part of the LaTeX required distribution; however, several
2539contributed packages add still further to its appeal; examples are
2540@code{empheqempheq}, which provides functions for decorating and highlighting
2541mathematics, and @code{ntheoremntheorem}, for specifying theorem (and similar)
2542definitions.")
2543 (license license:lppl1.3c+)))
2544
18e366e8
RW
2545(define-public texlive-latex-amscls
2546 (package
2547 (name "texlive-latex-amscls")
2548 (version (number->string %texlive-revision))
2549 (source (origin
2550 (method svn-fetch)
2551 (uri (texlive-ref "latex" "amscls"))
43059ed0 2552 (file-name (string-append name "-" version "-checkout"))
18e366e8
RW
2553 (sha256
2554 (base32
d4d9a1ec 2555 "0c2j9xh4qpi0x1vvcxdjxq6say0zhyr569fryi5cmhp8bclh4kca"))))
18e366e8
RW
2556 (build-system texlive-build-system)
2557 (arguments
2558 `(#:tex-directory "latex/amscls"))
b8d8806b 2559 (home-page "https://www.ctan.org/pkg/amscls")
18e366e8
RW
2560 (synopsis "AMS document classes for LaTeX")
2561 (description
2562 "This bundle contains three AMS classes: @code{amsartamsart} (for writing
2563articles for the AMS), @code{amsbookamsbook} (for books) and
2564@code{amsprocamsproc} (for proceedings), together with some supporting
2565material. The material is made available as part of the AMS-LaTeX
2566distribution.")
2567 (license license:lppl1.3c+)))
2568
f84d5a09
RW
2569(define-public texlive-latex-babel
2570 (package
2571 (name "texlive-latex-babel")
2572 (version (number->string %texlive-revision))
2573 (source (origin
2574 (method svn-fetch)
2575 (uri (texlive-ref "latex" "babel"))
8732493e 2576 (file-name (string-append name "-" version "-checkout"))
f84d5a09
RW
2577 (sha256
2578 (base32
d4d9a1ec 2579 "0yhlfiz3fjc8jd46f1zrjj4jig48l8rrzh8cmd8ammml8z9a01z6"))))
f84d5a09
RW
2580 (build-system texlive-build-system)
2581 (arguments
dcc8af4a 2582 '(#:tex-directory "generic/babel"
f84d5a09
RW
2583 #:phases
2584 (modify-phases %standard-phases
2585 ;; This package tries to produce babel.aux twice but refuses to
2586 ;; overwrite the first one.
2587 (add-before 'build 'fix-ins
2588 (lambda _
2589 (substitute* "babel.ins"
2590 (("askonceonly") "askforoverwritefalse"))
2591 #t)))))
b8d8806b 2592 (home-page "https://www.ctan.org/pkg/babel")
f84d5a09
RW
2593 (synopsis "Multilingual support for Plain TeX or LaTeX")
2594 (description
2595 "The package manages culturally-determined typographical (and other)
2596rules, and hyphenation patterns for a wide range of languages. A document may
2597select a single language to be supported, or it may select several, in which
2598case the document may switch from one language to another in a variety of
2599ways. Babel uses contributed configuration files that provide the detail of
2600what has to be done for each language. Users of XeTeX are advised to use the
2601polyglossia package rather than Babel.")
2602 (license license:lppl1.3+)))
2603
876a1980
RW
2604(define-public texlive-generic-babel-english
2605 (package
2606 (name "texlive-generic-babel-english")
2607 (version (number->string %texlive-revision))
2608 (source (origin
2609 (method svn-fetch)
2610 (uri (texlive-ref "generic" "babel-english"))
2611 (file-name (string-append name "-" version "-checkout"))
2612 (sha256
2613 (base32
2614 "1s404wbx91z5w65hm024kyl4h56zsa096irx18vsx8jvlmwsr5wc"))))
2615 (build-system texlive-build-system)
2616 (arguments '(#:tex-directory "generic/babel-english"))
b8d8806b 2617 (home-page "https://www.ctan.org/pkg/babel-english")
876a1980
RW
2618 (synopsis "Babel support for English")
2619 (description
2620 "This package provides the language definition file for support of
2621English in @code{babel}. Care is taken to select British hyphenation patterns
2622for British English and Australian text, and default (\"american\") patterns
2623for Canadian and USA text.")
2624 (license license:lppl1.3+)))
2625
6309d215
RW
2626(define-public texlive-generic-babel-german
2627 (package
2628 (name "texlive-generic-babel-german")
2629 (version (number->string %texlive-revision))
2630 (source (origin
2631 (method svn-fetch)
2632 (uri (texlive-ref "generic" "babel-german"))
2633 (file-name (string-append name "-" version "-checkout"))
2634 (sha256
2635 (base32
2636 "0h47s67gnhdaxfgbf8pirp5vw4z6rrhxl8zav803yjxka0096i3y"))))
2637 (build-system texlive-build-system)
2638 (arguments '(#:tex-directory "generic/babel-german"))
2639 (home-page "https://www.ctan.org/pkg/babel-german")
2640 (synopsis "Babel support for German")
2641 (description
2642 "This package provides the language definition file for support of German
2643in @code{babel}. It provides all the necessary macros, definitions and
2644settings to typeset German documents. The bundle includes support for the
2645traditional and reformed German orthography as well as for the Austrian and
2646Swiss varieties of German.")
2647 (license license:lppl1.3+)))
2648
93286d38
RW
2649(define-public texlive-latex-cyrillic
2650 (package
2651 (name "texlive-latex-cyrillic")
2652 (version (number->string %texlive-revision))
2653 (source (origin
2654 (method svn-fetch)
2655 (uri (texlive-ref "latex" "cyrillic"))
51bffe79 2656 (file-name (string-append name "-" version "-checkout"))
93286d38
RW
2657 (sha256
2658 (base32
d4d9a1ec 2659 "083xbwg7hrnlv47fkwvz8yjb830bhxx7y0mq7z7nz2f96y2ldr6b"))))
93286d38
RW
2660 (build-system texlive-build-system)
2661 (arguments
2662 '(#:tex-directory "latex/cyrillic"))
b8d8806b 2663 (home-page "https://www.ctan.org/pkg/latex-cyrillic")
93286d38
RW
2664 (synopsis "Support for Cyrillic fonts in LaTeX")
2665 (description
2666 "This bundle of macros files provides macro support (including font
2667encoding macros) for the use of Cyrillic characters in fonts encoded under the
2668T2* and X2 encodings. These encodings cover (between them) pretty much every
2669language that is written in a Cyrillic alphabet.")
2670 (license license:lppl1.3c+)))
2671
83fe6231
RW
2672(define-public texlive-latex-psnfss
2673 (package
2674 (name "texlive-latex-psnfss")
2675 (version (number->string %texlive-revision))
2676 (source (origin
2677 (method svn-fetch)
2678 (uri (texlive-ref "latex" "psnfss"))
b5b10f3b 2679 (file-name (string-append name "-" version "-checkout"))
83fe6231
RW
2680 (sha256
2681 (base32
2682 "1920dcq8613yzprasbg80fh4fcjcidvvl54wkx438nimyxcri7qz"))))
2683 (build-system texlive-build-system)
2684 (arguments '(#:tex-directory "latex/psnfss"))
b8d8806b 2685 (home-page "https://www.ctan.org/pkg/psnfss")
83fe6231
RW
2686 (synopsis "Font support for common PostScript fonts")
2687 (description
2688 "The PSNFSS collection includes a set of files that provide a complete
2689working setup of the LaTeX font selection scheme (NFSS2) for use with common
2690PostScript fonts. It covers the so-called \"Base\" fonts (which are built
2691into any Level 2 PostScript printing device and the Ghostscript interpreter)
2692and a number of free fonts. It provides font definition files, macros and
2693font metrics. The bundle as a whole is part of the LaTeX required set of
2694packages.")
2695 (license license:lppl1.2+)))
2696
bfcb9d4d
RW
2697;; For user profiles
2698(define-public texlive-base
2699 (let ((default-packages
2700 (list texlive-bin
2701 texlive-dvips
2702 texlive-fontname
2703 texlive-fonts-cm
2704 texlive-fonts-latex
2705 texlive-metafont-base
2706 texlive-latex-base
2707 ;; LaTeX packages from the "required" set.
2708 texlive-latex-amsmath
2709 texlive-latex-amscls
2710 texlive-latex-babel
2711 texlive-generic-babel-english
2712 texlive-latex-cyrillic
2713 texlive-latex-graphics
2714 texlive-latex-psnfss
2715 texlive-latex-tools)))
2716 (package
2717 (name "texlive-base")
2718 (version (number->string %texlive-revision))
2719 (source #f)
2720 (build-system trivial-build-system)
2721 (arguments
2722 '(#:builder
2723 (begin (mkdir (assoc-ref %outputs "out")))))
2724 (propagated-inputs
2725 (map (lambda (package)
2726 (list (package-name package) package))
2727 default-packages))
2728 (home-page (package-home-page texlive-bin))
2729 (synopsis "TeX Live base packages")
2730 (description "This is a very limited subset of the TeX Live distribution.
2731It includes little more than the required set of LaTeX packages.")
2732 (license (fold (lambda (package result)
2733 (match (package-license package)
2734 ((lst ...)
2735 (append lst result))
2736 ((? license:license? license)
2737 (cons license result))))
2738 '()
2739 default-packages)))))
2740
d7da2372 2741;; For use in package definitions only
cb7bc20a
RW
2742(define-public texlive-union
2743 (lambda* (#:optional (packages '()))
2744 "Return 'texlive-union' package which is a union of PACKAGES and the
2745standard LaTeX packages."
d7da2372
RW
2746 (let ((default-packages (match (package-propagated-inputs texlive-base)
2747 (((labels packages) ...) packages))))
2748 (package (inherit texlive-base)
cb7bc20a 2749 (name "texlive-union")
cb7bc20a
RW
2750 (build-system trivial-build-system)
2751 (arguments
2752 '(#:modules ((guix build union)
2753 (guix build utils)
2754 (guix build texlive-build-system)
2755 (guix build gnu-build-system)
2756 (guix build gremlin)
2757 (guix elf))
2758 #:builder
2759 (begin
2760 (use-modules (ice-9 match)
1a64a7b3 2761 (ice-9 popen)
cb7bc20a
RW
2762 (srfi srfi-26)
2763 (guix build union)
2764 (guix build utils)
2765 (guix build texlive-build-system))
2766 (let* ((out (assoc-ref %outputs "out"))
2767 (texmf.cnf (string-append out "/share/texmf-dist/web2c/texmf.cnf")))
1a64a7b3
RW
2768 ;; Build a modifiable union of all inputs (but exclude bash and
2769 ;; the updmap.cfg file)
cb7bc20a
RW
2770 (match (filter (match-lambda
2771 ((name . _)
1a64a7b3 2772 (not (member name '("bash" "updmap.cfg")))))
cb7bc20a
RW
2773 %build-inputs)
2774 (((names . directories) ...)
2775 (union-build (assoc-ref %outputs "out")
2776 directories
c58d1b5f
RW
2777 #:create-all-directories? #t
2778 #:log-port (%make-void-port "w"))))
cb7bc20a
RW
2779
2780 ;; The configuration file "texmf.cnf" is provided by the
2781 ;; "texlive-bin" package. We take it and override only the
2782 ;; setting for TEXMFROOT and TEXMF. This file won't be consulted
2783 ;; by default, though, so we still need to set TEXMFCNF.
2784 (substitute* texmf.cnf
2785 (("^TEXMFROOT = .*")
2786 (string-append "TEXMFROOT = " out "/share\n"))
2787 (("^TEXMF = .*")
2788 "TEXMF = $TEXMFROOT/share/texmf-dist\n"))
1a64a7b3
RW
2789 (setenv "PATH" (string-append
2790 (assoc-ref %build-inputs "bash") "/bin:"
2791 (assoc-ref %build-inputs "coreutils") "/bin:"
2792 (string-append out "/bin")))
cb7bc20a
RW
2793 (for-each
2794 (cut wrap-program <>
476f7fce
RW
2795 `("TEXMFCNF" ":" suffix (,(dirname texmf.cnf)))
2796 `("TEXMF" ":" suffix (,(string-append out "/share/texmf-dist"))))
cb7bc20a 2797 (find-files (string-append out "/bin") ".*"))
1a64a7b3
RW
2798
2799 ;; Remove invalid maps from config file.
2800 (let ((port (open-pipe* OPEN_WRITE "updmap-sys"
2801 "--syncwithtrees"
2802 "--nohash"
2803 (assoc-ref %build-inputs "updmap.cfg"))))
2804 (display "Y\n" port)
2805 (when (not (zero? (status:exit-val (close-pipe port))))
2806 (error "failed to filter updmap.cfg")))
2807 ;; Generate maps.
2808 (invoke "updmap-sys" "--force"
2809 (string-append out "/share/texmf-config/web2c/updmap.cfg"))
cb7bc20a
RW
2810 #t))))
2811 (inputs
2812 `(("bash" ,bash)
2813 ,@(map (lambda (package)
2814 (list (package-name package) package))
2815 (append default-packages packages))))
1a64a7b3
RW
2816 (native-inputs
2817 `(("coreutils" ,coreutils)
2818 ("sed" ,sed)
2819 ("updmap.cfg"
2820 ,(origin
2821 (method url-fetch)
2822 (uri (string-append "https://tug.org/svn/texlive/tags/"
2823 %texlive-tag "/Master/texmf-dist/web2c/updmap.cfg"
2824 "?revision=" (number->string %texlive-revision)))
2825 (file-name (string-append "updmap.cfg-"
2826 (number->string %texlive-revision)))
2827 (sha256
2828 (base32
2829 "06mwpy5i218g5k3sf4gba0fmxgas82hkzx9fhwn67z5ik37d8apq"))))))
cb7bc20a
RW
2830 (home-page (package-home-page texlive-bin))
2831 (synopsis "Union of TeX Live packages")
2832 (description "This package provides a subset of the TeX Live
2833distribution.")
2834 (license (fold (lambda (package result)
2835 (match (package-license package)
2836 ((lst ...)
2837 (append lst result))
2838 ((? license:license? license)
2839 (cons license result))))
2840 '()
2841 (append default-packages packages)))))))
2842
d7da2372 2843;; For use in package definitions only
9d4f8dc2
RW
2844(define-public texlive-tiny
2845 (package
2846 (inherit (texlive-union))
2847 (name "texlive-tiny")
2848 (description "This is a very limited subset of the TeX Live distribution.
2849It includes little more than the required set of LaTeX packages.")))
2850
60b5e228
RW
2851(define-public texlive-latex-amsrefs
2852 (package
2853 (name "texlive-latex-amsrefs")
2854 (version (number->string %texlive-revision))
2855 (source (origin
2856 (method svn-fetch)
2857 (uri (texlive-ref "latex" "amsrefs"))
2858 (file-name (string-append name "-" version "-checkout"))
2859 (sha256
2860 (base32
2861 "15i4k479dwrpr0kspmm70g1yn4p3dkh0whyzmr93hph9bggnh1i1"))))
2862 (build-system texlive-build-system)
2863 (arguments '(#:tex-directory "latex/amsrefs"))
b8d8806b 2864 (home-page "https://www.ctan.org/pkg/amsrefs")
60b5e228
RW
2865 (synopsis "LaTeX-based replacement for BibTeX")
2866 (description
2867 "Amsrefs is a LaTeX package for bibliographies that provides an archival
2868data format similar to the format of BibTeX database files, but adapted to
2869make direct processing by LaTeX easier. The package can be used either in
2870conjunction with BibTeX or as a replacement for BibTeX.")
2871 (license license:lppl1.3+)))
2872
3236599f
RW
2873(define-public texlive-latex-bigfoot
2874 (package
2875 (name "texlive-latex-bigfoot")
2876 (version (number->string %texlive-revision))
2877 (source (origin
2878 (method svn-fetch)
2879 (uri (texlive-ref "latex" "bigfoot"))
2880 (file-name (string-append name "-" version "-checkout"))
2881 (sha256
2882 (base32
2883 "092g8alnsdwlgl1isdnqrr32l161994295kadr1n05d81xgj5wnv"))))
2884 (build-system texlive-build-system)
2885 (arguments
2886 '(#:tex-directory "latex/bigfoot"
2887 #:phases
2888 (modify-phases %standard-phases
2889 (add-after 'unpack 'remove-generated-file
2890 (lambda _
2891 (for-each delete-file (find-files "." "\\.drv$"))
2892 #t)))))
b8d8806b 2893 (home-page "https://www.ctan.org/pkg/bigfoot")
3236599f
RW
2894 (synopsis "Footnotes for critical editions")
2895 (description
2896 "This package aims to provide a one-stop solution to requirements for
2897footnotes. It offers: Multiple footnote apparatus superior to that of
2898@code{manyfoot}. Footnotes can be formatted in separate paragraphs, or be run
2899into a single paragraph (this choice may be selected per footnote series);
2900Things you might have expected (such as @code{\\verb}-like material in
2901footnotes, and color selections over page breaks) now work. Note that the
2902majority of the bigfoot package's interface is identical to that of
2903@code{manyfoot}; users should seek information from that package's
2904documentation. The bigfoot bundle also provides the @code{perpage} and
2905@code{suffix} packages.")
2906 (license license:gpl2+)))
2907
8e732b49
RW
2908(define-public texlive-latex-blindtext
2909 (package
2910 (name "texlive-latex-blindtext")
2911 (version (number->string %texlive-revision))
2912 (source (origin
2913 (method svn-fetch)
2914 (uri (texlive-ref "latex" "blindtext"))
2915 (file-name (string-append name "-" version "-checkout"))
2916 (sha256
2917 (base32
2918 "1jrja9b1pzdh9zgv1jh807w4xijqja58n2mqny6dkwicv8qfgbfg"))))
2919 (build-system texlive-build-system)
2920 (arguments '(#:tex-directory "latex/blindtext"))
b8d8806b 2921 (home-page "https://www.ctan.org/pkg/blindtext")
8e732b49
RW
2922 (synopsis "Producing 'blind' text for testing")
2923 (description
2924 "The package provides the commands @code{\\blindtext} and
2925@code{\\Blindtext} for creating \"blind\" text useful in testing new classes
2926and packages, and @code{\\blinddocument}, @code{\\Blinddocument} for creating
2927an entire random document with sections, lists, mathematics, etc. The package
2928supports three languages, @code{english}, @code{(n)german} and @code{latin};
2929the @code{latin} option provides a short \"lorem ipsum\" (for a fuller \"lorem
2930ipsum\" text, see the @code{lipsum} package).")
2931 (license license:lppl)))
2932
7cda03bd
RW
2933(define-public texlive-latex-dinbrief
2934 (package
2935 (name "texlive-latex-dinbrief")
2936 (version (number->string %texlive-revision))
2937 (source (origin
2938 (method svn-fetch)
2939 (uri (texlive-ref "latex" "dinbrief"))
2940 (file-name (string-append name "-" version "-checkout"))
2941 (sha256
2942 (base32
2943 "0lb0kiy8fxzl6cnhcw1sggy6jrjvcd6kj1kkw3k9lkimm388yjz6"))))
2944 (build-system texlive-build-system)
2945 (arguments
2946 '(#:tex-directory "latex/dinbrief"
2947 #:phases
2948 (modify-phases %standard-phases
2949 (add-after 'unpack 'remove-generated-file
2950 (lambda _
2951 (delete-file "dinbrief.drv")
d4d9a1ec
RW
2952 #t))
2953 (add-after 'unpack 'fix-encoding-error
2954 (lambda _
2955 (with-fluids ((%default-port-encoding "ISO-8859-1"))
2956 (substitute* "dinbrief.dtx"
2957 (("zur Verf.+ung. In der Pr\"aambel")
2958 "zur Verf\"ung. In der Pr\"aambel")))
7cda03bd 2959 #t)))))
b8d8806b 2960 (home-page "https://www.ctan.org/pkg/dinbrief")
7cda03bd
RW
2961 (synopsis "German letter DIN style")
2962 (description
2963 "This package implements a document layout for writing letters according
2964to the rules of DIN (Deutsches Institut für Normung, German standardisation
2965institute). A style file for LaTeX 2.09 (with limited support of the
2966features) is part of the package. Since the letter layout is based on a
2967German standard, the user guide is written in German, but most macros have
2968English names from which the user can recognize what they are used for. In
2969addition there are example files showing how letters may be created with the
2970package.")
2971 (license license:lppl)))
2972
de224adb
RW
2973(define-public texlive-latex-draftwatermark
2974 (package
2975 (name "texlive-latex-draftwatermark")
2976 (version (number->string %texlive-revision))
2977 (source (origin
2978 (method svn-fetch)
2979 (uri (texlive-ref "latex" "draftwatermark"))
2980 (file-name (string-append name "-" version "-checkout"))
2981 (sha256
2982 (base32
2983 "1zyl2pcz2x529gzj5m93a1s4ipymdabf7qdjl3l1673pizd4hfyv"))))
2984 (build-system texlive-build-system)
2985 (arguments '(#:tex-directory "latex/draftwatermark"))
b8d8806b 2986 (home-page "https://www.ctan.org/pkg/draftwatermark")
de224adb
RW
2987 (synopsis "Put a grey textual watermark on document pages")
2988 (description
2989 "This package provides a means to add a textual, light grey watermark on
2990every page or on the first page of a document. Typical usage may consist in
2991writing words such as DRAFT or CONFIDENTIAL across document pages. The
2992package performs a similar function to that of @code{draftcopy}, but its
2993implementation is output device independent, and made very simple by relying
2994on everypage.")
2995 (license license:lppl1.3+)))
2996
74e9c9a4
RW
2997(define-public texlive-latex-environ
2998 (package
2999 (name "texlive-latex-environ")
3000 (version (number->string %texlive-revision))
3001 (source (origin
3002 (method svn-fetch)
3003 (uri (texlive-ref "latex" "environ"))
3004 (file-name (string-append name "-" version "-checkout"))
3005 (sha256
3006 (base32
3007 "06h28b26dyjkj9shksphgqfv4130jfkwhbw737hxn7d3yvdfffyd"))))
3008 (build-system texlive-build-system)
3009 (arguments '(#:tex-directory "latex/environ"))
b8d8806b 3010 (home-page "https://www.ctan.org/pkg/environ")
74e9c9a4
RW
3011 (synopsis "New interface for environments in LaTeX")
3012 (description
09acbb02
RW
3013 "This package provides the @code{\\collect@@body} command (as in
3014@code{amsmath}), as well as a @code{\\long} version @code{\\Collect@@Body},
3015for collecting the body text of an environment. These commands are used to
3016define a new author interface to creating new environments.")
74e9c9a4
RW
3017 (license license:lppl)))
3018
adfa7a2a
RW
3019(define-public texlive-latex-eqparbox
3020 (package
3021 (name "texlive-latex-eqparbox")
3022 (version (number->string %texlive-revision))
3023 (source (origin
3024 (method svn-fetch)
3025 (uri (texlive-ref "latex" "eqparbox"))
3026 (file-name (string-append name "-" version "-checkout"))
3027 (sha256
3028 (base32
d4d9a1ec 3029 "1ib5xdwcj5wk23wgk41m2hdcjr1dzrs4l3wwnpink9mlapz12wjs"))))
adfa7a2a
RW
3030 (build-system texlive-build-system)
3031 (arguments '(#:tex-directory "latex/eqparbox"))
b8d8806b 3032 (home-page "https://www.ctan.org/pkg/eqparbox")
adfa7a2a
RW
3033 (synopsis "Create equal-widthed parboxes")
3034 (description
3035 "LaTeX users sometimes need to ensure that two or more blocks of text
3036occupy the same amount of horizontal space on the page. To that end, the
3037@code{eqparbox} package defines a new command, @code{\\eqparbox}, which works
3038just like @code{\\parbox}, except that instead of specifying a width, one
3039specifies a tag. All @code{eqparbox}es with the same tag---regardless of
3040where they are in the document---will stretch to fit the widest
3041@code{eqparbox} with that tag. This simple, equal-width mechanism can be used
3042for a variety of alignment purposes, as is evidenced by the examples in
3043@code{eqparbox}'s documentation. Various derivatives of @code{\\eqparbox} are
3044also provided.")
3045 (license license:lppl1.3+)))
3046
32e623d0
RW
3047(define-public texlive-latex-expdlist
3048 (package
3049 (name "texlive-latex-expdlist")
3050 (version (number->string %texlive-revision))
3051 (source (origin
3052 (method svn-fetch)
3053 (uri (texlive-ref "latex" "expdlist"))
3054 (file-name (string-append name "-" version "-checkout"))
3055 (sha256
3056 (base32
3057 "1x7byk6x10njir3y9rm56glhdzrxwqag7gsnw2sqn1czlq525w7r"))))
3058 (build-system texlive-build-system)
3059 (arguments
3060 '(#:tex-directory "latex/expdlist"
3061 #:phases
3062 (modify-phases %standard-phases
3063 (add-after 'unpack 'remove-generated-file
3064 (lambda _
3065 (for-each delete-file
3066 (find-files "." "\\.drv$"))
3067 #t)))))
b8d8806b 3068 (home-page "https://www.ctan.org/pkg/expdlist")
32e623d0
RW
3069 (synopsis "Expanded description environments")
3070 (description
3071 "The package provides additional features for the LaTeX
3072@code{description} environment, including adjustable left margin. The package
3073also allows the user to \"break\" a list (for example, to interpose a comment)
3074without affecting the structure of the list (this works for @code{itemize} and
3075@code{enumerate} lists, and numbered lists remain in sequence).")
3076 (license license:lppl)))
3077
893e3fc1
RW
3078(define-public texlive-latex-filemod
3079 (package
3080 (name "texlive-latex-filemod")
3081 (version (number->string %texlive-revision))
3082 (source (origin
3083 (method svn-fetch)
3084 (uri (svn-reference
3085 (url (string-append "svn://www.tug.org/texlive/tags/"
3086 %texlive-tag "/Master/texmf-dist/"
3087 "/tex/latex/filemod"))
3088 (revision %texlive-revision)))
681b579d 3089 (file-name (string-append name "-" version "-checkout"))
893e3fc1
RW
3090 (sha256
3091 (base32
3092 "0vpxilfw69xv78f03g0j0zw0bw4qcn36whqp8phcq48qk1ax2kr2"))))
3093 (build-system trivial-build-system)
3094 (arguments
3095 `(#:modules ((guix build utils))
3096 #:builder
3097 (begin
3098 (use-modules (guix build utils))
3099 (let ((target (string-append (assoc-ref %outputs "out")
3100 "/share/texmf-dist/tex/latex/filemod")))
3101 (mkdir-p target)
3102 (copy-recursively (assoc-ref %build-inputs "source") target)
3103 #t))))
b8d8806b 3104 (home-page "https://www.ctan.org/pkg/filemod")
893e3fc1
RW
3105 (synopsis "Provide file modification times, and compare them")
3106 (description
3107 "This package provides macros to read and compare the modification dates
3108of files. The files may be @code{.tex} files, images or other files (as long
3109as they can be found by LaTeX). It uses the @code{\\pdffilemoddate} primitive
3110of pdfLaTeX to find the file modification date as PDF date string, parses the
3111string and returns the value to the user. The package will also work for DVI
3112output with recent versions of the LaTeX compiler which uses pdfLaTeX in DVI
3113mode. The functionality is provided by purely expandable macros or by faster
3114but non-expandable ones.")
3115 (license license:lppl1.3+)))
3116
8c23f238
RW
3117(define-public texlive-latex-ifplatform
3118 (package
3119 (name "texlive-latex-ifplatform")
3120 (version (number->string %texlive-revision))
3121 (source (origin
3122 (method svn-fetch)
3123 (uri (texlive-ref "latex" "ifplatform"))
3124 (file-name (string-append name "-" version "-checkout"))
3125 (sha256
3126 (base32
d4d9a1ec 3127 "157pplavvm2z97b3jl4x41w11k6q9wgy074mfg0dwmsx5lm328jy"))))
8c23f238
RW
3128 (build-system texlive-build-system)
3129 (arguments '(#:tex-directory "latex/ifplatform"))
b8d8806b 3130 (home-page "https://www.ctan.org/pkg/ifplatform")
8c23f238
RW
3131 (synopsis "Conditionals to test which platform is being used")
3132 (description
3133 "This package uses the (La)TeX extension @code{-shell-escape} to
3134establish whether the document is being processed on a Windows or on a
3135Unix-like system, or on Cygwin (Unix environment over a Windows system).
3136Booleans provided are: @code{\\ifwindows}, @code{\\iflinux}, @code{\\ifmacosx}
3137and @code{\\ifcygwin}. The package also preserves the output of @code{uname}
3138on a Unix-like system, which may be used to distinguish between various
3139classes of systems.")
3140 (license license:lppl)))
3141
9b416042
RW
3142(define-public texlive-latex-natbib
3143 (package
3144 (name "texlive-latex-natbib")
3145 (version (number->string %texlive-revision))
3146 (source (origin
3147 (method svn-fetch)
3148 (uri (texlive-ref "latex" "natbib"))
23ae6e65 3149 (file-name (string-append name "-" version "-checkout"))
9b416042
RW
3150 (sha256
3151 (base32
3152 "0aqliq0nwblxyrzhwhv77pnmk7qh2y3prgq7z7qhwcbgz5kisld7"))))
3153 (build-system texlive-build-system)
3154 (arguments '(#:tex-directory "latex/natbib"))
b8d8806b 3155 (home-page "https://www.ctan.org/pkg/natbib")
9b416042
RW
3156 (synopsis "Flexible bibliography support")
3157 (description
3158 "This bundle provides a package that implements both author-year and
3159numbered references, as well as much detailed of support for other
3160bibliography use. Also provided are versions of the standard BibTeX styles
3161that are compatible with @code{natbib}: @code{plainnat}, @code{unsrtnat},
3162@code{abbrnat}. The bibliography styles produced by @code{custom-bib} are
3163designed from the start to be compatible with @code{natbib}.")
3164 (license license:lppl)))
3165
d770d07f
RW
3166(define-public texlive-latex-psfrag
3167 (package
3168 (name "texlive-latex-psfrag")
3169 (version (number->string %texlive-revision))
3170 (source (origin
3171 (method svn-fetch)
3172 (uri (texlive-ref "latex" "psfrag"))
3173 (file-name (string-append name "-" version "-checkout"))
3174 (sha256
3175 (base32
3176 "1dxbl5il7wbbsp0v45vk884xi1192wxw03849pb1g5q4x808n352"))))
3177 (build-system texlive-build-system)
3178 (arguments '(#:tex-directory "latex/psfrag"))
b8d8806b 3179 (home-page "https://www.ctan.org/pkg/psfrag")
d770d07f
RW
3180 (synopsis "Replace strings in encapsulated PostScript figures")
3181 (description
3182 "This package allows LaTeX constructions (equations, picture
3183environments, etc.) to be precisely superimposed over Encapsulated PostScript
3184figures, using your own favorite drawing tool to create an EPS figure and
3185placing simple text \"tags\" where each replacement is to be placed, with
3186PSfrag automatically removing these tags from the figure and replacing them
3187with a user specified LaTeX construction, properly aligned, scaled, and/or
3188rotated.")
3189 (license (license:fsf-free "file://psfrag.dtx"))))
3190
d4d9a1ec
RW
3191(define-public texlive-latex-xkeyval
3192 (package
3193 (name "texlive-latex-xkeyval")
3194 (version (number->string %texlive-revision))
3195 (source (origin
3196 (method svn-fetch)
3197 (uri (texlive-ref "latex" "xkeyval"))
3198 (file-name (string-append name "-" version "-checkout"))
3199 (sha256
3200 (base32
3201 "0wancavix39j240pd8m9cgmwsijwx6jd6n54v8wg0x2rk5m44myp"))))
3202 (build-system texlive-build-system)
3203 (arguments '(#:tex-directory "latex/xkeyval"))
3204 (home-page "https://www.ctan.org/pkg/xkeyval")
3205 (synopsis "Macros for defining and setting keys")
3206 (description
3207 "This package is an extension of the @code{keyval} package and offers
3208more flexible macros for defining and setting keys. The package provides a
3209pointer and a preset system. Furthermore, it supplies macros to allow class
3210and package options to contain options of the @code{key=value} form. A LaTeX
3211kernel patch is provided to avoid premature expansions of macros in class or
3212package options. A specialized system for setting @code{PSTricks} keys is
3213provided by the @code{pst-xkey} package.")
3214 (license license:lppl1.3+)))
3215
5a1ee7d8
RW
3216(define-public texlive-latex-pstool
3217 (package
3218 (name "texlive-latex-pstool")
3219 (version (number->string %texlive-revision))
3220 (source (origin
3221 (method svn-fetch)
d4d9a1ec
RW
3222 (uri (svn-reference
3223 (url (string-append "svn://www.tug.org/texlive/tags/"
3224 %texlive-tag "/Master/texmf-dist/"
3225 "/tex/latex/pstool"))
3226 (revision %texlive-revision)))
5a1ee7d8
RW
3227 (file-name (string-append name "-" version "-checkout"))
3228 (sha256
3229 (base32
d4d9a1ec
RW
3230 "1h816jain8c9nky75kk8pmmwj5b4yf9dpqvdvi2l6jhfj5iqkzr8"))))
3231 (build-system trivial-build-system)
5a1ee7d8 3232 (arguments
d4d9a1ec
RW
3233 `(#:modules ((guix build utils))
3234 #:builder
3235 (begin
3236 (use-modules (guix build utils))
3237 (let ((target (string-append (assoc-ref %outputs "out")
3238 "/share/texmf-dist/tex/latex/pstool")))
3239 (mkdir-p target)
3240 (copy-recursively (assoc-ref %build-inputs "source") target)
3241 #t))))
5a1ee7d8 3242 (propagated-inputs
d4d9a1ec 3243 `(("texlive-latex-bigfoot" ,texlive-latex-bigfoot) ; for suffix
5a1ee7d8
RW
3244 ("texlive-latex-filemod" ,texlive-latex-filemod)
3245 ("texlive-latex-graphics" ,texlive-latex-graphics)
3246 ("texlive-latex-ifplatform" ,texlive-latex-ifplatform)
d4d9a1ec 3247 ("texlive-latex-l3kernel" ,texlive-latex-l3kernel) ; for expl3
5a1ee7d8
RW
3248 ("texlive-latex-oberdiek" ,texlive-latex-oberdiek)
3249 ("texlive-latex-psfrag" ,texlive-latex-psfrag)
d4d9a1ec
RW
3250 ("texlive-latex-tools" ,texlive-latex-tools) ; for shellesc
3251 ("texlive-latex-trimspaces" ,texlive-latex-trimspaces)
3252 ("texlive-latex-xkeyval" ,texlive-latex-xkeyval)))
b8d8806b 3253 (home-page "https://www.ctan.org/pkg/pstool")
d4d9a1ec 3254 (synopsis "Process PostScript graphics within pdfLaTeX documents")
5a1ee7d8
RW
3255 (description
3256 "This is a package for processing PostScript graphics with @code{psfrag}
3257labels within pdfLaTeX documents. Every graphic is compiled individually,
3258drastically speeding up compilation time when only a single figure needs
3259re-processing.")
3260 (license license:lppl)))
3261
171160d5
RW
3262(define-public texlive-latex-seminar
3263 (package
3264 (name "texlive-latex-seminar")
3265 (version (number->string %texlive-revision))
3266 (source (origin
3267 (method svn-fetch)
3268 (uri (svn-reference
3269 (url (string-append "svn://www.tug.org/texlive/tags/"
3270 %texlive-tag "/Master/texmf-dist/"
3271 "/tex/latex/seminar"))
3272 (revision %texlive-revision)))
a74ac06b 3273 (file-name (string-append name "-" version "-checkout"))
171160d5
RW
3274 (sha256
3275 (base32
3276 "0y4i651b75y6006n03x8n86bsqvjsailvvz9bhzy51dzsznqidq0"))))
1d4c2dab
RW
3277 (build-system trivial-build-system)
3278 (arguments
3279 `(#:modules ((guix build utils))
3280 #:builder
3281 (begin
3282 (use-modules (guix build utils))
3283 (let ((target (string-append (assoc-ref %outputs "out")
3284 "/share/texmf-dist/tex/latex/seminar")))
3285 (mkdir-p target)
3286 (copy-recursively (assoc-ref %build-inputs "source") target)
3287 #t))))
b8d8806b 3288 (home-page "https://www.ctan.org/pkg/seminar")
171160d5
RW
3289 (synopsis "Make overhead slides")
3290 ;; TODO: This package may need fancybox and xcomment at runtime.
3291 (description
3292 "This package provides a class that produces overhead
3293slides (transparencies), with many facilities. Seminar is not nowadays
3294reckoned a good basis for a presentation — users are advised to use more
3295recent classes such as powerdot or beamer, both of which are tuned to
329621st-century presentation styles.")
3297 (license license:lppl1.2+)))
3298
f3540dbd
RW
3299(define-public texlive-latex-trimspaces
3300 (package
3301 (name "texlive-latex-trimspaces")
3302 (version (number->string %texlive-revision))
3303 (source (origin
3304 (method svn-fetch)
3305 (uri (texlive-ref "latex" "trimspaces"))
70a71d19 3306 (file-name (string-append name "-" version "-checkout"))
f3540dbd
RW
3307 (sha256
3308 (base32
3309 "0da00lb32am4g63mn96625wg48p3pj3spx79lajrk17d549apwqa"))))
3310 (build-system texlive-build-system)
3311 (arguments
3312 '(#:tex-directory "latex/trimspaces"
3313 #:tex-format "latex"
3314 #:phases
3315 (modify-phases %standard-phases
3316 (add-after 'unpack 'fix-bug
3317 (lambda _
3318 ;; The "ins" file refers to the wrong source file.
3319 (substitute* "trimspaces.ins"
3320 (("pstool.tex") "trimspaces.tex"))
3321 #t)))))
3322 (inputs
3323 `(("texlive-latex-filecontents" ,texlive-latex-filecontents)))
b8d8806b 3324 (home-page "https://www.ctan.org/pkg/trimspaces")
f3540dbd
RW
3325 (synopsis "Trim spaces around an argument or within a macro")
3326 (description
3327 "This very short package allows you to expandably remove spaces around a
3328token list (commands are provided to remove spaces before, spaces after, or
3329both); or to remove surrounding spaces within a macro definition, or to define
3330space-stripped macros.")
3331 (license license:lppl)))
3332
7709d4d8
RW
3333(define-public texlive-latex-capt-of
3334 (package
3335 (name "texlive-latex-capt-of")
3336 (version (number->string %texlive-revision))
3337 (source (origin
3338 (method svn-fetch)
3339 (uri (svn-reference
3340 (url (string-append "svn://www.tug.org/texlive/tags/"
3341 %texlive-tag "/Master/texmf-dist/"
3342 "/tex/latex/capt-of"))
3343 (revision %texlive-revision)))
3344 (file-name (string-append name "-" version "-checkout"))
3345 (sha256
3346 (base32
3347 "1y2s50f6lz0jx2748lj3iy56hrpcczgnbzmvphxv7aqndyyamd4x"))))
3348 (build-system trivial-build-system)
3349 (arguments
3350 `(#:modules ((guix build utils))
3351 #:builder
3352 (begin
3353 (use-modules (guix build utils))
3354 (let ((target (string-append (assoc-ref %outputs "out")
3355 "/share/texmf-dist/tex/latex/capt-of")))
3356 (mkdir-p target)
3357 (copy-recursively (assoc-ref %build-inputs "source") target)
3358 #t))))
b8d8806b 3359 (home-page "https://www.ctan.org/pkg/capt-of")
7709d4d8
RW
3360 (synopsis "Captions on more than floats")
3361 (description
3362 "This package defines a command @code{\\captionof} for putting a caption
3363to something that's not a float.")
3364 (license license:lppl)))
3365
49b2e86a
RW
3366(define-public texlive-latex-doi
3367 (package
3368 (name "texlive-latex-doi")
3369 (version (number->string %texlive-revision))
3370 (source (origin
3371 (method svn-fetch)
3372 (uri (svn-reference
3373 (url (string-append "svn://www.tug.org/texlive/tags/"
3374 %texlive-tag "/Master/texmf-dist/"
3375 "/tex/latex/doi"))
3376 (revision %texlive-revision)))
3377 (file-name (string-append name "-" version "-checkout"))
3378 (sha256
3379 (base32
3380 "0378rdmrgr2lzbfi4qqy4dfpj5im20diyd8z8b9m4mlg05r7wgnb"))))
3381 (build-system trivial-build-system)
3382 (arguments
3383 `(#:modules ((guix build utils))
3384 #:builder
3385 (begin
3386 (use-modules (guix build utils))
3387 (let ((target (string-append (assoc-ref %outputs "out")
3388 "/share/texmf-dist/tex/latex/doi")))
3389 (mkdir-p target)
3390 (copy-recursively (assoc-ref %build-inputs "source") target)
3391 #t))))
3392 (home-page "https://www.ctan.org/pkg/doi")
3393 (synopsis "Create correct hyperlinks for DOI numbers")
3394 (description
3395 "You can hyperlink DOI numbers to doi.org. However, some publishers have
3396elected to use nasty characters in their DOI numbering scheme (@code{<},
3397@code{>}, @code{_} and @code{;} have all been spotted). This will either
3398upset LaTeX, or your PDF reader. This package contains a single user-level
3399command @code{\\doi{}}, which takes a DOI number, and creates a correct
3400hyperlink to the target of the DOI.")
3401 ;; Any version of the LPPL.
3402 (license license:lppl1.3+)))
3403
a8ac7c0b
RW
3404(define-public texlive-latex-etoolbox
3405 (package
3406 (name "texlive-latex-etoolbox")
3407 (version (number->string %texlive-revision))
3408 (source (origin
3409 (method svn-fetch)
3410 (uri (svn-reference
3411 (url (string-append "svn://www.tug.org/texlive/tags/"
3412 %texlive-tag "/Master/texmf-dist/"
3413 "/tex/latex/etoolbox"))
3414 (revision %texlive-revision)))
3415 (file-name (string-append name "-" version "-checkout"))
3416 (sha256
3417 (base32
d4d9a1ec 3418 "1agmq6bf8wzcd77n20ng8bl4kh69cg5f6sjniii7bcw4llhd3nc8"))))
a8ac7c0b
RW
3419 (build-system trivial-build-system)
3420 (arguments
3421 `(#:modules ((guix build utils))
3422 #:builder
3423 (begin
3424 (use-modules (guix build utils))
3425 (let ((target (string-append (assoc-ref %outputs "out")
3426 "/share/texmf-dist/tex/latex/etoolbox")))
3427 (mkdir-p target)
3428 (copy-recursively (assoc-ref %build-inputs "source") target)
3429 #t))))
b8d8806b 3430 (home-page "https://www.ctan.org/pkg/etoolbox")
a8ac7c0b
RW
3431 (synopsis "e-TeX tools for LaTeX")
3432 (description
3433 "This package is a toolbox of programming facilities geared primarily
3434towards LaTeX class and package authors. It provides LaTeX frontends to some
3435of the new primitives provided by e-TeX as well as some generic tools which
3436are not strictly related to e-TeX but match the profile of this package. The
3437package provides functions that seem to offer alternative ways of implementing
3438some LaTeX kernel commands; nevertheless, the package will not modify any part
3439of the LaTeX kernel.")
3440 (license license:lppl1.3+)))
3441
17dce7e5
RW
3442(define-public texlive-latex-fncychap
3443 (package
3444 (name "texlive-latex-fncychap")
3445 (version (number->string %texlive-revision))
3446 (source (origin
3447 (method svn-fetch)
3448 (uri (svn-reference
3449 (url (string-append "svn://www.tug.org/texlive/tags/"
3450 %texlive-tag "/Master/texmf-dist/"
3451 "/tex/latex/fncychap"))
3452 (revision %texlive-revision)))
3453 (file-name (string-append name "-" version "-checkout"))
3454 (sha256
3455 (base32
3456 "0fdk84dbicfjfprkz6vk15x36mvlhaw9isjmgkc56jp2khwjswwq"))))
3457 (build-system trivial-build-system)
3458 (arguments
3459 `(#:modules ((guix build utils))
3460 #:builder
3461 (begin
3462 (use-modules (guix build utils))
3463 (let ((target (string-append (assoc-ref %outputs "out")
3464 "/share/texmf-dist/tex/latex/fncychap")))
3465 (mkdir-p target)
3466 (copy-recursively (assoc-ref %build-inputs "source") target)
3467 #t))))
b8d8806b 3468 (home-page "https://www.ctan.org/pkg/fncychap")
17dce7e5
RW
3469 (synopsis "Seven predefined chapter heading styles")
3470 (description
3471 "This package provides seven predefined chapter heading styles. Each
3472style can be modified using a set of simple commands. Optionally one can
3473modify the formatting routines in order to create additional chapter
3474headings.")
3475 (license license:lppl1.3+)))
3476
ef1e2ef0
RW
3477(define-public texlive-latex-framed
3478 (package
3479 (name "texlive-latex-framed")
3480 (version (number->string %texlive-revision))
3481 (source (origin
3482 (method svn-fetch)
3483 (uri (svn-reference
3484 (url (string-append "svn://www.tug.org/texlive/tags/"
3485 %texlive-tag "/Master/texmf-dist/"
3486 "/tex/latex/framed"))
3487 (revision %texlive-revision)))
3488 (file-name (string-append name "-" version "-checkout"))
3489 (sha256
3490 (base32
3491 "14a4ydqsvp3vcfavl21jrv0ybiqypaaqzg2q2cs3rzkandg7w98x"))))
3492 (build-system trivial-build-system)
3493 (arguments
3494 `(#:modules ((guix build utils))
3495 #:builder
3496 (begin
3497 (use-modules (guix build utils))
3498 (let ((target (string-append (assoc-ref %outputs "out")
3499 "/share/texmf-dist/tex/latex/framed")))
3500 (mkdir-p target)
3501 (copy-recursively (assoc-ref %build-inputs "source") target)
3502 #t))))
b8d8806b 3503 (home-page "https://www.ctan.org/pkg/framed")
ef1e2ef0
RW
3504 (synopsis "Framed or shaded regions that can break across pages")
3505 (description
3506 "The package creates three environments: @code{framed}, which puts an
3507ordinary frame box around the region, @code{shaded}, which shades the region,
3508and @code{leftbar}, which places a line at the left side. The environments
3509allow a break at their start (the @code{\\FrameCommand} enables creation of a
3510title that is “attached” to the environment); breaks are also allowed in the
3511course of the framed/shaded matter. There is also a command
3512@code{\\MakeFramed} to make your own framed-style environments.")
3513 ;; The header states: "These macros may be freely transmitted, reproduced,
3514 ;; or modified for any purpose provided that this notice is left intact."
3515 (license (license:fsf-free "file://framed.sty"))))
3516
588b5e96
RW
3517(define-public texlive-latex-g-brief
3518 (package
3519 (name "texlive-latex-g-brief")
3520 (version (number->string %texlive-revision))
3521 (source (origin
3522 (method svn-fetch)
3523 (uri (texlive-ref "latex" "g-brief"))
3524 (file-name (string-append name "-" version "-checkout"))
3525 (sha256
3526 (base32
3527 "0sikazkg0dpkcpzlbqw8qzxr81paf2f443vsrh14jnw7s4gswvc5"))))
3528 (build-system texlive-build-system)
3529 (arguments
3530 '(#:tex-directory "latex/g-brief"
3531 #:phases
3532 (modify-phases %standard-phases
3533 (add-after 'unpack 'remove-generated-file
3534 (lambda _
3535 (delete-file "g-brief.drv")
3536 #t)))))
b8d8806b 3537 (home-page "https://www.ctan.org/pkg/g-brief")
588b5e96
RW
3538 (synopsis "Letter document class")
3539 (description
3540 "This package is designed for formatting formless letters in German; it
3541can also be used for English (by those who can read the documentation). There
3542are LaTeX 2.09 @code{documentstyle} and LaTeX 2e class files for both an
3543\"old\" and a \"new\" version of g-brief.")
3544 (license license:lppl)))
3545
9b4d5c09
RW
3546(define-public texlive-latex-galois
3547 (package
3548 (name "texlive-latex-galois")
3549 (version (number->string %texlive-revision))
3550 (source (origin
3551 (method svn-fetch)
3552 (uri (texlive-ref "latex" "galois"))
3553 (file-name (string-append name "-" version "-checkout"))
3554 (sha256
3555 (base32
3556 "0d4l0msk8j5pi95xnmm9wygv1vbpkwkv5amx9l0km86cs79jpp1h"))))
3557 (build-system texlive-build-system)
3558 (arguments '(#:tex-directory "latex/galois"))
b8d8806b 3559 (home-page "https://www.ctan.org/pkg/galois")
9b4d5c09
RW
3560 (synopsis "Typeset Galois connections")
3561 (description
3562 "The package deals with connections in two-dimensional style, optionally
3563in colour.")
3564 (license license:lppl)))
3565
5f691e2e
RW
3566(define-public texlive-latex-gcite
3567 (package
3568 (name "texlive-latex-gcite")
3569 (version (number->string %texlive-revision))
3570 (source (origin
3571 (method svn-fetch)
3572 (uri (texlive-ref "latex" "gcite"))
3573 (file-name (string-append name "-" version "-checkout"))
3574 (sha256
3575 (base32
3576 "03g9by54yrypn599y98r1xh7qw0bbbmpzq0bfwpj6j5q5rkl1mfa"))))
3577 (build-system texlive-build-system)
3578 (arguments '(#:tex-directory "latex/gcite"))
b8d8806b 3579 (home-page "https://www.ctan.org/pkg/gcite")
5f691e2e
RW
3580 (synopsis "Citations in a reader-friendly style")
3581 (description
3582 "The package allows citations in the German style, which is considered by
3583many to be particularly reader-friendly. The citation provides a small amount
3584of bibliographic information in a footnote on the page where each citation is
3585made. It combines a desire to eliminate unnecessary page-turning with the
3586look-up efficiency afforded by numeric citations. The package makes use of
3587BibLaTeX, and is considered experimental.")
3588 (license license:lppl1.3+)))
3589
f47d1a52
RW
3590(define-public texlive-latex-geometry
3591 (package
3592 (name "texlive-latex-geometry")
3593 (version (number->string %texlive-revision))
3594 (source (origin
3595 (method svn-fetch)
3596 (uri (texlive-ref "latex" "geometry"))
3597 (file-name (string-append name "-" version "-checkout"))
3598 (sha256
3599 (base32
d4d9a1ec 3600 "0yw6bjfgsli3s1dldsgb7mkr7lnk329cgdjbgs8z2xn59pmmdsn4"))))
f47d1a52
RW
3601 (build-system texlive-build-system)
3602 (arguments '(#:tex-directory "latex/geometry"))
00a7af0e
RW
3603 (propagated-inputs
3604 `(("texlive-latex-oberdiek" ,texlive-latex-oberdiek))) ;for ifpdf
b8d8806b 3605 (home-page "https://www.ctan.org/pkg/geometry")
f47d1a52
RW
3606 (synopsis "Flexible and complete interface to document dimensions")
3607 (description
3608 "This package provides an easy and flexible user interface to customize
3609page layout, implementing auto-centering and auto-balancing mechanisms so that
3610the users have only to give the least description for the page layout. The
3611package knows about all the standard paper sizes, so that the user need not
3612know what the nominal \"real\" dimensions of the paper are, just its standard
3613name (such as a4, letter, etc.). An important feature is the package's
3614ability to communicate the paper size it's set up to the output.")
3615 (license license:lppl)))
3616
d48091be
RW
3617(define-public texlive-latex-mdwtools
3618 (package
3619 (name "texlive-latex-mdwtools")
3620 (version (number->string %texlive-revision))
3621 (source (origin
3622 (method svn-fetch)
3623 (uri (texlive-ref "latex" "mdwtools"))
3624 (file-name (string-append name "-" version "-checkout"))
3625 (sha256
3626 (base32
3627 "0caxs74hla28hc67csf5i5ahadx97w8vxh3mdmsprxbpd1mr7ssg"))))
3628 (build-system texlive-build-system)
3629 (arguments '(#:tex-directory "latex/mdwtools"))
b8d8806b 3630 (home-page "https://www.ctan.org/pkg/mdwtools")
d48091be
RW
3631 (synopsis "Miscellaneous tools by Mark Wooding")
3632 (description
3633 "This collection of tools includes: @code{atsupport} for short commands
fb5dfa86
RW
3634starting with @code{@@}, macros to sanitize the OT1 encoding of the
3635@code{cmtt} fonts; a @code{doafter} command; improved @code{footnote} support;
d48091be
RW
3636@code{mathenv} for various alignment in maths; list handling; @code{mdwmath}
3637which adds some minor changes to LaTeX maths; a rewrite of LaTeX's tabular and
3638array environments; verbatim handling; and syntax diagrams.")
3639 (license license:gpl3+)))
3640
80bf1f21
RW
3641(define-public texlive-latex-polyglossia
3642 (package
3643 (name "texlive-latex-polyglossia")
3644 (version (number->string %texlive-revision))
3645 (source (origin
3646 (method svn-fetch)
3647 (uri (texlive-ref "latex" "polyglossia"))
3648 (file-name (string-append name "-" version "-checkout"))
3649 (sha256
3650 (base32
d4d9a1ec 3651 "03ma58z3ypsbp7zgkzb1ylpn2ygr27cxzkf042ns0rif4g8s491f"))))
80bf1f21
RW
3652 (build-system texlive-build-system)
3653 (arguments '(#:tex-directory "latex/polyglossia"))
b8d8806b 3654 (home-page "https://www.ctan.org/pkg/polyglossia")
80bf1f21
RW
3655 (synopsis "Alternative to babel for XeLaTeX and LuaLaTeX")
3656 (description
3657 "This package provides a complete Babel replacement for users of LuaLaTeX
3658and XeLaTeX; it relies on the @code{fontspec} package, version 2.0 at least.")
3659 (license license:lppl1.3+)))
3660
84f8035a
RW
3661(define-public texlive-latex-supertabular
3662 (package
3663 (name "texlive-latex-supertabular")
3664 (version (number->string %texlive-revision))
3665 (source (origin
3666 (method svn-fetch)
3667 (uri (texlive-ref "latex" "supertabular"))
3668 (file-name (string-append name "-" version "-checkout"))
3669 (sha256
3670 (base32
3671 "14b2bc7cqz4ckxxycim9sw6jkrr1pahivm1rdbpz5k6hl967w1s3"))))
3672 (build-system texlive-build-system)
3673 (arguments '(#:tex-directory "latex/supertabular"))
b8d8806b 3674 (home-page "https://www.ctan.org/pkg/supertabular")
84f8035a
RW
3675 (synopsis "Multi-page tables package")
3676 (description
3677 "This package was a predecessor of @code{longtable}; the newer
3678package (designed on quite different principles) is easier to use and more
3679flexible, in many cases, but supertabular retains its usefulness in a few
3680situations where longtable has problems.")
3681 (license license:lppl1.3+)))
3682
a0aa6b59
RW
3683(define-public texlive-tex-texinfo
3684 (package
3685 (name "texlive-tex-texinfo")
3686 (version (number->string %texlive-revision))
3687 (source (origin
3688 (method svn-fetch)
3689 (uri (svn-reference
3690 (url (string-append "svn://www.tug.org/texlive/tags/"
3691 %texlive-tag "/Master/texmf-dist/"
3692 "/tex/texinfo"))
3693 (revision %texlive-revision)))
88ae1921 3694 (file-name (string-append name "-" version "-checkout"))
a0aa6b59
RW
3695 (sha256
3696 (base32
d4d9a1ec 3697 "06cf821y1j7jdg93pb41ayigrfwgn0y49d7w1025zlijjxi6bvjp"))))
a0aa6b59
RW
3698 (build-system trivial-build-system)
3699 (arguments
3700 `(#:modules ((guix build utils))
3701 #:builder
3702 (begin
3703 (use-modules (guix build utils))
3704 (let ((target (string-append (assoc-ref %outputs "out")
3705 "/share/texmf-dist/tex/texinfo")))
3706 (mkdir-p target)
3707 (copy-recursively (assoc-ref %build-inputs "source") target)
3708 #t))))
b8d8806b 3709 (home-page "https://www.ctan.org/pkg/texinfo")
a0aa6b59
RW
3710 (synopsis "TeX macros to handle Texinfo files")
3711 (description
3712 "Texinfo is the preferred format for documentation in the GNU project;
3713the format may be used to produce online or printed output from a single
3714source. The Texinfo macros may be used to produce printable output using TeX;
3715other programs in the distribution offer online interactive use (with
3716hypertext linkages in some cases).")
3717 (license license:gpl3+)))
3718
0de81b09
RW
3719(define-public texlive-latex-upquote
3720 (package
3721 (name "texlive-latex-upquote")
3722 (version (number->string %texlive-revision))
3723 (source (origin
3724 (method svn-fetch)
3725 (uri (texlive-ref "latex" "upquote"))
3726 (file-name (string-append name "-" version "-checkout"))
3727 (sha256
3728 (base32
3729 "0d1050i973wnxigy0xpky5l7vn4ff7ldhkjpdqsw5s653gagwixp"))))
3730 (build-system texlive-build-system)
3731 (arguments '(#:tex-directory "latex/upquote"))
b8d8806b 3732 (home-page "https://www.ctan.org/pkg/upquote")
0de81b09
RW
3733 (synopsis "Show \"realistic\" quotes in verbatim")
3734 (description
3735 "Typewriter-style fonts are best for program listings, but Computer
3736Modern Typewriter prints @code{`} and @code{'} as bent opening and closing
3737single quotes. Other fonts, and most programming languages, print @code{`} as
3738a grave accent and @code{'} upright; @code{'} is used both to open and to
3739close quoted strings. The package switches the typewriter font to Computer
3740Modern Typewriter in OT1 encoding, and modifies the behaviour of
3741@code{verbatim}, @code{verbatim*}, @code{\\verb}, and @code{\\verb*} to print
3742in the expected way. It does this regardless of other fonts or encodings in
3743use, so long as the package is loaded after the other fonts were. The package
3744does not affect @code{\\tt}, @code{\\texttt}, etc.")
3745 (license license:lppl1.2+)))
3746
bda61541
RW
3747(define-public texlive-latex-anysize
3748 (package
3749 (name "texlive-latex-anysize")
3750 (version (number->string %texlive-revision))
3751 (source (origin
3752 (method svn-fetch)
3753 (uri (svn-reference
3754 (url (string-append "svn://www.tug.org/texlive/tags/"
3755 %texlive-tag "/Master/texmf-dist/"
3756 "/tex/latex/anysize"))
3757 (revision %texlive-revision)))
de4eb4d1 3758 (file-name (string-append name "-" version "-checkout"))
bda61541
RW
3759 (sha256
3760 (base32
3761 "19khwqjlvznc955sijhww3c4zbb0053rvzwv9nz738qknq7y18vb"))))
3762 (build-system trivial-build-system)
3763 (arguments
3764 `(#:modules ((guix build utils))
3765 #:builder
3766 (begin
3767 (use-modules (guix build utils))
3768 (let ((target (string-append (assoc-ref %outputs "out")
3769 "/share/texmf-dist/tex/latex/anysize")))
3770 (mkdir-p target)
3771 (copy-recursively (assoc-ref %build-inputs "source") target)
3772 #t))))
b8d8806b 3773 (home-page "https://www.ctan.org/pkg/anysize")
bda61541
RW
3774 (synopsis "Simple package to set up document margins")
3775 (description
3776 "This is a simple package to set up document margins. This package is
3777considered obsolete; alternatives are the @code{typearea} package from the
3778@code{koma-script} bundle, or the @code{geometry} package.")
3779 (license license:public-domain)))
3780
1d3be84e
RW
3781(define-public texlive-latex-appendix
3782 (package
3783 (name "texlive-latex-appendix")
3784 (version (number->string %texlive-revision))
3785 (source (origin
3786 (method svn-fetch)
3787 (uri (texlive-ref "latex" "appendix"))
72d5adf4 3788 (file-name (string-append name "-" version "-checkout"))
1d3be84e
RW
3789 (sha256
3790 (base32
3791 "0rxfpr8vq3brwx5rc7qn91ixlp9zva4zrms8a579fqa1g5yva7vg"))))
3792 (build-system texlive-build-system)
3793 (arguments '(#:tex-directory "latex/appendix"))
b8d8806b 3794 (home-page "https://www.ctan.org/pkg/appendix")
1d3be84e
RW
3795 (synopsis "Extra control of appendices")
3796 (description
3797 "The appendix package provides various ways of formatting the titles of
3798appendices. Also (sub)appendices environments are provided that can be used,
3799for example, for per chapter/section appendices. An @code{appendices}
3800environment is provided which can be used instead of the @code{\\appendix}
3801command.")
3802 (license license:lppl)))
3803
b92ac281
RW
3804(define-public texlive-latex-changebar
3805 (package
3806 (name "texlive-latex-changebar")
3807 (version (number->string %texlive-revision))
3808 (source (origin
3809 (method svn-fetch)
3810 (uri (texlive-ref "latex" "changebar"))
af8aa105 3811 (file-name (string-append name "-" version "-checkout"))
b92ac281
RW
3812 (sha256
3813 (base32
d4d9a1ec 3814 "05x15ilynqrl448h8l6qiraygamdldlngz89a2bw7kg74fym14ch"))))
b92ac281
RW
3815 (build-system texlive-build-system)
3816 (arguments '(#:tex-directory "latex/changebar"))
b8d8806b 3817 (home-page "https://www.ctan.org/pkg/changebar")
b92ac281
RW
3818 (synopsis "Generate changebars in LaTeX documents")
3819 (description
3820 "Identify areas of text to be marked with changebars with the
3821@code{\\cbstart} and @code{\\cbend} commands; the bars may be coloured. The
36a4366d
EF
3822package uses @code{drivers} to place the bars; the available drivers can work
3823with @code{dvitoln03}, @code{dvitops}, @code{dvips}, the emTeX and TeXtures DVI
b92ac281
RW
3824drivers, and VTeX and pdfTeX.")
3825 (license license:lppl)))
3826
fedd77c1
RW
3827(define-public texlive-latex-cmap
3828 (package
3829 (name "texlive-latex-cmap")
3830 (version (number->string %texlive-revision))
3831 (source (origin
3832 (method svn-fetch)
3833 (uri (svn-reference
3834 (url (string-append "svn://www.tug.org/texlive/tags/"
3835 %texlive-tag "/Master/texmf-dist/"
3836 "/tex/latex/cmap"))
3837 (revision %texlive-revision)))
3838 (file-name (string-append name "-" version "-checkout"))
3839 (sha256
3840 (base32
3841 "1s1rv6zgw105w2j6ffhnk914qrix87y1ndzri1q72g2kbr91zlbg"))))
3842 (build-system trivial-build-system)
3843 (arguments
3844 `(#:modules ((guix build utils))
3845 #:builder
3846 (begin
3847 (use-modules (guix build utils))
3848 (let ((target (string-append (assoc-ref %outputs "out")
3849 "/share/texmf-dist/tex/latex/cmap")))
3850 (mkdir-p target)
3851 (copy-recursively (assoc-ref %build-inputs "source") target)
3852 #t))))
3853 (home-page "https://www.tug.org/svn/texlive/tags/texlive-2017.1/\
3854Master/texmf-dist/tex/latex/cmap/")
3855 (synopsis "CMap support for PDF files")
3856 (description
3857 "This package embeds CMap tables into PDF files to make search and
3858copy-and-paste functions work properly.")
3859 (license license:lppl)))
3860
e003a5f0
RW
3861(define-public texlive-latex-colortbl
3862 (package
3863 (name "texlive-latex-colortbl")
3864 (version (number->string %texlive-revision))
3865 (source (origin
3866 (method svn-fetch)
3867 (uri (texlive-ref "latex" "colortbl"))
4439c1de 3868 (file-name (string-append name "-" version "-checkout"))
e003a5f0
RW
3869 (sha256
3870 (base32
3871 "190pmq8la2rq07xry8bn8z8yywzxv6fqyqaj7yjfj5rgw6x0mas8"))))
3872 (build-system texlive-build-system)
3873 (arguments '(#:tex-directory "latex/colortbl"))
b8d8806b 3874 (home-page "https://www.ctan.org/pkg/colortbl")
e003a5f0
RW
3875 (synopsis "Add colour to LaTeX tables")
3876 (description
3877 "This package allows rows, columns, and even individual cells in LaTeX
3878tables to be coloured.")
3879 (license license:lppl)))
3880
36ce05ff
RW
3881(define-public texlive-latex-fancybox
3882 (package
3883 (name "texlive-latex-fancybox")
3884 (version (number->string %texlive-revision))
3885 (source (origin
3886 (method svn-fetch)
3887 (uri (svn-reference
3888 (url (string-append "svn://www.tug.org/texlive/tags/"
3889 %texlive-tag "/Master/texmf-dist/"
3890 "/tex/latex/fancybox"))
3891 (revision %texlive-revision)))
62ee46b9 3892 (file-name (string-append name "-" version "-checkout"))
36ce05ff
RW
3893 (sha256
3894 (base32
3895 "0smmnaad2q8qwicay1frri990lv65l0k8cwzsvdsyp3jk8kp042w"))))
3896 (build-system trivial-build-system)
3897 (arguments
3898 `(#:modules ((guix build utils))
3899 #:builder
3900 (begin
3901 (use-modules (guix build utils))
3902 (let ((target (string-append (assoc-ref %outputs "out")
3903 "/share/texmf-dist/tex/latex/fancybox")))
3904 (mkdir-p target)
3905 (copy-recursively (assoc-ref %build-inputs "source") target)
3906 #t))))
b8d8806b 3907 (home-page "https://www.ctan.org/pkg/fancybox")
36ce05ff
RW
3908 (synopsis "Variants of \\fbox and other games with boxes")
3909 (description
3910 "This package provides variants of @code{\\fbox}: @code{\\shadowbox},
3911@code{\\doublebox}, @code{\\ovalbox}, @code{\\Ovalbox}, with helpful tools for
3912using box macros and flexible verbatim macros. You can box mathematics,
3913floats, center, flushleft, and flushright, lists, and pages.")
3914 (license license:lppl1.2+)))
3915
20282111
RW
3916(define-public texlive-latex-fancyhdr
3917 (package
3918 (name "texlive-latex-fancyhdr")
3919 (version (number->string %texlive-revision))
3920 (source (origin
3921 (method svn-fetch)
3922 (uri (svn-reference
3923 (url (string-append "svn://www.tug.org/texlive/tags/"
3924 %texlive-tag "/Master/texmf-dist/"
3925 "/tex/latex/fancyhdr"))
3926 (revision %texlive-revision)))
e89d5cf4 3927 (file-name (string-append name "-" version "-checkout"))
20282111
RW
3928 (sha256
3929 (base32
d4d9a1ec 3930 "1xsnzx7vgdfh9zh2m7bjz6bgdpxsgb1kyc19p50vhs34x5nbgsnr"))))
20282111
RW
3931 (build-system trivial-build-system)
3932 (arguments
3933 `(#:modules ((guix build utils))
3934 #:builder
3935 (begin
3936 (use-modules (guix build utils))
3937 (let ((target (string-append (assoc-ref %outputs "out")
3938 "/share/texmf-dist/tex/latex/fancyhdr")))
3939 (mkdir-p target)
3940 (copy-recursively (assoc-ref %build-inputs "source") target)
3941 #t))))
b8d8806b 3942 (home-page "https://www.ctan.org/pkg/fancyhdr")
20282111
RW
3943 (synopsis "Extensive control of page headers and footers in LaTeX2e")
3944 (description
3945 "The package provides extensive facilities, both for constructing headers
3946and footers, and for controlling their use (for example, at times when LaTeX
3947would automatically change the heading style in use).")
3948 (license license:lppl)))
3949
df2b9bb4
RW
3950(define-public texlive-latex-float
3951 (package
3952 (name "texlive-latex-float")
3953 (version (number->string %texlive-revision))
3954 (source (origin
3955 (method svn-fetch)
3956 (uri (texlive-ref "latex" "float"))
4fd0a591 3957 (file-name (string-append name "-" version "-checkout"))
df2b9bb4
RW
3958 (sha256
3959 (base32
3960 "0nbl7wylkv22fcdv4p8byhhj575fli6jnqjpkhrkbv8dzwah84nq"))))
3961 (build-system texlive-build-system)
3962 (arguments '(#:tex-directory "latex/float"))
b8d8806b 3963 (home-page "https://www.ctan.org/pkg/float")
df2b9bb4
RW
3964 (synopsis "Improved interface for floating objects")
3965 (description
3966 "This package improves the interface for defining floating objects such
3967as figures and tables. It introduces the boxed float, the ruled float and the
3968plaintop float. You can define your own floats and improve the behaviour of
3969the old ones. The package also provides the @code{H} float modifier option of
3970the obsolete @code{here} package. You can select this as automatic default
3971with @code{\\floatplacement{figure}{H}}.")
3972 (license license:lppl)))
3973
3921bc7c
RW
3974(define-public texlive-latex-footmisc
3975 (package
3976 (name "texlive-latex-footmisc")
3977 (version (number->string %texlive-revision))
3978 (source (origin
3979 (method svn-fetch)
3980 (uri (texlive-ref "latex" "footmisc"))
dae1d9e4 3981 (file-name (string-append name "-" version "-checkout"))
3921bc7c
RW
3982 (sha256
3983 (base32
3984 "03x61wwql8nh6zrqiiiq3rb0x7m3pn48c606zapy19y21fybwdxs"))))
3985 (build-system texlive-build-system)
3986 (arguments '(#:tex-directory "latex/footmisc"))
b8d8806b 3987 (home-page "https://www.ctan.org/pkg/footmisc")
3921bc7c
RW
3988 (synopsis "Range of footnote options")
3989 (description
3990 "This is a collection of ways to change the typesetting of footnotes.
3991The package provides means of changing the layout of the footnotes themselves,
3992a way to number footnotes per page, to make footnotes disappear in a
3993\"moving\" argument, and to deal with multiple references to footnotes from
3994the same place. The package also has a range of techniques for labelling
3995footnotes with symbols rather than numbers.")
3996 (license license:lppl1.3+)))
3997
b2bc1daf
RW
3998(define-public texlive-latex-listings
3999 (package
4000 (name "texlive-latex-listings")
4001 (version (number->string %texlive-revision))
4002 (source (origin
4003 (method svn-fetch)
4004 (uri (texlive-ref "latex" "listings"))
aeb135e3 4005 (file-name (string-append name "-" version "-checkout"))
b2bc1daf
RW
4006 (sha256
4007 (base32
4008 "1nsn9wp3wl12b36c0sqrim33lf33cr5wky0h4ncnw8lvqgm7h8wf"))))
4009 (build-system texlive-build-system)
4010 (arguments
4011 '(#:tex-directory "latex/listings"
4012 #:build-targets '("listings.ins")))
b8d8806b 4013 (home-page "https://www.ctan.org/pkg/listings")
b2bc1daf
RW
4014 (synopsis "Typeset source code listings using LaTeX")
4015 (description
4016 "The package enables the user to typeset programs (programming code)
4017within LaTeX; the source code is read directly by TeX---no front-end processor
4018is needed. Keywords, comments and strings can be typeset using different
4019styles. Support for @code{hyperref} is provided.")
4020 (license license:lppl1.3+)))
4021
02fd07b3
RW
4022(define-public texlive-latex-jknapltx
4023 (package
4024 (name "texlive-latex-jknapltx")
4025 (version (number->string %texlive-revision))
4026 (source (origin
4027 (method svn-fetch)
4028 (uri (svn-reference
4029 (url (string-append "svn://www.tug.org/texlive/tags/"
4030 %texlive-tag "/Master/texmf-dist/"
4031 "/tex/latex/jknapltx"))
4032 (revision %texlive-revision)))
aa499191 4033 (file-name (string-append name "-" version "-checkout"))
02fd07b3
RW
4034 (sha256
4035 (base32
4036 "0m034x72f2g07icr50gacyxfb9g1lz2rmqh4kqr1qjb421x2kds9"))))
4037 (build-system trivial-build-system)
4038 (arguments
4039 `(#:modules ((guix build utils))
4040 #:builder
4041 (begin
4042 (use-modules (guix build utils))
4043 (let ((target (string-append (assoc-ref %outputs "out")
4044 "/share/texmf-dist/tex/latex/jknapltx")))
4045 (mkdir-p target)
4046 (copy-recursively (assoc-ref %build-inputs "source") target)
4047 #t))))
b8d8806b 4048 (home-page "https://www.ctan.org/pkg/jknappen")
02fd07b3
RW
4049 (synopsis "Miscellaneous packages by Joerg Knappen")
4050 (description
4051 "This package provides miscellaneous macros by Joerg Knappen, including:
4052represent counters in greek; Maxwell's non-commutative division;
4053@code{latin1jk}, @code{latin2jk} and @code{latin3jk}, which are
4054@code{inputenc} definition files that allow verbatim input in the respective
4055ISO Latin codes; blackboard bold fonts in maths; use of RSFS fonts in maths;
4056extra alignments for @code{\\parboxes}; swap Roman and Sans fonts;
4057transliterate semitic languages; patches to make (La)TeX formulae embeddable
4058in SGML; use maths minus in text as appropriate; simple Young tableaux.")
4059 (license license:gpl2)))
4060
83c830d1
RW
4061(define-public texlive-fonts-ec
4062 (package
4063 (name "texlive-fonts-ec")
4064 (version (number->string %texlive-revision))
4065 (source (origin
4066 (method svn-fetch)
4067 (uri (svn-reference
4068 (url (string-append "svn://www.tug.org/texlive/tags/"
4069 %texlive-tag "/Master/texmf-dist/"
4070 "/fonts/source/jknappen/ec/"))
4071 (revision %texlive-revision)))
ca816eb3 4072 (file-name (string-append name "-" version "-checkout"))
83c830d1
RW
4073 (sha256
4074 (base32
4075 "12av65fbz9xiashm09c9m1fj1mijxls5xspd7652ry1n5s0nixy4"))))
4076 (build-system gnu-build-system)
4077 (arguments
4078 `(#:modules ((guix build gnu-build-system)
4079 (guix build utils)
4080 (srfi srfi-1)
4081 (srfi srfi-26))
4082 #:tests? #f ; no tests
4083 #:phases
4084 (modify-phases %standard-phases
4085 (delete 'configure)
4086 (replace 'build
4087 (lambda* (#:key inputs #:allow-other-keys)
4088 (let ((mf (assoc-ref inputs "texlive-metafont-base")))
4089 ;; Tell mf where to find mf.base
4090 (setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
4091 ;; Tell mf where to look for source files
4092 (setenv "MFINPUTS"
4093 (string-append (getcwd) ":"
4094 mf "/share/texmf-dist/metafont/base:"
4095 (assoc-ref inputs "texlive-fonts-cm")
4096 "/share/texmf-dist/fonts/source/public/cm")))
4097 (mkdir "build")
c4fc86e4
MW
4098 (for-each (lambda (font)
4099 (format #t "building font ~a\n" font)
4100 (invoke "mf" "-progname=mf"
4101 "-output-directory=build"
4102 (string-append "\\"
4103 "mode:=ljfour; "
4104 "mag:=1; "
4105 "batchmode; "
4106 "input " (basename font ".mf"))))
4107 (find-files "." "[0-9]+\\.mf$"))
4108 #t))
83c830d1
RW
4109 (replace 'install
4110 (lambda* (#:key outputs #:allow-other-keys)
4111 (let* ((out (assoc-ref outputs "out"))
4112 (tfm (string-append
4113 out "/share/texmf-dist/fonts/tfm/jknappen/ec"))
4114 (mf (string-append
4115 out "/share/texmf-dist/fonts/source/jknappen/ec")))
4116 (for-each (cut install-file <> tfm)
4117 (find-files "build" "\\.*"))
4118 (for-each (cut install-file <> mf)
4119 (find-files "." "\\.mf"))
4120 #t))))))
4121 (native-inputs
4122 `(("texlive-bin" ,texlive-bin)
4123 ("texlive-metafont-base" ,texlive-metafont-base)
4124 ("texlive-fonts-cm" ,texlive-fonts-cm)))
b8d8806b 4125 (home-page "https://www.ctan.org/pkg/ec")
83c830d1
RW
4126 (synopsis "Computer modern fonts in T1 and TS1 encodings")
4127 (description
4128 "The EC fonts are European Computer Modern Fonts, supporting the complete
4129LaTeX T1 encoding defined at the 1990 TUG conference hold at Cork/Ireland.
4130These fonts are intended to be stable with no changes being made to the tfm
4131files. The set also contains a Text Companion Symbol font, called @code{tc},
4132featuring many useful characters needed in text typesetting, for example
4133oldstyle digits, currency symbols (including the newly created Euro symbol),
4134the permille sign, copyright, trade mark and servicemark as well as a copyleft
4135sign, and many others. Recent releases of LaTeX2e support the EC fonts. The
4136EC fonts supersede the preliminary version released as the DC fonts. The
4137fonts are available in (traced) Adobe Type 1 format, as part of the
4138@code{cm-super} bundle. The other Computer Modern-style T1-encoded Type 1
4139set, Latin Modern, is not actually a direct development of the EC set, and
4140differs from the EC in a number of particulars.")
4141 (license (license:fsf-free "https://www.tug.org/svn/texlive/tags/\
4142texlive-2017.1/Master/texmf-dist/doc/fonts/ec/copyrite.txt"))))
4143
5e9bf5a2
RW
4144(define-public texlive-fonts-adobe-times
4145 (package
4146 (name "texlive-fonts-adobe-times")
4147 (version (number->string %texlive-revision))
4148 (source (origin
4149 (method svn-fetch)
4150 (uri (svn-reference
4151 (url (string-append "svn://www.tug.org/texlive/tags/"
4152 %texlive-tag "/Master/texmf-dist/"
4153 "/fonts/type1/urw/times/"))
4154 (revision %texlive-revision)))
4155 (file-name (string-append name "-" version "-checkout"))
4156 (sha256
4157 (base32
4158 "15vzyr7favkv1mj00qxr03s89kw78nd066fh69by93272g8p5sgd"))))
4159 (build-system trivial-build-system)
4160 (arguments
4161 `(#:modules ((guix build utils)
4162 (ice-9 match))
4163 #:builder
4164 (begin
4165 (use-modules (guix build utils)
4166 (ice-9 match))
4167 (let ((root (string-append (assoc-ref %outputs "out")
4168 "/share/texmf-dist/"))
4169 (pkgs '(("source" . "fonts/type1/urw/times")
4170
4171 ("times-afm" . "fonts/afm/adobe/times")
4172 ("times-tfm" . "fonts/tfm/adobe/times")
4173 ("times-vf" . "fonts/vf/adobe/times")
4174
4175 ("urw-afm" . "fonts/afm/urw/times")
4176 ("urw35vf-tfm" . "fonts/tfm/urw35vf/times")
4177 ("urw35vf-vf" . "fonts/vf/urw35vf/times")
4178
4179 ("times-tex" . "tex/latex/times")
4180 ("dvips" . "dvips/times")
4181 ("fonts-map" . "fonts/map/dvips/times"))))
4182 (for-each (match-lambda
4183 ((pkg . dir)
4184 (let ((target (string-append root dir)))
4185 (mkdir-p target)
4186 (copy-recursively (assoc-ref %build-inputs pkg)
4187 target))))
4188 pkgs)
4189 #t))))
4190 (native-inputs
4191 `(("times-afm"
4192 ,(origin
4193 (method svn-fetch)
4194 (uri (svn-reference
4195 (url (string-append "svn://www.tug.org/texlive/tags/"
4196 %texlive-tag "/Master/texmf-dist/"
4197 "/fonts/afm/adobe/times"))
4198 (revision %texlive-revision)))
4199 (file-name (string-append name "-afm-" version "-checkout"))
4200 (sha256
4201 (base32
4202 "1k7h6vihfc6ri2lq9ggnq2g4zq3qcgq1vd0hr486g9cqrdpys6cy"))))
4203 ("times-tfm"
4204 ,(origin
4205 (method svn-fetch)
4206 (uri (svn-reference
4207 (url (string-append "svn://www.tug.org/texlive/tags/"
4208 %texlive-tag "/Master/texmf-dist/"
4209 "/fonts/tfm/adobe/times"))
4210 (revision %texlive-revision)))
4211 (file-name (string-append name "-tfm-" version "-checkout"))
4212 (sha256
4213 (base32
4214 "1hbgkjnf5xyganbznwpwszvr3iyk4bzb0ys4hd8ybawp60paadrr"))))
4215 ("times-vf"
4216 ,(origin
4217 (method svn-fetch)
4218 (uri (svn-reference
4219 (url (string-append "svn://www.tug.org/texlive/tags/"
4220 %texlive-tag "/Master/texmf-dist/"
4221 "/fonts/vf/adobe/times"))
4222 (revision %texlive-revision)))
4223 (file-name (string-append name "-vf-" version "-checkout"))
4224 (sha256
4225 (base32
4226 "18rfspnwdw9r81dy18lb4w96d09b6c4g7y80azwylalkhwdf2lfp"))))
4227 ("urw-afm"
4228 ,(origin
4229 (method svn-fetch)
4230 (uri (svn-reference
4231 (url (string-append "svn://www.tug.org/texlive/tags/"
4232 %texlive-tag "/Master/texmf-dist/"
4233 "/fonts/afm/urw/times"))
4234 (revision %texlive-revision)))
4235 (file-name (string-append name "-urw-afm-" version "-checkout"))
4236 (sha256
4237 (base32
4238 "0g0xpsyn6634g0b4rpd420v7i4gkz3zr12vcy2b8csbcscjvwri5"))))
4239 ("urw35vf-tfm"
4240 ,(origin
4241 (method svn-fetch)
4242 (uri (svn-reference
4243 (url (string-append "svn://www.tug.org/texlive/tags/"
4244 %texlive-tag "/Master/texmf-dist/"
4245 "/fonts/tfm/urw35vf/times"))
4246 (revision %texlive-revision)))
4247 (file-name (string-append name "-urw35vf-tfm-" version "-checkout"))
4248 (sha256
4249 (base32
4250 "0a4idlvpaqd0ypqgy1xw0rpx8q23bvssg8xq757zzn3zikj0w7pr"))))
4251 ("urw35vf-vf"
4252 ,(origin
4253 (method svn-fetch)
4254 (uri (svn-reference
4255 (url (string-append "svn://www.tug.org/texlive/tags/"
4256 %texlive-tag "/Master/texmf-dist/"
4257 "/fonts/vf/urw35vf/times"))
4258 (revision %texlive-revision)))
4259 (file-name (string-append name "-urw35vf-vf-" version "-checkout"))
4260 (sha256
4261 (base32
4262 "05mppwxd4c5x0yw50gca726f0ylc1rk8jf0jjkrriixq6rnw03di"))))
4263 ("times-tex"
4264 ,(origin
4265 (method svn-fetch)
4266 (uri (svn-reference
4267 (url (string-append "svn://www.tug.org/texlive/tags/"
4268 %texlive-tag "/Master/texmf-dist/"
4269 "/tex/latex/times"))
4270 (revision %texlive-revision)))
4271 (file-name (string-append name "-tex-" version "-checkout"))
4272 (sha256
4273 (base32
4274 "1gmd0x7c3vkvfzgmrsp4866rcdbyimfk3bjr91zaadc41r1i8xrp"))))
4275 ("dvips"
4276 ,(origin
4277 (method svn-fetch)
4278 (uri (svn-reference
4279 (url (string-append "svn://www.tug.org/texlive/tags/"
4280 %texlive-tag "/Master/texmf-dist/"
4281 "/dvips/times/"))
4282 (revision %texlive-revision)))
4283 (file-name (string-append name "-dvips-" version "-checkout"))
4284 (sha256
4285 (base32
4286 "1fvqpgqi7bp2q76nf5kmlhsdijxw65arqfy3ax3djwih3yg12mp0"))))
4287 ("fonts-map"
4288 ,(origin
4289 (method svn-fetch)
4290 (uri (svn-reference
4291 (url (string-append "svn://www.tug.org/texlive/tags/"
4292 %texlive-tag "/Master/texmf-dist/"
4293 "/fonts/map/dvips/times/"))
4294 (revision %texlive-revision)))
4295 (file-name (string-append name "-fonts-map-" version "-checkout"))
4296 (sha256
4297 (base32
4298 "12f00gzs2zgllkm59qdhw2xxj7lvg3p256232f1l275z3pldfqqi"))))))
4299 (home-page "https://ctan.org/pkg/urw-base35")
4300 (synopsis "URW Base 35 font pack for LaTeX")
4301 (description
4302 "This package provides a drop-in replacements for the Times font from
4303Adobe's basic set.")
4304 ;; No license version specified.
4305 (license license:gpl3+)))
4306
f2d1f060
RW
4307(define-public texlive-fonts-adobe-palatino
4308 (package
4309 (name "texlive-fonts-adobe-palatino")
4310 (version (number->string %texlive-revision))
4311 (source (origin
4312 (method svn-fetch)
4313 (uri (svn-reference
4314 (url (string-append "svn://www.tug.org/texlive/tags/"
4315 %texlive-tag "/Master/texmf-dist/"
4316 "/fonts/type1/urw/palatino/"))
4317 (revision %texlive-revision)))
4318 (file-name (string-append name "-" version "-checkout"))
4319 (sha256
4320 (base32
4321 "18dw5260c6fy7acxaqwrg3hw04kg63ijq4lkn56q5pa2g6nyylrp"))))
4322 (build-system trivial-build-system)
4323 (arguments
4324 `(#:modules ((guix build utils)
4325 (ice-9 match))
4326 #:builder
4327 (begin
4328 (use-modules (guix build utils)
4329 (ice-9 match))
4330 (let ((root (string-append (assoc-ref %outputs "out")
4331 "/share/texmf-dist/"))
4332 (pkgs '(("source" . "fonts/type1/urw/palatino")
4333
4334 ("palatino-afm" . "fonts/afm/adobe/palatino")
4335 ("palatino-tfm" . "fonts/tfm/adobe/palatino")
4336 ("palatino-vf" . "fonts/vf/adobe/palatino")
4337
4338 ("urw-afm" . "fonts/afm/urw/palatino")
4339 ("urw35vf-tfm" . "fonts/tfm/urw35vf/palatino")
4340 ("urw35vf-vf" . "fonts/vf/urw35vf/palatino")
4341
4342 ("palatino-tex" . "tex/latex/palatino")
4343 ("dvips" . "dvips/palatino")
4344 ("fonts-map" . "fonts/map/dvips/palatino"))))
4345 (for-each (match-lambda
4346 ((pkg . dir)
4347 (let ((target (string-append root dir)))
4348 (mkdir-p target)
4349 (copy-recursively (assoc-ref %build-inputs pkg)
4350 target))))
4351 pkgs)
4352 #t))))
4353 (native-inputs
4354 `(("palatino-afm"
4355 ,(origin
4356 (method svn-fetch)
4357 (uri (svn-reference
4358 (url (string-append "svn://www.tug.org/texlive/tags/"
4359 %texlive-tag "/Master/texmf-dist/"
4360 "/fonts/afm/adobe/palatino"))
4361 (revision %texlive-revision)))
4362 (file-name (string-append name "-afm-" version "-checkout"))
4363 (sha256
4364 (base32
4365 "0pxizay730cx7rb9y5bqq9dn1zxx3arc33rmdsn7l29pc51flmmi"))))
4366 ("palatino-tfm"
4367 ,(origin
4368 (method svn-fetch)
4369 (uri (svn-reference
4370 (url (string-append "svn://www.tug.org/texlive/tags/"
4371 %texlive-tag "/Master/texmf-dist/"
4372 "/fonts/tfm/adobe/palatino"))
4373 (revision %texlive-revision)))
4374 (file-name (string-append name "-tfm-" version "-checkout"))
4375 (sha256
4376 (base32
4377 "1w1vm0sk9kpsy14yhyf1v1q3c6b97cgbba74g578bcwjlh810mg0"))))
4378 ("palatino-vf"
4379 ,(origin
4380 (method svn-fetch)
4381 (uri (svn-reference
4382 (url (string-append "svn://www.tug.org/texlive/tags/"
4383 %texlive-tag "/Master/texmf-dist/"
4384 "/fonts/vf/adobe/palatino"))
4385 (revision %texlive-revision)))
4386 (file-name (string-append name "-vf-" version "-checkout"))
4387 (sha256
4388 (base32
4389 "1maqfis8hpybcn9lmm8r2b1g56620lfpsncg0742c3kkjd6dh97h"))))
4390 ("urw-afm"
4391 ,(origin
4392 (method svn-fetch)
4393 (uri (svn-reference
4394 (url (string-append "svn://www.tug.org/texlive/tags/"
4395 %texlive-tag "/Master/texmf-dist/"
4396 "/fonts/afm/urw/palatino"))
4397 (revision %texlive-revision)))
4398 (file-name (string-append name "-urw-afm-" version "-checkout"))
4399 (sha256
4400 (base32
4401 "0gk0xwy1fs2si5kb1j3dzgm52c8sagv32gd9dmw88m7sgh5qkd87"))))
4402 ("urw35vf-tfm"
4403 ,(origin
4404 (method svn-fetch)
4405 (uri (svn-reference
4406 (url (string-append "svn://www.tug.org/texlive/tags/"
4407 %texlive-tag "/Master/texmf-dist/"
4408 "/fonts/tfm/urw35vf/palatino"))
4409 (revision %texlive-revision)))
4410 (file-name (string-append name "-urw35vf-tfm-" version "-checkout"))
4411 (sha256
4412 (base32
4413 "19aq3xwfg7vkf1qzjdxgcvcdqwpvpavq3l25y64xni72qx0kmppz"))))
4414 ("urw35vf-vf"
4415 ,(origin
4416 (method svn-fetch)
4417 (uri (svn-reference
4418 (url (string-append "svn://www.tug.org/texlive/tags/"
4419 %texlive-tag "/Master/texmf-dist/"
4420 "/fonts/vf/urw35vf/palatino"))
4421 (revision %texlive-revision)))
4422 (file-name (string-append name "-urw35vf-vf-" version "-checkout"))
4423 (sha256
4424 (base32
4425 "1lkn4p6zimrs0ah6mxsang4bicp8j7xzl016529a3f168an7mdmj"))))
4426 ("palatino-tex"
4427 ,(origin
4428 (method svn-fetch)
4429 (uri (svn-reference
4430 (url (string-append "svn://www.tug.org/texlive/tags/"
4431 %texlive-tag "/Master/texmf-dist/"
4432 "/tex/latex/palatino"))
4433 (revision %texlive-revision)))
4434 (file-name (string-append name "-tex-" version "-checkout"))
4435 (sha256
4436 (base32
4437 "0ng9w7i0p1nb51amla32jj86vx6p84m6qc7asam3g4x8w5jf7s27"))))
4438 ("dvips"
4439 ,(origin
4440 (method svn-fetch)
4441 (uri (svn-reference
4442 (url (string-append "svn://www.tug.org/texlive/tags/"
4443 %texlive-tag "/Master/texmf-dist/"
4444 "/dvips/palatino/"))
4445 (revision %texlive-revision)))
4446 (file-name (string-append name "-dvips-" version "-checkout"))
4447 (sha256
4448 (base32
4449 "1pdbkfmhx4kk3brh5lg6fyl9ad2kbjmkrhgcx84klnlhq01mfdhb"))))
4450 ("fonts-map"
4451 ,(origin
4452 (method svn-fetch)
4453 (uri (svn-reference
4454 (url (string-append "svn://www.tug.org/texlive/tags/"
4455 %texlive-tag "/Master/texmf-dist/"
4456 "/fonts/map/dvips/palatino/"))
4457 (revision %texlive-revision)))
4458 (file-name (string-append name "-fonts-map-" version "-checkout"))
4459 (sha256
4460 (base32
4461 "0rg13hyp652hp3gnrj5pbyb84zkqmyi1qnm8c6spcyaq8pm06l0d"))))))
4462 (home-page "https://ctan.org/pkg/urw-base35")
4463 (synopsis "URW Base 35 font pack for LaTeX")
4464 (description
4465 "This package provides a drop-in replacements for the Palatino font from
4466Adobe's basic set.")
4467 ;; No license version specified.
4468 (license license:gpl3+)))
4469
4628315b
RW
4470(define-public texlive-fonts-adobe-zapfding
4471 (package
4472 (name "texlive-fonts-adobe-zapfding")
4473 (version (number->string %texlive-revision))
4474 (source (origin
4475 (method svn-fetch)
4476 (uri (svn-reference
4477 (url (string-append "svn://www.tug.org/texlive/tags/"
4478 %texlive-tag "/Master/texmf-dist/"
4479 "/fonts/type1/urw/zapfding/"))
4480 (revision %texlive-revision)))
4481 (file-name (string-append name "-" version "-checkout"))
4482 (sha256
4483 (base32
4484 "1sp3jblg3khp0yj121blvhph6ib09919kyrsk5x2lg258yypqyis"))))
4485 (build-system trivial-build-system)
4486 (arguments
4487 `(#:modules ((guix build utils)
4488 (ice-9 match))
4489 #:builder
4490 (begin
4491 (use-modules (guix build utils)
4492 (ice-9 match))
4493 (let ((root (string-append (assoc-ref %outputs "out")
4494 "/share/texmf-dist/"))
4495 (pkgs '(("source" . "fonts/type1/urw/zapfding")
4496 ("zapf-afm" . "fonts/afm/adobe/zapfding")
4497 ("zapf-tfm" . "fonts/tfm/adobe/zapfding")
4498 ("urw-afm" . "fonts/afm/urw/zapfding")
4499 ("urw35vf-tfm" . "fonts/tfm/urw35vf/zapfding")
4500
4501 ("zapf-tex" . "tex/latex/zapfding")
4502 ("dvips" . "dvips/zapfding")
4503 ("fonts-map" . "fonts/map/dvips/zapfding"))))
4504 (for-each (match-lambda
4505 ((pkg . dir)
4506 (let ((target (string-append root dir)))
4507 (mkdir-p target)
4508 (copy-recursively (assoc-ref %build-inputs pkg)
4509 target))))
4510 pkgs)
4511 #t))))
4512 (native-inputs
4513 `(("zapf-afm"
4514 ,(origin
4515 (method svn-fetch)
4516 (uri (svn-reference
4517 (url (string-append "svn://www.tug.org/texlive/tags/"
4518 %texlive-tag "/Master/texmf-dist/"
4519 "/fonts/afm/adobe/zapfding"))
4520 (revision %texlive-revision)))
4521 (file-name (string-append name "-afm-" version "-checkout"))
4522 (sha256
4523 (base32
4524 "0qvl4w1bfcpiakkd8rvkism46qnvzj9w7x4r8z9m0y7mspbkblyr"))))
4525 ("zapf-tfm"
4526 ,(origin
4527 (method svn-fetch)
4528 (uri (svn-reference
4529 (url (string-append "svn://www.tug.org/texlive/tags/"
4530 %texlive-tag "/Master/texmf-dist/"
4531 "/fonts/tfm/adobe/zapfding"))
4532 (revision %texlive-revision)))
4533 (file-name (string-append name "-tfm-" version "-checkout"))
4534 (sha256
4535 (base32
4536 "1i8mh9xsl8l4cgsg3nl4ha9q6m55j122riclaxsvkc5ka83432qm"))))
4537 ("urw-afm"
4538 ,(origin
4539 (method svn-fetch)
4540 (uri (svn-reference
4541 (url (string-append "svn://www.tug.org/texlive/tags/"
4542 %texlive-tag "/Master/texmf-dist/"
4543 "/fonts/afm/urw/zapfding"))
4544 (revision %texlive-revision)))
4545 (file-name (string-append name "-urw-afm-" version "-checkout"))
4546 (sha256
4547 (base32
4548 "0m4qndqh7ji723ff82c5c1q8ziqvblbaip7vx05vnl15fqbsnfx1"))))
4549 ("urw35vf-tfm"
4550 ,(origin
4551 (method svn-fetch)
4552 (uri (svn-reference
4553 (url (string-append "svn://www.tug.org/texlive/tags/"
4554 %texlive-tag "/Master/texmf-dist/"
4555 "/fonts/tfm/urw35vf/zapfding"))
4556 (revision %texlive-revision)))
4557 (file-name (string-append name "-urw35vf-tfm-" version "-checkout"))
4558 (sha256
4559 (base32
4560 "167g2x6mpjfqh0w1fhjbw14qcx6ridrj2zm1bd8bi0l2d7phj28m"))))
4561 ("zapf-tex"
4562 ,(origin
4563 (method svn-fetch)
4564 (uri (svn-reference
4565 (url (string-append "svn://www.tug.org/texlive/tags/"
4566 %texlive-tag "/Master/texmf-dist/"
4567 "/tex/latex/zapfding"))
4568 (revision %texlive-revision)))
4569 (file-name (string-append name "-tex-" version "-checkout"))
4570 (sha256
4571 (base32
4572 "0hp7i8f6nbrg7irrwc8fd7n1hrzjysa84d6iyivwlc65v9p7lmd0"))))
4573 ("dvips"
4574 ,(origin
4575 (method svn-fetch)
4576 (uri (svn-reference
4577 (url (string-append "svn://www.tug.org/texlive/tags/"
4578 %texlive-tag "/Master/texmf-dist/"
4579 "/dvips/zapfding/"))
4580 (revision %texlive-revision)))
4581 (file-name (string-append name "-dvips-" version "-checkout"))
4582 (sha256
4583 (base32
4584 "1f18sc4qwxykd786zhn6szcrycqvpvfhlcim71aamxmwghakd7fa"))))
4585 ("fonts-map"
4586 ,(origin
4587 (method svn-fetch)
4588 (uri (svn-reference
4589 (url (string-append "svn://www.tug.org/texlive/tags/"
4590 %texlive-tag "/Master/texmf-dist/"
4591 "/fonts/map/dvips/zapfding/"))
4592 (revision %texlive-revision)))
4593 (file-name (string-append name "-fonts-map-" version "-checkout"))
4594 (sha256
4595 (base32
4596 "17kwxmdrgz2fb072hx57a3pidcrhbgayphx11zyld2hv9149pkyl"))))))
4597 (home-page "https://ctan.org/pkg/urw-base35")
4598 (synopsis "URW Base 35 font pack for LaTeX")
4599 (description
4600 "This package provides a drop-in replacements for the Zapfding font from
4601Adobe's basic set.")
4602 ;; No license version specified.
4603 (license license:gpl3+)))
4604
f45a5520
RW
4605(define-public texlive-fonts-rsfs
4606 (package
4607 (name "texlive-fonts-rsfs")
4608 (version (number->string %texlive-revision))
4609 (source (origin
4610 (method svn-fetch)
4611 (uri (svn-reference
4612 (url (string-append "svn://www.tug.org/texlive/tags/"
4613 %texlive-tag "/Master/texmf-dist/"
4614 "/fonts/source/public/rsfs/"))
4615 (revision %texlive-revision)))
e26de9c9 4616 (file-name (string-append name "-" version "-checkout"))
f45a5520
RW
4617 (sha256
4618 (base32
4619 "0r12pn02r4a955prcvq0048nifh86ihlcgvw3pppqqvfngv34l5h"))))
4620 (build-system gnu-build-system)
4621 (arguments
4622 `(#:modules ((guix build gnu-build-system)
4623 (guix build utils)
4624 (srfi srfi-1)
4625 (srfi srfi-26))
4626 #:tests? #f ; no tests
4627 #:phases
4628 (modify-phases %standard-phases
4629 (delete 'configure)
4630 (replace 'build
4631 (lambda* (#:key inputs #:allow-other-keys)
4632 (let ((mf (assoc-ref inputs "texlive-metafont-base")))
4633 ;; Tell mf where to find mf.base
4634 (setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
4635 ;; Tell mf where to look for source files
4636 (setenv "MFINPUTS"
4637 (string-append (getcwd) ":"
4638 mf "/share/texmf-dist/metafont/base:"
4639 (assoc-ref inputs "texlive-fonts-cm")
4640 "/share/texmf-dist/fonts/source/public/cm")))
4641 (mkdir "build")
d8ac82c2
MW
4642 (for-each (lambda (font)
4643 (format #t "building font ~a\n" font)
4644 (invoke "mf" "-progname=mf"
4645 "-output-directory=build"
4646 (string-append "\\"
4647 "mode:=ljfour; "
4648 "mag:=1; "
4649 "batchmode; "
4650 "input " (basename font ".mf"))))
4651 (find-files "." "[0-9]+\\.mf$"))
4652 #t))
f45a5520
RW
4653 (replace 'install
4654 (lambda* (#:key outputs #:allow-other-keys)
4655 (let* ((out (assoc-ref outputs "out"))
4656 (tfm (string-append
4657 out "/share/texmf-dist/fonts/tfm/public/rsfs"))
4658 (mf (string-append
4659 out "/share/texmf-dist/fonts/source/public/rsfs")))
4660 (for-each (cut install-file <> tfm)
4661 (find-files "build" "\\.*"))
4662 (for-each (cut install-file <> mf)
4663 (find-files "." "\\.mf"))
4664 #t))))))
4665 (native-inputs
4666 `(("texlive-bin" ,texlive-bin)
4667 ("texlive-metafont-base" ,texlive-metafont-base)
4668 ("texlive-fonts-cm" ,texlive-fonts-cm)))
b8d8806b 4669 (home-page "https://www.ctan.org/pkg/rsfs")
f45a5520
RW
4670 (synopsis "Ralph Smith's Formal Script font")
4671 (description
4672 "The fonts provide uppercase formal script letters for use as symbols in
4673scientific and mathematical typesetting (in contrast to the informal script
4674fonts such as that used for the calligraphic symbols in the TeX maths symbol
4675font). The fonts are provided as Metafont source, and as derived Adobe Type 1
4676format. LaTeX support, for using these fonts in mathematics, is available via
4677one of the packages @code{calrsfs} and @code{mathrsfs}.")
4678 (license (license:fsf-free "http://mirrors.ctan.org/fonts/rsfs/README"))))
4679
1562763c
RW
4680(define-public texlive-latex-eso-pic
4681 (package
4682 (name "texlive-latex-eso-pic")
4683 (version (number->string %texlive-revision))
4684 (source (origin
4685 (method svn-fetch)
4686 (uri (texlive-ref "latex" "eso-pic"))
2678a63b 4687 (file-name (string-append name "-" version "-checkout"))
1562763c
RW
4688 (sha256
4689 (base32
4690 "1xvmms28mvvfpks9x7lfya2xhh5k8jy3qnlih1mzcnf156xnb89z"))))
4691 (build-system texlive-build-system)
4692 (arguments '(#:tex-directory "latex/eso-pic"))
b8d8806b 4693 (home-page "https://www.ctan.org/pkg/eso-pic")
1562763c
RW
4694 (synopsis "Add picture commands (or backgrounds) to every page")
4695 (description
4696 "The package adds one or more user commands to LaTeX's @code{shipout}
4697routine, which may be used to place the output at fixed positions. The
4698@code{grid} option may be used to find the correct places.")
4699 (license license:lppl1.3+)))
4700
ae3779d5
RW
4701(define-public texlive-latex-eepic
4702 (package
4703 (name "texlive-latex-eepic")
4704 (version (number->string %texlive-revision))
4705 (source (origin
4706 (method svn-fetch)
4707 (uri (svn-reference
4708 (url (string-append "svn://www.tug.org/texlive/tags/"
4709 %texlive-tag "/Master/texmf-dist/"
4710 "/tex/latex/eepic"))
4711 (revision %texlive-revision)))
84d63643 4712 (file-name (string-append name "-" version "-checkout"))
ae3779d5
RW
4713 (sha256
4714 (base32
4715 "1c68gvh021pvybg07apsd2xhq2ljbg80kq94wh71drdga3c2zqjw"))))
4716 (build-system trivial-build-system)
4717 (arguments
4718 `(#:modules ((guix build utils))
4719 #:builder
4720 (begin
4721 (use-modules (guix build utils))
4722 (let ((target (string-append (assoc-ref %outputs "out")
4723 "/share/texmf-dist/tex/latex/eepic")))
4724 (mkdir-p target)
4725 (copy-recursively (assoc-ref %build-inputs "source") target)
4726 #t))))
b8d8806b 4727 (home-page "https://www.ctan.org/pkg/eepic")
ae3779d5
RW
4728 (synopsis "Extensions to epic and the LaTeX drawing tools")
4729 (description
4730 "Extensions to @code{epic} and the LaTeX picture drawing environment,
4731include the drawing of lines at any slope, the drawing of circles in any
4732radii, and the drawing of dotted and dashed lines much faster with much less
4733TeX memory, and providing several new commands for drawing ellipses, arcs,
4734splines, and filled circles and ellipses. The package uses @code{tpic}
4735@code{\\special} commands.")
4736 (license license:public-domain)))
4737
245f1f31
RW
4738(define-public texlive-latex-enumitem
4739 (package
4740 (name "texlive-latex-enumitem")
4741 (version (number->string %texlive-revision))
4742 (source (origin
4743 (method svn-fetch)
4744 (uri (svn-reference
4745 (url (string-append "svn://www.tug.org/texlive/tags/"
4746 %texlive-tag "/Master/texmf-dist/"
4747 "/tex/latex/enumitem"))
4748 (revision %texlive-revision)))
4749 (file-name (string-append name "-" version "-checkout"))
4750 (sha256
4751 (base32
4752 "0q24b1bkdi9l6bw787bpggww83jh2vj8955aw2m5yccqbx4vgr5r"))))
4753 (build-system trivial-build-system)
4754 (arguments
4755 `(#:modules ((guix build utils))
4756 #:builder
4757 (begin
4758 (use-modules (guix build utils))
4759 (let ((target (string-append (assoc-ref %outputs "out")
4760 "/share/texmf-dist/tex/latex/enumitem")))
4761 (mkdir-p target)
4762 (copy-recursively (assoc-ref %build-inputs "source") target)
4763 #t))))
b8d8806b 4764 (home-page "https://www.ctan.org/pkg/enumitem")
245f1f31
RW
4765 (synopsis "Customize basic list environments")
4766 (description
4767 "This package is intended to ease customizing the three basic list
4768environments: @code{enumerate}, @code{itemize} and @code{description}. It
4769extends their syntax to allow an optional argument where a set of parameters
4770in the form @code{key=value} are available, for example:
4771@code{\\begin{itemize}[itemsep=1ex,leftmargin=1cm]}.")
4772 (license license:lppl1.3+)))
4773
ecffeeb5
RW
4774(define-public texlive-latex-multirow
4775 (package
4776 (name "texlive-latex-multirow")
4777 (version (number->string %texlive-revision))
4778 (source (origin
4779 (method svn-fetch)
4780 (uri (texlive-ref "latex" "multirow"))
6a919804 4781 (file-name (string-append name "-" version "-checkout"))
ecffeeb5
RW
4782 (sha256
4783 (base32
4784 "0qlxy47f1f8plgch3jqfsnrdgpyz20sz46yp33i2jwvf9hvfczf0"))))
4785 (build-system texlive-build-system)
4786 (arguments '(#:tex-directory "latex/multirow"))
b8d8806b 4787 (home-page "https://www.ctan.org/pkg/multirow")
ecffeeb5
RW
4788 (synopsis "Create tabular cells spanning multiple rows")
4789 (description
4790 "The package provides tools for creating tabular cells spanning multiple
4791rows. It has a lot of flexibility, including an option for specifying an
4792entry at the \"natural\" width of its text.")
4793 (license license:lppl1.3+)))
4794
da38b235
RW
4795(define-public texlive-latex-overpic
4796 (package
4797 (name "texlive-latex-overpic")
4798 (version (number->string %texlive-revision))
4799 (source (origin
4800 (method svn-fetch)
4801 (uri (svn-reference
4802 (url (string-append "svn://www.tug.org/texlive/tags/"
4803 %texlive-tag "/Master/texmf-dist/"
4804 "/tex/latex/overpic"))
4805 (revision %texlive-revision)))
b2aef721 4806 (file-name (string-append name "-" version "-checkout"))
da38b235
RW
4807 (sha256
4808 (base32
d4d9a1ec 4809 "1rpx4ibjncj5416rg19v0xjbj3z9avhfdfn2gzp8r8sz9vz25c6g"))))
da38b235
RW
4810 (build-system trivial-build-system)
4811 (arguments
4812 `(#:modules ((guix build utils))
4813 #:builder
4814 (begin
4815 (use-modules (guix build utils))
4816 (let ((target (string-append (assoc-ref %outputs "out")
4817 "/share/texmf-dist/tex/latex/overpic")))
4818 (mkdir-p target)
4819 (copy-recursively (assoc-ref %build-inputs "source") target)
4820 #t))))
b8d8806b 4821 (home-page "https://www.ctan.org/pkg/overpic")
da38b235
RW
4822 (synopsis "Combine LaTeX commands over included graphics")
4823 (description
4824 "The @code{overpic} environment is a cross between the LaTeX
4825@code{picture} environment and the @code{\\includegraphics} command of
4826@code{graphicx}. The resulting picture environment has the same dimensions as
4827the included graphic. LaTeX commands can be placed on the graphic at defined
4828positions; a grid for orientation is available.")
4829 (license license:lppl1.0+)))
4830
e0d307d1
RW
4831(define-public texlive-latex-parskip
4832 (package
4833 (name "texlive-latex-parskip")
4834 (version (number->string %texlive-revision))
4835 (source (origin
4836 (method svn-fetch)
4837 (uri (svn-reference
4838 (url (string-append "svn://www.tug.org/texlive/tags/"
4839 %texlive-tag "/Master/texmf-dist/"
4840 "/tex/latex/parskip"))
4841 (revision %texlive-revision)))
4842 (file-name (string-append name "-" version "-checkout"))
4843 (sha256
4844 (base32
4845 "14r6h9hqb0qgccxj5l1208694fx8sb8avmgzps36lsbbpszl7i7m"))))
4846 (build-system trivial-build-system)
4847 (arguments
4848 `(#:modules ((guix build utils))
4849 #:builder
4850 (begin
4851 (use-modules (guix build utils))
4852 (let ((target (string-append (assoc-ref %outputs "out")
4853 "/share/texmf-dist/tex/latex/parskip")))
4854 (mkdir-p target)
4855 (copy-recursively (assoc-ref %build-inputs "source") target)
4856 #t))))
b8d8806b 4857 (home-page "https://www.ctan.org/pkg/parskip")
e0d307d1
RW
4858 (synopsis "Layout with zero \\parindent, non-zero \\parskip")
4859 (description
4860 "Simply changing @code{\\parskip} and @code{\\parindent} leaves a layout
4861that is untidy; this package (though it is no substitute for a properly
4862designed class) helps alleviate this untidiness.")
4863 (license license:lppl)))
4864
adc02c70
RW
4865(define-public texlive-latex-pdfpages
4866 (package
4867 (name "texlive-latex-pdfpages")
4868 (version (number->string %texlive-revision))
4869 (source (origin
4870 (method svn-fetch)
4871 (uri (texlive-ref "latex" "pdfpages"))
7372ce18 4872 (file-name (string-append name "-" version "-checkout"))
adc02c70
RW
4873 (sha256
4874 (base32
d4d9a1ec 4875 "0s4izcah7im67889qz4d26pcfpasmm35sj1rw4ragkkdk3rlbbbd"))))
adc02c70
RW
4876 (build-system texlive-build-system)
4877 (arguments '(#:tex-directory "latex/pdfpages"))
b8d8806b 4878 (home-page "https://www.ctan.org/pkg/pdfpages")
adc02c70
RW
4879 (synopsis "Include PDF documents in LaTeX")
4880 (description
4881 "This package simplifies the inclusion of external multi-page PDF
4882documents in LaTeX documents. Pages may be freely selected and it is possible
4883to put several logical pages onto each sheet of paper. Furthermore a lot of
4884hypertext features like hyperlinks and article threads are provided. The
4885package supports pdfTeX (pdfLaTeX) and VTeX. With VTeX it is even possible to
4886use this package to insert PostScript files, in addition to PDF files.")
4887 (license license:lppl1.3+)))
4888
d8fef6ea
RW
4889(define-public texlive-fonts-stmaryrd
4890 (package
4891 (name "texlive-fonts-stmaryrd")
4892 (version (number->string %texlive-revision))
4893 (source (origin
4894 (method svn-fetch)
4895 (uri (texlive-ref "fonts" "stmaryrd"))
19835372 4896 (file-name (string-append name "-" version "-checkout"))
d8fef6ea
RW
4897 (sha256
4898 (base32
4899 "08pn4ca3vl6qm9l3wm5h5iyjsrg411kkm1yana329xwg2j14s9n6"))))
4900 (build-system texlive-build-system)
4901 (arguments
4902 '(#:tex-directory "latex/stmaryrd"
4903 #:phases
4904 (modify-phases %standard-phases
4905 (add-after 'configure 'patch-ins
4906 (lambda _
4907 (substitute* "stmaryrd.ins"
4908 (("^%% LaTeX2e.*") "\\input docstrip\n")
4909 (("fontdef\\}\\}" line)
4910 (string-append line "\n\\endbatchfile")))
4911 #t)))))
b8d8806b 4912 (home-page "https://www.ctan.org/pkg/stmaryrd")
d8fef6ea
RW
4913 (synopsis "St Mary Road symbols for theoretical computer science")
4914 (description
4915 "The fonts were originally distributed as Metafont sources only, but
4916Adobe Type 1 versions are also now available. Macro support is provided for
4917use under LaTeX; the package supports the @code{only} option (provided by the
4918@code{somedefs} package) to restrict what is loaded, for those who don't need
4919the whole font.")
4920 (license license:lppl)))
4921
2db3a034
RW
4922(define-public texlive-latex-subfigure
4923 (package
4924 (name "texlive-latex-subfigure")
4925 (version (number->string %texlive-revision))
4926 (source (origin
4927 (method svn-fetch)
4928 (uri (texlive-ref "latex" "subfigure"))
e1834df6 4929 (file-name (string-append name "-" version "-checkout"))
2db3a034
RW
4930 (sha256
4931 (base32
4932 "15spcl5wb7w269qd6y596vp4yi8sa5ppcx8w4z2i9kyp02r3a0yb"))))
4933 (build-system texlive-build-system)
4934 (arguments '(#:tex-directory "latex/subfigure"))
b8d8806b 4935 (home-page "https://www.ctan.org/pkg/subfigure")
2db3a034
RW
4936 (synopsis "Figures divided into subfigures")
4937 (description
4938 "This (deprecated) package provides support for the manipulation and
4939reference of small or \"sub\" figures and tables within a single figure or
4940table environment. It is convenient to use this package when your subfigures
4941are to be separately captioned, referenced, or are to be included in the
4942List-of-Figures. A new @code{\\subfigure} command is introduced which can be
4943used inside a figure environment for each subfigure. An optional first
4944argument is used as the caption for that subfigure. The package is now
4945considered obsolete: it was superseded by @code{subfig}, but users may find
4946the more recent @code{subcaption} package more satisfactory.")
4947 (license license:lppl)))
4948
c73d0e9d
RW
4949(define-public texlive-latex-tabulary
4950 (package
4951 (name "texlive-latex-tabulary")
4952 (version (number->string %texlive-revision))
4953 (source (origin
4954 (method svn-fetch)
4955 (uri (texlive-ref "latex" "tabulary"))
4956 (file-name (string-append name "-" version "-checkout"))
4957 (sha256
4958 (base32
4959 "1adkdx2zkk42g82nqf57lv1nc1z7kwl13jmy8vpcsizsa0xdnx9n"))))
4960 (build-system texlive-build-system)
4961 (arguments '(#:tex-directory "latex/tabulary"))
b8d8806b 4962 (home-page "https://www.ctan.org/pkg/tabulary")
c73d0e9d
RW
4963 (synopsis "Tabular with variable width columns balanced")
4964 (description
4965 "The package defines a @code{tabular*}-like environment, @code{tabulary},
4966taking a \"total width\" argument as well as the column specifications. The
4967environment uses column types @code{L}, @code{C}, @code{R} and @code{J} for
4968variable width columns (@code{\\raggedright}, @code{\\centering},
4969@code{\\raggedleft}, and normally justified). In contrast to
4970@code{tabularx}'s @code{X} columns, the width of each column is weighted
4971according to the natural width of the widest cell in the column.")
4972 (license license:lppl)))
4973
e3088297
RW
4974(define-public texlive-latex-threeparttable
4975 (package
4976 (name "texlive-latex-threeparttable")
4977 (version (number->string %texlive-revision))
4978 (source (origin
4979 (method svn-fetch)
4980 (uri (svn-reference
4981 (url (string-append "svn://www.tug.org/texlive/tags/"
4982 %texlive-tag "/Master/texmf-dist/"
4983 "/tex/latex/threeparttable"))
4984 (revision %texlive-revision)))
d57e5d41 4985 (file-name (string-append name "-" version "-checkout"))
e3088297
RW
4986 (sha256
4987 (base32
4988 "10vy9k150w2lviw8h22s2mcykff38xci653m5823s2vv44pwbmzq"))))
4989 (build-system trivial-build-system)
4990 (arguments
4991 `(#:modules ((guix build utils))
4992 #:builder
4993 (begin
4994 (use-modules (guix build utils))
4995 (let ((target (string-append (assoc-ref %outputs "out")
4996 "/share/texmf-dist/tex/latex/threeparttable")))
4997 (mkdir-p target)
4998 (copy-recursively (assoc-ref %build-inputs "source") target)
4999 #t))))
b8d8806b 5000 (home-page "https://www.ctan.org/pkg/threeparttable")
e3088297
RW
5001 (synopsis "Tables with captions and notes all the same width")
5002 (description
5003 "This package facilitates tables with titles (captions) and notes. The
5004title and notes are given a width equal to the body of the table (a
5005@code{tabular} environment). By itself, a @code{threeparttable} does not
5006float, but you can put it in a @code{table} or a @code{table*} or some other
5007environment.")
5008 (license (license:fsf-free "file://threeparttable.sty"))))
5009
1b10d494
RW
5010(define-public texlive-fonts-txfonts
5011 (package
5012 (name "texlive-fonts-txfonts")
5013 (version (number->string %texlive-revision))
5014 (source (origin
5015 (method svn-fetch)
5016 (uri (svn-reference
5017 (url (string-append "svn://www.tug.org/texlive/tags/"
5018 %texlive-tag "/Master/texmf-dist/"
5019 "/tex/latex/txfonts"))
5020 (revision %texlive-revision)))
5021 (file-name (string-append name "-" version "-checkout"))
5022 (sha256
5023 (base32
5024 "0jl921qdphg8i7bkfprackn3xd4gmvxckc526nmzqsmahqkavgg2"))))
5025 (build-system trivial-build-system)
5026 (arguments
5027 `(#:modules ((guix build utils)
5028 (ice-9 match))
5029 #:builder
5030 (begin
5031 (use-modules (guix build utils)
5032 (ice-9 match))
5033 (let ((root (string-append (assoc-ref %outputs "out")
5034 "/share/texmf-dist/"))
5035 (pkgs '(("source" . "tex/latex/txfonts")
5036 ("txfonts-vf" . "fonts/tfm/public/txfonts")
5037 ("txfonts-afm" . "fonts/afm/public/txfonts")
5038 ("txfonts-tfm" . "fonts/tfm/public/txfonts")
5039 ("txfonts-type1" . "fonts/type1/public/txfonts")
5040 ("txfonts-enc" . "fonts/enc/dvips/txfonts")
5041 ("txfonts-map" . "fonts/map/dvips/txfonts"))))
5042 (for-each (match-lambda
5043 ((pkg . dir)
5044 (let ((target (string-append root dir)))
5045 (mkdir-p target)
5046 (copy-recursively (assoc-ref %build-inputs pkg)
5047 target))))
5048 pkgs)
5049 #t))))
5050 (native-inputs
5051 `(("txfonts-tfm"
5052 ,(origin
5053 (method svn-fetch)
5054 (uri (svn-reference
5055 (url (string-append "svn://www.tug.org/texlive/tags/"
5056 %texlive-tag "/Master/texmf-dist/"
5057 "/fonts/tfm/public/txfonts"))
5058 (revision %texlive-revision)))
5059 (file-name (string-append name "-tfm-" version "-checkout"))
5060 (sha256
5061 (base32
5062 "12ffmbrp48ap35qa3b4mi6ckif9q2vf7972jxh5dc1yzykhla2xv"))))
5063 ("txfonts-vf"
5064 ,(origin
5065 (method svn-fetch)
5066 (uri (svn-reference
5067 (url (string-append "svn://www.tug.org/texlive/tags/"
5068 %texlive-tag "/Master/texmf-dist/"
5069 "/fonts/vf/public/txfonts"))
5070 (revision %texlive-revision)))
5071 (file-name (string-append name "-vf-" version "-checkout"))
5072 (sha256
5073 (base32
5074 "04acyfdwvxpfx4l2xh2bpzdmpvwdf2pzbs7a236b0xckz2jvc1ci"))))
5075 ("txfonts-afm"
5076 ,(origin
5077 (method svn-fetch)
5078 (uri (svn-reference
5079 (url (string-append "svn://www.tug.org/texlive/tags/"
5080 %texlive-tag "/Master/texmf-dist/"
5081 "/fonts/afm/public/txfonts"))
5082 (revision %texlive-revision)))
5083 (file-name (string-append name "-afm-" version "-checkout"))
5084 (sha256
5085 (base32
5086 "1705klz51pnqzcs89s3521b84b6c89wlczflsh0vci66nl155yis"))))
5087 ("txfonts-type1"
5088 ,(origin
5089 (method svn-fetch)
5090 (uri (svn-reference
5091 (url (string-append "svn://www.tug.org/texlive/tags/"
5092 %texlive-tag "/Master/texmf-dist/"
5093 "/fonts/type1/public/txfonts"))
5094 (revision %texlive-revision)))
5095 (file-name (string-append name "-type1-" version "-checkout"))
5096 (sha256
5097 (base32
5098 "0ajwr7zb6ch3gxd0g8p2i4llhy2wr9a9saz6jq6hm6fxf4pgl5h3"))))
5099 ("txfonts-map"
5100 ,(origin
5101 (method svn-fetch)
5102 (uri (svn-reference
5103 (url (string-append "svn://www.tug.org/texlive/tags/"
5104 %texlive-tag "/Master/texmf-dist/"
5105 "/fonts/map/dvips/txfonts"))
5106 (revision %texlive-revision)))
5107 (file-name (string-append name "-map-" version "-checkout"))
5108 (sha256
5109 (base32
5110 "0kamr8a9x24jakas3v09dgv7kkpybj3i7qv4vz1iyypqr6kk1raj"))))
5111 ("txfonts-enc"
5112 ,(origin
5113 (method svn-fetch)
5114 (uri (svn-reference
5115 (url (string-append "svn://www.tug.org/texlive/tags/"
5116 %texlive-tag "/Master/texmf-dist/"
5117 "/fonts/enc/dvips/txfonts"))
5118 (revision %texlive-revision)))
5119 (file-name (string-append name "-enc-" version "-checkout"))
5120 (sha256
5121 (base32
5122 "1bal5fhw0xlhl37ayv8vlnqnsn1y82kadzfjhbgr223blspp4zsj"))))))
b8d8806b 5123 (home-page "https://www.ctan.org/pkg/threeparttable")
1b10d494
RW
5124 (synopsis "Times-like fonts in support of mathematics")
5125 (description
5126 "Txfonts supplies virtual text roman fonts using Adobe Times (or URW
5127NimbusRomNo9L) with some modified and additional text symbols in the OT1, T1,
5128and TS1 encodings; maths alphabets using Times/URW Nimbus; maths fonts
5129providing all the symbols of the Computer Modern and AMS fonts, including all
5130the Greek capital letters from CMR; and additional maths fonts of various
5131other symbols.
5132
5133The set is complemented by a sans-serif set of text fonts, based on
5134Helvetica/NimbusSanL, and a monospace set.
5135
5136All the fonts are in Type 1 format (AFM and PFB files), and are supported by
5137TeX metrics (VF and TFM files) and macros for use with LaTeX.")
5138 ;; Any version of the GPL with font exception.
5139 (license license:gpl3+)))
5140
f9e0fcb2
RW
5141(define-public texlive-fonts-iwona
5142 (package
5143 (name "texlive-fonts-iwona")
5144 (version "0.995b")
5145 (source (origin
5146 (method url-fetch)
5147 (uri (string-append "http://jmn.pl/pliki/Iwona-tex-"
5148 (string-map (lambda (c)
5149 (if (char=? c #\.)
5150 #\_ c))
5151 version)
5152 ".zip"))
5153 (sha256
5154 (base32
5155 "13684iqx5granpc5rfvqnmyvdpgpbr1x9y7i7y7bcaq0qxv7ph1x"))))
5156 (build-system trivial-build-system)
5157 (arguments
5158 `(#:modules ((guix build utils))
5159 #:builder
5160 (begin
5161 (use-modules (guix build utils))
5162 (let ((target (string-append (assoc-ref %outputs "out")
5163 "/share/texmf-dist/"))
5164 (unzip (string-append (assoc-ref %build-inputs "unzip")
5165 "/bin/unzip")))
e3cfef22 5166 (invoke unzip (assoc-ref %build-inputs "source"))
f9e0fcb2 5167 (mkdir-p target)
e3cfef22
MW
5168 (copy-recursively "iwona" target)
5169 #t))))
f9e0fcb2
RW
5170 (native-inputs
5171 `(("unzip" ,unzip)))
5172 (home-page "http://jmn.pl/en/kurier-i-iwona/")
5173 (synopsis "Sans-serif typeface for TeX")
5174 (description "Iwona is a two-element sans-serif typeface. It was created
5175as an alternative version of the Kurier typeface, which was designed in 1975
5176for a diploma in typeface design at the Warsaw Academy of Fine Arts under the
5177supervision of Roman Tomaszewski. Kurier was designed for linotype
5178typesetting of newspapers and similar periodicals. The Iwona fonts are an
5179alternative version of the Kurier fonts. The difference lies in the absence
5180of ink traps which typify the Kurier font.")
5181 (license license:gfl1.0)))
5182
acc620d6
RW
5183(define-public texlive-latex-titlesec
5184 (package
5185 (name "texlive-latex-titlesec")
5186 (version (number->string %texlive-revision))
5187 (source (origin
5188 (method svn-fetch)
5189 (uri (svn-reference
5190 (url (string-append "svn://www.tug.org/texlive/tags/"
5191 %texlive-tag "/Master/texmf-dist/"
5192 "/tex/latex/titlesec"))
5193 (revision %texlive-revision)))
0475e35c 5194 (file-name (string-append name "-" version "-checkout"))
acc620d6
RW
5195 (sha256
5196 (base32
5197 "04nmkhqx6jxcxx9a30zbcd5smxi5fd0cbp132bki7fnvhspnhg21"))))
5198 (build-system trivial-build-system)
5199 (arguments
5200 `(#:modules ((guix build utils))
5201 #:builder
5202 (begin
5203 (use-modules (guix build utils))
5204 (let ((target (string-append (assoc-ref %outputs "out")
5205 "/share/texmf-dist/tex/latex/titlesec")))
5206 (mkdir-p target)
5207 (copy-recursively (assoc-ref %build-inputs "source") target)
5208 #t))))
b8d8806b 5209 (home-page "https://www.ctan.org/pkg/titlesec")
acc620d6
RW
5210 (synopsis "Select alternative section titles")
5211 (description
5212 "This package provides an interface to sectioning commands for selection
5213from various title styles, e.g. for marginal titles and to change the font of
5214all headings with a single command, also providing simple one-step page
5215styles. It also includes a package to change the page styles when there are
5216floats in a page. You may assign headers/footers to individual floats, too.")
5217 (license license:lppl)))
5218
274e3d4f
RW
5219(define-public texlive-latex-type1cm
5220 (package
5221 (name "texlive-latex-type1cm")
5222 (version (number->string %texlive-revision))
5223 (source (origin
5224 (method svn-fetch)
5225 (uri (texlive-ref "latex" "type1cm"))
5226 (file-name (string-append name "-" version "-checkout"))
5227 (sha256
5228 (base32
5229 "1lvxrqfwcwa4p31zyfm80gr05v8c28xybv5ri79zi2ngz6834z12"))))
5230 (build-system texlive-build-system)
5231 (arguments '(#:tex-directory "latex/type1cm"))
b8d8806b 5232 (home-page "https://www.ctan.org/pkg/type1cm")
274e3d4f
RW
5233 (synopsis "Arbitrary size font selection in LaTeX")
5234 (description
5235 "LaTeX, by default, restricts the sizes at which you can use its default
5236computer modern fonts, to a fixed set of discrete sizes (effectively, a set
5237specified by Knuth). The @code{type1cm} package removes this restriction;
5238this is particularly useful when using scalable versions of the CM
5239fonts (Bakoma, or the versions from BSR/Y&Y, or True Type versions from Kinch,
5240PCTeX, etc.). In fact, since modern distributions will automatically generate
5241any bitmap font you might need, @code{type1cm} has wider application than just
36a17f05 5242those using scalable versions of the fonts. Note that the LaTeX distribution
274e3d4f
RW
5243now contains a package @code{fix-cm},f which performs the task of
5244@code{type1cm}, as well as doing the same job for T1- and TS1-encoded
5245@code{ec} fonts.")
5246 (license license:lppl)))
5247
406af0d6
RW
5248(define-public texlive-latex-lh
5249 (package
5250 (name "texlive-latex-lh")
5251 (version (number->string %texlive-revision))
5252 (source (origin
5253 (method svn-fetch)
5254 (uri (texlive-ref "latex" "lh"))
de20fd6a 5255 (file-name (string-append name "-" version "-checkout"))
406af0d6
RW
5256 (sha256
5257 (base32
5258 "00gdiwh3sfhh1iimjhpja7lm7k4vzqzql2irgwnpz94qvh25zwi5"))))
5259 (build-system texlive-build-system)
5260 (arguments '(#:tex-directory "latex/lh"))
b8d8806b 5261 (home-page "https://www.ctan.org/pkg/lh")
406af0d6
RW
5262 (synopsis "Cyrillic fonts that support LaTeX standard encodings")
5263 (description
5264 "The LH fonts address the problem of the wide variety of alphabets that
5265are written with Cyrillic-style characters. The fonts are the original basis
5266of the set of T2* and X2 encodings that are now used when LaTeX users need to
5267write in Cyrillic languages. Macro support in standard LaTeX encodings is
5268offered through the latex-cyrillic and t2 bundles, and the package itself
5269offers support for other (more traditional) encodings. The fonts, in the
5270standard T2* and X2 encodings are available in Adobe Type 1 format, in the
5271CM-Super family of fonts. The package also offers its own LaTeX support for
5272OT2 encoded fonts, CM bright shaped fonts and Concrete shaped fonts.")
5273 (license license:lppl)))
5274
44436def
RW
5275(define-public texlive-metapost
5276 (package
5277 (name "texlive-metapost")
5278 (version (number->string %texlive-revision))
5279 (source (origin
5280 (method svn-fetch)
5281 (uri (svn-reference
5282 (url (string-append "svn://www.tug.org/texlive/tags/"
5283 %texlive-tag "/Master/texmf-dist/"
5284 "/metapost"))
5285 (revision %texlive-revision)))
b4bb2750 5286 (file-name (string-append name "-" version "-checkout"))
44436def
RW
5287 (sha256
5288 (base32
d4d9a1ec 5289 "0sf18pc6chgy26p9bxxn44xcqhzjrfb53jxjr2y7l3jb6xllhblq"))))
44436def
RW
5290 (build-system trivial-build-system)
5291 (arguments
5292 `(#:modules ((guix build utils))
5293 #:builder
5294 (begin
5295 (use-modules (guix build utils))
5296 (let ((target (string-append (assoc-ref %outputs "out")
5297 "/share/texmf-dist/metapost")))
5298 (mkdir-p target)
5299 (copy-recursively (assoc-ref %build-inputs "source") target)
5300 #t))))
b8d8806b 5301 (home-page "https://www.ctan.org/pkg/metapost")
44436def
RW
5302 (synopsis "Create scalable illustrations")
5303 (description
5304 "MetaPost uses a language based on that of Metafont to produce precise
5305technical illustrations. Its output is scalable PostScript or SVG, rather
5306than the bitmaps Metafont creates.")
5307 (license license:lppl)))
5308
9ff7161a
LC
5309(define-public texlive-latex-acmart
5310 (package
5311 (name "texlive-latex-acmart")
ff281acc 5312 (version "1.60")
9ff7161a
LC
5313 (source (origin
5314 (method svn-fetch)
5315 (uri (texlive-ref "latex" "acmart"))
5316 (sha256
5317 (base32
ff281acc 5318 "0n62cs8dhcbn29y9ij1nnyigzr76yhk36kyahhqkkmvbafbys9s7"))
9ff7161a
LC
5319 (file-name (string-append name "-" version "-checkout"))))
5320 (build-system texlive-build-system)
5321 (arguments '(#:tex-directory "latex/acmart"))
b8d8806b 5322 (home-page "https://www.ctan.org/pkg/acmart")
9ff7161a
LC
5323 (synopsis "Class for typesetting publications of ACM")
5324 (description
5325 "This package provides a class for typesetting publications of the
5326Association for Computing Machinery (ACM).")
5327 (license license:lppl1.3+)))
5328
3966ebbb
RW
5329(define-public texlive-latex-varwidth
5330 (package
5331 (name "texlive-latex-varwidth")
5332 (version (number->string %texlive-revision))
5333 (source (origin
5334 (method svn-fetch)
5335 (uri (svn-reference
5336 (url (string-append "svn://www.tug.org/texlive/tags/"
5337 %texlive-tag "/Master/texmf-dist/"
5338 "/tex/latex/varwidth"))
5339 (revision %texlive-revision)))
5340 (file-name (string-append name "-" version "-checkout"))
5341 (sha256
5342 (base32
5343 "1bmz9ap0ffyg7qry2xi7lki06qx4809w028xvk88cl66h7p46g52"))))
5344 (build-system trivial-build-system)
5345 (arguments
5346 `(#:modules ((guix build utils))
5347 #:builder
5348 (begin
5349 (use-modules (guix build utils))
5350 (let ((target (string-append (assoc-ref %outputs "out")
5351 "/share/texmf-dist/tex/latex/varwidth")))
5352 (mkdir-p target)
5353 (copy-recursively (assoc-ref %build-inputs "source") target)
5354 #t))))
b8d8806b 5355 (home-page "https://www.ctan.org/pkg/varwidth")
3966ebbb
RW
5356 (synopsis "Variable-width minipage")
5357 (description
5358 "The @code{varwidth} environment is superficially similar to
5359@code{minipage}, but the specified width is just a maximum value — the box may
5360get a narrower “natural” width.")
5361 (license license:lppl)))
5362
cd2c77f4
RW
5363(define-public texlive-latex-wasysym
5364 (package
5365 (name "texlive-latex-wasysym")
5366 (version (number->string %texlive-revision))
5367 (source (origin
5368 (method svn-fetch)
5369 (uri (texlive-ref "latex" "wasysym"))
2cc9c011 5370 (file-name (string-append name "-" version "-checkout"))
cd2c77f4
RW
5371 (sha256
5372 (base32
5373 "1sgwbfwjjf70g54hh93gsd9jp9nm67w6n74x9d72a56n07jbk5hv"))))
5374 (build-system texlive-build-system)
5375 (arguments '(#:tex-directory "latex/wasysym"))
b8d8806b 5376 (home-page "https://www.ctan.org/pkg/wasysym")
cd2c77f4
RW
5377 (synopsis "LaTeX support file to use the WASY2 fonts")
5378 (description
5379 "The wasy2WASY2 (Waldi Symbol) font by Roland Waldi provides many glyphs
5380like male and female symbols and astronomical symbols, as well as the complete
5381lasy font set and other odds and ends. The wasysym package implements an easy
5382to use interface for these symbols.")
5383 (license license:lppl)))
5384
63ed869b
RW
5385(define-public texlive-latex-wrapfig
5386 (package
5387 (name "texlive-latex-wrapfig")
5388 (version (number->string %texlive-revision))
5389 (source (origin
5390 (method svn-fetch)
5391 (uri (svn-reference
5392 (url (string-append "svn://www.tug.org/texlive/tags/"
5393 %texlive-tag "/Master/texmf-dist/"
5394 "/tex/latex/wrapfig"))
5395 (revision %texlive-revision)))
5396 (file-name (string-append name "-" version "-checkout"))
5397 (sha256
5398 (base32
5399 "16xpyl0csmmwndz1xhzqfg9l0zcsnqxslsixsqkwd4zsvfj30sv4"))))
5400 (build-system trivial-build-system)
5401 (arguments
5402 `(#:modules ((guix build utils))
5403 #:builder
5404 (begin
5405 (use-modules (guix build utils))
5406 (let ((target (string-append (assoc-ref %outputs "out")
5407 "/share/texmf-dist/tex/latex/wrapfig")))
5408 (mkdir-p target)
5409 (copy-recursively (assoc-ref %build-inputs "source") target)
5410 #t))))
b8d8806b 5411 (home-page "https://www.ctan.org/pkg/wrapfig")
63ed869b
RW
5412 (synopsis "Produces figures which text can flow around")
5413 (description
5414 "This package allows figures or tables to have text wrapped around them.
5415It does not work in combination with list environments, but can be used in a
5416@code{parbox} or @code{minipage}, and in two-column format.")
5417 (license license:lppl)))
5418
c178ffca
RW
5419(define-public texlive-latex-ucs
5420 (package
5421 (name "texlive-latex-ucs")
5422 (version (number->string %texlive-revision))
5423 (source (origin
5424 (method svn-fetch)
5425 (uri (svn-reference
5426 (url (string-append "svn://www.tug.org/texlive/tags/"
5427 %texlive-tag "/Master/texmf-dist/"
5428 "/tex/latex/ucs"))
5429 (revision %texlive-revision)))
5430 (file-name (string-append name "-" version "-checkout"))
5431 (sha256
5432 (base32
5433 "0rrxwi60wmz5dfjifl4fwk66plf7wix85qnhfv4ylvmj6qi6hw37"))))
5434 (build-system trivial-build-system)
5435 (arguments
5436 `(#:modules ((guix build utils))
5437 #:builder
5438 (begin
5439 (use-modules (guix build utils))
5440 (let ((target (string-append (assoc-ref %outputs "out")
5441 "/share/texmf-dist/tex/latex/ucs")))
5442 (mkdir-p target)
5443 (copy-recursively (assoc-ref %build-inputs "source") target)
5444 #t))))
b8d8806b 5445 (home-page "https://www.ctan.org/pkg/ucs")
c178ffca
RW
5446 (synopsis "Extended UTF-8 input encoding support for LaTeX")
5447 (description
5448 "The bundle provides the @code{ucs} package, and @code{utf8x.def},
5449together with a large number of support files. The @code{utf8x.def}
5450definition file for use with @code{inputenc} covers a wider range of Unicode
5451characters than does @code{utf8.def} in the LaTeX distribution. The package
5452provides facilities for efficient use of its large sets of Unicode characters.
5453Glyph production may be controlled by various options, which permits use of
5454non-ASCII characters when coding mathematical formulae. Note that the bundle
5455previously had an alias “unicode”; that alias has now been withdrawn, and no
5456package of that name now exists.")
5457 (license license:lppl1.3+)))
5458
86af0f2a
RW
5459(define-public texlive-latex-preview
5460 (package
5461 (name "texlive-latex-preview")
5462 (version (number->string %texlive-revision))
5463 (source (origin
5464 (method svn-fetch)
5465 (uri (texlive-ref "latex" "preview"))
5466 (file-name (string-append name "-" version "-checkout"))
5467 (sha256
5468 (base32
d4d9a1ec 5469 "1hpsk4yp08qvbl43kqiv0hhwxv3gcqqxcpahyv6ch2b38pbj4bh6"))))
86af0f2a
RW
5470 (build-system texlive-build-system)
5471 (arguments
5472 '(#:tex-directory "latex/preview"
5473 #:phases
5474 (modify-phases %standard-phases
5475 (add-after 'unpack 'remove-generated-file
5476 (lambda _
5477 (delete-file "preview.drv")
5478 #t)))))
b8d8806b 5479 (home-page "https://www.ctan.org/pkg/preview")
86af0f2a
RW
5480 (synopsis "Extract bits of a LaTeX source for output")
5481 (description
5482 "The main purpose of the preview package is the extraction of selected
5483elements from a LaTeX source, like formulas or graphics, into separate
5484pages of a DVI file. A flexible and convenient interface allows it to
5485specify what commands and constructs should be extracted. This works
5486with DVI files postprocessed by either Dvips and Ghostscript or
5487dvipng, but it also works when you are using PDFTeX for generating PDF
5488files.")
5489 (license license:gpl3+)))
5490
87b4360e
RW
5491(define-public texlive-latex-acronym
5492 (package
5493 (name "texlive-latex-acronym")
5494 (version (number->string %texlive-revision))
5495 (source (origin
5496 (method svn-fetch)
5497 (uri (texlive-ref "latex" "acronym"))
5498 (file-name (string-append name "-" version "-checkout"))
5499 (sha256
5500 (base32
5501 "0jmasg40bk53zdd2jc8nc18jvdai3p2wmamy7hwli8gls4nf25qp"))))
5502 (build-system texlive-build-system)
5503 (arguments '(#:tex-directory "latex/acronym"))
b8d8806b 5504 (home-page "https://www.ctan.org/pkg/acronym")
87b4360e
RW
5505 (synopsis "Expand acronyms at least once")
5506 (description
5507 "This package ensures that all acronyms used in the text are spelled out
5508in full at least once. It also provides an environment to build a list of
5509acronyms used. The package is compatible with PDF bookmarks. The package
5510requires the suffix package, which in turn requires that it runs under
5511e-TeX.")
5512 (license license:lppl1.3+)))
5513
fedb80ee
RW
5514(define-public texlive-generic-pdftex
5515 (package
5516 (name "texlive-generic-pdftex")
5517 (version (number->string %texlive-revision))
5518 (source (origin
5519 (method svn-fetch)
5520 (uri (svn-reference
5521 (url (string-append "svn://www.tug.org/texlive/tags/"
5522 %texlive-tag "/Master/texmf-dist/"
5523 "/tex/generic/pdftex"))
5524 (revision %texlive-revision)))
66e765a0 5525 (file-name (string-append name "-" version "-checkout"))
fedb80ee
RW
5526 (sha256
5527 (base32
5528 "0k68zmqzs4qvrqxdwsrawbjb14hxqjfamq649azvai0jjxdpkljd"))))
5529 (build-system trivial-build-system)
5530 (arguments
5531 `(#:modules ((guix build utils))
5532 #:builder
5533 (begin
5534 (use-modules (guix build utils))
5535 (let ((target (string-append (assoc-ref %outputs "out")
7002a45d
PN
5536 "/share/texmf-dist/tex/generic/pdftex"))
5537 (target-map (string-append (assoc-ref %outputs "out")
5538 "/share/texmf-dist/fonts/map/pdftex")))
fedb80ee
RW
5539 (mkdir-p target)
5540 (copy-recursively (assoc-ref %build-inputs "source") target)
7002a45d
PN
5541 (mkdir-p target-map)
5542 (copy-recursively (assoc-ref %build-inputs "pdftex-map") target-map)
fedb80ee 5543 #t))))
7002a45d
PN
5544 (native-inputs
5545 `(("pdftex-map"
5546 ,(origin
5547 (method svn-fetch)
5548 (uri (svn-reference
5549 (url (string-append "svn://www.tug.org/texlive/tags/"
5550 %texlive-tag "/Master/texmf-dist/"
5551 "/fonts/map/pdftex"))
5552 (revision %texlive-revision)))
5553 (file-name (string-append name "-map-" version "-checkout"))
5554 (sha256
5555 (base32
d4d9a1ec 5556 "18jvcm0vwpg6wwzijvnb92xx78la45kkh71k6l44425krp2vnwm0"))))))
b8d8806b 5557 (home-page "https://www.ctan.org/pkg/pdftex")
fedb80ee
RW
5558 (synopsis "TeX extension for direct creation of PDF")
5559 (description
5560 "This package provides an extension of TeX which can be configured to
5561directly generate PDF documents instead of DVI.")
5562 (license license:gpl2+)))
5563
8bcdc23f 5564(define texlive-texmf
0aa34e82
AE
5565 (package
5566 (name "texlive-texmf")
3e1ebaab 5567 (version "20180414")
0aa34e82
AE
5568 (source texlive-texmf-src)
5569 (build-system gnu-build-system)
5570 (inputs
5571 `(("texlive-bin" ,texlive-bin)
5572 ("lua" ,lua)
5573 ("perl" ,perl)
5574 ("python" ,python-2) ; incompatible with Python 3 (print syntax)
5575 ("ruby" ,ruby)
5576 ("tcsh" ,tcsh)))
5577 (arguments
5578 `(#:modules ((guix build gnu-build-system)
5579 (guix build utils)
5580 (srfi srfi-26))
a348af40
LC
5581
5582 ;; This package takes 4 GiB, which we can't afford to distribute from
5583 ;; our servers.
5584 #:substitutable? #f
5585
0aa34e82 5586 #:phases
4a6635f3
AE
5587 (modify-phases (map (cut assq <> %standard-phases)
5588 '(set-paths unpack patch-source-shebangs))
977403fe
RW
5589 (add-after 'unpack 'unset-environment-variables
5590 (lambda _
5591 (unsetenv "TEXMF")
5592 (unsetenv "TEXMFCNF")
5593 #t))
4a6635f3
AE
5594 (add-after 'patch-source-shebangs 'install
5595 (lambda* (#:key outputs #:allow-other-keys)
5596 (let ((share (string-append (assoc-ref outputs "out") "/share")))
5597 (mkdir-p share)
286eedec 5598 (invoke "mv" "texmf-dist" share))))
4a6635f3
AE
5599 (add-after 'install 'texmf-config
5600 (lambda* (#:key inputs outputs #:allow-other-keys)
5601 (let* ((out (assoc-ref outputs "out"))
5602 (share (string-append out "/share"))
5603 (texmfroot (string-append share "/texmf-dist/web2c"))
5604 (texmfcnf (string-append texmfroot "/texmf.cnf"))
5605 (texlive-bin (assoc-ref inputs "texlive-bin"))
5606 (texbin (string-append texlive-bin "/bin"))
5607 (tlpkg (string-append texlive-bin "/share/tlpkg")))
5608 ;; Register SHARE as TEXMFROOT in texmf.cnf.
5609 (substitute* texmfcnf
5610 (("TEXMFROOT = \\$SELFAUTOPARENT")
2d634d9b
FB
5611 (string-append "TEXMFROOT = " share))
5612 (("TEXMFLOCAL = \\$SELFAUTOGRANDPARENT/texmf-local")
5613 "TEXMFLOCAL = $SELFAUTODIR/share/texmf-local")
5614 (("!!\\$TEXMFLOCAL") "$TEXMFLOCAL"))
4a6635f3
AE
5615 ;; Register paths in texmfcnf.lua, needed for context.
5616 (substitute* (string-append texmfroot "/texmfcnf.lua")
5617 (("selfautodir:") out)
5618 (("selfautoparent:") (string-append share "/")))
5619 ;; Set path to TeXLive Perl modules
5620 (setenv "PERL5LIB"
5621 (string-append (getenv "PERL5LIB") ":" tlpkg))
5622 ;; Configure the texmf-dist tree; inspired from
5623 ;; http://slackbuilds.org/repository/13.37/office/texlive/
5624 (setenv "PATH" (string-append (getenv "PATH") ":" texbin))
5625 (setenv "TEXMFCNF" texmfroot)
286eedec
MW
5626 (invoke "updmap-sys" "--nohash" "--syncwithtrees")
5627 (invoke "mktexlsr")
0371132c 5628 (invoke "fmtutil-sys" "--all")))))))
7a15a68f 5629 (properties `((max-silent-time . 9600))) ; don't time out while grafting
0aa34e82 5630 (synopsis "TeX Live, a package of the TeX typesetting system")
eb0119ef
AE
5631 (description
5632 "TeX Live provides a comprehensive TeX document production system.
5633It includes all the major TeX-related programs, macro packages, and fonts
5634that are free software, including support for many languages around the
0aa34e82
AE
5635world.
5636
5637This package contains the complete tree of texmf-dist data.")
132e14b4
EF
5638 (license (license:fsf-free "https://www.tug.org/texlive/copying.html"))
5639 (home-page "https://www.tug.org/texlive/")))
0aa34e82
AE
5640
5641(define-public texlive
5642 (package
5643 (name "texlive")
3e1ebaab 5644 (version "20180414")
0aa34e82
AE
5645 (source #f)
5646 (build-system trivial-build-system)
5647 (inputs `(("bash" ,bash) ; for wrap-program
5648 ("texlive-bin" ,texlive-bin)
5649 ("texlive-texmf" ,texlive-texmf)))
2d634d9b
FB
5650 (native-search-paths
5651 (list (search-path-specification
5652 (variable "TEXMFLOCAL")
5653 (files '("share/texmf-local")))))
0aa34e82
AE
5654 (arguments
5655 `(#:modules ((guix build utils))
5656 #:builder
5657 ;; Build the union of texlive-bin and texlive-texmf, but take the
5658 ;; conflicting subdirectory share/texmf-dist from texlive-texmf.
5659 (begin
5660 (use-modules (guix build utils))
5661 (let ((out (assoc-ref %outputs "out"))
5662 (bin (assoc-ref %build-inputs "texlive-bin"))
5663 (texmf (assoc-ref %build-inputs "texlive-texmf"))
5664 (bash (assoc-ref %build-inputs "bash")))
5665 (mkdir out)
5666 (with-directory-excursion out
5667 (for-each
5668 (lambda (name)
5669 (symlink (string-append bin "/" name) name))
5670 '("include" "lib"))
5671 (mkdir "bin")
5672 (with-directory-excursion "bin"
5673 (setenv "PATH" (string-append bash "/bin"))
5674 (for-each
5675 (lambda (name)
5676 (symlink name (basename name))
5677 (wrap-program
5678 (basename name)
5679 `("TEXMFCNF" =
5680 (,(string-append texmf "/share/texmf-dist/web2c")))))
5681 (find-files (string-append bin "/bin/") "")))
5682 (mkdir "share")
5683 (with-directory-excursion "share"
5684 (for-each
5685 (lambda (name)
5686 (symlink (string-append bin "/share/" name) name))
5687 '("info" "man" "tlpkg"))
5688 (for-each
5689 (lambda (name)
5690 (symlink (string-append texmf "/share/" name) name))
e3cfef22
MW
5691 '("texmf-dist" "texmf-var"))))
5692 #t))))
0aa34e82
AE
5693 (synopsis "TeX Live, a package of the TeX typesetting system")
5694 (description
5695 "TeX Live provides a comprehensive TeX document production system.
5696It includes all the major TeX-related programs, macro packages, and fonts
5697that are free software, including support for many languages around the
5698world.
5699
5700This package contains the complete TeX Live distribution.")
132e14b4
EF
5701 (license (license:fsf-free "https://www.tug.org/texlive/copying.html"))
5702 (home-page "https://www.tug.org/texlive/")))
231eae53 5703
ebcf74da
RW
5704(define-public perl-text-bibtex
5705 (package
5706 (name "perl-text-bibtex")
a2460e0f 5707 (version "0.85")
ebcf74da
RW
5708 (source
5709 (origin
5710 (method url-fetch)
5711 (uri (string-append "mirror://cpan/authors/id/A/AM/AMBS/Text-BibTeX-"
5712 version ".tar.gz"))
5713 (sha256
5714 (base32
a2460e0f 5715 "036kxgbn1jf70pfm2lmjlzjwnhbkd888fp5lyvmkjpdd15gla18h"))))
ebcf74da
RW
5716 (build-system perl-build-system)
5717 (arguments
5718 `(#:phases
5719 (modify-phases %standard-phases
5720 (add-after 'unpack 'add-output-directory-to-rpath
5721 (lambda* (#:key outputs #:allow-other-keys)
5722 (substitute* "inc/MyBuilder.pm"
5723 (("-Lbtparse" line)
5724 (string-append "-Wl,-rpath="
5725 (assoc-ref outputs "out") "/lib " line)))
5726 #t))
5727 (add-after 'unpack 'install-libraries-to-/lib
5728 (lambda* (#:key outputs #:allow-other-keys)
5729 (substitute* "Build.PL"
5730 (("lib64") "lib"))
5731 #t)))))
5732 (native-inputs
5733 `(("perl-capture-tiny" ,perl-capture-tiny)
5734 ("perl-config-autoconf" ,perl-config-autoconf)
5735 ("perl-extutils-libbuilder" ,perl-extutils-libbuilder)
5736 ("perl-module-build" ,perl-module-build)))
9aba9b12 5737 (home-page "https://metacpan.org/release/Text-BibTeX")
ebcf74da
RW
5738 (synopsis "Interface to read and parse BibTeX files")
5739 (description "@code{Text::BibTeX} is a Perl library for reading, parsing,
5740and processing BibTeX files. @code{Text::BibTeX} gives you access to the data
5741at many different levels: you may work with BibTeX entries as simple field to
5742string mappings, or get at the original form of the data as a list of simple
5743values (strings, macros, or numbers) pasted together.")
2f3108ad 5744 (license license:perl-license)))
ebcf74da 5745
d4000680
RW
5746(define-public biber
5747 (package
1335167a 5748 (name "biber")
41a01087 5749 (version "2.12")
d4000680 5750 (source (origin
41a01087
JL
5751 (method git-fetch)
5752 (uri (git-reference
5753 (url "https://github.com/plk/biber/")
5754 (commit (string-append "v" version))))
5755 (file-name (git-file-name name version))
5756 ;; TODO: Patch awaiting inclusion upstream (see:
5757 ;; https://github.com/plk/biber/issues/239).
5758 (patches (search-patches "biber-fix-encoding-write.patch"))
d4000680
RW
5759 (sha256
5760 (base32
41a01087 5761 "1g1hi6zvf2hmrjly1sidjaxy5440gfqm4p7p3n7kayshnjsmlskx"))))
d4000680
RW
5762 (build-system perl-build-system)
5763 (arguments
5764 `(#:phases
5765 (modify-phases %standard-phases
5766 (add-after 'install 'wrap-programs
5767 (lambda* (#:key outputs #:allow-other-keys)
5768 (let* ((out (assoc-ref outputs "out"))
5769 (perl5lib (getenv "PERL5LIB")))
5770 (wrap-program (string-append out "/bin/biber")
5771 `("PERL5LIB" ":" prefix
5772 (,(string-append perl5lib ":" out
5773 "/lib/perl5/site_perl")))))
5774 #t)))))
5775 (inputs
5776 `(("perl-autovivification" ,perl-autovivification)
5777 ("perl-class-accessor" ,perl-class-accessor)
5778 ("perl-data-dump" ,perl-data-dump)
5779 ("perl-data-compare" ,perl-data-compare)
5780 ("perl-data-uniqid" ,perl-data-uniqid)
5781 ("perl-datetime-format-builder" ,perl-datetime-format-builder)
5782 ("perl-datetime-calendar-julian" ,perl-datetime-calendar-julian)
41a01087 5783 ("perl-file-slurper" ,perl-file-slurper)
d4000680
RW
5784 ("perl-ipc-cmd" ,perl-ipc-cmd)
5785 ("perl-ipc-run3" ,perl-ipc-run3)
5786 ("perl-list-allutils" ,perl-list-allutils)
5787 ("perl-list-moreutils" ,perl-list-moreutils)
5788 ("perl-mozilla-ca" ,perl-mozilla-ca)
5789 ("perl-regexp-common" ,perl-regexp-common)
5790 ("perl-log-log4perl" ,perl-log-log4perl)
5791 ;; We cannot use perl-unicode-collate here, because otherwise the
5792 ;; hardcoded hashes in the tests would differ. See
5793 ;; https://mail-archive.com/debian-bugs-dist@lists.debian.org/msg1469249.html
5794 ;;("perl-unicode-collate" ,perl-unicode-collate)
5795 ("perl-unicode-normalize" ,perl-unicode-normalize)
5796 ("perl-unicode-linebreak" ,perl-unicode-linebreak)
5797 ("perl-encode-eucjpascii" ,perl-encode-eucjpascii)
5798 ("perl-encode-jis2k" ,perl-encode-jis2k)
5799 ("perl-encode-hanextra" ,perl-encode-hanextra)
5800 ("perl-xml-libxml" ,perl-xml-libxml)
5801 ("perl-xml-libxml-simple" ,perl-xml-libxml-simple)
5802 ("perl-xml-libxslt" ,perl-xml-libxslt)
5803 ("perl-xml-writer" ,perl-xml-writer)
5804 ("perl-sort-key" ,perl-sort-key)
5805 ("perl-text-csv" ,perl-text-csv)
5806 ("perl-text-csv-xs" ,perl-text-csv-xs)
5807 ("perl-text-roman" ,perl-text-roman)
5808 ("perl-uri" ,perl-uri)
5809 ("perl-text-bibtex" ,perl-text-bibtex)
5810 ("perl-libwww" ,perl-libwww)
5811 ("perl-lwp-protocol-https" ,perl-lwp-protocol-https)
5812 ("perl-business-isbn" ,perl-business-isbn)
5813 ("perl-business-issn" ,perl-business-issn)
5814 ("perl-business-ismn" ,perl-business-ismn)
5815 ("perl-lingua-translit" ,perl-lingua-translit)))
5816 (native-inputs
5817 `(("perl-config-autoconf" ,perl-config-autoconf)
5818 ("perl-extutils-libbuilder" ,perl-extutils-libbuilder)
5819 ("perl-module-build" ,perl-module-build)
5820 ;; for tests
5821 ("perl-file-which" ,perl-file-which)
5822 ("perl-test-more" ,perl-test-most) ; FIXME: "more" would be sufficient
5823 ("perl-test-differences" ,perl-test-differences)))
5824 (home-page "http://biblatex-biber.sourceforge.net/")
5825 (synopsis "Backend for the BibLaTeX citation management tool")
5826 (description "Biber is a BibTeX replacement for users of biblatex. Among
5827other things it comes with full Unicode support.")
5828 (license license:artistic2.0)))
5829
231eae53
LC
5830(define-public rubber
5831 (package
5832 (name "rubber")
5833 (version "1.1")
5834 (source (origin
5835 (method url-fetch)
5836 (uri (list (string-append "https://launchpad.net/rubber/trunk/"
5837 version "/+download/rubber-"
5838 version ".tar.gz")
5839 (string-append "http://ebeffara.free.fr/pub/rubber-"
5840 version ".tar.gz")))
5841 (sha256
5842 (base32
5843 "1xbkv8ll889933gyi2a5hj7hhh216k04gn8fwz5lfv5iz8s34gbq"))))
5844 (build-system gnu-build-system)
5845 (arguments '(#:tests? #f)) ; no `check' target
5846 (inputs `(("texinfo" ,texinfo)
9bee5d6c 5847 ("python" ,python-2) ; incompatible with Python 3 (print syntax)
231eae53
LC
5848 ("which" ,which)))
5849 (home-page "https://launchpad.net/rubber")
35b9e423 5850 (synopsis "Wrapper for LaTeX and friends")
231eae53
LC
5851 (description
5852 "Rubber is a program whose purpose is to handle all tasks related to the
5853compilation of LaTeX documents. This includes compiling the document itself,
5854of course, enough times so that all references are defined, and running BibTeX
5855to manage bibliographic references. Automatic execution of dvips to produce
5856PostScript documents is also included, as well as usage of pdfLaTeX to produce
5857PDF documents.")
5858 (license license:gpl2+)))
4791876c
RJ
5859
5860(define-public texmaker
5861 (package
5862 (name "texmaker")
585be42f 5863 (version "5.0.3")
4791876c
RJ
5864 (source (origin
5865 (method url-fetch)
5866 (uri (string-append "http://www.xm1math.net/texmaker/texmaker-"
5867 version ".tar.bz2"))
5868 (sha256
5869 (base32
585be42f 5870 "0vrj9w5lk3vf6138n5bz8phmy3xp5kv4dq1rgirghcf4hbxdyx30"))))
4791876c
RJ
5871 (build-system gnu-build-system)
5872 (arguments
5873 `(#:phases
5874 (modify-phases %standard-phases
5875 ;; Qt has its own configuration utility.
5876 (replace 'configure
5877 (lambda* (#:key outputs #:allow-other-keys)
5878 (let ((out (assoc-ref outputs "out")))
6c23ed9b
MW
5879 (invoke "qmake"
5880 (string-append "PREFIX=" out)
c36d9725 5881 (string-append "DESKTOPDIR=" out "/share/applications")
6c23ed9b 5882 (string-append "ICONDIR=" out "/share/pixmaps")
c36d9725 5883 (string-append "METAINFODIR=" out "/share/metainfo")
6c23ed9b 5884 "texmaker.pro")))))))
4791876c
RJ
5885 (inputs
5886 `(("poppler-qt5" ,poppler-qt5)
bd917486
TD
5887 ("qtbase" ,qtbase)
5888 ("qtscript" ,qtscript)
5889 ("qtwebkit" ,qtwebkit)
4791876c
RJ
5890 ("zlib" ,zlib)))
5891 (native-inputs
5892 `(("pkg-config" ,pkg-config)))
5893 (home-page "http://www.xm1math.net/texmaker/")
5894 (synopsis "LaTeX editor")
5895 (description "Texmaker is a program that integrates many tools needed to
5896develop documents with LaTeX, in a single application.")
5897 (license license:gpl2+)))
83457fe0 5898
83457fe0
JD
5899(define-public teximpatient
5900 (package
5901 (name "teximpatient")
5902 (version "2.4")
5903 (source (origin
4f2ee8e2 5904 (method url-fetch/tarbomb)
83457fe0
JD
5905 (uri (string-append "mirror://gnu/" name "/" name "-"
5906 version ".tar.gz"))
5907 (sha256
5908 (base32
5909 "0h56w22d99dh4fgld4ssik8ggnmhmrrbnrn1lnxi1zr0miphn1sd"))))
5910 (build-system gnu-build-system)
5911 (arguments
4f2ee8e2
RW
5912 `(#:tests? #f ; there are none
5913 #:phases
83457fe0 5914 (modify-phases %standard-phases
4f2ee8e2
RW
5915 (add-after 'unpack 'fix-packaging-error
5916 (lambda* (#:key inputs #:allow-other-keys)
5917 ;; This file should have been part of the tarball.
5918 (install-file (car
5919 (find-files
5920 (assoc-ref inputs "automake")
5921 "^install-sh$"))
5922 ".")
5923 ;; Remove generated file.
5924 (delete-file "book.pdf")
5925 #t)))))
83457fe0 5926 (native-inputs
4f2ee8e2
RW
5927 `(("texlive" ,(texlive-union (list texlive-latex-amsfonts
5928 texlive-fonts-amsfonts
5929 texlive-fonts-adobe-palatino
5930 texlive-fonts-adobe-zapfding
5931 texlive-fonts-knuth-lib
5932 texlive-fonts-mflogo-font
5933 texlive-generic-pdftex)))
83457fe0 5934 ("automake" ,automake)))
6fd52309 5935 (home-page "https://www.gnu.org/software/teximpatient/")
83457fe0
JD
5936 (synopsis "Book on TeX, plain TeX and Eplain")
5937 (description "@i{TeX for the Impatient} is a ~350 page book on TeX,
5938plain TeX, and Eplain, originally written by Paul Abrahams, Kathryn Hargreaves,
5939and Karl Berry.")
5940 (license license:fdl1.3+)))
ec40a050
DM
5941
5942(define-public lyx
5943 (package
5944 (name "lyx")
b17c8923 5945 (version "2.3.2-2")
ec40a050 5946 (source (origin
b17c8923 5947 (method url-fetch)
e5a03489
EF
5948 (uri (string-append "http://ftp.lyx.org/pub/lyx/stable/"
5949 (version-major+minor version) ".x/"
b17c8923
RW
5950 name "-" version ".tar.gz"))
5951 (sha256
5952 (base32
5953 "0vr0qwis6rhind6azfa270hqxci7rj8qb1kk5x6lm80mc34nvrqi"))
5954 (modules '((guix build utils)))
5955 (snippet
5956 '(begin
5957 (delete-file-recursively "3rdparty")
5958 #t))))
ec40a050
DM
5959 (build-system cmake-build-system)
5960 (arguments
5961 `(#:configure-flags `("-DLYX_USE_QT=QT5"
5962 "-DLYX_EXTERNAL_BOOST=1"
5963 "-DLYX_INSTALL=1"
5964 "-DLYX_RELEASE=1"
5965 ,(string-append "-DLYX_INSTALL_PREFIX="
5966 (assoc-ref %outputs "out")
5967 ;; Exact name and level is necessary.
e5a03489 5968 "/lyx" ,(version-major+minor version)))
ec40a050
DM
5969 #:phases
5970 (modify-phases %standard-phases
b17c8923
RW
5971 ;; See ;; https://www.lyx.org/trac/changeset/3a123b90af838b08680471d87170c38e56787df9/lyxgit
5972 (add-after 'unpack 'fix-compilation-with-boost-1.69
5973 (lambda _
5974 (substitute* "src/support/FileName.cpp"
5975 (("^template struct boost::detail::crc_table_t.*") ""))
5976 #t))
ec40a050
DM
5977 (add-after 'unpack 'patch-python
5978 (lambda* (#:key inputs #:allow-other-keys)
5979 (substitute* '("src/support/os.cpp")
b17c8923
RW
5980 (("\"python ")
5981 (string-append "\""
5982 (assoc-ref inputs "python")
5983 "/bin/python ")))
ec40a050
DM
5984 #t))
5985 (add-after 'patch-python 'patch-desktop-file
5986 (lambda* (#:key outputs #:allow-other-keys)
5987 (substitute* "lib/lyx.desktop.in"
b17c8923
RW
5988 (("Exec=")
5989 (string-append "Exec="
5990 (assoc-ref outputs "out")
5991 "/")))
ec40a050
DM
5992 #t))
5993 (add-before 'check 'setenv-check
5994 (lambda _
b17c8923
RW
5995 ;; Create missing file that would cause tests to fail.
5996 (with-output-to-file (string-append "../lyx-"
5997 ,version
5998 "/src/tests/check_layout.cmake")
5999 (const #t))
e5a03489
EF
6000 (setenv (string-append "LYX_DIR_"
6001 (string-join
6002 (string-split
6003 ,(version-major+minor version) #\-)) "x")
6004 (string-append (getcwd) "/../lyx-" ,version "/lib"))
ec40a050
DM
6005 #t))
6006 (add-after 'install 'install-symlinks
6007 (lambda* (#:key outputs #:allow-other-keys)
6008 (let ((out (assoc-ref outputs "out")))
6009 (mkdir-p (string-append out "/bin"))
e5a03489
EF
6010 (symlink (string-append "../lyx" ,(version-major+minor version)
6011 "/bin/lyx" ,(version-major+minor version))
6012 (string-append out "/bin/lyx" ,(version-major+minor version)))
ec40a050
DM
6013 #t))))))
6014 (inputs
6015 `(("boost" ,boost)
b17c8923 6016 ("hunspell" ,hunspell) ; Note: Could also use aspell instead.
ec40a050 6017 ("libx11" ,libx11)
b17c8923
RW
6018 ("mythes" ,mythes)
6019 ("python" ,python-2)
ec40a050
DM
6020 ("qtbase" ,qtbase)
6021 ("qtsvg" ,qtsvg)
6022 ("zlib" ,zlib)))
6023 (propagated-inputs
b17c8923
RW
6024 `(("texlive" ,(texlive-union (list texlive-fonts-ec)))))
6025 ;; FIXME: Python 3.7.0 cannot be used because the test infrastructure
6026 ;; "requires a bytes-like object, not 'str'". This may be fixed with
6027 ;; upgrades to Python.
ec40a050 6028 (native-inputs
b17c8923 6029 `(("python" ,python-2)
ec40a050
DM
6030 ("pkg-config" ,pkg-config)
6031 ("bc" ,bc)))
8960b2e6 6032 (home-page "https://www.lyx.org/")
ec40a050
DM
6033 (synopsis "Document preparation system with GUI")
6034 (description "LyX is a document preparation system. It excels at letting
6035you create complex technical and scientific articles with mathematics,
6036cross-references, bibliographies, indexes, etc. It is very good for working
6037with documents of any length in which the usual processing abilities are
6038required: automatic sectioning and pagination, spell checking and so forth.")
6039 (license license:gpl2+)))
7d50dff3
PN
6040
6041(define-public texlive-latex-media9
6042 (package
6043 (name "texlive-latex-media9")
6044 (version (number->string %texlive-revision))
6045 (source (origin
6046 (method svn-fetch)
6047 (uri (svn-reference
6048 (url (string-append "svn://www.tug.org/texlive/tags/"
6049 %texlive-tag "/Master/texmf-dist/"
6050 "/tex/latex/media9"))
6051 (revision %texlive-revision)))
6052 (file-name (string-append name "-" version "-checkout"))
6053 (sha256
6054 (base32
d4d9a1ec 6055 "0lhb2h5hxjq9alpk4r3gvg21pwyifs4ah6hqzp92k55mkp1xv73j"))))
7d50dff3
PN
6056 (build-system trivial-build-system)
6057 (arguments
6058 `(#:modules ((guix build utils))
6059 #:builder
6060 (begin
6061 (use-modules (guix build utils))
6062 (let ((target (string-append (assoc-ref %outputs "out")
6063 "/share/texmf-dist/tex/latex/media9")))
6064 (mkdir-p target)
6065 (copy-recursively (assoc-ref %build-inputs "source") target)
6066 #t))))
6067 (home-page "https://www.ctan.org/pkg/media9")
6068 (synopsis "Multimedia inclusion package with Adobe Reader-9/X compatibility")
6069 (description
6070 "The package provides an interface to embed interactive Flash (SWF) and 3D
6071objects (Adobe U3D & PRC), as well as video and sound files or streams in the
6072popular MP4, FLV and MP3 formats into PDF documents with Acrobat-9/X
6073compatibility. Playback of multimedia files uses the built-in Flash Player of
6074Adobe Reader and does, therefore, not depend on external plug-ins. Flash Player
6075supports the efficient H.264 codec for video compression.
6076
6077The package is based on the RichMedia Annotation, an Adobe addition to the PDF
6078specification. It replaces the now obsolete @code{movie15} package.")
6079 (license license:lppl)))
288c8c97
PN
6080
6081(define-public texlive-latex-ocgx2
6082 (package
6083 (name "texlive-latex-ocgx2")
6084 (version (number->string %texlive-revision))
6085 (source (origin
6086 (method svn-fetch)
6087 (uri (svn-reference
6088 (url (string-append "svn://www.tug.org/texlive/tags/"
6089 %texlive-tag "/Master/texmf-dist/"
6090 "/tex/latex/ocgx2"))
6091 (revision %texlive-revision)))
6092 (file-name (string-append name "-" version "-checkout"))
6093 (sha256
6094 (base32
d4d9a1ec 6095 "0zp00jg058djx8xp0xqwas92y3j97clkyd8z6pqr890yqy06myqb"))))
288c8c97
PN
6096 (build-system trivial-build-system)
6097 (arguments
6098 `(#:modules ((guix build utils))
6099 #:builder
6100 (begin
6101 (use-modules (guix build utils))
6102 (let ((target (string-append (assoc-ref %outputs "out")
6103 "/share/texmf-dist/tex/latex/ogcx2")))
6104 (mkdir-p target)
6105 (copy-recursively (assoc-ref %build-inputs "source") target)
6106 #t))))
6107 (home-page "https://www.ctan.org/pkg/ocgx2")
6108 (synopsis "Provide OCG (Optional Content Groups) support within a PDF document")
6109 (description
6110 "This package provides OCG (Optional Content Groups) support within a PDF
6111document.
6112
6113It re-implements the functionality of the @code{ocg}, @code{ocgx}, and
6114@code{ocg-p} packages and adds support for all known engines and back-ends
6115including:
6116
6117@itemize
6118@item LaTeX → dvips → @code{ps2pdf}/Distiller
6119@item (Xe)LaTeX(x) → @code{dvipdfmx}
6120@item pdfLaTeX and LuaLaTeX .
6121@end itemize
6122
6123It also ensures compatibility with the @code{media9} and @code{animate} packages.")
6124 (license license:lppl)))
b718793e
PN
6125
6126(define-public texlive-latex-ms
6127 (package
6128 (name "texlive-latex-ms")
6129 (version (number->string %texlive-revision))
6130 (source (origin
6131 (method svn-fetch)
6132 (uri (texlive-ref "latex" "ms"))
6133 (file-name (string-append name "-" version "-checkout"))
6134 (sha256
6135 (base32
6136 "0m4wx3yjb5al1qsv995z8fii8xxy96mcfihbnlx43lpgayiwz35s"))))
6137 (build-system texlive-build-system)
6138 (arguments
6139 '(#:tex-directory "latex/ms"
6140 #:tex-format "latex"))
6141 (home-page "https://ctan.org/pkg/ms")
6142 (synopsis "Various LATEX packages by Martin Schröder")
6143 (description
6144 "A bundle of LATEX packages by Martin Schröder; the collection comprises:
6145
6146@itemize
6147@item @command{count1to}, make use of fixed TEX counters;
6148@item @command{everysel}, set commands to execute every time a font is selected;
6149@item @command{everyshi}, set commands to execute whenever a page is shipped out;
6150@item @command{multitoc}, typeset the table of contents in multiple columns;
6151@item @command{prelim2e}, mark typeset pages as preliminary; and
6152@item @command{ragged2e}, typeset ragged text and allow hyphenation.
6153@end itemize\n")
6154 (license license:lppl1.3c+)))
707babdd
PN
6155
6156(define-public texlive-latex-needspace
6157 (package
6158 (name "texlive-latex-needspace")
6159 (version (number->string %texlive-revision))
6160 (source (origin
6161 (method svn-fetch)
6162 (uri (texlive-ref "latex" "needspace"))
6163 (file-name (string-append name "-" version "-checkout"))
6164 (sha256
6165 (base32
6166 "0kw80f5jh4gdpa2ka815abza3gr5z8b929w0745vrlc59pl0017y"))))
6167 (build-system texlive-build-system)
6168 (arguments
6169 '(#:tex-directory "latex/needspace"
6170 #:tex-format "latex"))
6171 (inputs
6172 `(("texlive-latex-filecontents" ,texlive-latex-filecontents)))
6173 (home-page "https://www.ctan.org/pkg/needspace")
6174 (synopsis "Insert pagebreak if not enough space")
6175 (description
6176 "Provides commands to disable pagebreaking within a given vertical
6177space. If there is not enough space between the command and the bottom of the
6178page, a new page will be started.")
6179 (license license:lppl)))
0e73c11b 6180
73635e3f
RW
6181(define-public texlive-latex-changepage
6182 (package
6183 (name "texlive-latex-changepage")
6184 (version (number->string %texlive-revision))
6185 (source
6186 (origin
6187 (method svn-fetch)
6188 (uri (texlive-ref "latex" "changepage"))
6189 (sha256
6190 (base32
6191 "1rpw8xg5p4jsyh236jma9dz3l29wjx4062f154b3wak5yjcxyxyb"))))
6192 (build-system texlive-build-system)
6193 (arguments
6194 '(#:tex-directory "latex/changepage"
6195 #:tex-format "latex"))
6196 (inputs
6197 `(("texlive-latex-filecontents" ,texlive-latex-filecontents)))
6198 (home-page "https://www.ctan.org/pkg/changepage")
6199 (synopsis "Margin adjustment and detection of odd/even pages")
6200 (description
6201 "The package provides commands to change the page layout in the middle of
6202a document, and to robustly check for typesetting on odd or even pages.
6203Instructions for use are at the end of the file. The package is an extraction
6204of code from the @code{memoir} class, whose user interface it shares.")
6205 (license license:lppl1.3+)))
6206
0e73c11b
PN
6207(define-public texlive-latex-eukdate
6208 (package
6209 (name "texlive-latex-eukdate")
6210 (version (number->string %texlive-revision))
6211 (source
6212 (origin
6213 (method svn-fetch)
6214 (uri (svn-reference
6215 (url (string-append "svn://www.tug.org/texlive/tags/"
6216 %texlive-tag "/Master/texmf-dist/"
6217 "/tex/latex/eukdate"))
6218 (revision %texlive-revision)))
6219 (file-name (string-append name "-" version "-checkout"))
6220 (sha256
6221 (base32
6222 "18xan116l8w47v560bkw6nbhkrml7g04xrlzk3jrpc7qsyf3n5fz"))))
6223 (build-system trivial-build-system)
6224 (arguments
6225 `(#:modules ((guix build utils))
6226 #:builder
6227 (begin
6228 (use-modules (guix build utils))
6229 (let ((target (string-append (assoc-ref %outputs "out")
6230 "/share/texmf-dist/tex/latex/eukdate")))
6231 (mkdir-p target)
6232 (copy-recursively (assoc-ref %build-inputs "source") target)
6233 #t))))
6234 (home-page "https://www.ctan.org/pkg/eukdate")
6235 (synopsis "UK format dates, with weekday")
6236 (description
6237 "The package is used to change the format of @code{\\today}’s date,
6238including the weekday, e.g., \"Saturday, 26 June 2008\", the 'UK format', which
6239is preferred in many parts of the world, as distinct from that which is used in
6240@code{\\maketitle} of the article class, \"June 26, 2008\", the 'US format'.")
6241 (license license:lppl)))
910d67fb
PN
6242
6243(define-public texlive-generic-ulem
6244 (package
6245 (name "texlive-generic-ulem")
6246 (version (number->string %texlive-revision))
6247 (source
6248 (origin
6249 (method svn-fetch)
6250 (uri (svn-reference
6251 (url (string-append "svn://www.tug.org/texlive/tags/"
6252 %texlive-tag "/Master/texmf-dist/"
6253 "/tex/generic/ulem"))
6254 (revision %texlive-revision)))
6255 (file-name (string-append name "-" version "-checkout"))
6256 (sha256
6257 (base32
6258 "1rzdniqq9zk39w8ch8ylx3ywh2mj87s4ivchrsk2b8nx06jyn797"))))
6259 (build-system trivial-build-system)
6260 (arguments
6261 `(#:modules ((guix build utils))
6262 #:builder
6263 (begin
6264 (use-modules (guix build utils))
6265 (let ((target (string-append (assoc-ref %outputs "out")
6266 "/share/texmf-dist/tex/generic/ulem")))
6267 (mkdir-p target)
6268 (copy-recursively (assoc-ref %build-inputs "source") target)
6269 #t))))
6270 (home-page "https://www.ctan.org/pkg/ulem")
6271 (synopsis "Underline text in TeX")
6272 (description
6273 "The package provides an @code{\\ul} (underline) command which will break
6274over line ends; this technique may be used to replace @code{\\em} (both in that
6275form and as the @code{\\emph} command), so as to make output look as if it comes
6276from a typewriter. The package also offers double and wavy underlining, and
6277striking out (line through words) and crossing out (/// over words).")
6278 (license license:lppl1.3c+)))
17ef5f1f
PN
6279
6280(define-public texlive-latex-pgf
6281 (package
6282 (name "texlive-latex-pgf")
6283 (version (number->string %texlive-revision))
6284 (source
6285 (origin
6286 (method svn-fetch)
6287 (uri (svn-reference
6288 (url (string-append "svn://www.tug.org/texlive/tags/"
6289 %texlive-tag "/Master/texmf-dist/"
6290 "/tex/latex/pgf"))
6291 (revision %texlive-revision)))
6292 (file-name (string-append name "-" version "-checkout"))
6293 (sha256
6294 (base32
6295 "1dq8p10pz8wn0vx412m7d7d5gj1syxly3yqdqvf7lv2xl8zndn5h"))))
6296 (build-system trivial-build-system)
6297 (native-inputs
6298 `(("texlive-latex-pgf-generic"
6299 ,(origin
6300 (method svn-fetch)
6301 (uri (svn-reference
6302 (url (string-append "svn://www.tug.org/texlive/tags/"
6303 %texlive-tag "/Master/texmf-dist/"
6304 "/tex/generic/pgf"))
6305 (revision %texlive-revision)))
6306 (file-name (string-append "texlive-latex-pgf-generic" version "-checkout"))
6307 (sha256
6308 (base32
6309 "0xkxw26sjzr5npjpzpr28yygwdbhzpdd0hsk80gjpidhcxmz393i"))))))
0fc71e4b
RW
6310 (propagated-inputs
6311 `(("texlive-latex-xcolor" ,texlive-latex-xcolor)))
17ef5f1f
PN
6312 (arguments
6313 `(#:modules ((guix build utils))
6314 #:builder
6315 (begin
6316 (use-modules (guix build utils))
6317 (let ((target-generic (string-append (assoc-ref %outputs "out")
6318 "/share/texmf-dist/tex/generic/pgf"))
6319 (target-latex (string-append (assoc-ref %outputs "out")
6320 "/share/texmf-dist/tex/latex/pgf")))
6321 (mkdir-p target-generic)
6322 (mkdir-p target-latex)
6323 (copy-recursively (assoc-ref %build-inputs "texlive-latex-pgf-generic") target-generic)
6324 (copy-recursively (assoc-ref %build-inputs "source") target-latex)
6325 #t))))
6326 (home-page "https://www.ctan.org/pkg/tikz")
6327 (synopsis "Create PostScript and PDF graphics in TeX")
6328 (description
6329 "PGF is a macro package for creating graphics. It is platform- and
6330format-independent and works together with the most important TeX backend
6331drivers, including pdfTeX and dvips. It comes with a user-friendly syntax layer
6332called TikZ.
6333
6334Its usage is similar to pstricks and the standard picture environment. PGF
6335works with plain (pdf-)TeX, (pdf-)LaTeX, and ConTeXt. Unlike pstricks, it can
6336produce either PostScript or PDF output.")
6337 (license license:lppl1.3c+)))
e7b2937d
PN
6338
6339(define-public texlive-latex-koma-script
6340 (package
6341 (name "texlive-latex-koma-script")
6342 (version (number->string %texlive-revision))
6343 (source (origin
6344 (method svn-fetch)
6345 (uri (svn-reference
6346 (url (string-append "svn://www.tug.org/texlive/tags/"
6347 %texlive-tag "/Master/texmf-dist/"
6348 "/tex/latex/koma-script"))
6349 (revision %texlive-revision)))
6350 (file-name (string-append name "-" version "-checkout"))
6351 (sha256
6352 (base32
d4d9a1ec 6353 "0nqwf0sr4mf3v9gqa6apv6ml2xhcdwax0vgyf12a672g7rpdyvgm"))))
e7b2937d
PN
6354 (build-system trivial-build-system)
6355 (arguments
6356 `(#:modules ((guix build utils)
6357 (ice-9 match))
6358 #:builder
6359 (begin
6360 (use-modules (guix build utils)
6361 (ice-9 match))
6362 (let ((root (string-append (assoc-ref %outputs "out")
6363 "/share/texmf-dist/"))
6364 (pkgs '(("source" . "tex/latex/koma-script"))))
6365 (for-each (match-lambda
6366 ((pkg . dir)
6367 (let ((target (string-append root dir)))
6368 (mkdir-p target)
6369 (copy-recursively (assoc-ref %build-inputs pkg)
6370 target))))
6371 pkgs)
6372 #t))))
6373 (home-page "https://www.ctan.org/pkg/koma-script")
6374 (synopsis "Bundle of versatile classes and packages")
6375 (description
6376 "The KOMA-Script bundle provides replacements for the article, report, and
6377book classes with emphasis on typography and versatility. There is also a
6378letter class.
6379
6380The bundle also offers:
6381
6382@itemize
6383@item a package for calculating type areas in the way laid down by the
6384typographer Jan Tschichold,
6385@item packages for easily changing and defining page styles,
6386@item a package scrdate for getting not only the current date but also the name
6387of the day, and
6388@item a package scrtime for getting the current time.
6389@end itemize
6390
6391All these packages may be used not only with KOMA-Script classes but also with
6392the standard classes.
6393
6394Since every package has its own version number, the version number quoted only
6395refers to the version of scrbook, scrreprt, scrartcl, scrlttr2 and
6396typearea (which are the main parts of the bundle).")
6397 (license license:lppl1.3+)))
893fbf12
RW
6398
6399(define-public texlive-generic-listofitems
6400 (package
6401 (name "texlive-generic-listofitems")
6402 (version (number->string %texlive-revision))
6403 (source (origin
6404 (method svn-fetch)
6405 (uri (svn-reference
6406 (url (string-append "svn://www.tug.org/texlive/tags/"
6407 %texlive-tag "/Master/texmf-dist/"
6408 "/tex/generic/listofitems"))
6409 (revision %texlive-revision)))
6410 (file-name (string-append name "-" version "-checkout"))
6411 (sha256
6412 (base32
d4d9a1ec 6413 "0hs28fc0v2l92ad9las9b8xcckyrdrwmyhcx1yzmbr6s7s6nvsx8"))))
893fbf12
RW
6414 (build-system trivial-build-system)
6415 (arguments
6416 `(#:modules ((guix build utils))
6417 #:builder
6418 (begin
6419 (use-modules (guix build utils))
6420 (let ((target (string-append (assoc-ref %outputs "out")
6421 "/share/texmf-dist/tex/generic/listofitems")))
6422 (mkdir-p target)
6423 (copy-recursively (assoc-ref %build-inputs "source") target)
6424 #t))))
6425 (home-page "https://www.ctan.org/pkg/listofitems")
88868575 6426 (synopsis "Grab items in lists using user-specified separation character")
893fbf12
RW
6427 (description
6428 "This package allows one to capture all the items of a list, for which
6429the parsing character has been selected by the user, and to access any of
6430these items with a simple syntax.")
6431 (license license:lppl1.3c+)))
1d0669f4
RW
6432
6433(define-public texlive-latex-readarray
6434 (package
6435 (name "texlive-latex-readarray")
6436 (version (number->string %texlive-revision))
6437 (source (origin
6438 (method svn-fetch)
6439 (uri (svn-reference
6440 (url (string-append "svn://www.tug.org/texlive/tags/"
6441 %texlive-tag "/Master/texmf-dist/"
6442 "/tex/latex/readarray"))
6443 (revision %texlive-revision)))
6444 (file-name (string-append name "-" version "-checkout"))
6445 (sha256
6446 (base32
6447 "0c53k180ivn1n7fz3ngvd2w1i5dw3kxml0n64vhki88xsylz7lxp"))))
6448 (build-system trivial-build-system)
6449 (arguments
6450 `(#:modules ((guix build utils))
6451 #:builder
6452 (begin
6453 (use-modules (guix build utils))
6454 (let ((target (string-append (assoc-ref %outputs "out")
6455 "/share/texmf-dist/tex/latex/readarray")))
6456 (mkdir-p target)
6457 (copy-recursively (assoc-ref %build-inputs "source") target)
6458 #t))))
6459 (propagated-inputs
6460 `(("texlive-generic-listofitems" ,texlive-generic-listofitems)))
6461 (home-page "https://www.ctan.org/pkg/readarray")
6462 (synopsis "Read, store and recall array-formatted data")
6463 (description
6464 "This package allows the user to input formatted data into elements of a
64652-D or 3-D array and to recall that data at will by individual cell number.
6466The data can be but need not be numerical in nature. It can be, for example,
6467formatted text.")
6468 (license license:lppl1.3)))
f50f343e
RW
6469
6470(define-public texlive-latex-verbatimbox
6471 (package
6472 (name "texlive-latex-verbatimbox")
6473 (version (number->string %texlive-revision))
6474 (source (origin
6475 (method svn-fetch)
6476 (uri (svn-reference
6477 (url (string-append "svn://www.tug.org/texlive/tags/"
6478 %texlive-tag "/Master/texmf-dist/"
6479 "/tex/latex/verbatimbox"))
6480 (revision %texlive-revision)))
6481 (file-name (string-append name "-" version "-checkout"))
6482 (sha256
6483 (base32
6484 "0qh1cgvfs463zsi2pjg490gj0mkjfdpfc381j10cbb5la304psna"))))
6485 (build-system trivial-build-system)
6486 (arguments
6487 `(#:modules ((guix build utils))
6488 #:builder
6489 (begin
6490 (use-modules (guix build utils))
6491 (let ((target (string-append (assoc-ref %outputs "out")
6492 "/share/texmf-dist/tex/latex/verbatimbox")))
6493 (mkdir-p target)
6494 (copy-recursively (assoc-ref %build-inputs "source") target)
6495 #t))))
6496 (propagated-inputs
6497 `(("texlive-latex-readarray" ,texlive-latex-readarray)))
6498 (home-page "https://www.ctan.org/pkg/verbatimbox")
6499 (synopsis "Deposit verbatim text in a box")
6500 (description
6501 "The package provides a @code{verbbox} environment to place its contents
6502into a globally available box, or into a box specified by the user. The
6503global box may then be used in a variety of situations (for example, providing
6504a replica of the @code{boxedverbatim} environment itself). A valuable use is
6505in places where the standard @code{verbatim} environment (which is based on a
6506@code{trivlist}) may not appear.")
6507 (license license:lppl1.3+)))
4348a059
RW
6508
6509(define-public texlive-latex-examplep
6510 (package
6511 (name "texlive-latex-examplep")
6512 (version (number->string %texlive-revision))
6513 (source (origin
6514 (method svn-fetch)
6515 (uri (svn-reference
6516 (url (string-append "svn://www.tug.org/texlive/tags/"
6517 %texlive-tag "/Master/texmf-dist/"
6518 "/tex/latex/examplep"))
6519 (revision %texlive-revision)))
6520 (file-name (string-append name "-" version "-checkout"))
6521 (sha256
6522 (base32
6523 "0fsvvmz68ij0zwfzrny6x13d92grxr4ap59lxgah4smbkccd6s27"))))
6524 (build-system trivial-build-system)
6525 (arguments
6526 `(#:modules ((guix build utils))
6527 #:builder
6528 (begin
6529 (use-modules (guix build utils))
6530 (let ((target (string-append (assoc-ref %outputs "out")
6531 "/share/texmf-dist/tex/latex/examplep")))
6532 (mkdir-p target)
6533 (copy-recursively (assoc-ref %build-inputs "source") target)
6534 #t))))
6535 (home-page "https://www.ctan.org/pkg/examplep")
6536 (synopsis "Verbatim phrases and listings in LaTeX")
6537 (description
6538 "Examplep provides sophisticated features for typesetting verbatim source
6539code listings, including the display of the source code and its compiled LaTeX
6540or METAPOST output side-by-side, with automatic width detection and enabled
6541page breaks (in the source), without the need for specifying the source twice.
6542Special care is taken that section, page and footnote numbers do not interfere
6543with the main document. For typesetting short verbatim phrases, a replacement
6544for the @code{\\verb} command is also provided in the package, which can be
6545used inside tables and moving arguments such as footnotes and section
6546titles.")
6547 ;; No version of the GPL is specified.
6548 (license license:gpl3+)))
547ab650
PN
6549
6550(define-public texlive-generic-xypic
6551 (package
6552 (name "texlive-generic-xypic")
6553 (version (number->string %texlive-revision))
6554 (source
6555 (origin
6556 (method svn-fetch)
6557 (uri (svn-reference
6558 (url (string-append "svn://www.tug.org/texlive/tags/"
6559 %texlive-tag "/Master/texmf-dist/"
6560 "/tex/generic/xypic"))
6561 (revision %texlive-revision)))
6562 (file-name (string-append name "-" version "-checkout"))
6563 (sha256
6564 (base32
6565 "1g5cyxwdfznq4lk9zl6fkjkapmhmwd2cm4m5aibxj20qgwnaggfz"))))
6566 (build-system trivial-build-system)
6567 (arguments
6568 `(#:modules ((guix build utils))
6569 #:builder
6570 (begin
6571 (use-modules (guix build utils))
6572 (let ((target (string-append (assoc-ref %outputs "out")
6573 "/share/texmf-dist/tex/generic/xypic")))
6574 (mkdir-p target)
6575 (copy-recursively (assoc-ref %build-inputs "source") target)
6576 #t))))
6577 (home-page "https://www.ctan.org/pkg/xypic")
6578 (synopsis "Flexible diagramming macros for TeX")
6579 (description
6580 "A package for typesetting a variety of graphs and diagrams with TeX.
6581Xy-pic works with most formats (including LaTeX, AMS-LaTeX, AMS-TeX, and plain
6582TeX).")
6583 (license license:gpl3+)))
1d9ce461
PN
6584
6585(define-public texlive-fonts-xypic
6586 (package
6587 (name "texlive-fonts-xypic")
6588 (version (number->string %texlive-revision))
6589 (source (origin
6590 (method svn-fetch)
6591 (uri (svn-reference
6592 (url (string-append "svn://www.tug.org/texlive/tags/"
6593 %texlive-tag "/Master/texmf-dist/"
6594 "/fonts/source/public/xypic"))
6595 (revision %texlive-revision)))
6596 (file-name (string-append name "-" version "-checkout"))
6597 (sha256
6598 (base32
6599 "0p20v1257kwsqnrk98cdhhiz2viv8l3ly4xay4by0an3j37m9xs3"))))
6600 (build-system trivial-build-system)
6601 (arguments
6602 `(#:modules ((guix build utils)
6603 (ice-9 match))
6604 #:builder
6605 (begin
6606 (use-modules (guix build utils)
6607 (ice-9 match))
6608 (let ((root (string-append (assoc-ref %outputs "out")
6609 "/share/texmf-dist/"))
6610 (pkgs '(("source" . "fonts/source/public/xypic")
6611 ("xypic-afm" . "fonts/afm/public/xypic")
6612 ("xypic-type1" . "fonts/type1/public/xypic")
6613 ("xypic-enc" . "fonts/enc/dvips/xypic"))))
6614 (for-each (match-lambda
6615 ((pkg . dir)
6616 (let ((target (string-append root dir)))
6617 (mkdir-p target)
6618 (copy-recursively (assoc-ref %build-inputs pkg)
6619 target))))
6620 pkgs)
6621 #t))))
6622 (native-inputs
6623 `(("xypic-afm"
6624 ,(origin
6625 (method svn-fetch)
6626 (uri (svn-reference
6627 (url (string-append "svn://www.tug.org/texlive/tags/"
6628 %texlive-tag "/Master/texmf-dist/"
6629 "/fonts/afm/public/xypic"))
6630 (revision %texlive-revision)))
6631 (file-name (string-append name "-afm-" version "-checkout"))
6632 (sha256
6633 (base32
6634 "149xdijxp8lw3s0qv2aqxxxyyn748z57dpr596rjvkqdffpnsddh"))))
6635 ("xypic-type1"
6636 ,(origin
6637 (method svn-fetch)
6638 (uri (svn-reference
6639 (url (string-append "svn://www.tug.org/texlive/tags/"
6640 %texlive-tag "/Master/texmf-dist/"
6641 "/fonts/type1/public/xypic"))
6642 (revision %texlive-revision)))
6643 (file-name (string-append name "-type1-" version "-checkout"))
6644 (sha256
6645 (base32
6646 "1bln89wib7g3hcv2jny3qi6jb73k9d2vbgx3wnnjwp3ryg0846if"))))
6647 ("xypic-enc"
6648 ,(origin
6649 (method svn-fetch)
6650 (uri (svn-reference
6651 (url (string-append "svn://www.tug.org/texlive/tags/"
6652 %texlive-tag "/Master/texmf-dist/"
6653 "/fonts/enc/dvips/xypic"))
6654 (revision %texlive-revision)))
6655 (file-name (string-append name "-enc-" version "-checkout"))
6656 (sha256
6657 (base32
6658 "0yi8vms3203l3p5slnhrrlzzp0f0jw77fkcvcaicrz2vmw9z99x7"))))))
6659 (home-page "https://www.ctan.org/pkg/xypic")
6660 (synopsis "Fonts for XY-pic")
6661 (description "This package provides the XY-pic fonts.")
6662 (license license:gpl3+)))
31595689
PN
6663
6664(define-public texlive-bibtex
6665 (package
6666 (name "texlive-bibtex")
6667 (version (number->string %texlive-revision))
6668 (source
6669 (origin
6670 (method svn-fetch)
6671 (uri (svn-reference
6672 (url (string-append "svn://www.tug.org/texlive/tags/"
6673 %texlive-tag "/Master/texmf-dist/"
6674 "/bibtex"))
6675 (revision %texlive-revision)))
6676 (file-name (string-append name "-" version "-checkout"))
6677 (sha256
6678 (base32
d4d9a1ec 6679 "0hnbs0s1znbn32hfcsyijl39z81sdb00jf092a4blqz421qs2mbv"))))
31595689
PN
6680 (build-system trivial-build-system)
6681 (arguments
6682 `(#:modules ((guix build utils))
6683 #:builder
6684 (begin
6685 (use-modules (guix build utils))
6686 (let ((target (string-append (assoc-ref %outputs "out")
6687 "/share/texmf-dist/bibtex")))
6688 (mkdir-p target)
6689 (copy-recursively (assoc-ref %build-inputs "source") target)
6690 #t))))
6691 (home-page "https://www.ctan.org/pkg/bibtex")
6692 (synopsis "Process bibliographies for LaTeX")
6693 (description
6694 "BibTeX allows the user to store his citation data in generic form, while
6695printing citations in a document in the form specified by a BibTeX style, to
6696be specified in the document itself (one often needs a LaTeX citation-style
6697package, such as @command{natbib} as well).")
6698 (license license:knuth)))
744b883e
PN
6699
6700(define-public texlive-fonts-charter
6701 (package
6702 (name "texlive-fonts-charter")
6703 (version (number->string %texlive-revision))
6704 (source (origin
6705 (method svn-fetch)
6706 (uri (svn-reference
6707 (url (string-append "svn://www.tug.org/texlive/tags/"
6708 %texlive-tag "/Master/texmf-dist/"
6709 "/fonts/type1/bitstrea/charter"))
6710 (revision %texlive-revision)))
6711 (file-name (string-append name "-" version "-checkout"))
6712 (sha256
6713 (base32
6714 "0yvib45xxff3jm5270zij4q888pivbc18cqs7lz4pqfhn1am4wnv"))))
6715 (build-system trivial-build-system)
6716 (arguments
6717 `(#:modules ((guix build utils)
6718 (ice-9 match))
6719 #:builder
6720 (begin
6721 (use-modules (guix build utils)
6722 (ice-9 match))
6723 (let ((root (string-append (assoc-ref %outputs "out")
6724 "/share/texmf-dist/"))
6725 (pkgs '(("source" . "fonts/type1/bitstrea/charter")
6726 ("charter-afm" . "fonts/afm/bitstrea/charter")
6727 ("charter-tfm" . "fonts/tfm/bitstrea/charter"))))
6728 (for-each (match-lambda
6729 ((pkg . dir)
6730 (let ((target (string-append root dir)))
6731 (mkdir-p target)
6732 (copy-recursively (assoc-ref %build-inputs pkg)
6733 target))))
6734 pkgs)
6735 #t))))
6736 (native-inputs
6737 `(("charter-afm"
6738 ,(origin
6739 (method svn-fetch)
6740 (uri (svn-reference
6741 (url (string-append "svn://www.tug.org/texlive/tags/"
6742 %texlive-tag "/Master/texmf-dist/"
6743 "/fonts/afm/bitstrea/charter"))
6744 (revision %texlive-revision)))
6745 (file-name (string-append name "-afm-" version "-checkout"))
6746 (sha256
6747 (base32
6748 "02nbkqrlr3vypnzslmr7dxg1353mmc0rl4ynx0s6qbvf313fq76a"))))
6749 ("charter-tfm"
6750 ,(origin
6751 (method svn-fetch)
6752 (uri (svn-reference
6753 (url (string-append "svn://www.tug.org/texlive/tags/"
6754 %texlive-tag "/Master/texmf-dist/"
6755 "/fonts/tfm/bitstrea/charter"))
6756 (revision %texlive-revision)))
6757 (file-name (string-append name "-tfm-" version "-checkout"))
6758 (sha256
6759 (base32
6760 "0j7ci9vprivbhac70aq0z7m23hqcpx1g0i3wp1k0h8ilhimj80xk"))))))
6761 (home-page "https://www.ctan.org/pkg/charter")
6762 (synopsis "Charter fonts for TeX")
6763 (description "A commercial text font donated for the common good. Support
6764for use with LaTeX is available in @code{freenfss}, part of
6765@command{psnfss}. ")
6766 (license (license:non-copyleft (string-append "http://mirrors.ctan.org/"
6767 "fonts/charter/readme.charter")))))
a5bfedb4
PN
6768
6769(define-public texlive-context-base
6770 (package
6771 (name "texlive-context-base")
6772 (version (number->string %texlive-revision))
6773 (source (origin
6774 (method svn-fetch)
6775 (uri (svn-reference
6776 (url (string-append "svn://www.tug.org/texlive/tags/"
6777 %texlive-tag "/Master/texmf-dist/"
6778 "/tex/context/base"))
6779 (revision %texlive-revision)))
6780 (file-name (string-append name "-" version "-checkout"))
6781 (sha256
6782 (base32
d4d9a1ec 6783 "0rlx4qqijms1n64gjx475kvip8l322fh7v17zkmwp1l1g0w3vlyz"))))
a5bfedb4
PN
6784 (build-system trivial-build-system)
6785 (arguments
6786 `(#:modules ((guix build utils))
6787 #:builder
6788 (begin
6789 (use-modules (guix build utils))
6790 (let ((target (string-append (assoc-ref %outputs "out")
6791 "/share/texmf-dist/tex/context/case")))
6792 (mkdir-p target)
6793 (copy-recursively (assoc-ref %build-inputs "source") target)
6794 #t))))
6795 (home-page "https://www.ctan.org/pkg/context")
6796 (synopsis "Full featured, parameter driven macro package for TeX")
6797 (description "A full featured, parameter driven macro package, which fully
6798supports advanced interactive documents. See the ConTeXt garden for a wealth
6799of support information.")
6800 (license license:gpl2+)))
63133706
RW
6801
6802(define-public texlive-latex-beamer
6803 (package
6804 (name "texlive-latex-beamer")
6805 (version (number->string %texlive-revision))
6806 (source (origin
6807 (method svn-fetch)
6808 (uri (svn-reference
6809 (url (string-append "svn://www.tug.org/texlive/tags/"
6810 %texlive-tag "/Master/texmf-dist/"
6811 "/tex/latex/beamer"))
6812 (revision %texlive-revision)))
6813 (file-name (string-append name "-" version "-checkout"))
6814 (sha256
6815 (base32
6816 "09y3qwbj0nckshvg9afgwcv9v3zdif1d7bnpzrggsa1fbr80mgk2"))))
6817 (build-system trivial-build-system)
6818 (outputs '("out" "doc"))
6819 (arguments
6820 `(#:modules ((guix build utils))
6821 #:builder
6822 (begin
6823 (use-modules (guix build utils))
6824 (let ((target (string-append (assoc-ref %outputs "out")
6825 "/share/texmf-dist/tex/latex/beamer"))
6826 (docs (string-append (assoc-ref %outputs "doc")
6827 "/share/texmf-dist/doc/latex/beamer/")))
6828 (mkdir-p target)
6829 (copy-recursively (assoc-ref %build-inputs "source") target)
6830
6831 (mkdir-p docs)
6832 (copy-recursively (assoc-ref %build-inputs "docs") docs)
6833 #t))))
6834 (propagated-inputs
6835 `(("texlive-latex-hyperref" ,texlive-latex-hyperref)
6836 ("texlive-latex-oberdiek" ,texlive-latex-oberdiek)
6837 ("texlive-latex-etoolbox" ,texlive-latex-etoolbox)
6838 ("texlive-latex-pgf" ,texlive-latex-pgf)))
6839 (native-inputs
6840 `(("docs"
6841 ,(origin
6842 (method svn-fetch)
6843 (uri (svn-reference
6844 (url (string-append "svn://www.tug.org/texlive/tags/"
6845 %texlive-tag "/Master/texmf-dist/"
6846 "/doc/latex/beamer"))
6847 (revision %texlive-revision)))
6848 (file-name (string-append name "-" version "-checkout"))
6849 (sha256
6850 (base32
6851 "102b18b9nw9dicqqgjwx0srh1mav8vh9wdvwayn741niza9hac23"))))))
6852 (home-page "https://www.ctan.org/pkg/beamer")
6853 (synopsis "LaTeX class for producing presentations and slides")
6854 (description "The beamer LaTeX class can be used for producing slides.
6855The class works in both PostScript and direct PDF output modes, using the
6856@code{pgf} graphics system for visual effects. Content is created in the
6857@code{frame} environment, and each frame can be made up of a number of slides
6858using a simple notation for specifying material to appear on each slide within
6859a frame. Short versions of title, authors, institute can also be specified as
6860optional parameters. Whole frame graphics are supported by plain frames. The
6861class supports @code{figure} and @code{table} environments, transparency
6862effects, varying slide transitions and animations.")
6863 ;; Code is dual licensed under GPLv2+ or LPPL1.3c+; documentation is
6864 ;; dual-licensed under either FDLv1.3+ or LPPL1.3c+.
6865 (license (list license:lppl1.3c+ license:gpl2+ license:fdl1.3+))))
cafd4d38
RW
6866
6867(define-public texlive-latex-xmpincl
6868 (package
6869 (name "texlive-latex-xmpincl")
6870 (version (number->string %texlive-revision))
6871 (source
6872 (origin
6873 (method svn-fetch)
6874 (uri (texlive-ref "latex" "xmpincl"))
6875 (sha256
6876 (base32
6877 "0lq3dfb4fsw955gjwllnk7cg00ciq5mva64mlpbva6g2jz117734"))))
6878 (build-system texlive-build-system)
6879 (arguments '(#:tex-directory "latex/xmpincl"))
6880 (home-page "http://www.ctan.org/pkg/xmpincl")
6881 (synopsis "Include eXtensible Metadata Platform data in pdfLaTeX")
6882 (description
6883 "The XMP (eXtensible Metadata platform) is a framework to add metadata to
6884digital material to enhance the workflow in publication. The essence is that
6885the metadata is stored in an XML file, and this XML stream is then embedded in
6886the file to which it applies.")
6887 (license license:gpl3+)))
f87dcb4d
RW
6888
6889(define-public texlive-latex-pdfx
6890 (package
6891 (name "texlive-latex-pdfx")
6892 (version (number->string %texlive-revision))
6893 (source
6894 (origin
6895 (method svn-fetch)
6896 (uri (texlive-ref "latex" "pdfx"))
6897 (sha256
6898 (base32
6899 "0ikxg8yzq78hy5b9x13d4nah46d0yvmwlqmdri06pygbx116dcac"))))
6900 (build-system texlive-build-system)
6901 (arguments
6902 '(#:tex-directory "latex/pdfx"
6903 #:phases
6904 (modify-phases %standard-phases
6905 (add-after 'unpack 'fix-encoding
6906 (lambda _
6907 (substitute* "pdfx.dtx"
6908 ((" .+umaczy") "umaczy"))
6909 #t))
6910 (add-before 'install 'install-tex-files
6911 (lambda* (#:key inputs outputs #:allow-other-keys)
6912 (let ((target (string-append (assoc-ref outputs "out")
6913 "/share/texmf-dist/tex/latex/pdfx")))
6914 (mkdir-p target)
6915 (copy-recursively (assoc-ref inputs "texlive-tex-pdfx") target)
6916 ;; Install the generated version in the "install" phase.
6917 (delete-file (string-append target "/pdfx.sty"))
6918 #t))))))
6919 (propagated-inputs
6920 `(("texlive-generic-pdftex" ,texlive-generic-pdftex)))
6921 (native-inputs
6922 `(("texlive-tex-pdfx"
6923 ,(origin
6924 (method svn-fetch)
6925 (uri (svn-reference
6926 (url (string-append "svn://www.tug.org/texlive/tags/"
6927 %texlive-tag "/Master/texmf-dist/"
6928 "/tex/latex/pdfx"))
6929 (revision %texlive-revision)))
6930 (file-name (string-append "texlive-tex-latex-pdfx-" version "-checkout"))
6931 (sha256
6932 (base32
6933 "14j1zsvqc59ims3sk34v6km8db6cimks28y5fcxcr5mi2ykvj4vf"))))))
6934 (home-page "https://www.ctan.org/pkg/pdfx")
6935 (synopsis "PDF/X and PDF/A support for pdfTeX, LuaTeX and XeTeX")
6936 (description
6937 "This package helps LaTeX users to create PDF/X, PFD/A and other
6938standards-compliant PDF documents with pdfTeX, LuaTeX and XeTeX.")
6939 (license license:lppl1.2+)))