1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2014, 2017 Mark H Weaver <mhw@netris.org>
4 ;;; Copyright © 2014 Joshua Grant <tadni@riseup.net>
5 ;;; Copyright © 2014 Alex Kost <alezost@gmail.com>
6 ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
7 ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
8 ;;; Copyright © 2015, 2017 Ricardo Wurmus <rekado@elephly.net>
9 ;;; Copyright © 2015, 2016 Leo Famulari <leo@famulari.name>
10 ;;; Copyright © 2016, 2017 ng0 <ng0@infotropique.org>
11 ;;; Copyright © 2016 Jookia <166291@gmail.com>
12 ;;; Copyright © 2016 Eric Bavier <bavier@member.fsf.org>
13 ;;; Copyright © 2016 Dmitry Nikolaev <cameltheman@gmail.com>
14 ;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
15 ;;; Copyright © 2016 Marius Bakke <mbakke@fastmail.com>
16 ;;; Copyright © 2016 Toni Reina <areina@riseup.net>
17 ;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr>
18 ;;; Copyright © 2017 José Miguel Sánchez García <jmi2k@openmailbox.com>
19 ;;; Copyright © 2017 Alex Griffin <a@ajgrf.com>
20 ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
21 ;;; Copyright © 2017 Brendan Tildesley <brendan.tildesley@openmailbox.org>
22 ;;; Copyright © 2017 Arun Isaac <arunisaac@systemreboot.net>
23 ;;; Copyright © 2017 Mohammed Sadiq <sadiq@sadiqpk.org>
25 ;;; This file is part of GNU Guix.
27 ;;; GNU Guix is free software; you can redistribute it and/or modify it
28 ;;; under the terms of the GNU General Public License as published by
29 ;;; the Free Software Foundation; either version 3 of the License, or (at
30 ;;; your option) any later version.
32 ;;; GNU Guix is distributed in the hope that it will be useful, but
33 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
34 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
35 ;;; GNU General Public License for more details.
37 ;;; You should have received a copy of the GNU General Public License
38 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
40 (define-module (gnu packages fonts)
41 #:use-module (ice-9 regex)
42 #:use-module (guix utils)
43 #:use-module ((guix licenses) #:prefix license:)
44 #:use-module (guix packages)
45 #:use-module (guix download)
46 #:use-module (guix git-download)
47 #:use-module (guix build-system font)
48 #:use-module (guix build-system gnu)
49 #:use-module (guix build-system trivial)
50 #:use-module (gnu packages base)
51 #:use-module (gnu packages compression)
52 #:use-module (gnu packages fontutils)
53 #:use-module (gnu packages perl)
54 #:use-module (gnu packages pkg-config)
55 #:use-module (gnu packages python)
56 #:use-module (gnu packages xorg))
58 (define-public font-inconsolata
60 (name "font-inconsolata")
64 (uri "http://www.levien.com/type/myfonts/Inconsolata.otf")
67 "06js6znbcf7swn8y3b8ki416bz96ay7d3yvddqnvi88lqhbfcq8m"))))
68 (build-system font-build-system)
69 (home-page "http://levien.com/type/myfonts/inconsolata.html")
70 (synopsis "Monospace font")
71 (description "A monospace font, designed for code listings and the like,
72 in print. With attention to detail for high resolution rendering.")
73 (license license:silofl1.1)))
75 (define-public font-ubuntu
82 "http://font.ubuntu.com/download/ubuntu-font-family-"
86 "0hjvq2x758dx0sfwqhzflns0ns035qm7h6ygskbx1svzg517sva5"))))
87 (build-system font-build-system)
88 (home-page "http://font.ubuntu.com/")
89 (synopsis "The Ubuntu Font Family")
90 (description "The Ubuntu Font Family is a unique, custom designed font
91 that has a very distinctive look and feel. This package provides the
92 TrueType (TTF) files.")
95 "http://font.ubuntu.com/ufl/ubuntu-font-licence-1.0.txt"
96 "Ubuntu Font License v1.0"))))
98 (define-public font-dejavu
104 (uri (string-append "mirror://sourceforge/dejavu/dejavu/"
105 version "/dejavu-fonts-ttf-"
109 "1mqpds24wfs5cmfhj57fsfs07mji2z8812i5c4pi5pbi738s977s"))))
110 (build-system font-build-system)
113 (modify-phases %standard-phases
114 (add-after 'install 'install-conf
115 (lambda* (#:key outputs #:allow-other-keys)
116 (let ((conf-dir (string-append (assoc-ref outputs "out")
117 "/share/fontconfig/conf.avail")))
118 (copy-recursively "fontconfig" conf-dir)))))))
119 (home-page "http://dejavu-fonts.org/")
120 (synopsis "Vera font family derivate with additional characters")
121 (description "DejaVu provides an expanded version of the Vera font family
122 aiming for quality and broader Unicode coverage while retaining the original
123 Vera style. DejaVu currently works towards conformance to the Multilingual
124 European Standards (MES-1 and MES-2) for Unicode coverage. The DejaVu fonts
125 provide serif, sans and monospaced variants.")
128 "http://dejavu-fonts.org/"))))
130 (define-public font-bitstream-vera
132 (name "font-bitstream-vera")
136 (uri (string-append "mirror://gnome/sources/ttf-bitstream-vera/"
137 version "/ttf-bitstream-vera-"
141 "1p3qs51x5327gnk71yq8cvmxc6wgx79sqxfvxcv80cdvgggjfnyv"))))
142 (build-system font-build-system)
143 (home-page "https://www.gnome.org/fonts/")
144 (synopsis "Bitstream Vera sans-serif typeface")
145 (description "Vera is a sans-serif typeface from Bitstream, Inc. This
146 package provides the TrueType (TTF) files.")
148 (license:fsdg-compatible
149 "https://www.gnome.org/fonts/#Final_Bitstream_Vera_Fonts"
150 "The Font Software may be sold as part of a larger software package but
151 no copy of one or more of the Font Software typefaces may be sold by
154 (define-public font-cantarell
156 (name "font-abattis-cantarell")
160 (uri (string-append "mirror://gnome/sources/cantarell-fonts/"
161 (version-major+minor version)
162 "/cantarell-fonts-" version ".tar.xz"))
165 "0zvkd8cm1cg2919v1js9qmzwa02sjl7qajj3gcvgqvai1fm2i8hl"))))
166 (build-system gnu-build-system)
167 (home-page "https://wiki.gnome.org/Projects/CantarellFonts")
168 (synopsis "Cantarell sans-serif typeface")
169 (description "The Cantarell font family is a contemporary Humanist
170 sans-serif designed for on-screen reading. It is used by GNOME@tie{}3.")
171 (license license:silofl1.1)))
173 (define-public font-lato
179 (uri (string-append "http://www.latofonts.com/download/Lato2OFL.zip"))
182 "1f5540g0ja1nx3ddd3ywn77xc81ssrxpq8n3gyb9sabyq2b4xda2"))))
183 (build-system trivial-build-system)
185 `(#:modules ((guix build utils))
187 (use-modules (guix build utils)
190 (let ((PATH (string-append (assoc-ref %build-inputs
193 (font-dir (string-append %output
194 "/share/fonts/truetype")))
196 (system* "unzip" (assoc-ref %build-inputs "source"))
199 (for-each (lambda (ttf)
200 (install-file ttf font-dir))
201 (find-files "." "\\.ttf$"))))))
203 (native-inputs `(("unzip" ,unzip)))
204 (home-page "http://www.latofonts.com/lato-free-fonts/")
205 (synopsis "Lato sans-serif typeface")
207 "Lato is a sanserif typeface family. It covers over 3000 glyphs per style.
208 The Lato 2.010 family supports more than 100 Latin-based languages, over
209 50 Cyrillic-based languages as well as Greek and IPA phonetics.")
210 (license license:silofl1.1)))
212 (define-public font-gnu-freefont-ttf
214 (name "font-gnu-freefont-ttf")
218 (uri (string-append "mirror://gnu/freefont/freefont-src-"
222 "0yk58blhcd4hm7nyincmqq4jrzjjk82wif2zmk1l3y2m4vif4qhd"))))
223 (build-system gnu-build-system)
225 `(#:phases (modify-phases %standard-phases
229 (let ((doc-dir (string-append %output "/share/doc/"
231 (font-dir (string-append %output
232 "/share/fonts/truetype")))
234 (substitute* "Makefile"
235 (("\\$\\(TMPDIR\\)") doc-dir)
236 (("sfd/\\*.ttf") ""))
237 (system* "make" "ttftar")
239 (for-each (lambda (file)
240 (install-file file font-dir))
242 (lambda (file) (string-suffix? "ttf" file))
243 (find-files "." "")))))))
244 #:test-target "tests"))
245 ;; replace python 3 with python 2
246 ;; python 3 support commits aren't yet released in 20120503
247 ;; so freefont needs python 2 support in fontforge
248 (native-inputs `(("fontforge" ,(package (inherit fontforge)
249 (inputs `(("python-2" ,python-2)
250 ,@(package-inputs fontforge)))))))
251 (home-page "https://www.gnu.org/software/freefont/")
252 (synopsis "Unicode-encoded outline fonts")
254 "The GNU Freefont project aims to provide a set of free outline
255 (PostScript Type0, TrueType, OpenType...) fonts covering the ISO
256 10646/Unicode UCS (Universal Character Set).")
257 (license license:gpl3+)
258 (properties '((upstream-name . "freefont")
259 (ftp-directory . "/gnu/freefont")))))
261 (define-public font-liberation
263 (name "font-liberation")
267 (uri (string-append "https://releases.pagure.org/"
268 "liberation-fonts/liberation-fonts-ttf-"
272 "010m4zfqan4w04b6bs9pm3gapn9hsb18bmwwgp2p6y6idj52g43q"))))
273 (build-system font-build-system)
274 (home-page "https://pagure.io/liberation-fonts/")
276 "Fonts compatible with Arial, Times New Roman, and Courier New")
278 "The Liberation font family aims at metric compatibility with
279 Arial, Times New Roman, and Courier New.
280 There are three sets:
283 @item Sans (a substitute for Arial, Albany, Helvetica, Nimbus Sans L, and
284 Bitstream Vera Sans);
285 @item Serif (a substitute for Times New Roman, Thorndale, Nimbus Roman, and
286 Bitstream Vera Serif);
287 @item Mono (a substitute for Courier New, Cumberland, Courier, Nimbus Mono L,
288 and Bitstream Vera Sans Mono).
291 The Liberation Fonts are sponsored by Red Hat.")
292 (license license:silofl1.1)))
294 (define-public font-linuxlibertine
296 (name "font-linuxlibertine")
299 (method url-fetch/tarbomb)
300 (uri (string-append "mirror://sourceforge/linuxlibertine/"
301 "linuxlibertine/" version
302 "/LinLibertineSRC_" version "_2012_07_02.tgz"))
305 "0x7cz6hvhpil1rh03rax9zsfzm54bh7r4bbrq8rz673gl9h47v0v"))))
306 (build-system gnu-build-system)
308 `(#:tests? #f ; there are no tests
309 #:modules ((guix build utils)
310 (guix build gnu-build-system)
314 (modify-phases %standard-phases
321 "fontforge" "-lang=ff"
322 "-c" (string-append "Open('" name "');"
324 (basename name "sfd") ext
326 (every (lambda (name)
327 (and (compile name "ttf")
328 (compile name "otf")))
329 (find-files "." "\\.sfd$")))))
331 (lambda* (#:key outputs #:allow-other-keys)
332 (let ((font-dir (string-append (assoc-ref outputs "out")
333 "/share/fonts/truetype")))
335 (for-each (cut install-file <> font-dir)
336 (find-files "." "\\.(otf|ttf)$"))
339 `(("fontforge" ,fontforge)))
340 (home-page "http://www.linuxlibertine.org/")
341 (synopsis "Serif and sans serif typefaces")
342 (description "The Linux Libertine fonts is a set of typefaces containing
343 both a Serif version (\"Linux Libertine\") and a Sans Serif (\"Linux
344 Biolinum\") designed to be used together as an alternative for Times/Times New
345 Roman and Helvetica/Arial. The Serif typeface comes in two shapes and two
346 weights, and with a Small Capitals version of the regular typeface. Linux
347 Biolinum is available in both Regular and Bold weights.")
348 ;; The fonts are released under either of these licenses.
349 (license (list license:gpl2+ license:silofl1.1))))
351 (define-public font-terminus
353 (name "font-terminus")
359 "mirror://sourceforge/terminus-font/terminus-font-"
366 "0487cyx5h1f0crbny5sg73a22gmym5vk1i7646gy7hgiscj2rxb4"))))
367 (build-system gnu-build-system)
369 `(("pkg-config" ,pkg-config)
371 ("bdftopcf" ,bdftopcf)
372 ("font-util" ,font-util)
373 ("mkfontdir" ,mkfontdir)))
375 `(#:configure-flags (list
376 ;; install fonts into subdirectory of package output
377 ;; instead of font-util-?.?.?/share/fonts/X11
378 (string-append "--with-fontrootdir="
379 %output "/share/fonts/X11"))
380 #:tests? #f)) ;; No test target in tarball
381 (home-page "http://terminus-font.sourceforge.net/")
382 (synopsis "Simple bitmap programming font")
383 (description "Terminus Font is a clean, fixed-width bitmap font, designed
384 for long periods of working with computers (8 or more hours per day).")
385 (license license:silofl1.1)))
387 (define-public font-adobe-source-han-sans
389 (name "font-adobe-source-han-sans")
394 "https://github.com/adobe-fonts/source-han-sans/archive/"
396 (file-name (string-append "source-han-sans-" version "R.tar.gz"))
399 "1ssx0fw90sy6mj8fv8fv4dgzszpqwbmwpjnlx16g4pvaqzdmybbz"))))
400 (outputs '("out" ; OpenType/CFF Collection (OTC), 121 MiB.
401 "cn" "jp" "kr" "tw")) ; Region-specific Subset OpenType/CFF.
402 (build-system trivial-build-system)
404 `(#:modules ((guix build utils))
407 (use-modules (guix build utils))
408 (let ((tar (string-append (assoc-ref %build-inputs
411 (PATH (string-append (assoc-ref %build-inputs
414 (install-opentype-fonts
415 (lambda (fonts-dir out)
416 (copy-recursively fonts-dir
417 (string-append (assoc-ref %outputs out)
418 "/share/fonts/opentype")))))
420 (system* tar "xvf" (assoc-ref %build-inputs "source"))
421 (chdir (string-append "source-han-sans-" ,version "R"))
422 (install-opentype-fonts "OTC" "out")
423 (install-opentype-fonts "SubsetOTF/CN" "cn")
424 (install-opentype-fonts "SubsetOTF/JP" "jp")
425 (install-opentype-fonts "SubsetOTF/KR" "kr")
426 (install-opentype-fonts "SubsetOTF/TW" "tw")
427 (for-each delete-file (find-files %output "\\.zip$"))))))
431 (home-page "https://github.com/adobe-fonts/source-han-sans")
432 (synopsis "Pan-CJK fonts")
434 "Source Han Sans is a sans serif Pan-CJK font family that is offered in
435 seven weights: ExtraLight, Light, Normal, Regular, Medium, Bold, and Heavy.
436 And in several OpenType/CFF-based deployment configurations to accommodate
437 various system requirements or limitations. As the name suggests, Pan-CJK
438 fonts are intended to support the characters necessary to render or display
439 text in Simplified Chinese, Traditional Chinese, Japanese, and Korean.")
440 (license license:silofl1.1)))
442 (define-public font-cns11643
444 (name "font-cns11643")
445 (version "98.1.20170524")
448 (uri "http://www.cns11643.gov.tw/AIDB/Open_Data.zip")
451 "1iad6rklxkx03ji1fav9faq7cmqkci3i6pcyg2ilvh984j5qzhq3"))))
452 (build-system font-build-system)
453 (home-page "http://www.cns11643.gov.tw/AIDB/welcome.do")
454 (synopsis "CJK TrueType fonts, TW-Kai and TW-Sung")
456 "@code{CNS 11643} character set (Chinese National Standard, or Chinese
457 Standard Interchange Code) is the standard character set of the Republic of
458 China (Taiwan) for Chinese Characters and other Unicode symbols. Contained
459 are six TrueType fonts based on two script styles, Regular script (Kai), and
460 Sung/Ming script, each with three variants:
463 @item @code{CNS 11643} (@code{TW-Kai} and @code{TW-Sung}): Tens of thousands
464 of CJK characters from frequency tables published by the Taiwanese
465 Ministry of Education. ISO 10646 and Unicode compatible encoding.
466 @item @code{Big-5 Plus}: Several thousand frequently used CJK characters
467 encoded in the user defined area of the Big-5 code.
468 @item @code{Big-5 Extended}: A Big-5 character set based on the
469 @code{Big-5 Plus} and @code{CNS 11643} character sets.
471 (license (license:non-copyleft
472 "http://data.gov.tw/license")))) ; CC-BY 4.0 compatible
474 (define-public font-cns11643-swjz
476 (name "font-cns11643-swjz")
481 (uri "https://www.moedict.tw/fonts/truetype/cns11643/ebas927.ttf")
484 "1qkljldbmb53zp1rcmpsb8rzy67rnsqcjxi549m9743ifk4isl78"))))
485 (build-system font-build-system)
487 (string-append "http://www.cns11643.gov.tw/AIDB/download.do"
488 "?name=%E5%AD%97%E5%9E%8B%E4%B8%8B%E8%BC%89"))
489 (synopsis "TrueType seal script font")
491 "@code{Shuowen Jiezi} is a TrueType seal script font based on the ancient
492 text of the same name published by the Executive Yuan of Taiwan. 6721 glyphs
493 are included, at Unicode compatible code points corresponding to their modern
495 ;; Original text only available in Chinese. More info at
496 ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=26703#11
497 (license (license:non-copyleft
498 "http://www.cns11643.gov.tw/AIDB/copyright.do"))))
500 (define-public font-wqy-zenhei
502 (name "font-wqy-zenhei")
507 "mirror://sourceforge/wqy/wqy-zenhei/" version
508 "%20%28Fighting-state%20RC1%29/wqy-zenhei-"
510 (file-name (string-append "wqy-zenhei-" version ".tar.gz"))
513 "1mkmxq8g2hjcglb3zajfqj20r4r88l78ymsp2xyl5yav8w3f7dz4"))))
514 (build-system font-build-system)
515 (home-page "http://wenq.org/wqy2/")
516 (synopsis "CJK font")
518 "WenQuanYi Zen Hei is a Hei-Ti style (sans-serif type) Chinese outline
519 font. It is designed for general purpose text formatting and on-screen
520 display of Chinese characters and symbols from many other languages.
521 WenQuanYi Zen Hei provides a rather complete coverage of Chinese Hanzi glyphs,
522 including both simplified and traditional forms. The total glyph number in
523 this font is over 35,000, including over 21,000 Chinese Hanzi. This font has
524 full coverage of the GBK (CP936) charset, CJK Unified Ideographs, as well as
525 the code-points needed for zh_cn, zh_sg, zh_tw, zh_hk, zh_mo, ja (Japanese) and
526 ko (Korean) locales for @code{fontconfig}.")
527 ;; GPLv2 with font embedding exception
528 (license license:gpl2)))
530 (define-public font-wqy-microhei
532 (name "font-wqy-microhei")
533 (version "0.2.0-beta")
536 (uri (string-append "mirror://sourceforge/wqy/wqy-microhei/"
537 version "/wqy-microhei-" version ".tar.gz"))
540 "0gi1yxqph8xx869ichpzzxvx6y50wda5hi77lrpacdma4f0aq0i8"))))
541 (build-system font-build-system)
542 (home-page "http://wenq.org/wqy2/")
543 (synopsis "CJK font")
545 "WenQuanYi Micro Hei is a Sans-Serif style (also known as Hei, Gothic or
546 Dotum among the Chinese/Japanese/Korean users) high quality CJK outline font.
547 It was derived from \"Droid Sans Fallback\" and \"Droid Sans\" released by
548 Google Inc. This font contains all the unified CJK Han glyphs in the range of
549 U+4E00-U+9FC3 defined in Unicode Standard 5.1, together with many other
550 languages unicode blocks, including Latins, Extended Latins, Hanguls and
551 Kanas. The font file is extremely compact (~4M) compared with most known CJK
553 ;; This font is licensed under Apache2.0 or GPLv3 with font embedding
555 (license license:gpl3)))
557 (define-public font-rachana
559 (name "font-rachana")
565 "https://gitlab.com/smc/rachana/repository/archive.tar.gz?ref=Version"
567 (file-name (string-append name "-" version ".tar.gz"))
570 "0jc091gshna6p1dd6lf507jxkgk6rsja835fc9dm71mcplq53bm1"))))
571 (build-system font-build-system)
572 (home-page "https://smc.org.in")
573 (synopsis "Malayalam font")
575 "Rachana is a Malayalam font designed by Hussain K H. The project was
576 part of Rachana Aksharavedi for the original script of Malayalam in computing.
577 Rachana has about 1,200+ glyphs for Malayalam and contains glyphs required for
578 printing old Malayalam books without compromising the writing style.")
579 ;; This font is licensed under SIL 1.1 or GPLv3+ with font embedding
581 (license (list license:silofl1.1 license:gpl3+))))
583 (define-public font-tex-gyre
585 (name "font-tex-gyre")
589 (method url-fetch/zipbomb)
590 (uri (string-append "http://www.gust.org.pl/projects/e-foundry/"
591 "tex-gyre/whole/tg-" version "otf.zip"))
594 "0kph9l3g7jb2bpmxdbdg5zl56wacmnvdvsdn7is1gc750sqvsn31"))))
595 (build-system font-build-system)
596 (home-page "http://www.gust.org.pl/projects/e-foundry/tex-gyre/")
597 (synopsis "Remake of Ghostscript fonts")
598 (description "The TeX Gyre collection of fonts is the result of an
599 extensive remake and extension of the freely available base PostScript fonts
600 distributed with Ghostscript version 4.00. The collection contains the
601 following fonts in the OpenType format: Adventor, Bonum, Chorus, Cursor,
602 Heros, Pagella, Schola, Termes.")
603 (license license:gfl1.0)))
605 (define-public font-anonymous-pro
607 (name "font-anonymous-pro")
612 "http://www.marksimonson.com/assets/content/fonts/"
613 "AnonymousPro-" version ".zip"))
616 "1asj6lykvxh46czbal7ymy2k861zlcdqpz8x3s5bbpqwlm3mhrl6"))))
617 (build-system font-build-system)
618 (home-page "http://www.marksimonson.com/fonts/view/anonymous-pro")
619 (synopsis "Fixed-width fonts designed with coding in mind")
620 (description "Anonymous Pro is a family of four fixed-width fonts designed
621 with coding in mind. Anonymous Pro features an international, Unicode-based
622 character set, with support for most Western and Central European Latin-based
623 languages, plus Greek and Cyrillic.")
624 (license license:silofl1.1)))
626 (define-public font-gnu-unifont
628 (name "font-gnu-unifont")
633 "mirror://gnu/unifont/unifont-" version "/unifont-"
637 "1js8dn4v4pv8jqprsxa1fv4fs3hqhm9x4dj19fg9qgc8fx7k0v0k"))))
638 (build-system gnu-build-system)
639 (outputs '("out" ; TrueType version
640 "pcf" ; PCF (bitmap) version
641 "psf" ; PSF (console) version
642 "bin" ; Utilities to manipulate '.hex' format
645 '(#:parallel-build? #f ; parallel build fails
646 #:tests? #f ; no check target
648 (modify-phases %standard-phases
651 (lambda _ (setenv "CC" "gcc") #t))
654 (lambda* (#:key outputs #:allow-other-keys)
655 (let* ((ttf (string-append (assoc-ref outputs "out")
656 "/share/fonts/truetype"))
657 (pcf (string-append (assoc-ref outputs "pcf")
658 "/share/fonts/misc"))
659 (psf (string-append (assoc-ref outputs "psf")
660 "/share/consolefonts"))
661 (bin (assoc-ref outputs "bin")))
663 (string-append "PREFIX=" bin)
664 (string-append "TTFDEST=" ttf)
665 (string-append "PCFDEST=" pcf)
666 (string-append "CONSOLEDEST=" psf)
668 ;; Move Texinfo file to the right place.
669 (mkdir (string-append bin "/share/info"))
670 (rename-file (string-append bin "/share/unifont/unifont.info.gz")
671 (string-append bin "/share/info/unifont.info.gz"))
674 `(("perl" ,perl))) ; for utilities
676 "Large bitmap font covering Unicode's Basic Multilingual Plane")
678 "GNU Unifont is a bitmap font covering essentially all of
679 Unicode's Basic Multilingual Plane. The package also includes
680 utilities to ease adding new glyphs to the font.")
681 (home-page "http://unifoundry.com/unifont.html")
682 (properties '((upstream-name . "unifont")))
683 (license license:gpl2+)))
685 (define-public font-google-noto
687 (name "font-google-noto")
690 (method url-fetch/zipbomb)
691 (uri (string-append "https://noto-website.storage.googleapis.com/"
692 "pkgs/Noto-hinted.zip"))
693 (file-name (string-append name "-" version ".zip"))
696 "1p92a6dvs7wqwjfpp1ahr9z1wz35am0l8r78521383spd77bmrfm"))))
697 (build-system font-build-system)
698 (home-page "https://www.google.com/get/noto/")
699 (synopsis "Fonts to cover all languages")
700 (description "Google Noto Fonts is a family of fonts designed to support
701 all languages with a consistent look and aesthetic. Its goal is to properly
702 display all Unicode symbols.")
703 (license license:silofl1.1)))
705 (define-public font-google-roboto
707 (name "font-google-roboto")
712 (uri (string-append "https://github.com/google/roboto/releases/download/"
713 "v" version "/roboto-hinted.zip"))
714 (file-name (string-append name "-" version ".zip"))
717 "0spscx08fad7i8qs7icns96iwcapniq8lwwqqvbf7bamvs8qfln4"))))
718 (build-system font-build-system)
719 (home-page "https://github.com/google/roboto")
720 (synopsis "The Roboto family of fonts")
722 "Roboto is Google’s signature family of fonts, the default font on Android
723 and Chrome OS, and the recommended font for the
724 visual language \"Material Design\".")
725 (license license:asl2.0)))
727 (define-public font-un
730 (version "1.0.2-080608")
734 "https://kldp.net/unfonts/release/2607-"
735 "un-fonts-core-" version ".tar.gz"))
736 (file-name (string-append name "-" version ".tar.gz"))
739 "13liaz2pmww3aqabm55la5npd08m1skh334ky7qfidxaz5s742iv"))))
740 (build-system font-build-system)
741 (home-page "https://kldp.net/projects/unfonts/")
742 (synopsis "Collection of Korean fonts")
744 "Un-fonts is a family of mainly Korean fonts.
745 It contains the following fonts and styles:
748 @item UnBatang, UnBatangBold: serif;
749 @item UnDotum, UnDotumBold: sans-serif;
750 @item UnGraphic, UnGraphicBold: sans-serif style;
751 @item UnDinaru, UnDinaruBold, UnDinaruLight;
752 @item UnPilgi, UnPilgiBold: script;
753 @item UnGungseo: cursive, brush-stroke.
755 (license license:gpl2+)))
757 (define-public font-fantasque-sans
759 (name "font-fantasque-sans")
764 (uri (string-append "https://github.com/belluzj/fantasque-sans/"
765 "archive/v" version ".tar.gz"))
766 (file-name (string-append name "-" version ".tar.gz"))
769 "07fpy53k2x2nz5q61swkab6cfk9gw2kc4x4brsj6zjgbm16fap85"))))
770 (build-system gnu-build-system)
772 `(("ttfautohint" ,ttfautohint)
773 ("woff-tools" ,woff-tools)
774 ("fontforge" ,fontforge)
776 ("ttf2eot" ,ttf2eot)))
778 `(#:tests? #f ;test target intended for visual inspection
779 #:phases (modify-phases %standard-phases
780 (delete 'configure) ;no configuration
782 ;; 'make install' wants to install to ~/.fonts, install to
784 (lambda* (#:key outputs #:allow-other-keys)
785 (let* ((out (assoc-ref outputs "out"))
786 (font-dir (string-append out "/share/fonts"))
787 (truetype-dir (string-append font-dir "/truetype"))
788 (opentype-dir (string-append font-dir "/opentype"))
789 (webfonts-dir (string-append font-dir "/webfonts")))
790 (copy-recursively "OTF" opentype-dir)
791 (for-each (lambda (f) (install-file f truetype-dir))
792 (find-files "." "\\.ttf$"))
793 (copy-recursively "Webfonts" webfonts-dir)
795 (synopsis "Font family with a monospaced variant for programmers")
797 "Fantasque Sans Mono is a programming font designed with functionality in
798 mind. The font includes a bold version and a good italic version with new
799 glyph designs, not just an added slant.")
800 (home-page "https://fontlibrary.org/en/font/fantasque-sans-mono")
801 (license license:silofl1.1)))
803 (define-public font-hack
808 (method url-fetch/zipbomb)
810 "https://github.com/source-foundry/Hack/releases/download/v"
811 version "/Hack-v" version "-ttf.zip"))
814 "0h6slqg25a6cq57k6rh5hmnk8dxbprmf8shs4iyj1pc83sw6b1r3"))))
815 (build-system font-build-system)
816 (home-page "https://sourcefoundry.org/hack/")
817 (synopsis "Typeface designed for source code")
819 "Hack is designed to be a workhorse typeface for code. It expands upon
820 the Bitstream Vera & DejaVu projects, provides 1561 glyphs, and includes
823 ;; See https://github.com/source-foundry/Hack/issues/271 for details.
824 (list license:expat ; the Hack modifications to...
825 license:public-domain ; ...the DejaVu modifications to...
826 (license:x11-style ; ...the Bitstream Vera typeface
827 "file://LICENSE.md" "Bitstream Vera License")))))
829 (define-public font-adobe-source-code-pro
831 (name "font-adobe-source-code-pro")
832 (version "2.030R-ro-1.050R-it")
836 "https://github.com/adobe-fonts/source-code-pro/archive/"
837 (regexp-substitute/global
838 ;; The upstream tag uses "/" between the roman and italic
839 ;; versions, so substitute our "-" separator here.
840 #f "R-ro-" version 'pre "R-ro/" 'post) ".tar.gz"))
841 (file-name (string-append name "-" version ".tar.gz"))
844 "0arhhsf3i7ss39ykn73d1j8k4n8vx7115xph6jwkd970p1cxvr54"))))
845 (build-system font-build-system)
846 (home-page "https://github.com/adobe-fonts/source-code-pro")
848 "Monospaced font family for user interface and coding environments")
850 "Source Code Pro is a set of monospaced OpenType fonts that have been
851 designed to work well in user interface environments.")
852 (license license:silofl1.1)))
854 (define-public font-fira-mono
856 (name "font-fira-mono")
860 (uri (string-append "https://carrois.com/downloads/fira_mono_3_2/"
862 (string-replace-substring version "." "")
866 "1z65x0dw5dq6rs6p9wyfrir50rlh95vgzsxr8jcd40nqazw4jhpi"))))
867 (build-system font-build-system)
868 (home-page "http://mozilla.github.io/Fira/")
869 (synopsis "Mozilla's monospace font")
870 (description "This is the typeface used by Mozilla in Firefox OS.")
871 (license license:silofl1.1)))
873 (define-public font-fira-sans
875 (name "font-fira-sans")
879 (uri (string-append "https://github.com/mozilla/Fira/archive/"
881 (file-name (string-append name "-" version ".tar.gz"))
884 "1r6zdnqqp4bgq5nmgqbj0vvj7x1h9w912851ggbl9wc7fdjnjqnq"))))
885 (build-system font-build-system)
886 (home-page "http://mozilla.github.io/Fira/")
887 (synopsis "Mozilla's Fira Sans Font")
888 (description "This is the typeface used by Mozilla in Firefox OS.")
889 (license license:silofl1.1)))
891 (define-public font-awesome
893 (name "font-awesome")
897 (uri (string-append "http://fontawesome.io/assets/"
898 name "-" version ".zip"))
901 "1m1rfwm4sjkv10j3xd2dhwk286a5912b2zgvc692cmxi5gxs68jf"))))
902 (build-system font-build-system)
903 (home-page "http://fontawesome.io")
904 (synopsis "Font that contains a rich iconset")
906 "Font Awesome is a full suite of pictographic icons for easy scalable
908 (license license:silofl1.1)))
910 (define-public font-tamzen
917 (uri (string-append "https://github.com/sunaku/tamzen-font/archive/"
918 "Tamzen-" version ".tar.gz"))
919 (file-name (string-append name "-" version ".tar.gz"))
922 "1ryd7gp6qiwaqw73jqbmh4kwlriyd8xykh4j7z90z8xp9fm7lrys"))))
923 (build-system trivial-build-system)
925 `(#:modules ((guix build utils))
928 (use-modules (guix build utils))
930 (let ((tar (string-append (assoc-ref %build-inputs "tar")
932 (PATH (string-append (assoc-ref %build-inputs "gzip")
934 (font-dir (string-append %output "/share/fonts/misc"))
935 (psf-dir (string-append %output "/share/kbd/consolefonts"))
936 (src-pcf-dir (string-append "tamzen-font-Tamzen-"
939 (system* tar "xvf" (assoc-ref %build-inputs "source"))
943 (for-each (lambda (pcf)
944 (install-file pcf font-dir))
945 (find-files "." "\\.pcf$"))
947 (for-each (lambda (psf)
948 (install-file psf psf-dir))
949 (find-files "." "\\.psf$"))
954 (home-page "https://github.com/sunaku/tamzen-font")
955 (synopsis "Monospaced bitmap font for console and X11")
957 "Tamzen is a fork of the @code{Tamsyn} font. It is programatically forked
958 from @code{Tamsyn} version 1.11, backporting glyphs from older versions while
959 deleting deliberately empty glyphs (which are marked as unimplemented) to
960 allow secondary/fallback fonts to provide real glyphs at those codepoints.
962 The @code{TamzenForPowerline} fonts provide additional @code{Powerline} symbols,
963 which are programatically injected with @code{bitmap-font-patcher} and
964 later hand-tweaked with the gbdfed(1) editor:
967 @item all icons are expanded to occupy the maximum available space
968 @item the branch of the fork icon ( U+E0A0) was made larger than the trunk
969 @item for the newline icon ( U+E0A1), the @emph{N} was made larger at the bottom
970 @item the keyhole in the padlock icon ( U+E0A2) was replaced with @emph{//} lines.
972 (license (license:non-copyleft "file://LICENSE"))))
974 (define-public font-comic-neue
976 (name "font-comic-neue")
979 (method url-fetch/zipbomb)
981 "http://www.comicneue.com/comic-neue-" version ".zip"))
984 "1695hkpd8kqnr2a88p8xs496slgzxjjkzpa9aa33ml3pnh7519zk"))))
985 (build-system font-build-system)
988 (modify-phases %standard-phases
989 ;; Delete Mac OS X specific files. If not deleted, these cause
990 ;; several hidden files to be installed.
991 (add-before 'install 'delete-macosx-files
993 (delete-file-recursively "__MACOSX")
995 (add-after 'install 'install-conf
996 (lambda* (#:key outputs #:allow-other-keys)
997 (let ((conf-dir (string-append (assoc-ref outputs "out")
998 "/share/fontconfig/conf.avail")))
1000 (call-with-output-file
1001 (string-append conf-dir "/30-comic-neue.conf")
1003 (format port "<?xml version=\"1.0\"?>
1004 <!DOCTYPE fontconfig SYSTEM \"fonts.dtd\">
1006 <!-- If Comic Sans is missing, use Comic Neue instead. -->
1008 <family>Comic Sans MS</family>
1010 <family>Comic Neue</family>
1013 </fontconfig>\n"))))
1015 (home-page "http://www.comicneue.com/")
1016 (synopsis "Font that fixes the shortcomings of Comic Sans")
1018 "Comic Neue is a font that attempts to create a respectable casual
1019 typeface, by mimicking Comic Sans while fixing its most obvious shortcomings.")
1020 (license license:silofl1.1)))
1022 (define-public font-iosevka
1024 (name "font-iosevka")
1027 (method url-fetch/zipbomb)
1029 "https://github.com/be5invis/Iosevka/releases/download/v"
1030 version "/iosevka-pack-" version ".zip"))
1033 "0s3g6mk0ngwsrw9h9dqinb50cd9i8zhqdcmmh93fhyf4d87yfwyi"))))
1034 (build-system font-build-system)
1035 (home-page "https://be5invis.github.io/Iosevka/")
1036 (synopsis "Coders' typeface, built from code")
1038 "Iosevka is a slender monospace sans-serif or slab-serif typeface inspired
1039 by Pragmata Pro, M+, and PF DIN Mono, designed to be the ideal font for
1040 programming. Iosevka is completely generated from its source code.")
1041 (license (list license:silofl1.1 ; build artifacts (i.e. the fonts)
1042 license:bsd-3)))) ; supporting code
1044 (define-public font-go
1045 (let ((commit "f03a046406d4d7fbfd4ed29f554da8f6114049fc")
1049 (version (string-append "20170330-" revision "." (string-take commit 7)))
1051 (file-name (string-append "go-image-" version "-checkout"))
1054 (url "https://go.googlesource.com/image")
1058 "1aq6mnjayks55gd9ahavk6jfydlq5lm4xm0xk4pd5sqa74p5p74d"))))
1059 (build-system font-build-system)
1062 (modify-phases %standard-phases
1063 (add-before 'install 'chdir
1065 (chdir "font/gofont/ttfs")
1067 (home-page "https://blog.golang.org/go-fonts")
1068 (synopsis "The Go font family")
1070 "The Go font family is a set of WGL4 TrueType fonts from the Bigelow &
1071 Holmes type foundry, released under the same license as the Go programming
1072 language. It includes a set of proportional, sans-serif fonts, and a set of
1073 monospace, slab-serif fonts.")
1074 (license license:bsd-3))))
1076 (define-public font-google-material-design-icons
1078 (name "font-google-material-design-icons")
1083 "https://github.com/google/material-design-icons/archive/"
1087 "018i3za9r6kf6svci33z09lc5pr5yz4164m8gzzwjzzqcrng0p5j"))
1088 (file-name (string-append name "-" version ".tar.gz"))))
1089 (build-system font-build-system)
1090 (home-page "http://google.github.io/material-design-icons")
1091 (synopsis "Icon font of Google Material Design icons")
1093 "Material design system icons are simple, modern, friendly, and sometimes
1094 quirky. Each icon is created using our design guidelines to depict in simple
1095 and minimal forms the universal concepts used commonly throughout a UI.
1096 Ensuring readability and clarity at both large and small sizes, these icons
1097 have been optimized for beautiful display on all common platforms and display
1099 (license license:asl2.0)))
1101 (define-public font-open-dyslexic
1103 (name "font-open-dyslexic")
1104 (version "20160623")
1108 (uri (string-append "https://github.com/antijingoist/open-dyslexic/"
1109 "archive/" version "-Stable.tar.gz"))
1110 (file-name (string-append name "-" version ".tar.gz"))
1113 "0al0j9kb32kfavcpq1kigsd36yzvf5yhzqhds0jkh7ngbxyxwkx4"))))
1114 (build-system font-build-system)
1115 (home-page "https://opendyslexic.org")
1116 (synopsis "Font for dyslexics and high readability")
1117 (description "OpenDyslexic is a font designed to help readability for some
1118 of the symptoms of dyslexia. Letters have heavy weighted bottoms to provide
1119 an indication of orientation to make it more difficult to confuse with other
1120 similar letters. Consistently weighted bottoms can also help reinforce the
1121 line of text. The unique shapes of each letter can help prevent flipping and
1122 swapping. The italic style for OpenDyslexic has been crafted to be used for
1123 emphasis while still being readable.")
1125 (license:fsdg-compatible
1126 "https://www.gnome.org/fonts/#Final_Bitstream_Vera_Fonts"
1127 "The Font Software may be sold as part of a larger software package but
1128 no copy of one or more of the Font Software typefaces may be sold by
1131 (define-public font-dosis
1138 (uri (string-append "http://www.impallari.com/media/releases/dosis-"
1139 "v" version ".zip"))
1142 "1qhci68f68mf87jd69vjf9qjq3wydgw1q7ivn3amjb65ls1s0c4s"))))
1143 (build-system trivial-build-system)
1145 `(#:modules ((guix build utils))
1147 (use-modules (guix build utils)
1150 (let ((PATH (string-append (assoc-ref %build-inputs
1153 (ttf-dir (string-append %output
1154 "/share/fonts/truetype"))
1155 (otf-dir (string-append %output
1156 "/share/fonts/opentype")))
1157 (setenv "PATH" PATH)
1158 (system* "unzip" (assoc-ref %build-inputs "source"))
1162 (for-each (lambda (ttf)
1163 (install-file ttf ttf-dir))
1164 (find-files "." "\\.ttf$"))
1165 (for-each (lambda (otf)
1166 (install-file otf otf-dir))
1167 (find-files "." "\\.otf$"))))))
1168 (native-inputs `(("unzip" ,unzip)))
1169 (home-page "http://www.impallari.com/dosis")
1170 (synopsis "Very simple, rounded, sans serif family")
1172 "Dosis is a very simple, rounded, sans serif family.
1173 The lighter weights are minimalist. The bolder weights have more personality.
1174 The medium weight is nice and balanced. The overall result is a family
1175 that's clean and modern, and can express a wide range of voices & feelings.
1176 It comes in 7 incremental weights:
1177 ExtraLight, Light, Book, Medium, Semibold, Bold & ExtraBold")
1178 (license license:silofl1.1)))