gnu: Add texlive-latex-environ.
[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 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 Ricardo Wurmus <rekado@elephly.net>
10 ;;;
11 ;;; This file is part of GNU Guix.
12 ;;;
13 ;;; GNU Guix is free software; you can redistribute it and/or modify it
14 ;;; under the terms of the GNU General Public License as published by
15 ;;; the Free Software Foundation; either version 3 of the License, or (at
16 ;;; your option) any later version.
17 ;;;
18 ;;; GNU Guix is distributed in the hope that it will be useful, but
19 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
20 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 ;;; GNU General Public License for more details.
22 ;;;
23 ;;; You should have received a copy of the GNU General Public License
24 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
25
26 (define-module (gnu packages tex)
27 #:use-module ((guix licenses) #:prefix license:)
28 #:use-module (guix packages)
29 #:use-module (guix download)
30 #:use-module (guix build-system gnu)
31 #:use-module (guix build-system perl)
32 #:use-module (guix build-system trivial)
33 #:use-module (guix build-system texlive)
34 #:use-module (guix utils)
35 #:use-module (guix git-download)
36 #:use-module (guix svn-download)
37 #:use-module (gnu packages)
38 #:use-module (gnu packages autotools)
39 #:use-module (gnu packages bash)
40 #:use-module (gnu packages compression)
41 #:use-module (gnu packages fontutils)
42 #:use-module (gnu packages gd)
43 #:use-module (gnu packages ghostscript)
44 #:use-module (gnu packages gtk)
45 #:use-module (gnu packages icu4c)
46 #:use-module (gnu packages image)
47 #:use-module (gnu packages lua)
48 #:use-module (gnu packages multiprecision)
49 #:use-module (gnu packages pdf)
50 #:use-module (gnu packages perl)
51 #:use-module (gnu packages pkg-config)
52 #:use-module (gnu packages python)
53 #:use-module (gnu packages qt)
54 #:use-module (gnu packages ruby)
55 #:use-module (gnu packages shells)
56 #:use-module (gnu packages base)
57 #:use-module (gnu packages web)
58 #:use-module (gnu packages xml)
59 #:use-module (gnu packages xorg)
60 #:use-module (gnu packages xdisorg)
61 #:autoload (gnu packages texinfo) (texinfo)
62 #:use-module (ice-9 ftw)
63 #:use-module (ice-9 match)
64 #:use-module ((srfi srfi-1) #:hide (zip)))
65
66 (define texlive-extra-src
67 (origin
68 (method url-fetch)
69 (uri "ftp://tug.org/historic/systems/texlive/2016/texlive-20160523-extra.tar.xz")
70 (sha256 (base32
71 "0q4a92zmwhn4ry6xgrp4k8wq11ax2sg9rg9yrsrdkr719y0x887a"))))
72
73 (define texlive-texmf-src
74 (origin
75 (method url-fetch)
76 (uri "ftp://tug.org/historic/systems/texlive/2016/texlive-20160523b-texmf.tar.xz")
77 (patches (search-patches "texlive-texmf-CVE-2016-10243.patch"))
78 (patch-flags '("-p2"))
79 (sha256 (base32
80 "1dv8vgfzpczqw82hv9g7a8djhhyzywljmrarlcyy6g2qi5q51glr"))))
81
82 (define-public texlive-bin
83 (package
84 (name "texlive-bin")
85 (version "2016")
86 (source
87 (origin
88 (method url-fetch)
89 (uri "ftp://tug.org/historic/systems/texlive/2016/texlive-20160523b-source.tar.xz")
90 (sha256 (base32
91 "1v91vahxlxkdra0qz3f132vvx5d9cx2jy84yl1hkch0agyj2rcx8"))))
92 (build-system gnu-build-system)
93 (inputs
94 `(("texlive-extra-src" ,texlive-extra-src)
95 ("cairo" ,cairo)
96 ("fontconfig" ,fontconfig)
97 ("fontforge" ,fontforge)
98 ("freetype" ,freetype)
99 ("gd" ,gd)
100 ("gmp" ,gmp)
101 ("ghostscript" ,ghostscript)
102 ("graphite2" ,graphite2)
103 ("harfbuzz" ,harfbuzz)
104 ("icu4c" ,icu4c)
105 ("libpaper" ,libpaper)
106 ("libpng" ,libpng)
107 ("libxaw" ,libxaw)
108 ("libxt" ,libxt)
109 ("mpfr" ,mpfr)
110 ("perl" ,perl)
111 ("pixman" ,pixman)
112 ("poppler" ,poppler)
113 ("potrace" ,potrace)
114 ("python" ,python-2) ; incompatible with Python 3 (print syntax)
115 ("ruby" ,ruby)
116 ("tcsh" ,tcsh)
117 ("teckit" ,teckit)
118 ("zlib" ,zlib)
119 ("zziplib" ,zziplib)))
120 (native-inputs
121 `(("pkg-config" ,pkg-config)))
122 (arguments
123 `(#:out-of-source? #t
124 #:configure-flags
125 `("--disable-native-texlive-build"
126 "--with-system-cairo"
127 "--with-system-freetype2"
128 "--with-system-gd"
129 "--with-system-gmp"
130 "--with-system-graphite2"
131 "--with-system-harfbuzz"
132 "--with-system-icu"
133 "--with-system-libgs"
134 "--with-system-libpaper"
135 "--with-system-libpng"
136 "--with-system-mpfr"
137 "--with-system-pixman"
138 "--with-system-poppler"
139 "--with-system-potrace"
140 "--with-system-teckit"
141 "--with-system-xpdf"
142 "--with-system-zlib"
143 "--with-system-zziplib")
144
145 ;; Disable tests on mips64 to cope with a failure of luajiterr.test.
146 ;; XXX FIXME fix luajit properly on mips64.
147 #:tests? ,(not (string-prefix? "mips64" (or (%current-target-system)
148 (%current-system))))
149 #:phases
150 (modify-phases %standard-phases
151 (add-after 'install 'postint
152 (lambda* (#:key inputs outputs #:allow-other-keys #:rest args)
153 (let* ((out (assoc-ref outputs "out"))
154 (share (string-append out "/share"))
155 (texlive-extra (assoc-ref inputs "texlive-extra-src"))
156 (unpack (assoc-ref %standard-phases 'unpack))
157 (patch-source-shebangs
158 (assoc-ref %standard-phases 'patch-source-shebangs)))
159 ;; Create symbolic links for the latex variants and their
160 ;; man pages.
161 (with-directory-excursion (string-append out "/bin/")
162 (for-each symlink
163 '("pdftex" "pdftex" "xetex" "luatex")
164 '("latex" "pdflatex" "xelatex" "lualatex")))
165 (with-directory-excursion (string-append share "/man/man1/")
166 (symlink "luatex.1" "lualatex.1"))
167 ;; Unpack texlive-extra and install tlpkg.
168 (mkdir "texlive-extra")
169 (with-directory-excursion "texlive-extra"
170 (apply unpack (list #:source texlive-extra))
171 (apply patch-source-shebangs (list #:source texlive-extra))
172 (system* "mv" "tlpkg" share))))))))
173 (synopsis "TeX Live, a package of the TeX typesetting system")
174 (description
175 "TeX Live provides a comprehensive TeX document production system.
176 It includes all the major TeX-related programs, macro packages, and fonts
177 that are free software, including support for many languages around the
178 world.
179
180 This package contains the binaries.")
181 (license (license:fsf-free "https://www.tug.org/texlive/copying.html"))
182 (home-page "https://www.tug.org/texlive/")))
183
184 (define-public texlive-dvips
185 (package
186 (name "texlive-dvips")
187 (version (number->string %texlive-revision))
188 (source (origin
189 (method svn-fetch)
190 (uri (svn-reference
191 (url (string-append "svn://www.tug.org/texlive/tags/"
192 %texlive-tag "/Master/texmf-dist/"
193 "/dvips"))
194 (revision %texlive-revision)))
195 (sha256
196 (base32
197 "0fcy2hpapbj01ncpjj3v39yhr0jjxb6rm13qaxjjw66s3vydxls1"))))
198 (build-system trivial-build-system)
199 (arguments
200 `(#:modules ((guix build utils))
201 #:builder
202 (begin
203 (use-modules (guix build utils))
204 (let ((target (string-append (assoc-ref %outputs "out")
205 "/share/texmf-dist/dvips")))
206 (mkdir-p target)
207 (copy-recursively (assoc-ref %build-inputs "source") target)
208 #t))))
209 (home-page "http://www.ctan.org/pkg/dvips")
210 (synopsis "DVI to PostScript drivers")
211 (description "This package provides files needed for converting DVI files
212 to PostScript.")
213 ;; Various free software licenses apply to individual files.
214 (license (list license:lppl1.3c+
215 license:expat
216 license:lgpl3+))))
217
218 (define-public texlive-generic-unicode-data
219 (package
220 (name "texlive-generic-unicode-data")
221 (version (number->string %texlive-revision))
222 (source (origin
223 (method svn-fetch)
224 (uri (svn-reference
225 (url (string-append "svn://www.tug.org/texlive/tags/"
226 %texlive-tag "/Master/texmf-dist/"
227 "/tex/generic/unicode-data"))
228 (revision %texlive-revision)))
229 (sha256
230 (base32
231 "0ivrhp6jz31pl4z841g4ws41lmvdiwz4sslmhf02inlib79gz6r2"))))
232 (build-system trivial-build-system)
233 (arguments
234 `(#:modules ((guix build utils))
235 #:builder
236 (begin
237 (use-modules (guix build utils))
238 (let ((target (string-append (assoc-ref %outputs "out")
239 "/share/texmf-dist/tex/generic/unicode-data")))
240 (mkdir-p target)
241 (copy-recursively (assoc-ref %build-inputs "source") target)
242 #t))))
243 (home-page "http://www.ctan.org/pkg/unicode-data")
244 (synopsis "Unicode data and loaders for TeX")
245 (description "This bundle provides generic access to Unicode Consortium
246 data for TeX use. It contains a set of text files provided by the Unicode
247 Consortium which are currently all from Unicode 8.0.0, with the exception of
248 @code{MathClass.txt} which is not currently part of the Unicode Character
249 Database. Accompanying these source data are generic TeX loader files
250 allowing this data to be used as part of TeX runs, in particular in building
251 format files. Currently there are two loader files: one for general character
252 set up and one for initializing XeTeX character classes as has been carried
253 out to date by @code{unicode-letters.tex}. ")
254 (license license:lppl1.3c+)))
255
256 (define-public texlive-generic-dehyph-exptl
257 (package
258 (name "texlive-generic-dehyph-exptl")
259 (version (number->string %texlive-revision))
260 (source (origin
261 (method svn-fetch)
262 (uri (svn-reference
263 (url (string-append "svn://www.tug.org/texlive/tags/"
264 %texlive-tag "/Master/texmf-dist/"
265 "/tex/generic/dehyph-exptl"))
266 (revision %texlive-revision)))
267 (sha256
268 (base32
269 "1l9wgv99qq0ysvlxqpj4g8bl0dywbzra4g8m2kmpg2fb0i0hczap"))))
270 (build-system trivial-build-system)
271 (arguments
272 `(#:modules ((guix build utils))
273 #:builder
274 (begin
275 (use-modules (guix build utils))
276 (let ((target (string-append (assoc-ref %outputs "out")
277 "/share/texmf-dist/tex/generic/dehyph-exptl")))
278 (mkdir-p target)
279 (copy-recursively (assoc-ref %build-inputs "source") target)
280 #t))))
281 (home-page "http://projekte.dante.de/Trennmuster/WebHome")
282 (synopsis "Hyphenation patterns for German")
283 (description "The package provides experimental hyphenation patterns for
284 the German language, covering both traditional and reformed orthography. The
285 patterns can be used with packages Babel and hyphsubst from the Oberdiek
286 bundle.")
287 ;; Hyphenation patterns are under the Expat license; documentation is
288 ;; under LPPL.
289 (license (list license:expat license:lppl))))
290
291 (define-public texlive-generic-tex-ini-files
292 (package
293 (name "texlive-generic-tex-ini-files")
294 (version (number->string %texlive-revision))
295 (source (origin
296 (method svn-fetch)
297 (uri (svn-reference
298 (url (string-append "svn://www.tug.org/texlive/tags/"
299 %texlive-tag "/Master/texmf-dist/"
300 "/tex/generic/tex-ini-files"))
301 (revision %texlive-revision)))
302 (sha256
303 (base32
304 "1wh42n1lmzcvi3g6mm31nm3yd5ha5bl260xqc444jg1m9fdp3wz5"))))
305 (build-system trivial-build-system)
306 (arguments
307 `(#:modules ((guix build utils))
308 #:builder
309 (begin
310 (use-modules (guix build utils))
311 (let ((target (string-append (assoc-ref %outputs "out")
312 "/share/texmf-dist/tex/generic/tex-ini-files")))
313 (mkdir-p target)
314 (copy-recursively (assoc-ref %build-inputs "source") target)
315 #t))))
316 (home-page "http://ctan.org/pkg/tex-ini-files")
317 (synopsis "Files for creating TeX formats")
318 (description "This bundle provides a collection of model \".ini\" files
319 for creating TeX formats. These files are commonly used to introduced
320 distribution-dependent variations in formats. They are also used to
321 allow existing format source files to be used with newer engines, for example
322 to adapt the plain e-TeX source file to work with XeTeX and LuaTeX.")
323 (license license:public-domain)))
324
325 (define-public texlive-generic-hyph-utf8
326 (package
327 (name "texlive-generic-hyph-utf8")
328 (version (number->string %texlive-revision))
329 (source (origin
330 (method svn-fetch)
331 (uri (svn-reference
332 (url (string-append "svn://www.tug.org/texlive/tags/"
333 %texlive-tag "/Master/texmf-dist/"
334 "/tex/generic/hyph-utf8"))
335 (revision %texlive-revision)))
336 (sha256
337 (base32
338 "0ghizcz7ps16dzfqf66wwg5i181assc6qsm0g7g5dbmp909931vi"))))
339 (build-system trivial-build-system)
340 (arguments
341 `(#:modules ((guix build utils))
342 #:builder
343 (begin
344 (use-modules (guix build utils))
345 (let ((target (string-append (assoc-ref %outputs "out")
346 "/share/texmf-dist/tex/generic/hyph-utf8")))
347 (mkdir-p target)
348 (copy-recursively (assoc-ref %build-inputs "source") target)
349 #t))))
350 (home-page "http://ctan.org/pkg/hyph-utf8")
351 (synopsis "Hyphenation patterns expressed in UTF-8")
352 (description "Modern native UTF-8 engines such as XeTeX and LuaTeX need
353 hyphenation patterns in UTF-8 format, whereas older systems require
354 hyphenation patterns in the 8-bit encoding of the font in use (such encodings
355 are codified in the LaTeX scheme with names like OT1, T2A, TS1, OML, LY1,
356 etc). The present package offers a collection of conversions of existing
357 patterns to UTF-8 format, together with converters for use with 8-bit fonts in
358 older systems. Since hyphenation patterns for Knuthian-style TeX systems are
359 only read at iniTeX time, it is hoped that the UTF-8 patterns, with their
360 converters, will completely supplant the older patterns.")
361 ;; Individual files each have their own license. Most of these files are
362 ;; independent hyphenation patterns.
363 (license (list license:lppl1.0+
364 license:lppl1.2+
365 license:lppl1.3
366 license:lppl1.3+
367 license:lppl1.3a+
368 license:lgpl2.1
369 license:lgpl2.1+
370 license:lgpl3+
371 license:gpl2+
372 license:gpl3+
373 license:mpl1.1
374 license:asl2.0
375 license:expat
376 license:bsd-3
377 license:cc0
378 license:public-domain
379 license:wtfpl2))))
380
381 (define-public texlive-metafont-base
382 (package
383 (name "texlive-metafont-base")
384 (version (number->string %texlive-revision))
385 (source (origin
386 (method svn-fetch)
387 (uri (svn-reference
388 (url (string-append "svn://www.tug.org/texlive/tags/"
389 %texlive-tag "/Master/texmf-dist/"
390 "/metafont"))
391 (revision %texlive-revision)))
392 (sha256
393 (base32
394 "1yl4n8cn5xqk2nc22zgzq6ymd7bhm6xx1mz3azip7i3ki4bhb5q5"))))
395 (build-system gnu-build-system)
396 (arguments
397 `(#:tests? #f ; no test target
398 #:phases
399 (modify-phases %standard-phases
400 (delete 'configure)
401 (replace 'build
402 (lambda* (#:key inputs #:allow-other-keys)
403 (let ((cwd (getcwd)))
404 (setenv "MFINPUTS"
405 (string-append cwd "/base:"
406 cwd "/misc:"
407 cwd "/roex:"
408 cwd "/feynmf:"
409 cwd "/mfpic:"
410 cwd "/config")))
411 (mkdir "build")
412 (with-directory-excursion "build"
413 (zero? (system* "inimf" "mf.mf")))))
414 (replace 'install
415 (lambda* (#:key outputs #:allow-other-keys)
416 (let* ((out (assoc-ref outputs "out"))
417 (base (string-append out "/share/texmf-dist/web2c"))
418 (mf (string-append out "/share/texmf-dist/metafont/base")))
419 (mkdir-p base)
420 (mkdir-p mf)
421 (install-file "build/mf.base" base)
422 (copy-recursively "base" mf)
423 #t))))))
424 (native-inputs
425 `(("texlive-bin" ,texlive-bin)))
426 (home-page "http://www.ctan.org/pkg/metafont")
427 (synopsis "Metafont base files")
428 (description "This package provides the Metafont base files needed to
429 build fonts using the Metafont system.")
430 (license license:knuth)))
431
432 (define-public texlive-fonts-cm
433 (package
434 (name "texlive-fonts-cm")
435 (version (number->string %texlive-revision))
436 (source (origin
437 (method svn-fetch)
438 (uri (svn-reference
439 (url (string-append "svn://www.tug.org/texlive/tags/"
440 %texlive-tag "/Master/texmf-dist/"
441 "/fonts/source/public/cm"))
442 (revision %texlive-revision)))
443 (sha256
444 (base32
445 "045k5b9rdmbxpy1a3006l1x96z1rd18vg3cwrvnld9bqybw5qz44"))))
446 (build-system gnu-build-system)
447 (arguments
448 `(#:modules ((guix build gnu-build-system)
449 (guix build utils)
450 (srfi srfi-1)
451 (srfi srfi-26))
452 #:tests? #f ; no tests
453 #:phases
454 (modify-phases %standard-phases
455 (delete 'configure)
456 (replace 'build
457 (lambda* (#:key inputs #:allow-other-keys)
458 (let ((mf (assoc-ref inputs "texlive-metafont-base")))
459 ;; Tell mf where to find mf.base
460 (setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
461 ;; Tell mf where to look for source files
462 (setenv "MFINPUTS"
463 (string-append (getcwd) ":"
464 mf "/share/texmf-dist/metafont/base")))
465 (mkdir "build")
466 (every (lambda (font)
467 (format #t "building font ~a\n" font)
468 (zero? (system* "mf" "-progname=mf"
469 "-output-directory=build"
470 (string-append "\\"
471 "mode:=ljfour; "
472 "mag:=1; "
473 "batchmode; "
474 "input "
475 (basename font ".mf")))))
476 (find-files "." "cm(.*[0-9]+.*|inch)\\.mf$"))))
477 (replace 'install
478 (lambda* (#:key outputs #:allow-other-keys)
479 (let* ((out (assoc-ref outputs "out"))
480 (tfm (string-append
481 out "/share/texmf-dist/fonts/tfm/public/cm"))
482 (mf (string-append
483 out "/share/texmf-dist/fonts/source/public/cm")))
484 (for-each (cut install-file <> tfm)
485 (find-files "build" "\\.*"))
486 (for-each (cut install-file <> mf)
487 (find-files "." "\\.mf"))
488 #t))))))
489 (native-inputs
490 `(("texlive-bin" ,texlive-bin)
491 ("texlive-metafont-base" ,texlive-metafont-base)))
492 (home-page "http://www.ctan.org/pkg/cm")
493 (synopsis "Computer Modern fonts for TeX")
494 (description "This package provides the Computer Modern fonts by Donald
495 Knuth. The Computer Modern font family is a large collection of text,
496 display, and mathematical fonts in a range of styles, based on Monotype Modern
497 8A.")
498 (license license:knuth)))
499
500 (define-public texlive-fonts-knuth-lib
501 (package
502 (name "texlive-fonts-knuth-lib")
503 (version (number->string %texlive-revision))
504 (source (origin
505 (method svn-fetch)
506 (uri (svn-reference
507 (url (string-append "svn://www.tug.org/texlive/tags/"
508 %texlive-tag "/Master/texmf-dist/"
509 "/fonts/source/public/knuth-lib"))
510 (revision %texlive-revision)))
511 (sha256
512 (base32
513 "0in9aqyi8jkyf9d16z0li50z5fpwj1iwgwm83gmvwqcf7chfs04y"))))
514 (build-system gnu-build-system)
515 (arguments
516 `(#:modules ((guix build gnu-build-system)
517 (guix build utils)
518 (srfi srfi-26))
519 #:tests? #f ; no tests
520 #:phases
521 (modify-phases %standard-phases
522 (delete 'configure)
523 (replace 'build
524 (lambda* (#:key inputs #:allow-other-keys)
525 (let ((mf (assoc-ref inputs "texlive-metafont-base")))
526 ;; Tell mf where to find mf.base
527 (setenv "MFBASES"
528 (string-append mf "/share/texmf-dist/web2c"))
529 ;; Tell mf where to look for source files
530 (setenv "MFINPUTS"
531 (string-append (getcwd) ":"
532 mf "/share/texmf-dist/metafont/base")))
533 (mkdir "build")
534 (zero? (system* "mf" "-progname=mf"
535 "-output-directory=build"
536 (string-append "\\"
537 "mode:=ljfour; "
538 "mag:=1; "
539 "batchmode; "
540 "input manfnt")))))
541 (replace 'install
542 (lambda* (#:key outputs #:allow-other-keys)
543 (let* ((out (assoc-ref outputs "out"))
544 (tfm (string-append
545 out "/share/texmf-dist/fonts/tfm/public/knuth-lib"))
546 (mf (string-append
547 out "/share/texmf-dist/fonts/source/public/knuth-lib")))
548 (for-each (cut install-file <> tfm)
549 (find-files "build" "\\.*"))
550 (for-each (cut install-file <> mf)
551 (find-files "." "\\.mf"))
552 #t))))))
553 (native-inputs
554 `(("texlive-bin" ,texlive-bin)
555 ("texlive-metafont-base" ,texlive-metafont-base)))
556 (home-page "https://www.ctan.org/pkg/knuth-lib")
557 (synopsis "Small library of METAFONT sources")
558 (description "This is a collection of core TeX and METAFONT macro files
559 from Donald Knuth, including the plain format, plain base, and the MF logo
560 fonts.")
561 (license license:knuth)))
562
563 (define-public texlive-fonts-latex
564 (package
565 (name "texlive-fonts-latex")
566 (version (number->string %texlive-revision))
567 (source (origin
568 (method svn-fetch)
569 (uri (svn-reference
570 (url (string-append "svn://www.tug.org/texlive/tags/"
571 %texlive-tag "/Master/texmf-dist/"
572 "/fonts/source/public/latex-fonts"))
573 (revision %texlive-revision)))
574 (sha256
575 (base32
576 "0ypsm4xv9cw0jckk2qc7gi9hcmhf31mrg56pz3llyx3yd9vq2lps"))))
577 (build-system gnu-build-system)
578 (arguments
579 `(#:modules ((guix build gnu-build-system)
580 (guix build utils)
581 (srfi srfi-1)
582 (srfi srfi-26))
583 #:tests? #f ; no tests
584 #:phases
585 (modify-phases %standard-phases
586 (delete 'configure)
587 (replace 'build
588 (lambda* (#:key inputs #:allow-other-keys)
589 (let ((mf (assoc-ref inputs "texlive-metafont-base")))
590 ;; Tell mf where to find mf.base
591 (setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
592 ;; Tell mf where to look for source files
593 (setenv "MFINPUTS"
594 (string-append (getcwd) ":"
595 mf "/share/texmf-dist/metafont/base:"
596 (assoc-ref inputs "texlive-fonts-cm")
597 "/share/texmf-dist/fonts/source/public/cm")))
598 (mkdir "build")
599 (every (lambda (font)
600 (format #t "building font ~a\n" font)
601 (zero? (system* "mf" "-progname=mf"
602 "-output-directory=build"
603 (string-append "\\"
604 "mode:=ljfour; "
605 "mag:=1; "
606 "batchmode; "
607 "input " font))))
608 '("icmcsc10" "icmex10" "icmmi8" "icmsy8" "icmtt8"
609 "ilasy8" "ilcmss8" "ilcmssb8" "ilcmssi8"
610 "lasy5" "lasy6" "lasy7" "lasy8" "lasy9" "lasy10" "lasyb10"
611 "lcircle10" "lcirclew10" "lcmss8" "lcmssb8" "lcmssi8"
612 "line10" "linew10"))))
613 (replace 'install
614 (lambda* (#:key outputs #:allow-other-keys)
615 (let* ((out (assoc-ref outputs "out"))
616 (tfm (string-append
617 out "/share/texmf-dist/fonts/tfm/public/latex-fonts"))
618 (mf (string-append
619 out "/share/texmf-dist/fonts/source/public/latex-fonts")))
620 (for-each (cut install-file <> tfm)
621 (find-files "build" "\\.*"))
622 (for-each (cut install-file <> mf)
623 (find-files "." "\\.mf"))
624 #t))))))
625 (native-inputs
626 `(("texlive-bin" ,texlive-bin)
627 ("texlive-metafont-base" ,texlive-metafont-base)
628 ("texlive-fonts-cm" ,texlive-fonts-cm)))
629 (home-page "http://www.ctan.org/pkg/latex-fonts")
630 (synopsis "Collection of fonts used in LaTeX distributions")
631 (description "This is a collection of fonts for use with standard LaTeX
632 packages and classes. It includes invisible fonts (for use with the slides
633 class), line and circle fonts (for use in the picture environment) and LaTeX
634 symbol fonts.")
635 (license license:lppl1.2+)))
636
637 (define-public texlive-fonts-amsfonts
638 (package
639 (name "texlive-fonts-amsfonts")
640 (version (number->string %texlive-revision))
641 (source (origin
642 (method svn-fetch)
643 (uri (svn-reference
644 (url (string-append "svn://www.tug.org/texlive/tags/"
645 %texlive-tag "/Master/texmf-dist/"
646 "/fonts/source/public/amsfonts"))
647 (revision %texlive-revision)))
648 (sha256
649 (base32
650 "07h20rvpbdb4k72hzmjkyb29426zr9wxsfp6yd4ajbbpd3vx8grb"))))
651 (build-system gnu-build-system)
652 (arguments
653 `(#:modules ((guix build gnu-build-system)
654 (guix build utils)
655 (srfi srfi-1)
656 (srfi srfi-26))
657 #:tests? #f ; no tests
658 #:phases
659 (modify-phases %standard-phases
660 (delete 'configure)
661 (replace 'build
662 (lambda* (#:key inputs #:allow-other-keys)
663 (let ((mf (assoc-ref inputs "texlive-metafont-base"))
664 (cwd (getcwd)))
665 ;; Tell mf where to find mf.base
666 (setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
667 ;; Tell mf where to look for source files
668 (setenv "MFINPUTS"
669 (string-append cwd ":"
670 cwd "/cmextra:"
671 cwd "/cyrillic:"
672 cwd "/dummy:"
673 cwd "/symbols:"
674 mf "/share/texmf-dist/metafont/base:"
675 (assoc-ref inputs "texlive-fonts-cm")
676 "/share/texmf-dist/fonts/source/public/cm")))
677 (mkdir "build")
678 (every (lambda (font)
679 (format #t "building font ~a\n" (basename font ".mf"))
680 (with-directory-excursion (dirname font)
681 (zero? (system* "mf" "-progname=mf"
682 "-output-directory=../build"
683 (string-append "\\"
684 "mode:=ljfour; "
685 "mag:=1; "
686 "nonstopmode; "
687 "input "
688 (getcwd) "/"
689 (basename font ".mf"))))))
690 (find-files "." "[0-9]+\\.mf$"))))
691 (replace 'install
692 (lambda* (#:key outputs #:allow-other-keys)
693 (let* ((out (assoc-ref outputs "out"))
694 (tfm (string-append
695 out "/share/texmf-dist/fonts/tfm/public/amsfonts"))
696 (mf (string-append
697 out "/share/texmf-dist/fonts/source/public/amsfonts")))
698 (for-each (cut install-file <> tfm)
699 (find-files "build" "\\.*"))
700 (for-each (cut install-file <> mf)
701 (find-files "." "\\.mf"))
702 #t))))))
703 (native-inputs
704 `(("texlive-fonts-cm" ,texlive-fonts-cm)
705 ("texlive-metafont-base" ,texlive-metafont-base)
706 ("texlive-bin" ,texlive-bin)))
707 (home-page "http://www.ctan.org/pkg/amsfonts")
708 (synopsis "TeX fonts from the American Mathematical Society")
709 (description
710 "This package provides an extended set of fonts for use in mathematics,
711 including: extra mathematical symbols; blackboard bold letters (uppercase
712 only); fraktur letters; subscript sizes of bold math italic and bold Greek
713 letters; subscript sizes of large symbols such as sum and product; added sizes
714 of the Computer Modern small caps font; cyrillic fonts (from the University of
715 Washington); Euler mathematical fonts. All fonts are provided as Adobe Type 1
716 files, and all except the Euler fonts are provided as Metafont source. The
717 distribution also includes the canonical Type 1 versions of the Computer
718 Modern family of fonts. The Euler fonts are supported by separate packages;
719 details can be found in the documentation.")
720 (license license:silofl1.1)))
721
722 (define-public texlive-latex-amsfonts
723 (package
724 (name "texlive-latex-amsfonts")
725 (version (number->string %texlive-revision))
726 (source (origin
727 (method svn-fetch)
728 (uri (texlive-ref "latex" "amsfonts"))
729 (sha256
730 (base32
731 "0slzfv5h2m03b2xvm2sasznz4azh6rgi069z161dja3l8rln79hm"))))
732 (build-system texlive-build-system)
733 (arguments '(#:tex-directory "latex/amsfonts"))
734 (native-inputs
735 `(("texlive-fonts-cm" ,texlive-fonts-cm)
736 ("texlive-metafont-base" ,texlive-metafont-base)))
737 (home-page "http://www.ctan.org/pkg/amsfonts")
738 (synopsis "TeX fonts from the American Mathematical Society")
739 (description
740 "This package provides basic LaTeX support for the symbol fonts provides
741 by the amsfonts package. It provides @code{amsfonts.sty}, with names of
742 individual symbols defined in @code{amssymb.sty}.")
743 (license license:silofl1.1)))
744
745 ;; This provides etex.src which is needed to build various formats, including
746 ;; luatex.fmt and pdflatex.fmt
747 (define-public texlive-tex-plain
748 (package
749 (name "texlive-tex-plain")
750 (version (number->string %texlive-revision))
751 (source (origin
752 (method svn-fetch)
753 (uri (svn-reference
754 (url (string-append "svn://www.tug.org/texlive/tags/"
755 %texlive-tag "/Master/texmf-dist/"
756 "/tex/plain"))
757 (revision %texlive-revision)))
758 (sha256
759 (base32
760 "0mjgl3gscn3ps29yjambz1j9fg81ynnncb96vpprwx4xsijhsns0"))))
761 (build-system trivial-build-system)
762 (arguments
763 `(#:modules ((guix build utils))
764 #:builder
765 (begin
766 (use-modules (guix build utils))
767 (let ((target (string-append (assoc-ref %outputs "out")
768 "/share/texmf-dist/tex/plain")))
769 (mkdir-p target)
770 (copy-recursively (assoc-ref %build-inputs "source") target)
771 #t))))
772 (home-page "https://www.ctan.org/pkg/plain")
773 (synopsis "Plain TeX format and supporting files")
774 (description
775 "Contains files used to build the Plain TeX format, as described in the
776 TeXbook, together with various supporting files (some also discussed in the
777 book).")
778 (license license:knuth)))
779
780 (define-public texlive-latex-base
781 (let ((texlive-dir
782 (lambda (dir hash)
783 (origin
784 (method svn-fetch)
785 (uri (svn-reference
786 (url (string-append "svn://www.tug.org/texlive/tags/"
787 %texlive-tag "/Master/texmf-dist/"
788 dir))
789 (revision %texlive-revision)))
790 (sha256 (base32 hash))))))
791 (package
792 (name "texlive-latex-base")
793 (version (number->string %texlive-revision))
794 (source (origin
795 (method svn-fetch)
796 (uri (texlive-ref "latex" "base"))
797 (sha256
798 (base32
799 "1h9pir2hz6i9avc4lrl733p3zf4rpkg8537x1zdbhs91hvhikw9k"))))
800 (build-system gnu-build-system)
801 (arguments
802 `(#:modules ((guix build gnu-build-system)
803 (guix build utils)
804 (ice-9 match)
805 (srfi srfi-1)
806 (srfi srfi-26))
807 #:tests? #f ; no tests
808 #:phases
809 (modify-phases %standard-phases
810 (delete 'configure)
811 (replace 'build
812 (lambda* (#:key inputs #:allow-other-keys)
813 ;; Find required fonts
814 (setenv "TFMFONTS"
815 (string-append (assoc-ref inputs "texlive-fonts-cm")
816 "/share/texmf-dist/fonts/tfm/public/cm:"
817 (assoc-ref inputs "texlive-fonts-latex")
818 "/share/texmf-dist/fonts/tfm/public/latex-fonts:"
819 (assoc-ref inputs "texlive-fonts-knuth-lib")
820 "/share/texmf-dist/fonts/tfm/public/knuth-lib"))
821 (setenv "TEXINPUTS"
822 (string-append
823 (getcwd) ":"
824 (getcwd) "/build:"
825 (string-join
826 (append-map (match-lambda
827 ((_ . dir)
828 (find-files dir
829 (lambda (_ stat)
830 (eq? 'directory (stat:type stat)))
831 #:directories? #t
832 #:stat stat)))
833 inputs)
834 ":")))
835
836 ;; Create an empty texsys.cfg, because latex.ltx wants to include
837 ;; it. This file must exist and it's fine if it's empty.
838 (with-output-to-file "texsys.cfg"
839 (lambda _ (format #t "%")))
840
841 (mkdir "build")
842 (mkdir "web2c")
843 (and (zero? (system* "luatex" "-ini" "-interaction=batchmode"
844 "-output-directory=build"
845 "unpack.ins"))
846 (zero? (system* "tex" "-ini" "-interaction=batchmode"
847 "-output-directory=web2c"
848 "tex.ini"))
849 ;; LaTeX, pdfetex/pdftex, and XeTeX require e-TeX, which
850 ;; is enabled only in extended mode (activated with a
851 ;; leading asterisk). We should not use luatex here,
852 ;; because that would make the generated format files
853 ;; incompatible with any other TeX engine.
854 (every
855 (lambda (format)
856 (zero? (system* "latex" "-ini" "-interaction=batchmode"
857 "-output-directory=web2c"
858 "-translate-file=cp227.tcx"
859 (string-append "*" format ".ini"))))
860 '("latex"
861 "pdflatex"
862 "pdfetex"))
863 (every
864 (lambda (format)
865 (zero? (system* format "-ini" "-interaction=batchmode"
866 "-output-directory=web2c"
867 (string-append "*" format ".ini"))))
868 '("xetex"
869 "xelatex"))
870 (every
871 (lambda (format)
872 (zero? (system* "luatex" "-ini" "-interaction=batchmode"
873 "-output-directory=web2c"
874 (string-append format ".ini"))))
875 '("dviluatex" "dvilualatex" "luatex" "lualatex")))))
876 (replace 'install
877 (lambda* (#:key outputs #:allow-other-keys)
878 (let* ((out (assoc-ref outputs "out"))
879 (target (string-append
880 out "/share/texmf-dist/tex/latex/base"))
881 (web2c (string-append
882 out "/share/texmf-dist/web2c")))
883 (mkdir-p target)
884 (mkdir-p web2c)
885 (for-each delete-file (find-files "." "\\.(log|aux)$"))
886 (for-each (cut install-file <> target)
887 (find-files "build" ".*"))
888 (for-each (cut install-file <> web2c)
889 (find-files "web2c" ".*"))
890 ;; pdftex is really just the same as pdfetex, but since it
891 ;; doesn't have its own format file, we need to copy it.
892 (copy-file "web2c/pdfetex.fmt"
893 (string-append web2c "/pdftex.fmt"))
894 #t))))))
895 (native-inputs
896 `(("texlive-bin" ,texlive-bin)
897 ("texlive-generic-unicode-data" ,texlive-generic-unicode-data)
898 ("texlive-generic-dehyph-exptl" ,texlive-generic-dehyph-exptl)
899 ("texlive-generic-tex-ini-files" ,texlive-generic-tex-ini-files)
900 ("texlive-latex-latexconfig"
901 ,(texlive-dir "tex/latex/latexconfig/"
902 "1zb3j49cj8p75yph6c8iysjp7qbdvghwf0mn9j0l7qq3qkbz2xaf"))
903 ("texlive-generic-hyph-utf8" ,texlive-generic-hyph-utf8)
904 ("texlive-generic-hyphen"
905 ,(texlive-dir "tex/generic/hyphen/"
906 "0xim36wybw2625yd0zwlp9m2c2xrcybw58gl4rih9nkph0wqwwhd"))
907 ("texlive-generic-ruhyphen"
908 ,(texlive-dir "tex/generic/ruhyphen/"
909 "14rjkpl4zkjqs13rcf9kcd24mn2kx7i1jbdwxq8ds94bi66ylzsd"))
910 ("texlive-generic-ukrhyph"
911 ,(texlive-dir "tex/generic/ukrhyph/"
912 "1cfwdg2rhbayl3w0x1xqd36d45zbc96f029myp13s7cb6kbmbppv"))
913 ("texlive-generic-config"
914 ,(texlive-dir "tex/generic/config/"
915 "19vj088p4kkp6xll0141m4kl6ssgdzhs3g10i232khb07aqiag8s"))
916 ("texlive-tex-plain" ,texlive-tex-plain)
917 ("texlive-fonts-cm" ,texlive-fonts-cm)
918 ("texlive-fonts-latex" ,texlive-fonts-latex)
919 ("texlive-fonts-knuth-lib" ,texlive-fonts-knuth-lib)))
920 (home-page "http://www.ctan.org/pkg/latex-base")
921 (synopsis "Base sources of LaTeX")
922 (description
923 "This bundle comprises the source of LaTeX itself, together with several
924 packages which are considered \"part of the kernel\". This bundle, together
925 with the required packages, constitutes what every LaTeX distribution should
926 contain.")
927 (license license:lppl1.3c+))))
928
929 (define-public texlive-latex-filecontents
930 (package
931 (name "texlive-latex-filecontents")
932 (version (number->string %texlive-revision))
933 (source (origin
934 (method svn-fetch)
935 (uri (texlive-ref "latex" "filecontents"))
936 (sha256
937 (base32
938 "0swkbxv8vg0yizadfnvrwjb4cj0pn34v9wm6v7wqq903fdav7k7q"))))
939 (build-system texlive-build-system)
940 (arguments '(#:tex-directory "latex/filecontents"))
941 (home-page "http://www.ctan.org/pkg/filecontents")
942 (synopsis "Extended filecontents and filecontents* environments")
943 (description
944 "LaTeX2e's @code{filecontents} and @code{filecontents*} environments
945 enable a LaTeX source file to generate external files as it runs through
946 LaTeX. However, there are two limitations of these environments: they refuse
947 to overwrite existing files, and they can only be used in the preamble of a
948 document. The filecontents package removes these limitations, letting you
949 overwrite existing files and letting you use @code{filecontents} /
950 @code{filecontents*} anywhere.")
951 (license license:lppl1.3c+)))
952
953 (define-public texlive-generic-ifxetex
954 (package
955 (name "texlive-generic-ifxetex")
956 (version (number->string %texlive-revision))
957 (source (origin
958 (method svn-fetch)
959 (uri (texlive-ref "generic" "ifxetex"))
960 (sha256
961 (base32
962 "0w2xj7n0szavj329kds09q626szkc378p3w0sk022q0ln4ksz86d"))))
963 (build-system texlive-build-system)
964 (arguments
965 '(#:tex-directory "generic/ifxetex"
966 #:tex-format "xelatex"))
967 (inputs
968 `(("texlive-latex-filecontents" ,texlive-latex-filecontents)))
969 (home-page "http://www.ctan.org/pkg/ifxetex")
970 (synopsis "Am I running under XeTeX?")
971 (description
972 "This is a simple package which provides an @code{\\ifxetex} conditional,
973 so that other code can determine that it is running under XeTeX. The package
974 requires the e-TeX extensions to the TeX primitive set.")
975 (license license:lppl1.3c+)))
976
977 (define-public texlive-generic-epsf
978 (package
979 (name "texlive-generic-epsf")
980 (version (number->string %texlive-revision))
981 (source (origin
982 (method svn-fetch)
983 (uri (svn-reference
984 (url (string-append "svn://www.tug.org/texlive/tags/"
985 %texlive-tag "/Master/texmf-dist/"
986 "/tex/generic/epsf"))
987 (revision %texlive-revision)))
988 (sha256
989 (base32
990 "14w3j81ympyvg8hkk9i1xgr8a0gfnfsb2ki8qqsk5pa051za1xcy"))))
991 (build-system trivial-build-system)
992 (arguments
993 `(#:modules ((guix build utils))
994 #:builder
995 (begin
996 (use-modules (guix build utils))
997 (let ((target (string-append (assoc-ref %outputs "out")
998 "/share/texmf-dist/tex/generic/epfs")))
999 (mkdir-p target)
1000 (copy-recursively (assoc-ref %build-inputs "source") target)
1001 #t))))
1002 (home-page "http://www.ctan.org/pkg/epsf")
1003 (synopsis "Simple macros for EPS inclusion")
1004 (description
1005 "This package provides the original (and now obsolescent) graphics
1006 inclusion macros for use with dvips, still widely used by Plain TeX users (in
1007 particular). For LaTeX users, the package is nowadays (rather strongly)
1008 deprecated in favour of the more sophisticated standard LaTeX latex-graphics
1009 bundle of packages. (The latex-graphics bundle is also available to Plain TeX
1010 users, via its Plain TeX version.)")
1011 (license license:public-domain)))
1012
1013 (define-public texlive-latex-fancyvrb
1014 (package
1015 (name "texlive-latex-fancyvrb")
1016 (version (number->string %texlive-revision))
1017 (source (origin
1018 (method svn-fetch)
1019 (uri (texlive-ref "latex" "fancyvrb"))
1020 (sha256
1021 (base32
1022 "03l7140y031rr14h02i4z9zqsfvrbn7wzwxbjsrjcgrk6sdr71wv"))))
1023 (build-system texlive-build-system)
1024 (arguments
1025 '(#:tex-directory "latex/fancyvrb"
1026 ;; We exclude "fvrb-ex" to avoid a dependency on texlive-luaotfload and
1027 ;; thus texlive-luatex-lualibs.
1028 #:build-targets '("fancyvrb.ins")))
1029 (home-page "http://www.ctan.org/pkg/fancyvrb")
1030 (synopsis "Sophisticated verbatim text")
1031 (description
1032 "This package provides tools for the flexible handling of verbatim text
1033 including: verbatim commands in footnotes; a variety of verbatim environments
1034 with many parameters; ability to define new customized verbatim environments;
1035 save and restore verbatim text and environments; write and read files in
1036 verbatim mode; build \"example\" environments (showing both result and
1037 verbatim source).")
1038 (license license:lppl1.0+)))
1039
1040 (define-public texlive-latex-graphics
1041 (package
1042 (name "texlive-latex-graphics")
1043 (version (number->string %texlive-revision))
1044 (source (origin
1045 (method svn-fetch)
1046 (uri (texlive-ref "latex" "graphics"))
1047 (sha256
1048 (base32
1049 "07azyn0b1s49vbdlr6dmygrminxp72ndl24j1091hiiccvrjq3xc"))))
1050 (build-system texlive-build-system)
1051 (arguments
1052 '(#:tex-directory "latex/graphics"
1053 #:phases
1054 (modify-phases %standard-phases
1055 (add-after 'install 'install-config
1056 (lambda* (#:key inputs outputs #:allow-other-keys)
1057 (let ((cfg (assoc-ref inputs "graphics-cfg"))
1058 (target (string-append (assoc-ref outputs "out")
1059 "/share/texmf-dist/tex/latex/graphics-cfg")))
1060 (mkdir-p target)
1061 (install-file (string-append cfg "/graphics.cfg") target)
1062 (install-file (string-append cfg "/color.cfg") target)
1063 #t)))
1064 (add-after 'install 'install-defs
1065 (lambda* (#:key inputs outputs #:allow-other-keys)
1066 (let ((def (assoc-ref inputs "graphics-def"))
1067 (target (string-append (assoc-ref outputs "out")
1068 "/share/texmf-dist/tex/latex/graphics-def")))
1069 (mkdir-p target)
1070 (copy-recursively def target)
1071 #t))))))
1072 (native-inputs
1073 `(("graphics-cfg"
1074 ,(origin
1075 (method git-fetch)
1076 (uri (git-reference
1077 (url "https://github.com/latex3/graphics-cfg.git")
1078 (commit "19d1238af17df376cd46333b229579b0f7f3a41f")))
1079 (sha256
1080 (base32
1081 "12kbgbm52gmmgn8zajb74s8n5rvnxcfdvs3iyj8vcw5vrsw5i6mh"))))
1082 ("graphics-def"
1083 ,(origin
1084 (method svn-fetch)
1085 (uri (svn-reference
1086 (url (string-append "svn://www.tug.org/texlive/tags/"
1087 %texlive-tag "/Master/texmf-dist/"
1088 "/tex/latex/graphics-def"))
1089 (revision %texlive-revision)))
1090 (sha256
1091 (base32
1092 "0gi4qv6378nl84s8n1yx3hjqvv7r4lza7hpbymbl5rzwgw8qrnyb"))))))
1093 (home-page "http://www.ctan.org/pkg/latex-graphics")
1094 (synopsis "LaTeX standard graphics bundle")
1095 (description
1096 "This is a collection of LaTeX packages for producing color, including
1097 graphics (e.g. PostScript) files, and rotation and scaling of text in LaTeX
1098 documents. It comprises the packages color, graphics, graphicx, trig, epsfig,
1099 keyval, and lscape.")
1100 ;; The configuration files are released under CC0.
1101 (license (list license:lppl1.3c+
1102 license:cc0))))
1103
1104 (define-public texlive-latex-xcolor
1105 (package
1106 (name "texlive-latex-xcolor")
1107 (version (number->string %texlive-revision))
1108 (source (origin
1109 (method svn-fetch)
1110 (uri (texlive-ref "latex" "xcolor"))
1111 (sha256
1112 (base32
1113 "01n613s7bcrd2n4jfawm0k4nn2ny3aaifp2jjfif3lz4sbv31494"))))
1114 (build-system texlive-build-system)
1115 (arguments '(#:tex-directory "latex/xcolor"))
1116 (home-page "http://www.ctan.org/pkg/xcolor")
1117 (synopsis "Driver-independent color extensions for LaTeX and pdfLaTeX")
1118 (description
1119 "The package starts from the basic facilities of the colorcolor package,
1120 and provides easy driver-independent access to several kinds of color tints,
1121 shades, tones, and mixes of arbitrary colors. It allows a user to select a
1122 document-wide target color model and offers complete tools for conversion
1123 between eight color models. Additionally, there is a command for alternating
1124 row colors plus repeated non-aligned material (like horizontal lines) in
1125 tables.")
1126 (license license:lppl1.2+)))
1127
1128 (define-public texlive-latex-hyperref
1129 (package
1130 (name "texlive-latex-hyperref")
1131 (version "6.84a2")
1132 ;; The sources in the TeX Live SVN repository do not contain hluatex.dtx,
1133 ;; so we fetch the release from GitHub.
1134 (source (origin
1135 (method url-fetch)
1136 (uri (string-append "https://github.com/ho-tex/hyperref/"
1137 "archive/release-" version ".tar.gz"))
1138 (file-name (string-append name "-" version ".tar.gz"))
1139 (sha256
1140 (base32
1141 "1d3rmjgzh0025a1dza55zb6nzzlgd1y9snwx45wq1c1vf42m79h2"))))
1142 (build-system texlive-build-system)
1143 (arguments '(#:tex-directory "latex/hyperref"))
1144 (home-page "http://www.ctan.org/pkg/hyperref")
1145 (synopsis "Extensive support for hypertext in LaTeX")
1146 (description
1147 "The hyperref package is used to handle cross-referencing commands in
1148 LaTeX to produce hypertext links in the document. The package provides
1149 backends for the special set defined for HyperTeX DVI processors; for embedded
1150 pdfmark commands for processing by Acrobat Distiller (dvips and dvipsone); for
1151 dviwindo; for PDF control within pdfTeX and dvipdfm; for TeX4ht; and for VTeX
1152 pdf and HTML backends. The package is distributed with the backref and
1153 nameref packages, which make use of the facilities of hyperref.")
1154 (license license:lppl1.3+)))
1155
1156 (define-public texlive-latex-oberdiek
1157 (package
1158 (name "texlive-latex-oberdiek")
1159 (version (number->string %texlive-revision))
1160 (source (origin
1161 (method svn-fetch)
1162 (uri (texlive-ref "latex" "oberdiek"))
1163 (sha256
1164 (base32
1165 "0aswvsxgsn709xmvpcg50d2xl7vcy1ckdxb9c1cligqqfjjvviqf"))))
1166 (build-system texlive-build-system)
1167 (arguments
1168 '(#:tex-directory "latex/oberdiek"
1169 #:build-targets '("oberdiek.ins")
1170 #:phases
1171 (modify-phases %standard-phases
1172 ;; "ifpdf.ins" is not generated, so we need to process the dtx file.
1173 (add-after 'unpack 'do-not-process-ifpdf.ins
1174 (lambda _
1175 (substitute* "oberdiek.ins"
1176 (("ifpdf.ins") "ifpdf.dtx"))
1177 #t)))))
1178 (home-page "http://www.ctan.org/pkg/oberdiek")
1179 (synopsis "Bundle of packages submitted by Heiko Oberdiek")
1180 (description
1181 "The bundle comprises various LaTeX packages, providing among others:
1182 better accessibility support for PDF files; extensible chemists reaction
1183 arrows; record information about document class(es) used; and many more.")
1184 (license license:lppl1.3+)))
1185
1186 (define-public texlive-latex-tools
1187 (package
1188 (name "texlive-latex-tools")
1189 (version (number->string %texlive-revision))
1190 (source (origin
1191 (method svn-fetch)
1192 (uri (texlive-ref "latex" "tools"))
1193 (sha256
1194 (base32
1195 "052a0pch2k5zls5jlay9xxcf93rw3i60a2x28y3ip3rhbsv3xgiz"))))
1196 (build-system texlive-build-system)
1197 (arguments
1198 '(#:tex-directory "latex/tools"
1199 #:build-targets '("tools.ins")))
1200 (home-page "http://www.ctan.org/pkg/latex-tools")
1201 (synopsis "LaTeX standard tools bundle")
1202 (description
1203 "This package is a collection of (variously) simple tools provided as
1204 part of the LaTeX required tools distribution, comprising the following
1205 packages: afterpage, array, bm, calc, dcolumn, delarray, enumerate, fileerr,
1206 fontsmpl, ftnright, hhline, indentfirst, layout, longtable, multicol,
1207 rawfonts, showkeys, somedefs, tabularx, theorem, trace, varioref, verbatim,
1208 xr, and xspace.")
1209 (license license:lppl1.3+)))
1210
1211 (define-public texlive-latex-url
1212 (package
1213 (name "texlive-latex-url")
1214 (version (number->string %texlive-revision))
1215 (source (origin
1216 (method svn-fetch)
1217 (uri (svn-reference
1218 (url (string-append "svn://www.tug.org/texlive/tags/"
1219 %texlive-tag "/Master/texmf-dist/"
1220 "/tex/latex/url"))
1221 (revision %texlive-revision)))
1222 (sha256
1223 (base32
1224 "184s2543cwia5l7iibhlkl1ffbncfhjpv5p56zq0c15by5sghlac"))))
1225 (build-system trivial-build-system)
1226 (arguments
1227 `(#:modules ((guix build utils))
1228 #:builder
1229 (begin
1230 (use-modules (guix build utils))
1231 (let ((target (string-append (assoc-ref %outputs "out")
1232 "/share/texmf-dist/tex/latex/url")))
1233 (mkdir-p target)
1234 (copy-recursively (assoc-ref %build-inputs "source") target)
1235 #t))))
1236 (home-page "https://www.ctan.org/pkg/url")
1237 (synopsis "Verbatim with URL-sensitive line breaks")
1238 (description "The command @code{\\url} is a form of verbatim command that
1239 allows linebreaks at certain characters or combinations of characters, accepts
1240 reconfiguration, and can usually be used in the argument to another command.
1241 The command is intended for email addresses, hypertext links,
1242 directories/paths, etc., which normally have no spaces, so by default the
1243 package ignores spaces in its argument. However, a package option allows
1244 spaces, which is useful for operating systems where spaces are a common part
1245 of file names.")
1246 ;; The license header states that it is under LPPL version 2 or later, but
1247 ;; the latest version is 1.3c.
1248 (license license:lppl1.3c+)))
1249
1250 (define-public texlive-latex-l3kernel
1251 (package
1252 (name "texlive-latex-l3kernel")
1253 (version (number->string %texlive-revision))
1254 (source (origin
1255 (method svn-fetch)
1256 (uri (texlive-ref "latex" "l3kernel"))
1257 (sha256
1258 (base32
1259 "0r0wfk594j8wkdqhh21haimwsfq8x5jch4ldm21hkzk5dnmvpbg6"))))
1260 (build-system texlive-build-system)
1261 (arguments
1262 '(#:tex-directory "latex/l3kernel"))
1263 (home-page "http://www.ctan.org/pkg/l3kernel")
1264 (synopsis "LaTeX3 programmers’ interface")
1265 (description
1266 "The l3kernel bundle provides an implementation of the LaTeX3
1267 programmers’ interface, as a set of packages that run under LaTeX 2e. The
1268 interface provides the foundation on which the LaTeX3 kernel and other future
1269 code are built: it is an API for TeX programmers. The packages are set up so
1270 that the LaTeX3 conventions can be used with regular LaTeX 2e packages.")
1271 (license license:lppl1.3c+)))
1272
1273 (define-public texlive-latex-l3packages
1274 (package
1275 (name "texlive-latex-l3packages")
1276 (version (number->string %texlive-revision))
1277 (source (origin
1278 (method svn-fetch)
1279 (uri (texlive-ref "latex" "l3packages"))
1280 (sha256
1281 (base32
1282 "16jplkvzdysfssijq9l051nsks65c2nrarsl17k8gjhc28yznj8y"))))
1283 (build-system texlive-build-system)
1284 (arguments
1285 '(#:tex-directory "latex/l3packages"
1286 #:phases
1287 (modify-phases %standard-phases
1288 ;; All package sources are in sub-directories, so we need to add them
1289 ;; to TEXINPUTS.
1290 (add-after 'unpack 'set-TEXINPUTS
1291 (lambda _
1292 (let ((cwd (getcwd)))
1293 (setenv "TEXINPUTS"
1294 (string-append cwd "/l3keys2e:"
1295 cwd "/xparse:"
1296 cwd "/xfrac:"
1297 cwd "/xfp:"
1298 cwd "/xtemplate")))
1299 #t)))))
1300 (inputs
1301 `(("texlive-latex-l3kernel" ,texlive-latex-l3kernel)))
1302 (home-page "http://www.ctan.org/pkg/l3packages")
1303 (synopsis "High-level LaTeX3 concepts")
1304 (description
1305 "This bundle holds prototype implementations of concepts for a LaTeX
1306 designer interface, to be used with the experimental LaTeX kernel as
1307 programming tools and kernel sup­port. Packages provided in this release are:
1308
1309 @enumerate
1310 @item l3keys2e, which makes the facilities of the kernel module l3keys
1311 available for use by LaTeX 2e packages;
1312 @item xfrac, which provides flexible splitlevel fractions;
1313 @item xparse, which provides a high-level interface for declaring document
1314 commands; and
1315 @item xtemplate, which provides a means of defining generic functions using a
1316 key-value syntax.
1317 @end enumerate\n")
1318 (license license:lppl1.3c+)))
1319
1320 (define-public texlive-latex-fontspec
1321 (package
1322 (name "texlive-latex-fontspec")
1323 (version (number->string %texlive-revision))
1324 (source (origin
1325 (method svn-fetch)
1326 (uri (texlive-ref "latex" "fontspec"))
1327 (sha256
1328 (base32
1329 "1rx43y5xmjqvc27pjdnmqwp4pcw3czcfd6nfpmzc1gnqfl1hlc0q"))))
1330 (build-system texlive-build-system)
1331 (arguments
1332 '(#:tex-directory "latex/fontspec"
1333 #:build-targets '("fontspec.dtx")))
1334 (inputs
1335 `(("texlive-latex-l3kernel" ,texlive-latex-l3kernel)))
1336 (home-page "http://www.ctan.org/pkg/fontspec")
1337 (synopsis "Advanced font selection in XeLaTeX and LuaLaTeX")
1338 (description
1339 "Fontspec is a package for XeLaTeX and LuaLaTeX. It provides an
1340 automatic and unified interface to feature-rich AAT and OpenType fonts through
1341 the NFSS in LaTeX running on XeTeX or LuaTeX engines. The package requires
1342 the l3kernel and xparse bundles from the LaTeX 3 development team.")
1343 (license license:lppl1.3+)))
1344
1345 ;; The SVN directory contains little more than a dtx file that generates three
1346 ;; of the many lua files that should be installed as part of this package.
1347 ;; This is why we take the release from GitHub instead.
1348 (define-public texlive-luatex-lualibs
1349 (package
1350 (name "texlive-luatex-lualibs")
1351 (version "2.5")
1352 (source (origin
1353 (method url-fetch)
1354 (uri (string-append "https://github.com/lualatex/lualibs/"
1355 "releases/download/v"
1356 version "/lualibs.zip"))
1357 (sha256
1358 (base32
1359 "1xx9blvrmx9hyhrl345lpai9m6xxnw997261a1ahn1bm5r2j5fqy"))))
1360 (build-system gnu-build-system)
1361 (arguments
1362 `(#:make-flags
1363 (list (string-append "DESTDIR="
1364 (assoc-ref %outputs "out")
1365 "/share/texmf-dist"))
1366 #:phases
1367 (modify-phases %standard-phases
1368 (delete 'configure))))
1369 (native-inputs
1370 `(("texlive-bin" ,texlive-bin)
1371 ("unzip" ,unzip)
1372 ("zip" ,zip)))
1373 (home-page "https://github.com/lualatex/lualibs")
1374 (synopsis "Lua modules for general programming (in the (La)TeX world)")
1375 (description
1376 "Lualibs is a collection of Lua modules useful for general programming.
1377 The bundle is based on Lua modules shipped with ConTeXt, and made available in
1378 this bundle for use independent of ConTeXt.")
1379 ;; GPL version 2 only
1380 (license license:gpl2)))
1381
1382 (define-public texlive-latex-amsmath
1383 (package
1384 (name "texlive-latex-amsmath")
1385 (version (number->string %texlive-revision))
1386 (source (origin
1387 (method svn-fetch)
1388 (uri (texlive-ref "latex" "amsmath"))
1389 (sha256
1390 (base32
1391 "178ywjpdlv78qmfzqdyn6gy14620zjsn2q9wap76fbr9s4hw6dba"))))
1392 (build-system texlive-build-system)
1393 (arguments '(#:tex-directory "latex/amsmath"))
1394 (home-page "http://www.ctan.org/pkg/amsmath")
1395 (synopsis "AMS mathematical facilities for LaTeX")
1396 (description
1397 "This is the principal package in the AMS-LaTeX distribution. It adapts
1398 for use in LaTeX most of the mathematical features found in AMS-TeX; it is
1399 highly recommended as an adjunct to serious mathematical typesetting in LaTeX.
1400 When amsmath is loaded, AMS-LaTeX packages @code{amsbsyamsbsy} (for bold
1401 symbols), @code{amsopnamsopn} (for operator names) and
1402 @code{amstextamstext} (for text embedded in mathematics) are also loaded.
1403 This package is part of the LaTeX required distribution; however, several
1404 contributed packages add still further to its appeal; examples are
1405 @code{empheqempheq}, which provides functions for decorating and highlighting
1406 mathematics, and @code{ntheoremntheorem}, for specifying theorem (and similar)
1407 definitions.")
1408 (license license:lppl1.3c+)))
1409
1410 (define-public texlive-latex-amscls
1411 (package
1412 (name "texlive-latex-amscls")
1413 (version (number->string %texlive-revision))
1414 (source (origin
1415 (method svn-fetch)
1416 (uri (texlive-ref "latex" "amscls"))
1417 (sha256
1418 (base32
1419 "0jmcr37mcdi7drczppvr6lmz5d5yd9m67ii79gp2nglg1xpw934j"))))
1420 (build-system texlive-build-system)
1421 (arguments
1422 `(#:tex-directory "latex/amscls"))
1423 (home-page "http://www.ctan.org/pkg/amscls")
1424 (synopsis "AMS document classes for LaTeX")
1425 (description
1426 "This bundle contains three AMS classes: @code{amsartamsart} (for writing
1427 articles for the AMS), @code{amsbookamsbook} (for books) and
1428 @code{amsprocamsproc} (for proceedings), together with some supporting
1429 material. The material is made available as part of the AMS-LaTeX
1430 distribution.")
1431 (license license:lppl1.3c+)))
1432
1433 (define-public texlive-latex-babel
1434 (package
1435 (name "texlive-latex-babel")
1436 (version (number->string %texlive-revision))
1437 (source (origin
1438 (method svn-fetch)
1439 (uri (texlive-ref "latex" "babel"))
1440 (sha256
1441 (base32
1442 "1n3i5adsyy7jw0imnzrm2i8wkf73i3mjk9h3ic8cb9cd19i4r9r3"))))
1443 (build-system texlive-build-system)
1444 (arguments
1445 '(#:tex-directory "generic/babel"
1446 #:phases
1447 (modify-phases %standard-phases
1448 ;; This package tries to produce babel.aux twice but refuses to
1449 ;; overwrite the first one.
1450 (add-before 'build 'fix-ins
1451 (lambda _
1452 (substitute* "babel.ins"
1453 (("askonceonly") "askforoverwritefalse"))
1454 #t)))))
1455 (home-page "http://www.ctan.org/pkg/babel")
1456 (synopsis "Multilingual support for Plain TeX or LaTeX")
1457 (description
1458 "The package manages culturally-determined typographical (and other)
1459 rules, and hyphenation patterns for a wide range of languages. A document may
1460 select a single language to be supported, or it may select several, in which
1461 case the document may switch from one language to another in a variety of
1462 ways. Babel uses contributed configuration files that provide the detail of
1463 what has to be done for each language. Users of XeTeX are advised to use the
1464 polyglossia package rather than Babel.")
1465 (license license:lppl1.3+)))
1466
1467 (define-public texlive-generic-babel-english
1468 (package
1469 (name "texlive-generic-babel-english")
1470 (version (number->string %texlive-revision))
1471 (source (origin
1472 (method svn-fetch)
1473 (uri (texlive-ref "generic" "babel-english"))
1474 (file-name (string-append name "-" version "-checkout"))
1475 (sha256
1476 (base32
1477 "1s404wbx91z5w65hm024kyl4h56zsa096irx18vsx8jvlmwsr5wc"))))
1478 (build-system texlive-build-system)
1479 (arguments '(#:tex-directory "generic/babel-english"))
1480 (home-page "http://www.ctan.org/pkg/babel-english")
1481 (synopsis "Babel support for English")
1482 (description
1483 "This package provides the language definition file for support of
1484 English in @code{babel}. Care is taken to select British hyphenation patterns
1485 for British English and Australian text, and default (\"american\") patterns
1486 for Canadian and USA text.")
1487 (license license:lppl1.3+)))
1488
1489 (define-public texlive-latex-cyrillic
1490 (package
1491 (name "texlive-latex-cyrillic")
1492 (version (number->string %texlive-revision))
1493 (source (origin
1494 (method svn-fetch)
1495 (uri (texlive-ref "latex" "cyrillic"))
1496 (sha256
1497 (base32
1498 "1mdhl35hwas68ki56qqngzar37dwv4mm64l2canihr255bz34lbv"))))
1499 (build-system texlive-build-system)
1500 (arguments
1501 '(#:tex-directory "latex/cyrillic"))
1502 (home-page "http://www.ctan.org/pkg/latex-cyrillic")
1503 (synopsis "Support for Cyrillic fonts in LaTeX")
1504 (description
1505 "This bundle of macros files provides macro support (including font
1506 encoding macros) for the use of Cyrillic characters in fonts encoded under the
1507 T2* and X2 encodings. These encodings cover (between them) pretty much every
1508 language that is written in a Cyrillic alphabet.")
1509 (license license:lppl1.3c+)))
1510
1511 (define-public texlive-latex-psnfss
1512 (package
1513 (name "texlive-latex-psnfss")
1514 (version (number->string %texlive-revision))
1515 (source (origin
1516 (method svn-fetch)
1517 (uri (texlive-ref "latex" "psnfss"))
1518 (sha256
1519 (base32
1520 "1920dcq8613yzprasbg80fh4fcjcidvvl54wkx438nimyxcri7qz"))))
1521 (build-system texlive-build-system)
1522 (arguments '(#:tex-directory "latex/psnfss"))
1523 (home-page "http://www.ctan.org/pkg/psnfss")
1524 (synopsis "Font support for common PostScript fonts")
1525 (description
1526 "The PSNFSS collection includes a set of files that provide a complete
1527 working setup of the LaTeX font selection scheme (NFSS2) for use with common
1528 PostScript fonts. It covers the so-called \"Base\" fonts (which are built
1529 into any Level 2 PostScript printing device and the Ghostscript interpreter)
1530 and a number of free fonts. It provides font definition files, macros and
1531 font metrics. The bundle as a whole is part of the LaTeX required set of
1532 packages.")
1533 (license license:lppl1.2+)))
1534
1535 (define-public texlive-union
1536 (lambda* (#:optional (packages '()))
1537 "Return 'texlive-union' package which is a union of PACKAGES and the
1538 standard LaTeX packages."
1539 (let ((default-packages
1540 (list texlive-bin
1541 texlive-dvips
1542 texlive-fonts-cm
1543 texlive-fonts-latex
1544 texlive-metafont-base
1545 texlive-latex-base
1546 ;; LaTeX packages from the "required" set.
1547 texlive-latex-amsmath
1548 texlive-latex-amscls
1549 texlive-latex-babel
1550 texlive-generic-babel-english
1551 texlive-latex-cyrillic
1552 texlive-latex-graphics
1553 texlive-latex-psnfss
1554 texlive-latex-tools)))
1555 (package
1556 (name "texlive-union")
1557 (version (number->string %texlive-revision))
1558 (source #f)
1559 (build-system trivial-build-system)
1560 (arguments
1561 '(#:modules ((guix build union)
1562 (guix build utils)
1563 (guix build texlive-build-system)
1564 (guix build gnu-build-system)
1565 (guix build gremlin)
1566 (guix elf))
1567 #:builder
1568 (begin
1569 (use-modules (ice-9 match)
1570 (srfi srfi-26)
1571 (guix build union)
1572 (guix build utils)
1573 (guix build texlive-build-system))
1574 (let* ((out (assoc-ref %outputs "out"))
1575 (texmf.cnf (string-append out "/share/texmf-dist/web2c/texmf.cnf")))
1576 ;; Build a modifiable union of all inputs (but exclude bash)
1577 (match (filter (match-lambda
1578 ((name . _)
1579 (not (string=? "bash" name))))
1580 %build-inputs)
1581 (((names . directories) ...)
1582 (union-build (assoc-ref %outputs "out")
1583 directories
1584 #:create-all-directories? #t)))
1585
1586 ;; The configuration file "texmf.cnf" is provided by the
1587 ;; "texlive-bin" package. We take it and override only the
1588 ;; setting for TEXMFROOT and TEXMF. This file won't be consulted
1589 ;; by default, though, so we still need to set TEXMFCNF.
1590 (substitute* texmf.cnf
1591 (("^TEXMFROOT = .*")
1592 (string-append "TEXMFROOT = " out "/share\n"))
1593 (("^TEXMF = .*")
1594 "TEXMF = $TEXMFROOT/share/texmf-dist\n"))
1595 (setenv "PATH" (string-append (assoc-ref %build-inputs "bash")
1596 "/bin"))
1597 (for-each
1598 (cut wrap-program <>
1599 `("TEXMFCNF" ":" = (,(dirname texmf.cnf)))
1600 `("TEXMF" ":" = (,(string-append out "/share/texmf-dist"))))
1601 (find-files (string-append out "/bin") ".*"))
1602 #t))))
1603 (inputs
1604 `(("bash" ,bash)
1605 ,@(map (lambda (package)
1606 (list (package-name package) package))
1607 (append default-packages packages))))
1608 (home-page (package-home-page texlive-bin))
1609 (synopsis "Union of TeX Live packages")
1610 (description "This package provides a subset of the TeX Live
1611 distribution.")
1612 (license (fold (lambda (package result)
1613 (match (package-license package)
1614 ((lst ...)
1615 (append lst result))
1616 ((? license:license? license)
1617 (cons license result))))
1618 '()
1619 (append default-packages packages)))))))
1620
1621 (define-public texlive-tiny
1622 (package
1623 (inherit (texlive-union))
1624 (name "texlive-tiny")
1625 (description "This is a very limited subset of the TeX Live distribution.
1626 It includes little more than the required set of LaTeX packages.")))
1627
1628 (define-public texlive-latex-amsrefs
1629 (package
1630 (name "texlive-latex-amsrefs")
1631 (version (number->string %texlive-revision))
1632 (source (origin
1633 (method svn-fetch)
1634 (uri (texlive-ref "latex" "amsrefs"))
1635 (file-name (string-append name "-" version "-checkout"))
1636 (sha256
1637 (base32
1638 "15i4k479dwrpr0kspmm70g1yn4p3dkh0whyzmr93hph9bggnh1i1"))))
1639 (build-system texlive-build-system)
1640 (arguments '(#:tex-directory "latex/amsrefs"))
1641 (home-page "http://www.ctan.org/pkg/amsrefs")
1642 (synopsis "LaTeX-based replacement for BibTeX")
1643 (description
1644 "Amsrefs is a LaTeX package for bibliographies that provides an archival
1645 data format similar to the format of BibTeX database files, but adapted to
1646 make direct processing by LaTeX easier. The package can be used either in
1647 conjunction with BibTeX or as a replacement for BibTeX.")
1648 (license license:lppl1.3+)))
1649
1650 (define-public texlive-latex-bigfoot
1651 (package
1652 (name "texlive-latex-bigfoot")
1653 (version (number->string %texlive-revision))
1654 (source (origin
1655 (method svn-fetch)
1656 (uri (texlive-ref "latex" "bigfoot"))
1657 (file-name (string-append name "-" version "-checkout"))
1658 (sha256
1659 (base32
1660 "092g8alnsdwlgl1isdnqrr32l161994295kadr1n05d81xgj5wnv"))))
1661 (build-system texlive-build-system)
1662 (arguments
1663 '(#:tex-directory "latex/bigfoot"
1664 #:phases
1665 (modify-phases %standard-phases
1666 (add-after 'unpack 'remove-generated-file
1667 (lambda _
1668 (for-each delete-file (find-files "." "\\.drv$"))
1669 #t)))))
1670 (home-page "http://www.ctan.org/pkg/bigfoot")
1671 (synopsis "Footnotes for critical editions")
1672 (description
1673 "This package aims to provide a one-stop solution to requirements for
1674 footnotes. It offers: Multiple footnote apparatus superior to that of
1675 @code{manyfoot}. Footnotes can be formatted in separate paragraphs, or be run
1676 into a single paragraph (this choice may be selected per footnote series);
1677 Things you might have expected (such as @code{\\verb}-like material in
1678 footnotes, and color selections over page breaks) now work. Note that the
1679 majority of the bigfoot package's interface is identical to that of
1680 @code{manyfoot}; users should seek information from that package's
1681 documentation. The bigfoot bundle also provides the @code{perpage} and
1682 @code{suffix} packages.")
1683 (license license:gpl2+)))
1684
1685 (define-public texlive-latex-blindtext
1686 (package
1687 (name "texlive-latex-blindtext")
1688 (version (number->string %texlive-revision))
1689 (source (origin
1690 (method svn-fetch)
1691 (uri (texlive-ref "latex" "blindtext"))
1692 (file-name (string-append name "-" version "-checkout"))
1693 (sha256
1694 (base32
1695 "1jrja9b1pzdh9zgv1jh807w4xijqja58n2mqny6dkwicv8qfgbfg"))))
1696 (build-system texlive-build-system)
1697 (arguments '(#:tex-directory "latex/blindtext"))
1698 (home-page "http://www.ctan.org/pkg/blindtext")
1699 (synopsis "Producing 'blind' text for testing")
1700 (description
1701 "The package provides the commands @code{\\blindtext} and
1702 @code{\\Blindtext} for creating \"blind\" text useful in testing new classes
1703 and packages, and @code{\\blinddocument}, @code{\\Blinddocument} for creating
1704 an entire random document with sections, lists, mathematics, etc. The package
1705 supports three languages, @code{english}, @code{(n)german} and @code{latin};
1706 the @code{latin} option provides a short \"lorem ipsum\" (for a fuller \"lorem
1707 ipsum\" text, see the @code{lipsum} package).")
1708 (license license:lppl)))
1709
1710 (define-public texlive-latex-dinbrief
1711 (package
1712 (name "texlive-latex-dinbrief")
1713 (version (number->string %texlive-revision))
1714 (source (origin
1715 (method svn-fetch)
1716 (uri (texlive-ref "latex" "dinbrief"))
1717 (file-name (string-append name "-" version "-checkout"))
1718 (sha256
1719 (base32
1720 "0lb0kiy8fxzl6cnhcw1sggy6jrjvcd6kj1kkw3k9lkimm388yjz6"))))
1721 (build-system texlive-build-system)
1722 (arguments
1723 '(#:tex-directory "latex/dinbrief"
1724 #:phases
1725 (modify-phases %standard-phases
1726 (add-after 'unpack 'remove-generated-file
1727 (lambda _
1728 (delete-file "dinbrief.drv")
1729 #t)))))
1730 (home-page "http://www.ctan.org/pkg/dinbrief")
1731 (synopsis "German letter DIN style")
1732 (description
1733 "This package implements a document layout for writing letters according
1734 to the rules of DIN (Deutsches Institut für Normung, German standardisation
1735 institute). A style file for LaTeX 2.09 (with limited support of the
1736 features) is part of the package. Since the letter layout is based on a
1737 German standard, the user guide is written in German, but most macros have
1738 English names from which the user can recognize what they are used for. In
1739 addition there are example files showing how letters may be created with the
1740 package.")
1741 (license license:lppl)))
1742
1743 (define-public texlive-latex-draftwatermark
1744 (package
1745 (name "texlive-latex-draftwatermark")
1746 (version (number->string %texlive-revision))
1747 (source (origin
1748 (method svn-fetch)
1749 (uri (texlive-ref "latex" "draftwatermark"))
1750 (file-name (string-append name "-" version "-checkout"))
1751 (sha256
1752 (base32
1753 "1zyl2pcz2x529gzj5m93a1s4ipymdabf7qdjl3l1673pizd4hfyv"))))
1754 (build-system texlive-build-system)
1755 (arguments '(#:tex-directory "latex/draftwatermark"))
1756 (home-page "http://www.ctan.org/pkg/draftwatermark")
1757 (synopsis "Put a grey textual watermark on document pages")
1758 (description
1759 "This package provides a means to add a textual, light grey watermark on
1760 every page or on the first page of a document. Typical usage may consist in
1761 writing words such as DRAFT or CONFIDENTIAL across document pages. The
1762 package performs a similar function to that of @code{draftcopy}, but its
1763 implementation is output device independent, and made very simple by relying
1764 on everypage.")
1765 (license license:lppl1.3+)))
1766
1767 (define-public texlive-latex-environ
1768 (package
1769 (name "texlive-latex-environ")
1770 (version (number->string %texlive-revision))
1771 (source (origin
1772 (method svn-fetch)
1773 (uri (texlive-ref "latex" "environ"))
1774 (file-name (string-append name "-" version "-checkout"))
1775 (sha256
1776 (base32
1777 "06h28b26dyjkj9shksphgqfv4130jfkwhbw737hxn7d3yvdfffyd"))))
1778 (build-system texlive-build-system)
1779 (arguments '(#:tex-directory "latex/environ"))
1780 (home-page "http://www.ctan.org/pkg/environ")
1781 (synopsis "New interface for environments in LaTeX")
1782 (description
1783 "This package provides the @code{\\collect@body} command (as in
1784 @code{amsmath}), as well as a @code{\\long} version @code{\\Collect@Body}, for
1785 collecting the body text of an environment. These commands are used to define
1786 a new author interface to creating new environments.")
1787 (license license:lppl)))
1788
1789 (define-public texlive-latex-eqparbox
1790 (package
1791 (name "texlive-latex-eqparbox")
1792 (version (number->string %texlive-revision))
1793 (source (origin
1794 (method svn-fetch)
1795 (uri (texlive-ref "latex" "eqparbox"))
1796 (file-name (string-append name "-" version "-checkout"))
1797 (sha256
1798 (base32
1799 "0pvmhsd4xmpil0m3c7qcgwilbk266mlkzv03g0jr8r3zd8jxlyzq"))))
1800 (build-system texlive-build-system)
1801 (arguments '(#:tex-directory "latex/eqparbox"))
1802 (home-page "http://www.ctan.org/pkg/eqparbox")
1803 (synopsis "Create equal-widthed parboxes")
1804 (description
1805 "LaTeX users sometimes need to ensure that two or more blocks of text
1806 occupy the same amount of horizontal space on the page. To that end, the
1807 @code{eqparbox} package defines a new command, @code{\\eqparbox}, which works
1808 just like @code{\\parbox}, except that instead of specifying a width, one
1809 specifies a tag. All @code{eqparbox}es with the same tag---regardless of
1810 where they are in the document---will stretch to fit the widest
1811 @code{eqparbox} with that tag. This simple, equal-width mechanism can be used
1812 for a variety of alignment purposes, as is evidenced by the examples in
1813 @code{eqparbox}'s documentation. Various derivatives of @code{\\eqparbox} are
1814 also provided.")
1815 (license license:lppl1.3+)))
1816
1817 (define-public texlive-latex-expdlist
1818 (package
1819 (name "texlive-latex-expdlist")
1820 (version (number->string %texlive-revision))
1821 (source (origin
1822 (method svn-fetch)
1823 (uri (texlive-ref "latex" "expdlist"))
1824 (file-name (string-append name "-" version "-checkout"))
1825 (sha256
1826 (base32
1827 "1x7byk6x10njir3y9rm56glhdzrxwqag7gsnw2sqn1czlq525w7r"))))
1828 (build-system texlive-build-system)
1829 (arguments
1830 '(#:tex-directory "latex/expdlist"
1831 #:phases
1832 (modify-phases %standard-phases
1833 (add-after 'unpack 'remove-generated-file
1834 (lambda _
1835 (for-each delete-file
1836 (find-files "." "\\.drv$"))
1837 #t)))))
1838 (home-page "http://www.ctan.org/pkg/expdlist")
1839 (synopsis "Expanded description environments")
1840 (description
1841 "The package provides additional features for the LaTeX
1842 @code{description} environment, including adjustable left margin. The package
1843 also allows the user to \"break\" a list (for example, to interpose a comment)
1844 without affecting the structure of the list (this works for @code{itemize} and
1845 @code{enumerate} lists, and numbered lists remain in sequence).")
1846 (license license:lppl)))
1847
1848 (define-public texlive-latex-natbib
1849 (package
1850 (name "texlive-latex-natbib")
1851 (version (number->string %texlive-revision))
1852 (source (origin
1853 (method svn-fetch)
1854 (uri (texlive-ref "latex" "natbib"))
1855 (sha256
1856 (base32
1857 "0aqliq0nwblxyrzhwhv77pnmk7qh2y3prgq7z7qhwcbgz5kisld7"))))
1858 (build-system texlive-build-system)
1859 (arguments '(#:tex-directory "latex/natbib"))
1860 (home-page "http://www.ctan.org/pkg/natbib")
1861 (synopsis "Flexible bibliography support")
1862 (description
1863 "This bundle provides a package that implements both author-year and
1864 numbered references, as well as much detailed of support for other
1865 bibliography use. Also provided are versions of the standard BibTeX styles
1866 that are compatible with @code{natbib}: @code{plainnat}, @code{unsrtnat},
1867 @code{abbrnat}. The bibliography styles produced by @code{custom-bib} are
1868 designed from the start to be compatible with @code{natbib}.")
1869 (license license:lppl)))
1870
1871 (define-public texlive-latex-seminar
1872 (package
1873 (name "texlive-latex-seminar")
1874 (version (number->string %texlive-revision))
1875 (source (origin
1876 (method svn-fetch)
1877 (uri (svn-reference
1878 (url (string-append "svn://www.tug.org/texlive/tags/"
1879 %texlive-tag "/Master/texmf-dist/"
1880 "/tex/latex/seminar"))
1881 (revision %texlive-revision)))
1882 (sha256
1883 (base32
1884 "0y4i651b75y6006n03x8n86bsqvjsailvvz9bhzy51dzsznqidq0"))))
1885 (build-system texlive-build-system)
1886 (arguments '(#:tex-directory "latex/seminar"))
1887 (home-page "http://www.ctan.org/pkg/seminar")
1888 (synopsis "Make overhead slides")
1889 ;; TODO: This package may need fancybox and xcomment at runtime.
1890 (description
1891 "This package provides a class that produces overhead
1892 slides (transparencies), with many facilities. Seminar is not nowadays
1893 reckoned a good basis for a presentation — users are advised to use more
1894 recent classes such as powerdot or beamer, both of which are tuned to
1895 21st-century presentation styles.")
1896 (license license:lppl1.2+)))
1897
1898 (define-public texlive-latex-capt-of
1899 (package
1900 (name "texlive-latex-capt-of")
1901 (version (number->string %texlive-revision))
1902 (source (origin
1903 (method svn-fetch)
1904 (uri (svn-reference
1905 (url (string-append "svn://www.tug.org/texlive/tags/"
1906 %texlive-tag "/Master/texmf-dist/"
1907 "/tex/latex/capt-of"))
1908 (revision %texlive-revision)))
1909 (file-name (string-append name "-" version "-checkout"))
1910 (sha256
1911 (base32
1912 "1y2s50f6lz0jx2748lj3iy56hrpcczgnbzmvphxv7aqndyyamd4x"))))
1913 (build-system trivial-build-system)
1914 (arguments
1915 `(#:modules ((guix build utils))
1916 #:builder
1917 (begin
1918 (use-modules (guix build utils))
1919 (let ((target (string-append (assoc-ref %outputs "out")
1920 "/share/texmf-dist/tex/latex/capt-of")))
1921 (mkdir-p target)
1922 (copy-recursively (assoc-ref %build-inputs "source") target)
1923 #t))))
1924 (home-page "http://www.ctan.org/pkg/capt-of")
1925 (synopsis "Captions on more than floats")
1926 (description
1927 "This package defines a command @code{\\captionof} for putting a caption
1928 to something that's not a float.")
1929 (license license:lppl)))
1930
1931 (define-public texlive-latex-etoolbox
1932 (package
1933 (name "texlive-latex-etoolbox")
1934 (version (number->string %texlive-revision))
1935 (source (origin
1936 (method svn-fetch)
1937 (uri (svn-reference
1938 (url (string-append "svn://www.tug.org/texlive/tags/"
1939 %texlive-tag "/Master/texmf-dist/"
1940 "/tex/latex/etoolbox"))
1941 (revision %texlive-revision)))
1942 (file-name (string-append name "-" version "-checkout"))
1943 (sha256
1944 (base32
1945 "0016bscnpima9krrg2569mva78xzwnygzlvg87dznsm6gf8g589v"))))
1946 (build-system trivial-build-system)
1947 (arguments
1948 `(#:modules ((guix build utils))
1949 #:builder
1950 (begin
1951 (use-modules (guix build utils))
1952 (let ((target (string-append (assoc-ref %outputs "out")
1953 "/share/texmf-dist/tex/latex/etoolbox")))
1954 (mkdir-p target)
1955 (copy-recursively (assoc-ref %build-inputs "source") target)
1956 #t))))
1957 (home-page "http://www.ctan.org/pkg/etoolbox")
1958 (synopsis "e-TeX tools for LaTeX")
1959 (description
1960 "This package is a toolbox of programming facilities geared primarily
1961 towards LaTeX class and package authors. It provides LaTeX frontends to some
1962 of the new primitives provided by e-TeX as well as some generic tools which
1963 are not strictly related to e-TeX but match the profile of this package. The
1964 package provides functions that seem to offer alternative ways of implementing
1965 some LaTeX kernel commands; nevertheless, the package will not modify any part
1966 of the LaTeX kernel.")
1967 (license license:lppl1.3+)))
1968
1969 (define-public texlive-latex-fncychap
1970 (package
1971 (name "texlive-latex-fncychap")
1972 (version (number->string %texlive-revision))
1973 (source (origin
1974 (method svn-fetch)
1975 (uri (svn-reference
1976 (url (string-append "svn://www.tug.org/texlive/tags/"
1977 %texlive-tag "/Master/texmf-dist/"
1978 "/tex/latex/fncychap"))
1979 (revision %texlive-revision)))
1980 (file-name (string-append name "-" version "-checkout"))
1981 (sha256
1982 (base32
1983 "0fdk84dbicfjfprkz6vk15x36mvlhaw9isjmgkc56jp2khwjswwq"))))
1984 (build-system trivial-build-system)
1985 (arguments
1986 `(#:modules ((guix build utils))
1987 #:builder
1988 (begin
1989 (use-modules (guix build utils))
1990 (let ((target (string-append (assoc-ref %outputs "out")
1991 "/share/texmf-dist/tex/latex/fncychap")))
1992 (mkdir-p target)
1993 (copy-recursively (assoc-ref %build-inputs "source") target)
1994 #t))))
1995 (home-page "http://www.ctan.org/pkg/fncychap")
1996 (synopsis "Seven predefined chapter heading styles")
1997 (description
1998 "This package provides seven predefined chapter heading styles. Each
1999 style can be modified using a set of simple commands. Optionally one can
2000 modify the formatting routines in order to create additional chapter
2001 headings.")
2002 (license license:lppl1.3+)))
2003
2004 (define-public texlive-latex-framed
2005 (package
2006 (name "texlive-latex-framed")
2007 (version (number->string %texlive-revision))
2008 (source (origin
2009 (method svn-fetch)
2010 (uri (svn-reference
2011 (url (string-append "svn://www.tug.org/texlive/tags/"
2012 %texlive-tag "/Master/texmf-dist/"
2013 "/tex/latex/framed"))
2014 (revision %texlive-revision)))
2015 (file-name (string-append name "-" version "-checkout"))
2016 (sha256
2017 (base32
2018 "14a4ydqsvp3vcfavl21jrv0ybiqypaaqzg2q2cs3rzkandg7w98x"))))
2019 (build-system trivial-build-system)
2020 (arguments
2021 `(#:modules ((guix build utils))
2022 #:builder
2023 (begin
2024 (use-modules (guix build utils))
2025 (let ((target (string-append (assoc-ref %outputs "out")
2026 "/share/texmf-dist/tex/latex/framed")))
2027 (mkdir-p target)
2028 (copy-recursively (assoc-ref %build-inputs "source") target)
2029 #t))))
2030 (home-page "http://www.ctan.org/pkg/framed")
2031 (synopsis "Framed or shaded regions that can break across pages")
2032 (description
2033 "The package creates three environments: @code{framed}, which puts an
2034 ordinary frame box around the region, @code{shaded}, which shades the region,
2035 and @code{leftbar}, which places a line at the left side. The environments
2036 allow a break at their start (the @code{\\FrameCommand} enables creation of a
2037 title that is “attached” to the environment); breaks are also allowed in the
2038 course of the framed/shaded matter. There is also a command
2039 @code{\\MakeFramed} to make your own framed-style environments.")
2040 ;; The header states: "These macros may be freely transmitted, reproduced,
2041 ;; or modified for any purpose provided that this notice is left intact."
2042 (license (license:fsf-free "file://framed.sty"))))
2043
2044 (define-public texlive-latex-g-brief
2045 (package
2046 (name "texlive-latex-g-brief")
2047 (version (number->string %texlive-revision))
2048 (source (origin
2049 (method svn-fetch)
2050 (uri (texlive-ref "latex" "g-brief"))
2051 (file-name (string-append name "-" version "-checkout"))
2052 (sha256
2053 (base32
2054 "0sikazkg0dpkcpzlbqw8qzxr81paf2f443vsrh14jnw7s4gswvc5"))))
2055 (build-system texlive-build-system)
2056 (arguments
2057 '(#:tex-directory "latex/g-brief"
2058 #:phases
2059 (modify-phases %standard-phases
2060 (add-after 'unpack 'remove-generated-file
2061 (lambda _
2062 (delete-file "g-brief.drv")
2063 #t)))))
2064 (home-page "http://www.ctan.org/pkg/g-brief")
2065 (synopsis "Letter document class")
2066 (description
2067 "This package is designed for formatting formless letters in German; it
2068 can also be used for English (by those who can read the documentation). There
2069 are LaTeX 2.09 @code{documentstyle} and LaTeX 2e class files for both an
2070 \"old\" and a \"new\" version of g-brief.")
2071 (license license:lppl)))
2072
2073 (define-public texlive-latex-galois
2074 (package
2075 (name "texlive-latex-galois")
2076 (version (number->string %texlive-revision))
2077 (source (origin
2078 (method svn-fetch)
2079 (uri (texlive-ref "latex" "galois"))
2080 (file-name (string-append name "-" version "-checkout"))
2081 (sha256
2082 (base32
2083 "0d4l0msk8j5pi95xnmm9wygv1vbpkwkv5amx9l0km86cs79jpp1h"))))
2084 (build-system texlive-build-system)
2085 (arguments '(#:tex-directory "latex/galois"))
2086 (home-page "http://www.ctan.org/pkg/galois")
2087 (synopsis "Typeset Galois connections")
2088 (description
2089 "The package deals with connections in two-dimensional style, optionally
2090 in colour.")
2091 (license license:lppl)))
2092
2093 (define-public texlive-latex-gcite
2094 (package
2095 (name "texlive-latex-gcite")
2096 (version (number->string %texlive-revision))
2097 (source (origin
2098 (method svn-fetch)
2099 (uri (texlive-ref "latex" "gcite"))
2100 (file-name (string-append name "-" version "-checkout"))
2101 (sha256
2102 (base32
2103 "03g9by54yrypn599y98r1xh7qw0bbbmpzq0bfwpj6j5q5rkl1mfa"))))
2104 (build-system texlive-build-system)
2105 (arguments '(#:tex-directory "latex/gcite"))
2106 (home-page "http://www.ctan.org/pkg/gcite")
2107 (synopsis "Citations in a reader-friendly style")
2108 (description
2109 "The package allows citations in the German style, which is considered by
2110 many to be particularly reader-friendly. The citation provides a small amount
2111 of bibliographic information in a footnote on the page where each citation is
2112 made. It combines a desire to eliminate unnecessary page-turning with the
2113 look-up efficiency afforded by numeric citations. The package makes use of
2114 BibLaTeX, and is considered experimental.")
2115 (license license:lppl1.3+)))
2116
2117 (define-public texlive-latex-geometry
2118 (package
2119 (name "texlive-latex-geometry")
2120 (version (number->string %texlive-revision))
2121 (source (origin
2122 (method svn-fetch)
2123 (uri (texlive-ref "latex" "geometry"))
2124 (file-name (string-append name "-" version "-checkout"))
2125 (sha256
2126 (base32
2127 "1r2kfcwclg33yk5z8mvlagwxj7nr1mc3w4bdpmhrwv6dn8mrbvw8"))))
2128 (build-system texlive-build-system)
2129 (arguments '(#:tex-directory "latex/geometry"))
2130 (home-page "http://www.ctan.org/pkg/geometry")
2131 (synopsis "Flexible and complete interface to document dimensions")
2132 (description
2133 "This package provides an easy and flexible user interface to customize
2134 page layout, implementing auto-centering and auto-balancing mechanisms so that
2135 the users have only to give the least description for the page layout. The
2136 package knows about all the standard paper sizes, so that the user need not
2137 know what the nominal \"real\" dimensions of the paper are, just its standard
2138 name (such as a4, letter, etc.). An important feature is the package's
2139 ability to communicate the paper size it's set up to the output.")
2140 (license license:lppl)))
2141
2142 (define-public texlive-latex-hyperref
2143 (package
2144 (name "texlive-latex-hyperref")
2145 (version (number->string %texlive-revision))
2146 (source (origin
2147 (method svn-fetch)
2148 (uri (texlive-ref "latex" "hyperref"))
2149 (sha256
2150 (base32
2151 "03arf3xvz1jsbvlpgc5qxbxbl9wmk8k09cn6b8gv9pzgpjy4vx4j"))))
2152 (build-system texlive-build-system)
2153 (arguments
2154 '(#:tex-directory "latex/hyperref"
2155 #:phases
2156 (modify-phases %standard-phases
2157 (add-after 'unpack 'remove-hluatex.def
2158 (lambda _
2159 ;; This depends on hluatex.dtx, which does not exist and is
2160 ;; nowhere to be found in the sources of the TeX Live
2161 ;; distribution.
2162 (substitute* "hyperref.ins"
2163 (("\\\\file\\{hluatex.def\\}.*") ""))
2164 #t)))))
2165 ;; The package depends on the kvoptions, ltxcmds, and refcount packages,
2166 ;; which are part of the oberdiek bundle.
2167 (inputs
2168 `(("texlive-latex-oberdiek" ,texlive-latex-oberdiek)))
2169 (home-page "http://www.ctan.org/pkg/hyperref")
2170 (synopsis "Extensive support for hypertext in LaTeX")
2171 (description
2172 "The @code{hyperref} package is used to handle cross-referencing commands
2173 in LaTeX to produce hypertext links in the document. The package provides
2174 backends for the @code{\\special} set defined for HyperTeX DVI processors; for
2175 embedded @code{pdfmark} commands for processing by Acrobat
2176 Distiller (@code{dvips} and Y&Y's @code{dvipsone}); for Y&Y's @code{dviwindo};
2177 for PDF control within pdfTeX and @code{dvipdfm}; for TeX4ht; and for VTeX's
2178 pdf and HTML backends. The package is distributed with the @code{backref} and
2179 @code{nameref} packages, which make use of the facilities of @code{hyperref}.")
2180 (license license:lppl1.3+)))
2181
2182 (define-public texlive-latex-mdwtools
2183 (package
2184 (name "texlive-latex-mdwtools")
2185 (version (number->string %texlive-revision))
2186 (source (origin
2187 (method svn-fetch)
2188 (uri (texlive-ref "latex" "mdwtools"))
2189 (file-name (string-append name "-" version "-checkout"))
2190 (sha256
2191 (base32
2192 "0caxs74hla28hc67csf5i5ahadx97w8vxh3mdmsprxbpd1mr7ssg"))))
2193 (build-system texlive-build-system)
2194 (arguments '(#:tex-directory "latex/mdwtools"))
2195 (home-page "http://www.ctan.org/pkg/mdwtools")
2196 (synopsis "Miscellaneous tools by Mark Wooding")
2197 (description
2198 "This collection of tools includes: @code{atsupport} for short commands
2199 starting with @code{@}, macros to sanitize the OT1 encoding of the @code{cmtt}
2200 fonts; a @code{doafter} command; improved @code{footnote} support;
2201 @code{mathenv} for various alignment in maths; list handling; @code{mdwmath}
2202 which adds some minor changes to LaTeX maths; a rewrite of LaTeX's tabular and
2203 array environments; verbatim handling; and syntax diagrams.")
2204 (license license:gpl3+)))
2205
2206 (define-public texlive-latex-polyglossia
2207 (package
2208 (name "texlive-latex-polyglossia")
2209 (version (number->string %texlive-revision))
2210 (source (origin
2211 (method svn-fetch)
2212 (uri (texlive-ref "latex" "polyglossia"))
2213 (file-name (string-append name "-" version "-checkout"))
2214 (sha256
2215 (base32
2216 "09mvszd5qgqg4cfglpj5qxyzjz190ppb9p8gnsnjydwp1akvhayf"))))
2217 (build-system texlive-build-system)
2218 (arguments '(#:tex-directory "latex/polyglossia"))
2219 (home-page "http://www.ctan.org/pkg/polyglossia")
2220 (synopsis "Alternative to babel for XeLaTeX and LuaLaTeX")
2221 (description
2222 "This package provides a complete Babel replacement for users of LuaLaTeX
2223 and XeLaTeX; it relies on the @code{fontspec} package, version 2.0 at least.")
2224 (license license:lppl1.3+)))
2225
2226 (define-public texlive-latex-supertabular
2227 (package
2228 (name "texlive-latex-supertabular")
2229 (version (number->string %texlive-revision))
2230 (source (origin
2231 (method svn-fetch)
2232 (uri (texlive-ref "latex" "supertabular"))
2233 (file-name (string-append name "-" version "-checkout"))
2234 (sha256
2235 (base32
2236 "14b2bc7cqz4ckxxycim9sw6jkrr1pahivm1rdbpz5k6hl967w1s3"))))
2237 (build-system texlive-build-system)
2238 (arguments '(#:tex-directory "latex/supertabular"))
2239 (home-page "http://www.ctan.org/pkg/supertabular")
2240 (synopsis "Multi-page tables package")
2241 (description
2242 "This package was a predecessor of @code{longtable}; the newer
2243 package (designed on quite different principles) is easier to use and more
2244 flexible, in many cases, but supertabular retains its usefulness in a few
2245 situations where longtable has problems.")
2246 (license license:lppl1.3+)))
2247
2248 (define-public texlive-tex-texinfo
2249 (package
2250 (name "texlive-tex-texinfo")
2251 (version (number->string %texlive-revision))
2252 (source (origin
2253 (method svn-fetch)
2254 (uri (svn-reference
2255 (url (string-append "svn://www.tug.org/texlive/tags/"
2256 %texlive-tag "/Master/texmf-dist/"
2257 "/tex/texinfo"))
2258 (revision %texlive-revision)))
2259 (sha256
2260 (base32
2261 "09zj2w3lx0y6i2syfjjgizahf86z301dw8p37ln6syfhqhzqdz46"))))
2262 (build-system trivial-build-system)
2263 (arguments
2264 `(#:modules ((guix build utils))
2265 #:builder
2266 (begin
2267 (use-modules (guix build utils))
2268 (let ((target (string-append (assoc-ref %outputs "out")
2269 "/share/texmf-dist/tex/texinfo")))
2270 (mkdir-p target)
2271 (copy-recursively (assoc-ref %build-inputs "source") target)
2272 #t))))
2273 (home-page "http://www.ctan.org/pkg/texinfo")
2274 (synopsis "TeX macros to handle Texinfo files")
2275 (description
2276 "Texinfo is the preferred format for documentation in the GNU project;
2277 the format may be used to produce online or printed output from a single
2278 source. The Texinfo macros may be used to produce printable output using TeX;
2279 other programs in the distribution offer online interactive use (with
2280 hypertext linkages in some cases).")
2281 (license license:gpl3+)))
2282
2283 (define-public texlive-latex-upquote
2284 (package
2285 (name "texlive-latex-upquote")
2286 (version (number->string %texlive-revision))
2287 (source (origin
2288 (method svn-fetch)
2289 (uri (texlive-ref "latex" "upquote"))
2290 (file-name (string-append name "-" version "-checkout"))
2291 (sha256
2292 (base32
2293 "0d1050i973wnxigy0xpky5l7vn4ff7ldhkjpdqsw5s653gagwixp"))))
2294 (build-system texlive-build-system)
2295 (arguments '(#:tex-directory "latex/upquote"))
2296 (home-page "http://www.ctan.org/pkg/upquote")
2297 (synopsis "Show \"realistic\" quotes in verbatim")
2298 (description
2299 "Typewriter-style fonts are best for program listings, but Computer
2300 Modern Typewriter prints @code{`} and @code{'} as bent opening and closing
2301 single quotes. Other fonts, and most programming languages, print @code{`} as
2302 a grave accent and @code{'} upright; @code{'} is used both to open and to
2303 close quoted strings. The package switches the typewriter font to Computer
2304 Modern Typewriter in OT1 encoding, and modifies the behaviour of
2305 @code{verbatim}, @code{verbatim*}, @code{\\verb}, and @code{\\verb*} to print
2306 in the expected way. It does this regardless of other fonts or encodings in
2307 use, so long as the package is loaded after the other fonts were. The package
2308 does not affect @code{\\tt}, @code{\\texttt}, etc.")
2309 (license license:lppl1.2+)))
2310
2311 (define-public texlive-latex-anysize
2312 (package
2313 (name "texlive-latex-anysize")
2314 (version (number->string %texlive-revision))
2315 (source (origin
2316 (method svn-fetch)
2317 (uri (svn-reference
2318 (url (string-append "svn://www.tug.org/texlive/tags/"
2319 %texlive-tag "/Master/texmf-dist/"
2320 "/tex/latex/anysize"))
2321 (revision %texlive-revision)))
2322 (sha256
2323 (base32
2324 "19khwqjlvznc955sijhww3c4zbb0053rvzwv9nz738qknq7y18vb"))))
2325 (build-system trivial-build-system)
2326 (arguments
2327 `(#:modules ((guix build utils))
2328 #:builder
2329 (begin
2330 (use-modules (guix build utils))
2331 (let ((target (string-append (assoc-ref %outputs "out")
2332 "/share/texmf-dist/tex/latex/anysize")))
2333 (mkdir-p target)
2334 (copy-recursively (assoc-ref %build-inputs "source") target)
2335 #t))))
2336 (home-page "http://www.ctan.org/pkg/anysize")
2337 (synopsis "Simple package to set up document margins")
2338 (description
2339 "This is a simple package to set up document margins. This package is
2340 considered obsolete; alternatives are the @code{typearea} package from the
2341 @code{koma-script} bundle, or the @code{geometry} package.")
2342 (license license:public-domain)))
2343
2344 (define-public texlive-latex-appendix
2345 (package
2346 (name "texlive-latex-appendix")
2347 (version (number->string %texlive-revision))
2348 (source (origin
2349 (method svn-fetch)
2350 (uri (texlive-ref "latex" "appendix"))
2351 (sha256
2352 (base32
2353 "0rxfpr8vq3brwx5rc7qn91ixlp9zva4zrms8a579fqa1g5yva7vg"))))
2354 (build-system texlive-build-system)
2355 (arguments '(#:tex-directory "latex/appendix"))
2356 (home-page "http://www.ctan.org/pkg/appendix")
2357 (synopsis "Extra control of appendices")
2358 (description
2359 "The appendix package provides various ways of formatting the titles of
2360 appendices. Also (sub)appendices environments are provided that can be used,
2361 for example, for per chapter/section appendices. An @code{appendices}
2362 environment is provided which can be used instead of the @code{\\appendix}
2363 command.")
2364 (license license:lppl)))
2365
2366 (define-public texlive-latex-changebar
2367 (package
2368 (name "texlive-latex-changebar")
2369 (version (number->string %texlive-revision))
2370 (source (origin
2371 (method svn-fetch)
2372 (uri (texlive-ref "latex" "changebar"))
2373 (sha256
2374 (base32
2375 "1ik4m8pzfsn1grlda6fniqqfwmgj7rfxwg63jdw0p0qv002vc7ik"))))
2376 (build-system texlive-build-system)
2377 (arguments '(#:tex-directory "latex/changebar"))
2378 (home-page "http://www.ctan.org/pkg/changebar")
2379 (synopsis "Generate changebars in LaTeX documents")
2380 (description
2381 "Identify areas of text to be marked with changebars with the
2382 @code{\\cbstart} and @code{\\cbend} commands; the bars may be coloured. The
2383 package uses 'drivers' to place the bars; the available drivers can work with
2384 @code{dvitoln03}, @code{dvitops}, @code{dvips}, the emTeX and TeXtures DVI
2385 drivers, and VTeX and pdfTeX.")
2386 (license license:lppl)))
2387
2388 (define-public texlive-latex-cmap
2389 (package
2390 (name "texlive-latex-cmap")
2391 (version (number->string %texlive-revision))
2392 (source (origin
2393 (method svn-fetch)
2394 (uri (svn-reference
2395 (url (string-append "svn://www.tug.org/texlive/tags/"
2396 %texlive-tag "/Master/texmf-dist/"
2397 "/tex/latex/cmap"))
2398 (revision %texlive-revision)))
2399 (file-name (string-append name "-" version "-checkout"))
2400 (sha256
2401 (base32
2402 "1s1rv6zgw105w2j6ffhnk914qrix87y1ndzri1q72g2kbr91zlbg"))))
2403 (build-system trivial-build-system)
2404 (arguments
2405 `(#:modules ((guix build utils))
2406 #:builder
2407 (begin
2408 (use-modules (guix build utils))
2409 (let ((target (string-append (assoc-ref %outputs "out")
2410 "/share/texmf-dist/tex/latex/cmap")))
2411 (mkdir-p target)
2412 (copy-recursively (assoc-ref %build-inputs "source") target)
2413 #t))))
2414 (home-page "https://www.tug.org/svn/texlive/tags/texlive-2017.1/\
2415 Master/texmf-dist/tex/latex/cmap/")
2416 (synopsis "CMap support for PDF files")
2417 (description
2418 "This package embeds CMap tables into PDF files to make search and
2419 copy-and-paste functions work properly.")
2420 (license license:lppl)))
2421
2422 (define-public texlive-latex-colortbl
2423 (package
2424 (name "texlive-latex-colortbl")
2425 (version (number->string %texlive-revision))
2426 (source (origin
2427 (method svn-fetch)
2428 (uri (texlive-ref "latex" "colortbl"))
2429 (sha256
2430 (base32
2431 "190pmq8la2rq07xry8bn8z8yywzxv6fqyqaj7yjfj5rgw6x0mas8"))))
2432 (build-system texlive-build-system)
2433 (arguments '(#:tex-directory "latex/colortbl"))
2434 (home-page "http://www.ctan.org/pkg/colortbl")
2435 (synopsis "Add colour to LaTeX tables")
2436 (description
2437 "This package allows rows, columns, and even individual cells in LaTeX
2438 tables to be coloured.")
2439 (license license:lppl)))
2440
2441 (define-public texlive-latex-fancybox
2442 (package
2443 (name "texlive-latex-fancybox")
2444 (version (number->string %texlive-revision))
2445 (source (origin
2446 (method svn-fetch)
2447 (uri (svn-reference
2448 (url (string-append "svn://www.tug.org/texlive/tags/"
2449 %texlive-tag "/Master/texmf-dist/"
2450 "/tex/latex/fancybox"))
2451 (revision %texlive-revision)))
2452 (sha256
2453 (base32
2454 "0smmnaad2q8qwicay1frri990lv65l0k8cwzsvdsyp3jk8kp042w"))))
2455 (build-system trivial-build-system)
2456 (arguments
2457 `(#:modules ((guix build utils))
2458 #:builder
2459 (begin
2460 (use-modules (guix build utils))
2461 (let ((target (string-append (assoc-ref %outputs "out")
2462 "/share/texmf-dist/tex/latex/fancybox")))
2463 (mkdir-p target)
2464 (copy-recursively (assoc-ref %build-inputs "source") target)
2465 #t))))
2466 (home-page "http://www.ctan.org/pkg/fancybox")
2467 (synopsis "Variants of \\fbox and other games with boxes")
2468 (description
2469 "This package provides variants of @code{\\fbox}: @code{\\shadowbox},
2470 @code{\\doublebox}, @code{\\ovalbox}, @code{\\Ovalbox}, with helpful tools for
2471 using box macros and flexible verbatim macros. You can box mathematics,
2472 floats, center, flushleft, and flushright, lists, and pages.")
2473 (license license:lppl1.2+)))
2474
2475 (define-public texlive-latex-fancyhdr
2476 (package
2477 (name "texlive-latex-fancyhdr")
2478 (version (number->string %texlive-revision))
2479 (source (origin
2480 (method svn-fetch)
2481 (uri (svn-reference
2482 (url (string-append "svn://www.tug.org/texlive/tags/"
2483 %texlive-tag "/Master/texmf-dist/"
2484 "/tex/latex/fancyhdr"))
2485 (revision %texlive-revision)))
2486 (sha256
2487 (base32
2488 "04h430agf8aj7ziwyb46xpk95c605rjk1wzhr63m6ylipihidlgw"))))
2489 (build-system trivial-build-system)
2490 (arguments
2491 `(#:modules ((guix build utils))
2492 #:builder
2493 (begin
2494 (use-modules (guix build utils))
2495 (let ((target (string-append (assoc-ref %outputs "out")
2496 "/share/texmf-dist/tex/latex/fancyhdr")))
2497 (mkdir-p target)
2498 (copy-recursively (assoc-ref %build-inputs "source") target)
2499 #t))))
2500 (home-page "http://www.ctan.org/pkg/fancyhdr")
2501 (synopsis "Extensive control of page headers and footers in LaTeX2e")
2502 (description
2503 "The package provides extensive facilities, both for constructing headers
2504 and footers, and for controlling their use (for example, at times when LaTeX
2505 would automatically change the heading style in use).")
2506 (license license:lppl)))
2507
2508 (define-public texlive-latex-fancyvrb
2509 (package
2510 (name "texlive-latex-fancyvrb")
2511 (version (number->string %texlive-revision))
2512 (source (origin
2513 (method svn-fetch)
2514 (uri (texlive-ref "latex" "fancyvrb"))
2515 (sha256
2516 (base32
2517 "03l7140y031rr14h02i4z9zqsfvrbn7wzwxbjsrjcgrk6sdr71wv"))))
2518 (build-system texlive-build-system)
2519 (arguments
2520 '(#:build-targets '("fancyvrb.ins") ; fvrb-ex.ins cannot be built
2521 #:tex-directory "latex/fancyvrb"))
2522 (home-page "http://www.ctan.org/pkg/fancyvrb")
2523 (synopsis "Sophisticated verbatim text")
2524 (description
2525 "This package provides tools for flexible handling of verbatim text
2526 including: verbatim commands in footnotes; a variety of verbatim environments
2527 with many parameters; ability to define new customized verbatim environments;
2528 save and restore verbatim text and environments; write and read files in
2529 verbatim mode; build \"example\" environments (showing both result and
2530 verbatim source).")
2531 (license license:lppl1.0+)))
2532
2533 (define-public texlive-latex-float
2534 (package
2535 (name "texlive-latex-float")
2536 (version (number->string %texlive-revision))
2537 (source (origin
2538 (method svn-fetch)
2539 (uri (texlive-ref "latex" "float"))
2540 (sha256
2541 (base32
2542 "0nbl7wylkv22fcdv4p8byhhj575fli6jnqjpkhrkbv8dzwah84nq"))))
2543 (build-system texlive-build-system)
2544 (arguments '(#:tex-directory "latex/float"))
2545 (home-page "http://www.ctan.org/pkg/float")
2546 (synopsis "Improved interface for floating objects")
2547 (description
2548 "This package improves the interface for defining floating objects such
2549 as figures and tables. It introduces the boxed float, the ruled float and the
2550 plaintop float. You can define your own floats and improve the behaviour of
2551 the old ones. The package also provides the @code{H} float modifier option of
2552 the obsolete @code{here} package. You can select this as automatic default
2553 with @code{\\floatplacement{figure}{H}}.")
2554 (license license:lppl)))
2555
2556 (define-public texlive-latex-footmisc
2557 (package
2558 (name "texlive-latex-footmisc")
2559 (version (number->string %texlive-revision))
2560 (source (origin
2561 (method svn-fetch)
2562 (uri (texlive-ref "latex" "footmisc"))
2563 (sha256
2564 (base32
2565 "03x61wwql8nh6zrqiiiq3rb0x7m3pn48c606zapy19y21fybwdxs"))))
2566 (build-system texlive-build-system)
2567 (arguments '(#:tex-directory "latex/footmisc"))
2568 (home-page "http://www.ctan.org/pkg/footmisc")
2569 (synopsis "Range of footnote options")
2570 (description
2571 "This is a collection of ways to change the typesetting of footnotes.
2572 The package provides means of changing the layout of the footnotes themselves,
2573 a way to number footnotes per page, to make footnotes disappear in a
2574 \"moving\" argument, and to deal with multiple references to footnotes from
2575 the same place. The package also has a range of techniques for labelling
2576 footnotes with symbols rather than numbers.")
2577 (license license:lppl1.3+)))
2578
2579 (define-public texlive-latex-listings
2580 (package
2581 (name "texlive-latex-listings")
2582 (version (number->string %texlive-revision))
2583 (source (origin
2584 (method svn-fetch)
2585 (uri (texlive-ref "latex" "listings"))
2586 (sha256
2587 (base32
2588 "1nsn9wp3wl12b36c0sqrim33lf33cr5wky0h4ncnw8lvqgm7h8wf"))))
2589 (build-system texlive-build-system)
2590 (arguments
2591 '(#:tex-directory "latex/listings"
2592 #:build-targets '("listings.ins")))
2593 (home-page "http://www.ctan.org/pkg/listings")
2594 (synopsis "Typeset source code listings using LaTeX")
2595 (description
2596 "The package enables the user to typeset programs (programming code)
2597 within LaTeX; the source code is read directly by TeX---no front-end processor
2598 is needed. Keywords, comments and strings can be typeset using different
2599 styles. Support for @code{hyperref} is provided.")
2600 (license license:lppl1.3+)))
2601
2602 (define-public texlive-latex-jknapltx
2603 (package
2604 (name "texlive-latex-jknapltx")
2605 (version (number->string %texlive-revision))
2606 (source (origin
2607 (method svn-fetch)
2608 (uri (svn-reference
2609 (url (string-append "svn://www.tug.org/texlive/tags/"
2610 %texlive-tag "/Master/texmf-dist/"
2611 "/tex/latex/jknapltx"))
2612 (revision %texlive-revision)))
2613 (sha256
2614 (base32
2615 "0m034x72f2g07icr50gacyxfb9g1lz2rmqh4kqr1qjb421x2kds9"))))
2616 (build-system trivial-build-system)
2617 (arguments
2618 `(#:modules ((guix build utils))
2619 #:builder
2620 (begin
2621 (use-modules (guix build utils))
2622 (let ((target (string-append (assoc-ref %outputs "out")
2623 "/share/texmf-dist/tex/latex/jknapltx")))
2624 (mkdir-p target)
2625 (copy-recursively (assoc-ref %build-inputs "source") target)
2626 #t))))
2627 (home-page "http://www.ctan.org/pkg/jknappen")
2628 (synopsis "Miscellaneous packages by Joerg Knappen")
2629 (description
2630 "This package provides miscellaneous macros by Joerg Knappen, including:
2631 represent counters in greek; Maxwell's non-commutative division;
2632 @code{latin1jk}, @code{latin2jk} and @code{latin3jk}, which are
2633 @code{inputenc} definition files that allow verbatim input in the respective
2634 ISO Latin codes; blackboard bold fonts in maths; use of RSFS fonts in maths;
2635 extra alignments for @code{\\parboxes}; swap Roman and Sans fonts;
2636 transliterate semitic languages; patches to make (La)TeX formulae embeddable
2637 in SGML; use maths minus in text as appropriate; simple Young tableaux.")
2638 (license license:gpl2)))
2639
2640 (define-public texlive-fonts-ec
2641 (package
2642 (name "texlive-fonts-ec")
2643 (version (number->string %texlive-revision))
2644 (source (origin
2645 (method svn-fetch)
2646 (uri (svn-reference
2647 (url (string-append "svn://www.tug.org/texlive/tags/"
2648 %texlive-tag "/Master/texmf-dist/"
2649 "/fonts/source/jknappen/ec/"))
2650 (revision %texlive-revision)))
2651 (sha256
2652 (base32
2653 "12av65fbz9xiashm09c9m1fj1mijxls5xspd7652ry1n5s0nixy4"))))
2654 (build-system gnu-build-system)
2655 (arguments
2656 `(#:modules ((guix build gnu-build-system)
2657 (guix build utils)
2658 (srfi srfi-1)
2659 (srfi srfi-26))
2660 #:tests? #f ; no tests
2661 #:phases
2662 (modify-phases %standard-phases
2663 (delete 'configure)
2664 (replace 'build
2665 (lambda* (#:key inputs #:allow-other-keys)
2666 (let ((mf (assoc-ref inputs "texlive-metafont-base")))
2667 ;; Tell mf where to find mf.base
2668 (setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
2669 ;; Tell mf where to look for source files
2670 (setenv "MFINPUTS"
2671 (string-append (getcwd) ":"
2672 mf "/share/texmf-dist/metafont/base:"
2673 (assoc-ref inputs "texlive-fonts-cm")
2674 "/share/texmf-dist/fonts/source/public/cm")))
2675 (mkdir "build")
2676 (every (lambda (font)
2677 (format #t "building font ~a\n" font)
2678 (zero? (system* "mf" "-progname=mf"
2679 "-output-directory=build"
2680 (string-append "\\"
2681 "mode:=ljfour; "
2682 "mag:=1; "
2683 "batchmode; "
2684 "input " (basename font ".mf")))))
2685 (find-files "." "[0-9]+\\.mf$"))))
2686 (replace 'install
2687 (lambda* (#:key outputs #:allow-other-keys)
2688 (let* ((out (assoc-ref outputs "out"))
2689 (tfm (string-append
2690 out "/share/texmf-dist/fonts/tfm/jknappen/ec"))
2691 (mf (string-append
2692 out "/share/texmf-dist/fonts/source/jknappen/ec")))
2693 (for-each (cut install-file <> tfm)
2694 (find-files "build" "\\.*"))
2695 (for-each (cut install-file <> mf)
2696 (find-files "." "\\.mf"))
2697 #t))))))
2698 (native-inputs
2699 `(("texlive-bin" ,texlive-bin)
2700 ("texlive-metafont-base" ,texlive-metafont-base)
2701 ("texlive-fonts-cm" ,texlive-fonts-cm)))
2702 (home-page "http://www.ctan.org/pkg/ec")
2703 (synopsis "Computer modern fonts in T1 and TS1 encodings")
2704 (description
2705 "The EC fonts are European Computer Modern Fonts, supporting the complete
2706 LaTeX T1 encoding defined at the 1990 TUG conference hold at Cork/Ireland.
2707 These fonts are intended to be stable with no changes being made to the tfm
2708 files. The set also contains a Text Companion Symbol font, called @code{tc},
2709 featuring many useful characters needed in text typesetting, for example
2710 oldstyle digits, currency symbols (including the newly created Euro symbol),
2711 the permille sign, copyright, trade mark and servicemark as well as a copyleft
2712 sign, and many others. Recent releases of LaTeX2e support the EC fonts. The
2713 EC fonts supersede the preliminary version released as the DC fonts. The
2714 fonts are available in (traced) Adobe Type 1 format, as part of the
2715 @code{cm-super} bundle. The other Computer Modern-style T1-encoded Type 1
2716 set, Latin Modern, is not actually a direct development of the EC set, and
2717 differs from the EC in a number of particulars.")
2718 (license (license:fsf-free "https://www.tug.org/svn/texlive/tags/\
2719 texlive-2017.1/Master/texmf-dist/doc/fonts/ec/copyrite.txt"))))
2720
2721 (define-public texlive-fonts-rsfs
2722 (package
2723 (name "texlive-fonts-rsfs")
2724 (version (number->string %texlive-revision))
2725 (source (origin
2726 (method svn-fetch)
2727 (uri (svn-reference
2728 (url (string-append "svn://www.tug.org/texlive/tags/"
2729 %texlive-tag "/Master/texmf-dist/"
2730 "/fonts/source/public/rsfs/"))
2731 (revision %texlive-revision)))
2732 (sha256
2733 (base32
2734 "0r12pn02r4a955prcvq0048nifh86ihlcgvw3pppqqvfngv34l5h"))))
2735 (build-system gnu-build-system)
2736 (arguments
2737 `(#:modules ((guix build gnu-build-system)
2738 (guix build utils)
2739 (srfi srfi-1)
2740 (srfi srfi-26))
2741 #:tests? #f ; no tests
2742 #:phases
2743 (modify-phases %standard-phases
2744 (delete 'configure)
2745 (replace 'build
2746 (lambda* (#:key inputs #:allow-other-keys)
2747 (let ((mf (assoc-ref inputs "texlive-metafont-base")))
2748 ;; Tell mf where to find mf.base
2749 (setenv "MFBASES" (string-append mf "/share/texmf-dist/web2c"))
2750 ;; Tell mf where to look for source files
2751 (setenv "MFINPUTS"
2752 (string-append (getcwd) ":"
2753 mf "/share/texmf-dist/metafont/base:"
2754 (assoc-ref inputs "texlive-fonts-cm")
2755 "/share/texmf-dist/fonts/source/public/cm")))
2756 (mkdir "build")
2757 (every (lambda (font)
2758 (format #t "building font ~a\n" font)
2759 (zero? (system* "mf" "-progname=mf"
2760 "-output-directory=build"
2761 (string-append "\\"
2762 "mode:=ljfour; "
2763 "mag:=1; "
2764 "batchmode; "
2765 "input " (basename font ".mf")))))
2766 (find-files "." "[0-9]+\\.mf$"))))
2767 (replace 'install
2768 (lambda* (#:key outputs #:allow-other-keys)
2769 (let* ((out (assoc-ref outputs "out"))
2770 (tfm (string-append
2771 out "/share/texmf-dist/fonts/tfm/public/rsfs"))
2772 (mf (string-append
2773 out "/share/texmf-dist/fonts/source/public/rsfs")))
2774 (for-each (cut install-file <> tfm)
2775 (find-files "build" "\\.*"))
2776 (for-each (cut install-file <> mf)
2777 (find-files "." "\\.mf"))
2778 #t))))))
2779 (native-inputs
2780 `(("texlive-bin" ,texlive-bin)
2781 ("texlive-metafont-base" ,texlive-metafont-base)
2782 ("texlive-fonts-cm" ,texlive-fonts-cm)))
2783 (home-page "http://www.ctan.org/pkg/rsfs")
2784 (synopsis "Ralph Smith's Formal Script font")
2785 (description
2786 "The fonts provide uppercase formal script letters for use as symbols in
2787 scientific and mathematical typesetting (in contrast to the informal script
2788 fonts such as that used for the calligraphic symbols in the TeX maths symbol
2789 font). The fonts are provided as Metafont source, and as derived Adobe Type 1
2790 format. LaTeX support, for using these fonts in mathematics, is available via
2791 one of the packages @code{calrsfs} and @code{mathrsfs}.")
2792 (license (license:fsf-free "http://mirrors.ctan.org/fonts/rsfs/README"))))
2793
2794 (define-public texlive-latex-eso-pic
2795 (package
2796 (name "texlive-latex-eso-pic")
2797 (version (number->string %texlive-revision))
2798 (source (origin
2799 (method svn-fetch)
2800 (uri (texlive-ref "latex" "eso-pic"))
2801 (sha256
2802 (base32
2803 "1xvmms28mvvfpks9x7lfya2xhh5k8jy3qnlih1mzcnf156xnb89z"))))
2804 (build-system texlive-build-system)
2805 (arguments '(#:tex-directory "latex/eso-pic"))
2806 (home-page "http://www.ctan.org/pkg/eso-pic")
2807 (synopsis "Add picture commands (or backgrounds) to every page")
2808 (description
2809 "The package adds one or more user commands to LaTeX's @code{shipout}
2810 routine, which may be used to place the output at fixed positions. The
2811 @code{grid} option may be used to find the correct places.")
2812 (license license:lppl1.3+)))
2813
2814 (define-public texlive-latex-eepic
2815 (package
2816 (name "texlive-latex-eepic")
2817 (version (number->string %texlive-revision))
2818 (source (origin
2819 (method svn-fetch)
2820 (uri (svn-reference
2821 (url (string-append "svn://www.tug.org/texlive/tags/"
2822 %texlive-tag "/Master/texmf-dist/"
2823 "/tex/latex/eepic"))
2824 (revision %texlive-revision)))
2825 (sha256
2826 (base32
2827 "1c68gvh021pvybg07apsd2xhq2ljbg80kq94wh71drdga3c2zqjw"))))
2828 (build-system trivial-build-system)
2829 (arguments
2830 `(#:modules ((guix build utils))
2831 #:builder
2832 (begin
2833 (use-modules (guix build utils))
2834 (let ((target (string-append (assoc-ref %outputs "out")
2835 "/share/texmf-dist/tex/latex/eepic")))
2836 (mkdir-p target)
2837 (copy-recursively (assoc-ref %build-inputs "source") target)
2838 #t))))
2839 (home-page "http://www.ctan.org/pkg/eepic")
2840 (synopsis "Extensions to epic and the LaTeX drawing tools")
2841 (description
2842 "Extensions to @code{epic} and the LaTeX picture drawing environment,
2843 include the drawing of lines at any slope, the drawing of circles in any
2844 radii, and the drawing of dotted and dashed lines much faster with much less
2845 TeX memory, and providing several new commands for drawing ellipses, arcs,
2846 splines, and filled circles and ellipses. The package uses @code{tpic}
2847 @code{\\special} commands.")
2848 (license license:public-domain)))
2849
2850 (define-public texlive-latex-multirow
2851 (package
2852 (name "texlive-latex-multirow")
2853 (version (number->string %texlive-revision))
2854 (source (origin
2855 (method svn-fetch)
2856 (uri (texlive-ref "latex" "multirow"))
2857 (sha256
2858 (base32
2859 "0qlxy47f1f8plgch3jqfsnrdgpyz20sz46yp33i2jwvf9hvfczf0"))))
2860 (build-system texlive-build-system)
2861 (arguments '(#:tex-directory "latex/multirow"))
2862 (home-page "http://www.ctan.org/pkg/multirow")
2863 (synopsis "Create tabular cells spanning multiple rows")
2864 (description
2865 "The package provides tools for creating tabular cells spanning multiple
2866 rows. It has a lot of flexibility, including an option for specifying an
2867 entry at the \"natural\" width of its text.")
2868 (license license:lppl1.3+)))
2869
2870 (define-public texlive-latex-overpic
2871 (package
2872 (name "texlive-latex-overpic")
2873 (version (number->string %texlive-revision))
2874 (source (origin
2875 (method svn-fetch)
2876 (uri (svn-reference
2877 (url (string-append "svn://www.tug.org/texlive/tags/"
2878 %texlive-tag "/Master/texmf-dist/"
2879 "/tex/latex/overpic"))
2880 (revision %texlive-revision)))
2881 (sha256
2882 (base32
2883 "0m29q9qdb00558b7g2i7iw6w62n5s46yx81j8m99qkv77magk4fm"))))
2884 (build-system trivial-build-system)
2885 (arguments
2886 `(#:modules ((guix build utils))
2887 #:builder
2888 (begin
2889 (use-modules (guix build utils))
2890 (let ((target (string-append (assoc-ref %outputs "out")
2891 "/share/texmf-dist/tex/latex/overpic")))
2892 (mkdir-p target)
2893 (copy-recursively (assoc-ref %build-inputs "source") target)
2894 #t))))
2895 (home-page "http://www.ctan.org/pkg/overpic")
2896 (synopsis "Combine LaTeX commands over included graphics")
2897 (description
2898 "The @code{overpic} environment is a cross between the LaTeX
2899 @code{picture} environment and the @code{\\includegraphics} command of
2900 @code{graphicx}. The resulting picture environment has the same dimensions as
2901 the included graphic. LaTeX commands can be placed on the graphic at defined
2902 positions; a grid for orientation is available.")
2903 (license license:lppl1.0+)))
2904
2905 (define-public texlive-latex-parskip
2906 (package
2907 (name "texlive-latex-parskip")
2908 (version (number->string %texlive-revision))
2909 (source (origin
2910 (method svn-fetch)
2911 (uri (svn-reference
2912 (url (string-append "svn://www.tug.org/texlive/tags/"
2913 %texlive-tag "/Master/texmf-dist/"
2914 "/tex/latex/parskip"))
2915 (revision %texlive-revision)))
2916 (file-name (string-append name "-" version "-checkout"))
2917 (sha256
2918 (base32
2919 "14r6h9hqb0qgccxj5l1208694fx8sb8avmgzps36lsbbpszl7i7m"))))
2920 (build-system trivial-build-system)
2921 (arguments
2922 `(#:modules ((guix build utils))
2923 #:builder
2924 (begin
2925 (use-modules (guix build utils))
2926 (let ((target (string-append (assoc-ref %outputs "out")
2927 "/share/texmf-dist/tex/latex/parskip")))
2928 (mkdir-p target)
2929 (copy-recursively (assoc-ref %build-inputs "source") target)
2930 #t))))
2931 (home-page "http://www.ctan.org/pkg/parskip")
2932 (synopsis "Layout with zero \\parindent, non-zero \\parskip")
2933 (description
2934 "Simply changing @code{\\parskip} and @code{\\parindent} leaves a layout
2935 that is untidy; this package (though it is no substitute for a properly
2936 designed class) helps alleviate this untidiness.")
2937 (license license:lppl)))
2938
2939 (define-public texlive-latex-pdfpages
2940 (package
2941 (name "texlive-latex-pdfpages")
2942 (version (number->string %texlive-revision))
2943 (source (origin
2944 (method svn-fetch)
2945 (uri (texlive-ref "latex" "pdfpages"))
2946 (sha256
2947 (base32
2948 "06p5smfq66559ppdnmkl3hp8534x84ywbscimsiir4gllpya3i9h"))))
2949 (build-system texlive-build-system)
2950 (arguments '(#:tex-directory "latex/pdfpages"))
2951 (home-page "http://www.ctan.org/pkg/pdfpages")
2952 (synopsis "Include PDF documents in LaTeX")
2953 (description
2954 "This package simplifies the inclusion of external multi-page PDF
2955 documents in LaTeX documents. Pages may be freely selected and it is possible
2956 to put several logical pages onto each sheet of paper. Furthermore a lot of
2957 hypertext features like hyperlinks and article threads are provided. The
2958 package supports pdfTeX (pdfLaTeX) and VTeX. With VTeX it is even possible to
2959 use this package to insert PostScript files, in addition to PDF files.")
2960 (license license:lppl1.3+)))
2961
2962 (define-public texlive-fonts-stmaryrd
2963 (package
2964 (name "texlive-fonts-stmaryrd")
2965 (version (number->string %texlive-revision))
2966 (source (origin
2967 (method svn-fetch)
2968 (uri (texlive-ref "fonts" "stmaryrd"))
2969 (sha256
2970 (base32
2971 "08pn4ca3vl6qm9l3wm5h5iyjsrg411kkm1yana329xwg2j14s9n6"))))
2972 (build-system texlive-build-system)
2973 (arguments
2974 '(#:tex-directory "latex/stmaryrd"
2975 #:phases
2976 (modify-phases %standard-phases
2977 (add-after 'configure 'patch-ins
2978 (lambda _
2979 (substitute* "stmaryrd.ins"
2980 (("^%% LaTeX2e.*") "\\input docstrip\n")
2981 (("fontdef\\}\\}" line)
2982 (string-append line "\n\\endbatchfile")))
2983 #t)))))
2984 (home-page "http://www.ctan.org/pkg/stmaryrd")
2985 (synopsis "St Mary Road symbols for theoretical computer science")
2986 (description
2987 "The fonts were originally distributed as Metafont sources only, but
2988 Adobe Type 1 versions are also now available. Macro support is provided for
2989 use under LaTeX; the package supports the @code{only} option (provided by the
2990 @code{somedefs} package) to restrict what is loaded, for those who don't need
2991 the whole font.")
2992 (license license:lppl)))
2993
2994 (define-public texlive-latex-subfigure
2995 (package
2996 (name "texlive-latex-subfigure")
2997 (version (number->string %texlive-revision))
2998 (source (origin
2999 (method svn-fetch)
3000 (uri (texlive-ref "latex" "subfigure"))
3001 (sha256
3002 (base32
3003 "15spcl5wb7w269qd6y596vp4yi8sa5ppcx8w4z2i9kyp02r3a0yb"))))
3004 (build-system texlive-build-system)
3005 (arguments '(#:tex-directory "latex/subfigure"))
3006 (home-page "http://www.ctan.org/pkg/subfigure")
3007 (synopsis "Figures divided into subfigures")
3008 (description
3009 "This (deprecated) package provides support for the manipulation and
3010 reference of small or \"sub\" figures and tables within a single figure or
3011 table environment. It is convenient to use this package when your subfigures
3012 are to be separately captioned, referenced, or are to be included in the
3013 List-of-Figures. A new @code{\\subfigure} command is introduced which can be
3014 used inside a figure environment for each subfigure. An optional first
3015 argument is used as the caption for that subfigure. The package is now
3016 considered obsolete: it was superseded by @code{subfig}, but users may find
3017 the more recent @code{subcaption} package more satisfactory.")
3018 (license license:lppl)))
3019
3020 (define-public texlive-latex-tabulary
3021 (package
3022 (name "texlive-latex-tabulary")
3023 (version (number->string %texlive-revision))
3024 (source (origin
3025 (method svn-fetch)
3026 (uri (texlive-ref "latex" "tabulary"))
3027 (file-name (string-append name "-" version "-checkout"))
3028 (sha256
3029 (base32
3030 "1adkdx2zkk42g82nqf57lv1nc1z7kwl13jmy8vpcsizsa0xdnx9n"))))
3031 (build-system texlive-build-system)
3032 (arguments '(#:tex-directory "latex/tabulary"))
3033 (home-page "http://www.ctan.org/pkg/tabulary")
3034 (synopsis "Tabular with variable width columns balanced")
3035 (description
3036 "The package defines a @code{tabular*}-like environment, @code{tabulary},
3037 taking a \"total width\" argument as well as the column specifications. The
3038 environment uses column types @code{L}, @code{C}, @code{R} and @code{J} for
3039 variable width columns (@code{\\raggedright}, @code{\\centering},
3040 @code{\\raggedleft}, and normally justified). In contrast to
3041 @code{tabularx}'s @code{X} columns, the width of each column is weighted
3042 according to the natural width of the widest cell in the column.")
3043 (license license:lppl)))
3044
3045 (define-public texlive-latex-threeparttable
3046 (package
3047 (name "texlive-latex-threeparttable")
3048 (version (number->string %texlive-revision))
3049 (source (origin
3050 (method svn-fetch)
3051 (uri (svn-reference
3052 (url (string-append "svn://www.tug.org/texlive/tags/"
3053 %texlive-tag "/Master/texmf-dist/"
3054 "/tex/latex/threeparttable"))
3055 (revision %texlive-revision)))
3056 (sha256
3057 (base32
3058 "10vy9k150w2lviw8h22s2mcykff38xci653m5823s2vv44pwbmzq"))))
3059 (build-system trivial-build-system)
3060 (arguments
3061 `(#:modules ((guix build utils))
3062 #:builder
3063 (begin
3064 (use-modules (guix build utils))
3065 (let ((target (string-append (assoc-ref %outputs "out")
3066 "/share/texmf-dist/tex/latex/threeparttable")))
3067 (mkdir-p target)
3068 (copy-recursively (assoc-ref %build-inputs "source") target)
3069 #t))))
3070 (home-page "http://www.ctan.org/pkg/threeparttable")
3071 (synopsis "Tables with captions and notes all the same width")
3072 (description
3073 "This package facilitates tables with titles (captions) and notes. The
3074 title and notes are given a width equal to the body of the table (a
3075 @code{tabular} environment). By itself, a @code{threeparttable} does not
3076 float, but you can put it in a @code{table} or a @code{table*} or some other
3077 environment.")
3078 (license (license:fsf-free "file://threeparttable.sty"))))
3079
3080 (define-public texlive-latex-titlesec
3081 (package
3082 (name "texlive-latex-titlesec")
3083 (version (number->string %texlive-revision))
3084 (source (origin
3085 (method svn-fetch)
3086 (uri (svn-reference
3087 (url (string-append "svn://www.tug.org/texlive/tags/"
3088 %texlive-tag "/Master/texmf-dist/"
3089 "/tex/latex/titlesec"))
3090 (revision %texlive-revision)))
3091 (sha256
3092 (base32
3093 "04nmkhqx6jxcxx9a30zbcd5smxi5fd0cbp132bki7fnvhspnhg21"))))
3094 (build-system trivial-build-system)
3095 (arguments
3096 `(#:modules ((guix build utils))
3097 #:builder
3098 (begin
3099 (use-modules (guix build utils))
3100 (let ((target (string-append (assoc-ref %outputs "out")
3101 "/share/texmf-dist/tex/latex/titlesec")))
3102 (mkdir-p target)
3103 (copy-recursively (assoc-ref %build-inputs "source") target)
3104 #t))))
3105 (home-page "http://www.ctan.org/pkg/titlesec")
3106 (synopsis "Select alternative section titles")
3107 (description
3108 "This package provides an interface to sectioning commands for selection
3109 from various title styles, e.g. for marginal titles and to change the font of
3110 all headings with a single command, also providing simple one-step page
3111 styles. It also includes a package to change the page styles when there are
3112 floats in a page. You may assign headers/footers to individual floats, too.")
3113 (license license:lppl)))
3114
3115 (define-public texlive-latex-lh
3116 (package
3117 (name "texlive-latex-lh")
3118 (version (number->string %texlive-revision))
3119 (source (origin
3120 (method svn-fetch)
3121 (uri (texlive-ref "latex" "lh"))
3122 (sha256
3123 (base32
3124 "00gdiwh3sfhh1iimjhpja7lm7k4vzqzql2irgwnpz94qvh25zwi5"))))
3125 (build-system texlive-build-system)
3126 (arguments '(#:tex-directory "latex/lh"))
3127 (home-page "http://www.ctan.org/pkg/lh")
3128 (synopsis "Cyrillic fonts that support LaTeX standard encodings")
3129 (description
3130 "The LH fonts address the problem of the wide variety of alphabets that
3131 are written with Cyrillic-style characters. The fonts are the original basis
3132 of the set of T2* and X2 encodings that are now used when LaTeX users need to
3133 write in Cyrillic languages. Macro support in standard LaTeX encodings is
3134 offered through the latex-cyrillic and t2 bundles, and the package itself
3135 offers support for other (more traditional) encodings. The fonts, in the
3136 standard T2* and X2 encodings are available in Adobe Type 1 format, in the
3137 CM-Super family of fonts. The package also offers its own LaTeX support for
3138 OT2 encoded fonts, CM bright shaped fonts and Concrete shaped fonts.")
3139 (license license:lppl)))
3140
3141 (define-public texlive-metapost
3142 (package
3143 (name "texlive-metapost")
3144 (version (number->string %texlive-revision))
3145 (source (origin
3146 (method svn-fetch)
3147 (uri (svn-reference
3148 (url (string-append "svn://www.tug.org/texlive/tags/"
3149 %texlive-tag "/Master/texmf-dist/"
3150 "/metapost"))
3151 (revision %texlive-revision)))
3152 (sha256
3153 (base32
3154 "03nvjddffiz796wll6axzmgfvynyciy2mqamv20qx252w71vwkwd"))))
3155 (build-system trivial-build-system)
3156 (arguments
3157 `(#:modules ((guix build utils))
3158 #:builder
3159 (begin
3160 (use-modules (guix build utils))
3161 (let ((target (string-append (assoc-ref %outputs "out")
3162 "/share/texmf-dist/metapost")))
3163 (mkdir-p target)
3164 (copy-recursively (assoc-ref %build-inputs "source") target)
3165 #t))))
3166 (home-page "http://www.ctan.org/pkg/metapost")
3167 (synopsis "Create scalable illustrations")
3168 (description
3169 "MetaPost uses a language based on that of Metafont to produce precise
3170 technical illustrations. Its output is scalable PostScript or SVG, rather
3171 than the bitmaps Metafont creates.")
3172 (license license:lppl)))
3173
3174 (define-public texlive-latex-varwidth
3175 (package
3176 (name "texlive-latex-varwidth")
3177 (version (number->string %texlive-revision))
3178 (source (origin
3179 (method svn-fetch)
3180 (uri (svn-reference
3181 (url (string-append "svn://www.tug.org/texlive/tags/"
3182 %texlive-tag "/Master/texmf-dist/"
3183 "/tex/latex/varwidth"))
3184 (revision %texlive-revision)))
3185 (file-name (string-append name "-" version "-checkout"))
3186 (sha256
3187 (base32
3188 "1bmz9ap0ffyg7qry2xi7lki06qx4809w028xvk88cl66h7p46g52"))))
3189 (build-system trivial-build-system)
3190 (arguments
3191 `(#:modules ((guix build utils))
3192 #:builder
3193 (begin
3194 (use-modules (guix build utils))
3195 (let ((target (string-append (assoc-ref %outputs "out")
3196 "/share/texmf-dist/tex/latex/varwidth")))
3197 (mkdir-p target)
3198 (copy-recursively (assoc-ref %build-inputs "source") target)
3199 #t))))
3200 (home-page "http://www.ctan.org/pkg/varwidth")
3201 (synopsis "Variable-width minipage")
3202 (description
3203 "The @code{varwidth} environment is superficially similar to
3204 @code{minipage}, but the specified width is just a maximum value — the box may
3205 get a narrower “natural” width.")
3206 (license license:lppl)))
3207
3208 (define-public texlive-latex-wasysym
3209 (package
3210 (name "texlive-latex-wasysym")
3211 (version (number->string %texlive-revision))
3212 (source (origin
3213 (method svn-fetch)
3214 (uri (texlive-ref "latex" "wasysym"))
3215 (sha256
3216 (base32
3217 "1sgwbfwjjf70g54hh93gsd9jp9nm67w6n74x9d72a56n07jbk5hv"))))
3218 (build-system texlive-build-system)
3219 (arguments '(#:tex-directory "latex/wasysym"))
3220 (home-page "http://www.ctan.org/pkg/wasysym")
3221 (synopsis "LaTeX support file to use the WASY2 fonts")
3222 (description
3223 "The wasy2WASY2 (Waldi Symbol) font by Roland Waldi provides many glyphs
3224 like male and female symbols and astronomical symbols, as well as the complete
3225 lasy font set and other odds and ends. The wasysym package implements an easy
3226 to use interface for these symbols.")
3227 (license license:lppl)))
3228
3229 (define-public texlive-latex-wrapfig
3230 (package
3231 (name "texlive-latex-wrapfig")
3232 (version (number->string %texlive-revision))
3233 (source (origin
3234 (method svn-fetch)
3235 (uri (svn-reference
3236 (url (string-append "svn://www.tug.org/texlive/tags/"
3237 %texlive-tag "/Master/texmf-dist/"
3238 "/tex/latex/wrapfig"))
3239 (revision %texlive-revision)))
3240 (file-name (string-append name "-" version "-checkout"))
3241 (sha256
3242 (base32
3243 "16xpyl0csmmwndz1xhzqfg9l0zcsnqxslsixsqkwd4zsvfj30sv4"))))
3244 (build-system trivial-build-system)
3245 (arguments
3246 `(#:modules ((guix build utils))
3247 #:builder
3248 (begin
3249 (use-modules (guix build utils))
3250 (let ((target (string-append (assoc-ref %outputs "out")
3251 "/share/texmf-dist/tex/latex/wrapfig")))
3252 (mkdir-p target)
3253 (copy-recursively (assoc-ref %build-inputs "source") target)
3254 #t))))
3255 (home-page "http://www.ctan.org/pkg/wrapfig")
3256 (synopsis "Produces figures which text can flow around")
3257 (description
3258 "This package allows figures or tables to have text wrapped around them.
3259 It does not work in combination with list environments, but can be used in a
3260 @code{parbox} or @code{minipage}, and in two-column format.")
3261 (license license:lppl)))
3262
3263 (define-public texlive-latex-ucs
3264 (package
3265 (name "texlive-latex-ucs")
3266 (version (number->string %texlive-revision))
3267 (source (origin
3268 (method svn-fetch)
3269 (uri (svn-reference
3270 (url (string-append "svn://www.tug.org/texlive/tags/"
3271 %texlive-tag "/Master/texmf-dist/"
3272 "/tex/latex/ucs"))
3273 (revision %texlive-revision)))
3274 (file-name (string-append name "-" version "-checkout"))
3275 (sha256
3276 (base32
3277 "0rrxwi60wmz5dfjifl4fwk66plf7wix85qnhfv4ylvmj6qi6hw37"))))
3278 (build-system trivial-build-system)
3279 (arguments
3280 `(#:modules ((guix build utils))
3281 #:builder
3282 (begin
3283 (use-modules (guix build utils))
3284 (let ((target (string-append (assoc-ref %outputs "out")
3285 "/share/texmf-dist/tex/latex/ucs")))
3286 (mkdir-p target)
3287 (copy-recursively (assoc-ref %build-inputs "source") target)
3288 #t))))
3289 (home-page "http://www.ctan.org/pkg/ucs")
3290 (synopsis "Extended UTF-8 input encoding support for LaTeX")
3291 (description
3292 "The bundle provides the @code{ucs} package, and @code{utf8x.def},
3293 together with a large number of support files. The @code{utf8x.def}
3294 definition file for use with @code{inputenc} covers a wider range of Unicode
3295 characters than does @code{utf8.def} in the LaTeX distribution. The package
3296 provides facilities for efficient use of its large sets of Unicode characters.
3297 Glyph production may be controlled by various options, which permits use of
3298 non-ASCII characters when coding mathematical formulae. Note that the bundle
3299 previously had an alias “unicode”; that alias has now been withdrawn, and no
3300 package of that name now exists.")
3301 (license license:lppl1.3+)))
3302
3303 (define-public texlive-latex-preview
3304 (package
3305 (name "texlive-latex-preview")
3306 (version (number->string %texlive-revision))
3307 (source (origin
3308 (method svn-fetch)
3309 (uri (texlive-ref "latex" "preview"))
3310 (file-name (string-append name "-" version "-checkout"))
3311 (sha256
3312 (base32
3313 "0j6fff6q0ca96nwfdgay2jm55792z4q9aa0rczmiw2qccyg5n2dv"))))
3314 (build-system texlive-build-system)
3315 (arguments
3316 '(#:tex-directory "latex/preview"
3317 #:phases
3318 (modify-phases %standard-phases
3319 (add-after 'unpack 'remove-generated-file
3320 (lambda _
3321 (delete-file "preview.drv")
3322 #t)))))
3323 (home-page "http://www.ctan.org/pkg/preview")
3324 (synopsis "Extract bits of a LaTeX source for output")
3325 (description
3326 "The main purpose of the preview package is the extraction of selected
3327 elements from a LaTeX source, like formulas or graphics, into separate
3328 pages of a DVI file. A flexible and convenient interface allows it to
3329 specify what commands and constructs should be extracted. This works
3330 with DVI files postprocessed by either Dvips and Ghostscript or
3331 dvipng, but it also works when you are using PDFTeX for generating PDF
3332 files.")
3333 (license license:gpl3+)))
3334
3335 (define-public texlive-latex-acronym
3336 (package
3337 (name "texlive-latex-acronym")
3338 (version (number->string %texlive-revision))
3339 (source (origin
3340 (method svn-fetch)
3341 (uri (texlive-ref "latex" "acronym"))
3342 (file-name (string-append name "-" version "-checkout"))
3343 (sha256
3344 (base32
3345 "0jmasg40bk53zdd2jc8nc18jvdai3p2wmamy7hwli8gls4nf25qp"))))
3346 (build-system texlive-build-system)
3347 (arguments '(#:tex-directory "latex/acronym"))
3348 (home-page "http://www.ctan.org/pkg/acronym")
3349 (synopsis "Expand acronyms at least once")
3350 (description
3351 "This package ensures that all acronyms used in the text are spelled out
3352 in full at least once. It also provides an environment to build a list of
3353 acronyms used. The package is compatible with PDF bookmarks. The package
3354 requires the suffix package, which in turn requires that it runs under
3355 e-TeX.")
3356 (license license:lppl1.3+)))
3357
3358 (define-public texlive-generic-pdftex
3359 (package
3360 (name "texlive-generic-pdftex")
3361 (version (number->string %texlive-revision))
3362 (source (origin
3363 (method svn-fetch)
3364 (uri (svn-reference
3365 (url (string-append "svn://www.tug.org/texlive/tags/"
3366 %texlive-tag "/Master/texmf-dist/"
3367 "/tex/generic/pdftex"))
3368 (revision %texlive-revision)))
3369 (sha256
3370 (base32
3371 "0k68zmqzs4qvrqxdwsrawbjb14hxqjfamq649azvai0jjxdpkljd"))))
3372 (build-system trivial-build-system)
3373 (arguments
3374 `(#:modules ((guix build utils))
3375 #:builder
3376 (begin
3377 (use-modules (guix build utils))
3378 (let ((target (string-append (assoc-ref %outputs "out")
3379 "/share/texmf-dist/tex/generic/pdftex")))
3380 (mkdir-p target)
3381 (copy-recursively (assoc-ref %build-inputs "source") target)
3382 #t))))
3383 (home-page "http://www.ctan.org/pkg/pdftex")
3384 (synopsis "TeX extension for direct creation of PDF")
3385 (description
3386 "This package provides an extension of TeX which can be configured to
3387 directly generate PDF documents instead of DVI.")
3388 (license license:gpl2+)))
3389
3390 (define texlive-texmf
3391 (package
3392 (name "texlive-texmf")
3393 (version "2016")
3394 (source texlive-texmf-src)
3395 (build-system gnu-build-system)
3396 (inputs
3397 `(("texlive-bin" ,texlive-bin)
3398 ("lua" ,lua)
3399 ("perl" ,perl)
3400 ("python" ,python-2) ; incompatible with Python 3 (print syntax)
3401 ("ruby" ,ruby)
3402 ("tcsh" ,tcsh)))
3403 (arguments
3404 `(#:modules ((guix build gnu-build-system)
3405 (guix build utils)
3406 (srfi srfi-26))
3407
3408 ;; This package takes 4 GiB, which we can't afford to distribute from
3409 ;; our servers.
3410 #:substitutable? #f
3411
3412 #:phases
3413 (modify-phases (map (cut assq <> %standard-phases)
3414 '(set-paths unpack patch-source-shebangs))
3415 (add-after 'patch-source-shebangs 'install
3416 (lambda* (#:key outputs #:allow-other-keys)
3417 (let ((share (string-append (assoc-ref outputs "out") "/share")))
3418 (mkdir-p share)
3419 (system* "mv" "texmf-dist" share))))
3420 (add-after 'install 'texmf-config
3421 (lambda* (#:key inputs outputs #:allow-other-keys)
3422 (let* ((out (assoc-ref outputs "out"))
3423 (share (string-append out "/share"))
3424 (texmfroot (string-append share "/texmf-dist/web2c"))
3425 (texmfcnf (string-append texmfroot "/texmf.cnf"))
3426 (texlive-bin (assoc-ref inputs "texlive-bin"))
3427 (texbin (string-append texlive-bin "/bin"))
3428 (tlpkg (string-append texlive-bin "/share/tlpkg")))
3429 ;; Register SHARE as TEXMFROOT in texmf.cnf.
3430 (substitute* texmfcnf
3431 (("TEXMFROOT = \\$SELFAUTOPARENT")
3432 (string-append "TEXMFROOT = " share))
3433 (("TEXMFLOCAL = \\$SELFAUTOGRANDPARENT/texmf-local")
3434 "TEXMFLOCAL = $SELFAUTODIR/share/texmf-local")
3435 (("!!\\$TEXMFLOCAL") "$TEXMFLOCAL"))
3436 ;; Register paths in texmfcnf.lua, needed for context.
3437 (substitute* (string-append texmfroot "/texmfcnf.lua")
3438 (("selfautodir:") out)
3439 (("selfautoparent:") (string-append share "/")))
3440 ;; Set path to TeXLive Perl modules
3441 (setenv "PERL5LIB"
3442 (string-append (getenv "PERL5LIB") ":" tlpkg))
3443 ;; Configure the texmf-dist tree; inspired from
3444 ;; http://slackbuilds.org/repository/13.37/office/texlive/
3445 (setenv "PATH" (string-append (getenv "PATH") ":" texbin))
3446 (setenv "TEXMFCNF" texmfroot)
3447 (system* "updmap-sys" "--nohash" "--syncwithtrees")
3448 (system* "mktexlsr")
3449 (system* "fmtutil-sys" "--all")))))))
3450 (properties `((max-silent-time . 9600))) ; don't time out while grafting
3451 (synopsis "TeX Live, a package of the TeX typesetting system")
3452 (description
3453 "TeX Live provides a comprehensive TeX document production system.
3454 It includes all the major TeX-related programs, macro packages, and fonts
3455 that are free software, including support for many languages around the
3456 world.
3457
3458 This package contains the complete tree of texmf-dist data.")
3459 (license (license:fsf-free "https://www.tug.org/texlive/copying.html"))
3460 (home-page "https://www.tug.org/texlive/")))
3461
3462 (define-public texlive
3463 (package
3464 (name "texlive")
3465 (version "2016")
3466 (source #f)
3467 (build-system trivial-build-system)
3468 (inputs `(("bash" ,bash) ; for wrap-program
3469 ("texlive-bin" ,texlive-bin)
3470 ("texlive-texmf" ,texlive-texmf)))
3471 (native-search-paths
3472 (list (search-path-specification
3473 (variable "TEXMFLOCAL")
3474 (files '("share/texmf-local")))))
3475 (arguments
3476 `(#:modules ((guix build utils))
3477 #:builder
3478 ;; Build the union of texlive-bin and texlive-texmf, but take the
3479 ;; conflicting subdirectory share/texmf-dist from texlive-texmf.
3480 (begin
3481 (use-modules (guix build utils))
3482 (let ((out (assoc-ref %outputs "out"))
3483 (bin (assoc-ref %build-inputs "texlive-bin"))
3484 (texmf (assoc-ref %build-inputs "texlive-texmf"))
3485 (bash (assoc-ref %build-inputs "bash")))
3486 (mkdir out)
3487 (with-directory-excursion out
3488 (for-each
3489 (lambda (name)
3490 (symlink (string-append bin "/" name) name))
3491 '("include" "lib"))
3492 (mkdir "bin")
3493 (with-directory-excursion "bin"
3494 (setenv "PATH" (string-append bash "/bin"))
3495 (for-each
3496 (lambda (name)
3497 (symlink name (basename name))
3498 (wrap-program
3499 (basename name)
3500 `("TEXMFCNF" =
3501 (,(string-append texmf "/share/texmf-dist/web2c")))))
3502 (find-files (string-append bin "/bin/") "")))
3503 (mkdir "share")
3504 (with-directory-excursion "share"
3505 (for-each
3506 (lambda (name)
3507 (symlink (string-append bin "/share/" name) name))
3508 '("info" "man" "tlpkg"))
3509 (for-each
3510 (lambda (name)
3511 (symlink (string-append texmf "/share/" name) name))
3512 '("texmf-dist" "texmf-var"))))))))
3513 (synopsis "TeX Live, a package of the TeX typesetting system")
3514 (description
3515 "TeX Live provides a comprehensive TeX document production system.
3516 It includes all the major TeX-related programs, macro packages, and fonts
3517 that are free software, including support for many languages around the
3518 world.
3519
3520 This package contains the complete TeX Live distribution.")
3521 (license (license:fsf-free "https://www.tug.org/texlive/copying.html"))
3522 (home-page "https://www.tug.org/texlive/")))
3523
3524
3525 ;; texlive-texmf-minimal is a pruned, small version of the texlive tree,
3526 ;; in particular dropping documentation and fonts. It weighs in at 470 MiB
3527 ;; instead of 4 GiB.
3528 (define texlive-texmf-minimal
3529 (package (inherit texlive-texmf)
3530 (name "texlive-texmf-minimal")
3531 (arguments
3532 (substitute-keyword-arguments
3533 (package-arguments texlive-texmf)
3534 ((#:modules modules)
3535 `((ice-9 ftw)
3536 (srfi srfi-1)
3537 ,@modules))
3538 ((#:phases phases)
3539 `(modify-phases ,phases
3540 (add-after 'unpack 'prune
3541 (lambda _
3542 (define (delete subdir exclude)
3543 "Delete all files and directories in SUBDIR except for those
3544 given in the list EXCLUDE."
3545 (with-directory-excursion subdir
3546 (for-each delete-file-recursively
3547 (lset-difference equal?
3548 (scandir ".")
3549 (append '("." "..")
3550 exclude)))))
3551 (with-directory-excursion "texmf-dist"
3552 (for-each delete-file-recursively
3553 '("doc" "source" "tex4ht"))
3554 ;; Delete all subdirectories of "fonts", except for "tfm" and
3555 ;; any directories named "cm".
3556 (delete "fonts" '("afm" "map" "pk" "source" "tfm" "type1"))
3557 (delete "fonts/afm" '("public"))
3558 (delete "fonts/afm/public" '("amsfonts"))
3559 (delete "fonts/afm/public/amsfonts" '("cm"))
3560 (delete "fonts/map" '("dvips"))
3561 (delete "fonts/map/dvips" '("cm"))
3562 (delete "fonts/source" '("public"))
3563 (delete "fonts/source/public" '("cm"))
3564 (delete "fonts/tfm" '("public"))
3565 (delete "fonts/type1" '("public"))
3566 (delete "fonts/type1/public" '("amsfonts"))
3567 (delete "fonts/type1/public/amsfonts" '("cm")))
3568 #t))))))
3569 (description
3570 "TeX Live provides a comprehensive TeX document production system.
3571 It includes all the major TeX-related programs, macro packages, and fonts
3572 that are free software, including support for many languages around the
3573 world.
3574
3575 This package contains a small subset of the texmf-dist data.")))
3576
3577
3578 ;; texlive-minimal is the same as texlive, but using texlive-texmf-minimal
3579 ;; instead of the full texlive-texmf. It can be used, for instance, as a
3580 ;; native input to packages that need texlive to build their documentation.
3581 (define-public texlive-minimal
3582 (package (inherit texlive)
3583 (name "texlive-minimal")
3584 (inputs
3585 `(("texlive-texmf" ,texlive-texmf-minimal)
3586 ,@(alist-delete "texlive-texmf" (package-inputs texlive))))
3587 (native-search-paths
3588 (list (search-path-specification
3589 (variable "TEXMFLOCAL")
3590 (files '("share/texmf-local")))))
3591 (description
3592 "TeX Live provides a comprehensive TeX document production system.
3593 It includes all the major TeX-related programs, macro packages, and fonts
3594 that are free software, including support for many languages around the
3595 world.
3596
3597 This package contains a small working part of the TeX Live distribution.")))
3598
3599 (define-public perl-text-bibtex
3600 (package
3601 (name "perl-text-bibtex")
3602 (version "0.77")
3603 (source
3604 (origin
3605 (method url-fetch)
3606 (uri (string-append "mirror://cpan/authors/id/A/AM/AMBS/Text-BibTeX-"
3607 version ".tar.gz"))
3608 (sha256
3609 (base32
3610 "0kkfx8skk763pivz6h2ffy2zdp1lvy6d5sz0kjaj0mdbjffvnnb4"))))
3611 (build-system perl-build-system)
3612 (arguments
3613 `(#:phases
3614 (modify-phases %standard-phases
3615 (add-after 'unpack 'add-output-directory-to-rpath
3616 (lambda* (#:key outputs #:allow-other-keys)
3617 (substitute* "inc/MyBuilder.pm"
3618 (("-Lbtparse" line)
3619 (string-append "-Wl,-rpath="
3620 (assoc-ref outputs "out") "/lib " line)))
3621 #t))
3622 (add-after 'unpack 'install-libraries-to-/lib
3623 (lambda* (#:key outputs #:allow-other-keys)
3624 (substitute* "Build.PL"
3625 (("lib64") "lib"))
3626 #t)))))
3627 (native-inputs
3628 `(("perl-capture-tiny" ,perl-capture-tiny)
3629 ("perl-config-autoconf" ,perl-config-autoconf)
3630 ("perl-extutils-libbuilder" ,perl-extutils-libbuilder)
3631 ("perl-module-build" ,perl-module-build)))
3632 (home-page "http://search.cpan.org/dist/Text-BibTeX")
3633 (synopsis "Interface to read and parse BibTeX files")
3634 (description "@code{Text::BibTeX} is a Perl library for reading, parsing,
3635 and processing BibTeX files. @code{Text::BibTeX} gives you access to the data
3636 at many different levels: you may work with BibTeX entries as simple field to
3637 string mappings, or get at the original form of the data as a list of simple
3638 values (strings, macros, or numbers) pasted together.")
3639 (license license:perl-license)))
3640
3641 (define-public biber
3642 (package
3643 (name "biber-next")
3644 (version "2.6")
3645 (source (origin
3646 (method url-fetch)
3647 (uri (string-append "https://github.com/plk/biber/archive/v"
3648 version ".tar.gz"))
3649 (file-name (string-append name "-" version ".tar.gz"))
3650 (sha256
3651 (base32
3652 "158smzgjhjvyabdv97si5q88zjj5l8j1zbfnddvzy6fkpfhskgkp"))))
3653 (build-system perl-build-system)
3654 (arguments
3655 `(#:phases
3656 (modify-phases %standard-phases
3657 (add-after 'install 'wrap-programs
3658 (lambda* (#:key outputs #:allow-other-keys)
3659 (let* ((out (assoc-ref outputs "out"))
3660 (perl5lib (getenv "PERL5LIB")))
3661 (wrap-program (string-append out "/bin/biber")
3662 `("PERL5LIB" ":" prefix
3663 (,(string-append perl5lib ":" out
3664 "/lib/perl5/site_perl")))))
3665 #t)))))
3666 (inputs
3667 `(("perl-autovivification" ,perl-autovivification)
3668 ("perl-class-accessor" ,perl-class-accessor)
3669 ("perl-data-dump" ,perl-data-dump)
3670 ("perl-data-compare" ,perl-data-compare)
3671 ("perl-data-uniqid" ,perl-data-uniqid)
3672 ("perl-datetime-format-builder" ,perl-datetime-format-builder)
3673 ("perl-datetime-calendar-julian" ,perl-datetime-calendar-julian)
3674 ("perl-file-slurp" ,perl-file-slurp)
3675 ("perl-ipc-cmd" ,perl-ipc-cmd)
3676 ("perl-ipc-run3" ,perl-ipc-run3)
3677 ("perl-list-allutils" ,perl-list-allutils)
3678 ("perl-list-moreutils" ,perl-list-moreutils)
3679 ("perl-mozilla-ca" ,perl-mozilla-ca)
3680 ("perl-regexp-common" ,perl-regexp-common)
3681 ("perl-log-log4perl" ,perl-log-log4perl)
3682 ;; We cannot use perl-unicode-collate here, because otherwise the
3683 ;; hardcoded hashes in the tests would differ. See
3684 ;; https://mail-archive.com/debian-bugs-dist@lists.debian.org/msg1469249.html
3685 ;;("perl-unicode-collate" ,perl-unicode-collate)
3686 ("perl-unicode-normalize" ,perl-unicode-normalize)
3687 ("perl-unicode-linebreak" ,perl-unicode-linebreak)
3688 ("perl-encode-eucjpascii" ,perl-encode-eucjpascii)
3689 ("perl-encode-jis2k" ,perl-encode-jis2k)
3690 ("perl-encode-hanextra" ,perl-encode-hanextra)
3691 ("perl-xml-libxml" ,perl-xml-libxml)
3692 ("perl-xml-libxml-simple" ,perl-xml-libxml-simple)
3693 ("perl-xml-libxslt" ,perl-xml-libxslt)
3694 ("perl-xml-writer" ,perl-xml-writer)
3695 ("perl-sort-key" ,perl-sort-key)
3696 ("perl-text-csv" ,perl-text-csv)
3697 ("perl-text-csv-xs" ,perl-text-csv-xs)
3698 ("perl-text-roman" ,perl-text-roman)
3699 ("perl-uri" ,perl-uri)
3700 ("perl-text-bibtex" ,perl-text-bibtex)
3701 ("perl-libwww" ,perl-libwww)
3702 ("perl-lwp-protocol-https" ,perl-lwp-protocol-https)
3703 ("perl-business-isbn" ,perl-business-isbn)
3704 ("perl-business-issn" ,perl-business-issn)
3705 ("perl-business-ismn" ,perl-business-ismn)
3706 ("perl-lingua-translit" ,perl-lingua-translit)))
3707 (native-inputs
3708 `(("perl-config-autoconf" ,perl-config-autoconf)
3709 ("perl-extutils-libbuilder" ,perl-extutils-libbuilder)
3710 ("perl-module-build" ,perl-module-build)
3711 ;; for tests
3712 ("perl-file-which" ,perl-file-which)
3713 ("perl-test-more" ,perl-test-most) ; FIXME: "more" would be sufficient
3714 ("perl-test-differences" ,perl-test-differences)))
3715 (home-page "http://biblatex-biber.sourceforge.net/")
3716 (synopsis "Backend for the BibLaTeX citation management tool")
3717 (description "Biber is a BibTeX replacement for users of biblatex. Among
3718 other things it comes with full Unicode support.")
3719 (license license:artistic2.0)))
3720
3721 ;; Our version of texlive comes with biblatex 3.4, which is only compatible
3722 ;; with biber 2.5 according to the compatibility matrix in the biber
3723 ;; documentation.
3724 (define-public biber-2.5
3725 (package (inherit biber)
3726 (name "biber")
3727 (version "2.5")
3728 (source (origin
3729 (method url-fetch)
3730 (uri (string-append "https://github.com/plk/biber/archive/v"
3731 version ".tar.gz"))
3732 (file-name (string-append name "-" version ".tar.gz"))
3733 (sha256
3734 (base32
3735 "163sd343wkrzwnvj2003m2j0kz517jmjr4savw6f8bjxhj8fdrqv"))))
3736 (arguments
3737 (substitute-keyword-arguments (package-arguments biber)
3738 ((#:phases phases)
3739 `(modify-phases ,phases
3740 (add-before 'check 'delete-failing-test
3741 (lambda _
3742 (delete-file "t/sort-order.t")
3743 #t))))))
3744 (inputs
3745 `(("perl-date-simple" ,perl-date-simple)
3746 ,@(package-inputs biber)))))
3747
3748 (define-public rubber
3749 (package
3750 (name "rubber")
3751 (version "1.1")
3752 (source (origin
3753 (method url-fetch)
3754 (uri (list (string-append "https://launchpad.net/rubber/trunk/"
3755 version "/+download/rubber-"
3756 version ".tar.gz")
3757 (string-append "http://ebeffara.free.fr/pub/rubber-"
3758 version ".tar.gz")))
3759 (sha256
3760 (base32
3761 "1xbkv8ll889933gyi2a5hj7hhh216k04gn8fwz5lfv5iz8s34gbq"))))
3762 (build-system gnu-build-system)
3763 (arguments '(#:tests? #f)) ; no `check' target
3764 (inputs `(("texinfo" ,texinfo)
3765 ("python" ,python-2) ; incompatible with Python 3 (print syntax)
3766 ("which" ,which)))
3767 (home-page "https://launchpad.net/rubber")
3768 (synopsis "Wrapper for LaTeX and friends")
3769 (description
3770 "Rubber is a program whose purpose is to handle all tasks related to the
3771 compilation of LaTeX documents. This includes compiling the document itself,
3772 of course, enough times so that all references are defined, and running BibTeX
3773 to manage bibliographic references. Automatic execution of dvips to produce
3774 PostScript documents is also included, as well as usage of pdfLaTeX to produce
3775 PDF documents.")
3776 (license license:gpl2+)))
3777
3778 (define-public texmaker
3779 (package
3780 (name "texmaker")
3781 (version "4.5")
3782 (source (origin
3783 (method url-fetch)
3784 (uri (string-append "http://www.xm1math.net/texmaker/texmaker-"
3785 version ".tar.bz2"))
3786 (sha256
3787 (base32
3788 "056njk6j8wma23mlp7xa3rgfaxx0q8ynwx8wkmj7iy0b85p9ds9c"))))
3789 (build-system gnu-build-system)
3790 (arguments
3791 `(#:phases
3792 (modify-phases %standard-phases
3793 ;; Qt has its own configuration utility.
3794 (replace 'configure
3795 (lambda* (#:key outputs #:allow-other-keys)
3796 (let ((out (assoc-ref outputs "out")))
3797 (zero? (system* "qmake"
3798 (string-append "PREFIX=" out)
3799 (string-append "DESKTOPDIR=" out
3800 "/share/applications")
3801 (string-append "ICONDIR=" out "/share/pixmaps")
3802 "texmaker.pro"))))))))
3803 (inputs
3804 `(("poppler-qt5" ,poppler-qt5)
3805 ("qtbase" ,qtbase)
3806 ("qtscript" ,qtscript)
3807 ("qtwebkit" ,qtwebkit)
3808 ("zlib" ,zlib)))
3809 (native-inputs
3810 `(("pkg-config" ,pkg-config)))
3811 (home-page "http://www.xm1math.net/texmaker/")
3812 (synopsis "LaTeX editor")
3813 (description "Texmaker is a program that integrates many tools needed to
3814 develop documents with LaTeX, in a single application.")
3815 (license license:gpl2+)))
3816
3817
3818 (define-public teximpatient
3819 (package
3820 (name "teximpatient")
3821 (version "2.4")
3822 (source (origin
3823 (method url-fetch)
3824 (uri (string-append "mirror://gnu/" name "/" name "-"
3825 version ".tar.gz"))
3826 (sha256
3827 (base32
3828 "0h56w22d99dh4fgld4ssik8ggnmhmrrbnrn1lnxi1zr0miphn1sd"))))
3829 (build-system gnu-build-system)
3830 (arguments
3831 `(#:phases
3832 (modify-phases %standard-phases
3833 (delete 'check)
3834 ;; Unfortunately some mistakes have been made in packaging.
3835 ;; Work around them here ...
3836 (replace 'unpack
3837 (lambda* (#:key inputs outputs #:allow-other-keys)
3838 (let ((srcdir "teximpatient-2.4"))
3839 (system* "tar" "-xzf" (assoc-ref inputs "source")
3840 (string-append "--one-top-level=" srcdir))
3841 (delete-file (string-append srcdir "/book.pdf"))
3842 (install-file (car
3843 (find-files
3844 (assoc-ref inputs "automake")
3845 "^install-sh$"))
3846 srcdir)
3847 (chdir srcdir)))))))
3848 (native-inputs
3849 `(("texlive" ,texlive)
3850 ("automake" ,automake)))
3851 (home-page "https://www.gnu.org/software/teximpatient/")
3852 (synopsis "Book on TeX, plain TeX and Eplain")
3853 (description "@i{TeX for the Impatient} is a ~350 page book on TeX,
3854 plain TeX, and Eplain, originally written by Paul Abrahams, Kathryn Hargreaves,
3855 and Karl Berry.")
3856 (license license:fdl1.3+)))