gnu: Use HTTPS for supported nongnu.org home pages.
[jackhill/guix/guix.git] / gnu / packages / fontutils.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015 Andreas Enge <andreas@enge.fr>
3 ;;; Copyright © 2014, 2016 Eric Bavier <bavier@member.fsf.org>
4 ;;; Copyright © 2016 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
6 ;;; Copyright © 2017 Rene Saavedra <rennes@openmailbox.org>
7 ;;; Copyright © 2017 Leo Famulari <leo@famulari.name>
8 ;;; Copyright © 2017 ng0 <ng0@n0.is>
9 ;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr>
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 fontutils)
27 #:use-module (gnu packages)
28 #:use-module (gnu packages compression)
29 #:use-module (gnu packages check)
30 #:use-module (gnu packages ghostscript)
31 #:use-module (gnu packages perl)
32 #:use-module (gnu packages pkg-config)
33 #:use-module (gnu packages autotools)
34 #:use-module (gnu packages gettext)
35 #:use-module (gnu packages python)
36 #:use-module (gnu packages image)
37 #:use-module (gnu packages bison)
38 #:use-module (gnu packages flex)
39 #:use-module (gnu packages glib)
40 #:use-module (gnu packages gperf)
41 #:use-module (gnu packages xorg)
42 #:use-module (gnu packages gtk)
43 #:use-module (gnu packages xml)
44 #:use-module ((guix licenses) #:prefix license:)
45 #:use-module (guix packages)
46 #:use-module (guix download)
47 #:use-module (guix svn-download)
48 #:use-module (guix git-download)
49 #:use-module (guix build-system cmake)
50 #:use-module (guix build-system gnu)
51 #:use-module (guix build-system python))
52
53 (define-public freetype
54 (package
55 (name "freetype")
56 (version "2.8")
57 (source (origin
58 (method url-fetch)
59 (uri (string-append "mirror://savannah/freetype/freetype-"
60 version ".tar.bz2"))
61 (sha256 (base32
62 "02xlj611alpvl3h33hvfw1jyxc1vp9mzwcckkiglkhn3hknh7im3"))))
63 (build-system gnu-build-system)
64 (native-inputs
65 `(("pkg-config" ,pkg-config)))
66 (propagated-inputs
67 ;; These are all in the Requires.private field of freetype2.pc.
68 ;; XXX: add harfbuzz.
69 `(("libpng" ,libpng)
70 ("zlib" ,zlib)))
71 (synopsis "Font rendering library")
72 (description
73 "Freetype is a library that can be used by applications to access the
74 contents of font files. It provides a uniform interface to access font files.
75 It supports both bitmap and scalable formats, including TrueType, OpenType,
76 Type1, CID, CFF, Windows FON/FNT, X11 PCF, and others. It supports high-speed
77 anti-aliased glyph bitmap generation with 256 gray levels.")
78 (license license:freetype) ; some files have other licenses
79 (home-page "https://www.freetype.org/")))
80
81 (define-public ttfautohint
82 (package
83 (name "ttfautohint")
84 (version "1.5")
85 (source
86 (origin
87 (method url-fetch)
88 (uri (string-append "mirror://savannah/freetype/ttfautohint-"
89 version ".tar.gz"))
90 (sha256
91 (base32
92 "1lgghck46p33z3hg8dnl76jryig4fh6d8rhzms837zp7x4hyfkv4"))
93 (patches (list (search-patch "ttfautohint-source-date-epoch.patch")))))
94 (build-system gnu-build-system)
95 (native-inputs
96 `(("flex" ,flex)
97 ("bison" ,bison)
98 ("pkg-config" ,pkg-config)))
99 (inputs
100 `(("freetype" ,freetype)
101 ("harfbuzz" ,harfbuzz)))
102 (arguments
103 `(#:configure-flags '("--with-qt=no"))) ;no gui
104 (synopsis "Automated font hinting")
105 (description
106 "ttfautohint provides a 99% automated hinting process and a platform for
107 finely hand-hinting the last 1%. It is ideal for web fonts and supports many
108 scripts.")
109 (license (list license:gpl2+ license:freetype)) ;choose one or the other
110 (home-page "http://www.freetype.org/ttfautohint/")))
111
112 (define-public woff-tools
113 (package
114 (name "woff-tools")
115 (version "2009.10.04")
116 (source
117 (origin
118 (method url-fetch)
119 ;; Upstream source is unversioned, so use Debian's versioned tarball
120 (uri (string-append "mirror://debian/pool/main/w/woff-tools/"
121 "woff-tools_" version ".orig.tar.gz"))
122 (file-name (string-append name "-" version ".tar.gz"))
123 (sha256
124 (base32
125 "1i97gkqa6jfzlslsngqf556kx60knlgf7yc9pzsq2pizc6f0d4zl"))))
126 (build-system gnu-build-system)
127 (inputs
128 `(("zlib" ,zlib)))
129 (arguments
130 `(#:make-flags '("CC=gcc")
131 #:tests? #f ;no tests
132 #:phases
133 (modify-phases %standard-phases
134 (delete 'configure) ;no configuration
135 (replace 'install
136 (lambda* (#:key outputs #:allow-other-keys)
137 (let* ((out (assoc-ref outputs "out"))
138 (bin (string-append out "/bin")))
139 (install-file "sfnt2woff" bin)
140 (install-file "woff2sfnt" bin)))))))
141 (synopsis "Convert between OpenType and WOFF fonts")
142 (description
143 "This package provides two tools:
144 @table @code
145 @item sfnt2woff
146 Converts OpenType fonts to WOFF fonts
147 @item woff2sfnt
148 Converts WOFF fonts to OpenType fonts
149 @end table")
150 (license (list license:mpl1.1 license:gpl2+ license:lgpl2.1+))
151 (home-page "https://people.mozilla.com/~jkew/woff/")))
152
153 (define-public ttf2eot
154 (package
155 (name "ttf2eot")
156 (version "0.0.2-2")
157 (source
158 (origin
159 (method url-fetch)
160 (uri (string-append "https://storage.googleapis.com/"
161 "google-code-archive-downloads/v2/"
162 "code.google.com/ttf2eot/"
163 "ttf2eot-" version ".tar.gz"))
164 (sha256
165 (base32
166 "1f4dzzmhn0208dvbm3ia5ar6ls9apwc6ampy5blmfxkigi6z0g02"))
167 (patches (list (search-patch "ttf2eot-cstddef.patch")))))
168 (build-system gnu-build-system)
169 (arguments
170 `(#:tests? #f ;no tests
171 #:phases
172 (modify-phases %standard-phases
173 (delete 'configure) ;no configuration
174 (replace 'install
175 (lambda* (#:key outputs #:allow-other-keys)
176 (let* ((out (assoc-ref outputs "out"))
177 (bin (string-append out "/bin")))
178 (install-file "ttf2eot" bin)))))))
179 (synopsis "Convert from TrueType to Embeddable Open Type")
180 (description
181 "This package contains a commandline wrapper around OpenTypeUtilities.cpp
182 from Chromium, used to make EOT (Embeddable Open Type) files from
183 TTF (TrueType/OpenType Font) files.")
184 ;; While the README states "License: Derived from WebKit, so BSD/LGPL
185 ;; 2/LGPL 2.1", the single derived source file includes only BSD in its
186 ;; license header, and the wrapper source contains no license header.
187 (license license:bsd-2)
188 (home-page "https://code.google.com/archive/p/ttf2eot/")))
189
190 (define-public woff2
191 (let ((commit "4e698b8c6c5e070d53c340db9ddf160e21070ede")
192 (revision "1"))
193 (package
194 (name "woff2")
195 (version (string-append "20160306-" revision "."
196 (string-take commit 7)))
197 (source (origin
198 (method git-fetch)
199 (uri (git-reference
200 (url "https://github.com/google/woff2.git")
201 (commit commit)))
202 (file-name (string-append name "-" version ".tar.xz"))
203 (sha256
204 (base32
205 "0wka0yhf0cjmd4rv2jckxpyv6lb5ckj4nj0k1ajq5hrjy7f30lcp"))
206 (patches (list (search-patch "woff2-libbrotli.patch")))))
207 (build-system gnu-build-system)
208 (native-inputs
209 `(("pkg-config" ,pkg-config)))
210 (inputs
211 `(("brotli" ,brotli)))
212 (arguments
213 `(#:tests? #f ;no tests
214 #:phases (modify-phases %standard-phases
215 (delete 'configure)
216 (replace 'install
217 (lambda* (#:key outputs #:allow-other-keys)
218 (let* ((out (assoc-ref outputs "out"))
219 (bin (string-append out "/bin")))
220 (install-file "woff2_compress" bin)
221 (install-file "woff2_decompress" bin)
222 #t))))))
223 (synopsis "Compress TrueType fonts to WOFF2")
224 (description
225 "This package provides utilities for compressing/decompressing TrueType
226 fonts to/from the WOFF2 format.")
227 (license license:asl2.0)
228 (home-page "https://github.com/google/woff2"))))
229
230 (define-public fontconfig
231 (package
232 (name "fontconfig")
233 (version "2.12.3")
234 (source (origin
235 (method url-fetch)
236 (uri (string-append
237 "https://www.freedesktop.org/software/fontconfig/release/fontconfig-"
238 version ".tar.bz2"))
239 (sha256 (base32
240 "1ggq6jmz3mlzk4xjs615aqw9h3hq33chjn82bhli26kk09kby95x"))))
241 (build-system gnu-build-system)
242 (propagated-inputs `(("expat" ,expat)
243 ("freetype" ,freetype)))
244 (inputs `(("gs-fonts" ,gs-fonts)))
245 (native-inputs
246 `(("gperf" ,gperf) ; Try dropping this for > 2.12.3.
247 ("pkg-config" ,pkg-config)))
248 (arguments
249 `(#:configure-flags
250 (list "--with-cache-dir=/var/cache/fontconfig"
251 ;; register gs-fonts as default fonts
252 (string-append "--with-default-fonts="
253 (assoc-ref %build-inputs "gs-fonts")
254 "/share/fonts")
255
256 ;; Register fonts from user and system profiles.
257 (string-append "--with-add-fonts="
258 "~/.guix-profile/share/fonts,"
259 "/run/current-system/profile/share/fonts")
260
261 ;; python is not actually needed
262 "PYTHON=false")
263 #:phases
264 (modify-phases %standard-phases
265 (add-before 'configure 'regenerate-fcobjshash
266 ;; XXX The pre-generated gperf files are broken.
267 ;; See <https://bugs.freedesktop.org/show_bug.cgi?id=101280>.
268 (lambda _
269 (delete-file "src/fcobjshash.h")
270 (delete-file "src/fcobjshash.gperf")
271 #t))
272 (replace 'install
273 (lambda _
274 ;; Don't try to create /var/cache/fontconfig.
275 (zero? (system* "make" "install"
276 "fc_cachedir=$(TMPDIR)"
277 "RUN_FC_CACHE_TEST=false")))))))
278 (synopsis "Library for configuring and customizing font access")
279 (description
280 "Fontconfig can discover new fonts when installed automatically;
281 perform font name substitution, so that appropriate alternative fonts can
282 be selected if fonts are missing;
283 identify the set of fonts required to completely cover a set of languages;
284 have GUI configuration tools built as it uses an XML-based configuration file;
285 efficiently and quickly find needed fonts among the set of installed fonts;
286 be used in concert with the X Render Extension and FreeType to implement
287 high quality, anti-aliased and subpixel rendered text on a display.")
288 ; The exact license is more X11-style than BSD-style.
289 (license (license:non-copyleft "file://COPYING"
290 "See COPYING in the distribution."))
291 (home-page "http://www.freedesktop.org/wiki/Software/fontconfig")))
292
293 (define-public t1lib
294 (package
295 (name "t1lib")
296 (version "5.1.2")
297 (source (origin
298 (method url-fetch)
299 (uri (list (string-append "ftp://sunsite.unc.edu/pub/Linux/libs/"
300 "graphics/" name "-" version ".tar.gz")
301 (string-append "https://fossies.org/linux/misc/old/"
302 name "-" version ".tar.gz")))
303 (sha256 (base32
304 "0nbvjpnmcznib1nlgg8xckrmsw3haa154byds2h90y2g0nsjh4w2"))
305 (patches (search-patches
306 "t1lib-CVE-2010-2642.patch" ; 2011-0443, 2011-5244
307 "t1lib-CVE-2011-0764.patch"
308 "t1lib-CVE-2011-1552+.patch")))) ; 2011-1553, 2011-1554
309 (properties `((lint-hidden-cve . ("CVE-2011-0433"
310 "CVE-2011-1553"
311 "CVE-2011-1554"
312 "CVE-2011-5244"))))
313 (build-system gnu-build-system)
314 (arguments
315 ;; Making the documentation requires latex, but t1lib is also an input
316 ;; for building texlive.
317 `(#:tests? #f ; no test target
318 #:make-flags
319 '("without_doc")))
320 (synopsis "Library for generating bitmaps from Type 1 fonts")
321 (description
322 "T1lib is a library for generating/rasterising bitmaps from Type 1 fonts.
323 It is based on the code of the X11 rasteriser of the X11 project.
324
325 The bitmaps created by t1lib are returned in a data structure with type
326 GLYPH. This special GLYPH-type is also used in the X11 window system to
327 describe character bitmaps. It contains the bitmap data as well as some
328 metric information. But t1lib is in itself entirely independent of the
329 X11-system or any other graphical user interface.")
330 (license license:gpl2)
331 (home-page "http://www.t1lib.org/")))
332
333 (define-public teckit
334 (package
335 (name "teckit")
336 (version "2.5.7")
337 (source (origin
338 (method url-fetch)
339 (uri (string-append
340 "https://github.com/silnrsi/teckit/releases/download/v"
341 version "/teckit-" version ".tar.gz"))
342 (sha256
343 (base32
344 "1pbp97vcpj6x4yixx6ww0vsi1rrr99fksxdjafs6gdargzd24cj4"))))
345 (build-system gnu-build-system)
346 (inputs
347 `(("zlib" ,zlib)
348 ("expat" ,expat)))
349 (native-inputs
350 `(("autoconf" ,autoconf)
351 ("automake" ,automake)
352 ("libtool" ,libtool)
353 ("perl" ,perl))) ; for the tests
354 (synopsis "Toolkit for encoding conversions")
355 (description
356 "TECkit is a low-level toolkit intended to be used by other applications
357 that need to perform encoding conversions (e.g., when importing legacy data
358 into a Unicode-based application). The primary component of the TECkit
359 package is therefore a library that performs conversions; this is the
360 \"TECkit engine\". The engine relies on mapping tables in a specific binary
361 format (for which documentation is available); there is a compiler that
362 creates such tables from a human-readable mapping description (a simple
363 text file).
364
365 To facilitate the development and testing of mapping tables for TECkit,
366 several applications are also included in the current package; these
367 include simple tools for applying conversions to plain-text and Standard
368 Format files, as well as both command-line and simple GUI versions of the
369 TECkit compiler. However, it is not intended that these tools will be the
370 primary means by which end users perform conversions, and they have not
371 been designed, tested, and debugged to the extent that general-purpose
372 applications should be.")
373 (license license:lgpl2.1+)
374 (home-page "http://scripts.sil.org/cms/scripts/page.php?cat_id=teckit")))
375
376 (define-public graphite2
377 (package
378 (name "graphite2")
379 (version "1.3.10")
380 (source
381 (origin
382 (method url-fetch)
383 (uri (string-append "https://github.com/silnrsi/graphite/releases/"
384 "download/" version "/" name "-" version ".tgz"))
385 (patches (search-patches "graphite2-ffloat-store.patch"))
386 (sha256
387 (base32
388 "1bm1rl2ww0m8rvmknh8fpajyz9xqv43qs9qrzf7xd5gaz6rf7zch"))))
389 (build-system cmake-build-system)
390 (native-inputs
391 `(("python" ,python-2) ; because of "import imap" in tests
392 ("python-fonttools" ,python2-fonttools)))
393 (inputs
394 `(("freetype" ,freetype)))
395 (synopsis "Reimplementation of the SIL Graphite text processing engine")
396 (description
397 "Graphite2 is a reimplementation of the SIL Graphite text processing
398 engine. Graphite is a smart font technology designed to facilitate the
399 process known as shaping. This process takes an input Unicode text string
400 and returns a sequence of positioned glyphids from the font.")
401 (license license:lgpl2.1+)
402 (home-page "https://github.com/silnrsi/graphite")))
403
404 (define-public potrace
405 (package
406 (name "potrace")
407 (version "1.15")
408 (source
409 (origin
410 (method url-fetch)
411 (uri (string-append "mirror://sourceforge/potrace/" version
412 "/potrace-" version ".tar.gz"))
413 (sha256
414 (base32
415 "17ajildjp14shsy339xarh1lw1p0k60la08ahl638a73mh23kcx9"))))
416 (build-system gnu-build-system)
417 (native-inputs `(("ghostscript" ,ghostscript))) ;for tests
418 (inputs `(("zlib" ,zlib)))
419 (arguments
420 `(#:configure-flags
421 `("--with-libpotrace"))) ; install library and headers
422 (synopsis "Transform bitmaps into vector graphics")
423 (description
424 "Potrace is a tool for tracing a bitmap, which means, transforming a
425 bitmap into a smooth, scalable image. The input is a bitmap (PBM, PGM, PPM,
426 or BMP format), and the default output is an encapsulated PostScript
427 file (EPS). A typical use is to create EPS files from scanned data, such as
428 company or university logos, handwritten notes, etc. The resulting image is
429 not \"jaggy\" like a bitmap, but smooth. It can then be rendered at any
430 resolution.")
431 (license license:gpl2+)
432 (home-page "http://potrace.sourceforge.net/")))
433
434 (define-public libotf
435 (package
436 (name "libotf")
437 (version "0.9.13")
438 (source (origin
439 (method url-fetch)
440 (uri (string-append "mirror://savannah/m17n/libotf-"
441 version ".tar.gz"))
442 (sha256
443 (base32 "0239zvfan56w7vrppriwy77fzb10ag9llaz15nsraps2a2x6di3v"))))
444 (build-system gnu-build-system)
445 (propagated-inputs
446 `(("freetype" ,freetype)))
447 (home-page "https://www.nongnu.org/m17n/")
448 (synopsis "Library for handling OpenType Font")
449 (description "This library can read Open Type Layout Tables from an OTF
450 file. Currently these tables are supported; head, name, cmap, GDEF, GSUB, and
451 GPOS. It can convert a Unicode character sequence to a glyph code sequence by
452 using the above tables.")
453 (license license:lgpl2.0+)))
454
455 (define-public libspiro
456 (package
457 (name "libspiro")
458 (version "20071029")
459 (source
460 (origin
461 (method url-fetch)
462 (uri (string-append "mirror://sourceforge/libspiro/libspiro/"
463 version "/libspiro_src-" version ".tar.bz2"))
464 (sha256
465 (base32
466 "1kylz8pvwnb85yya150r9i6mhbpzx38f32qy523qg3ylgd9b3zhy"))))
467 (build-system gnu-build-system)
468 (arguments `(#:tests? #f)) ;no tests
469 (synopsis "Clothoid to bezier conversion library")
470 (description
471 "Raph Levien's Spiro package as a library. A mechanism for drawing
472 smooth contours with constant curvature at the spline joins.")
473 (license license:gpl2+)
474 (home-page "http://libspiro.sourceforge.net/")))
475
476 (define-public libuninameslist
477 (package
478 (name "libuninameslist")
479 (version "20170807")
480 (source
481 (origin
482 (method url-fetch)
483 (uri (string-append "https://github.com/fontforge/libuninameslist/"
484 "archive/" version ".tar.gz"))
485 (file-name (string-append name "-" version ".tar.gz"))
486 (sha256
487 (base32
488 "0axwxjgcrwms9682vmpsq1x4swdx6q6qk6997rkfr8xrgi124c6a"))))
489 (build-system gnu-build-system)
490 (native-inputs `(("autoconf" ,autoconf)
491 ("automake" ,automake)
492 ("libtool" ,libtool)))
493 (arguments
494 `(#:phases
495 (modify-phases %standard-phases
496 (add-after 'unpack 'bootstrap
497 (lambda _ (zero? (system* "autoreconf" "-vi")))))))
498 (synopsis "Unicode names and annotation list")
499 (description
500 "LibUniNamesList holds www.unicode.org Nameslist.txt data which can be
501 useful for programs that need Unicode \"Names\", \"Annotations\", and block
502 definitions.")
503 (license license:gpl2)
504 (home-page "https://github.com/fontforge/libuninameslist")))
505
506 (define-public fontforge
507 (package
508 (name "fontforge")
509 (version "20170731")
510 (source (origin
511 (method url-fetch)
512 (uri (string-append
513 "https://github.com/fontforge/fontforge/releases/download/"
514 version "/fontforge-dist-" version ".tar.xz"))
515 (sha256 (base32
516 "08l8h3yvk4v7652jvmd3ls7nf5miybkx2fmkf1mpwwfixpxxw2l4"))))
517 (build-system gnu-build-system)
518 (native-inputs
519 `(("pkg-config" ,pkg-config)))
520 (inputs `(("cairo" ,cairo)
521 ("fontconfig" ,fontconfig) ;dlopen'd
522 ("freetype" ,freetype)
523 ("gettext" ,gettext-minimal)
524 ("glib" ,glib) ;needed for pango detection
525 ("libICE" ,libice)
526 ("libSM" ,libsm)
527 ("libX11" ,libx11)
528 ("libXi" ,libxi)
529 ("libjpeg" ,libjpeg)
530 ("libltdl" ,libltdl)
531 ("libpng" ,libpng)
532 ("libspiro" ,libspiro)
533 ("libtiff" ,libtiff)
534 ("libungif" ,libungif)
535 ("libuninameslist" ,libuninameslist)
536 ("libxft" ,libxft)
537 ("libxml2" ,libxml2)
538 ("pango" ,pango)
539 ("potrace" ,potrace)
540 ("python" ,python-wrapper)
541 ("zlib" ,zlib)))
542 (arguments
543 '(#:phases
544 (modify-phases %standard-phases
545 (add-after 'install 'set-library-path
546 (lambda* (#:key inputs outputs #:allow-other-keys)
547 (let ((out (assoc-ref outputs "out"))
548 (potrace (string-append (assoc-ref inputs "potrace") "/bin")))
549 (wrap-program (string-append out "/bin/fontforge")
550 ;; Fontforge dynamically opens libraries.
551 `("LD_LIBRARY_PATH" ":" prefix
552 ,(map (lambda (input)
553 (string-append (assoc-ref inputs input)
554 "/lib"))
555 '("libtiff" "libjpeg" "libpng" "libungif"
556 "libxml2" "zlib" "libspiro" "freetype"
557 "pango" "cairo" "fontconfig")))
558 ;; Checks for potrace program at runtime
559 `("PATH" ":" prefix (,potrace)))))))))
560 (synopsis "Outline font editor")
561 (description
562 "FontForge allows you to create and modify postscript, truetype and
563 opentype fonts. You can save fonts in many different outline formats, and
564 generate bitmaps.")
565 (license license:gpl3+)
566 (home-page "https://fontforge.github.io/en-US/")))
567
568 (define-public python2-ufolib
569 (package
570 (name "python2-ufolib")
571 (version "2.1.1")
572 (source
573 (origin
574 (method url-fetch)
575 (uri (pypi-uri "ufoLib" version ".zip"))
576 (sha256
577 (base32 "07qy6mx7z0wi9a30lc2hj5i9q1gnz1n8l40dmjz2c19mj9s6mz9l"))))
578 (build-system python-build-system)
579 (arguments
580 `(#:python ,python-2))
581 (propagated-inputs
582 `(("python2-fonttools" ,python2-fonttools)))
583 (native-inputs
584 `(("unzip" ,unzip)
585 ("python2-pytest-3.0" ,python2-pytest-3.0)
586 ("python2-pytest-runner" ,python2-pytest-runner)))
587 (home-page "https://github.com/unified-font-object/ufoLib")
588 (synopsis "Low-level UFO reader and writer")
589 (description
590 "UfoLib reads and writes Unified Font Object (UFO)
591 files. UFO is a file format that stores fonts source files.")
592 (license license:bsd-3)))
593
594 (define-public python2-defcon
595 (package
596 (name "python2-defcon")
597 (version "0.3.5")
598 (source
599 (origin
600 (method url-fetch)
601 (uri (pypi-uri "defcon" version ".zip"))
602 (sha256
603 (base32
604 "03jlm2gy9lvbwj68kfdm43yaddwd634jwkdg4wf0jxx2s8mwbg22"))))
605 (build-system python-build-system)
606 (arguments
607 `(#:python ,python-2))
608 (native-inputs
609 `(("unzip" ,unzip)
610 ("python2-pytest-3.0" ,python2-pytest-3.0)
611 ("python2-pytest-runner" ,python2-pytest-runner)))
612 (propagated-inputs
613 `(("python2-fonttools" ,python2-fonttools)
614 ("python2-ufolib" ,python2-ufolib)))
615 (home-page "https://pypi.python.org/pypi/defcon")
616 (synopsis "Flexible objects for representing @acronym{UFO, unified font object} data")
617 (description
618 "Defcon is a set of @acronym{UFO, unified font object} based objects
619 optimized for use in font editing applications. The objects are built to
620 be lightweight, fast and flexible. The objects are very bare-bones and
621 they are not meant to be end-all, be-all objects. Rather, they are meant
622 to provide base functionality so that you can focus on your application’s
623 behavior, not object observing or maintaining cached data. Defcon
624 implements UFO3 as described by the UFO font format.")
625 (license license:expat)))
626
627 (define-public nototools
628 (package
629 (name "nototools")
630 (version "20170925")
631 (source
632 (origin
633 (method url-fetch)
634 (uri (string-append "https://github.com/googlei18n/nototools/"
635 "archive/v2017-09-25-tooling-for-phase3-"
636 "update.tar.gz"))
637 (file-name (string-append name "-" version ".tar.gz"))
638 (sha256
639 (base32
640 "1pvacw18cm9l4sb66pqyjc7hc74xhhfxc7kd5ald8lixf4wzg0s8"))))
641 (build-system python-build-system)
642 (arguments
643 `(#:python ,python-2))
644 (propagated-inputs
645 `(("python2-booleanoperations" ,python2-booleanoperations)
646 ("python2-defcon" ,python2-defcon)
647 ("python2-fonttools" ,python2-fonttools)
648 ("python2-pillow" ,python2-pillow)
649 ("python2-pyclipper" ,python2-pyclipper)
650 ("python2-ufolib" ,python2-ufolib)))
651 (home-page "https://github.com/googlei18n/nototools")
652 (synopsis "Noto fonts support tools and scripts")
653 (description
654 "Nototools is a Python package containing Python scripts used to
655 maintain the Noto Fonts project.")
656 (license (list license:asl2.0
657 ;; Sample texts are attributed to UN and OHCHR.
658 ;; The permissions on the UDHR are pretty lax:
659 ;; http://www.ohchr.org/EN/UDHR/Pages/Introduction.aspx
660 ;; "If UDHR translations or materials are reproduced, users
661 ;; should make reference to this website as a source by
662 ;; providing a link."
663 license:public-domain
664 (license:non-copyleft
665 "file://sample_texts/attributions.txt"
666 "See sample_texts/attributions.txt in the distribution.")))))