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