container: Gracefully report mount errors in the child process.
[jackhill/guix/guix.git] / gnu / packages / aspell.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2015, 2016 Alex Kost <alezost@gmail.com>
4 ;;;
5 ;;; This file is part of GNU Guix.
6 ;;;
7 ;;; GNU Guix is free software; you can redistribute it and/or modify it
8 ;;; under the terms of the GNU General Public License as published by
9 ;;; the Free Software Foundation; either version 3 of the License, or (at
10 ;;; your option) any later version.
11 ;;;
12 ;;; GNU Guix is distributed in the hope that it will be useful, but
13 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
14 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 ;;; GNU General Public License for more details.
16 ;;;
17 ;;; You should have received a copy of the GNU General Public License
18 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
19
20 (define-module (gnu packages aspell)
21 #:use-module (guix packages)
22 #:use-module (guix download)
23 #:use-module (guix build-system gnu)
24 #:use-module (guix licenses)
25 #:use-module (gnu packages perl)
26 #:use-module (gnu packages base))
27
28 (define-public aspell
29 (package
30 (name "aspell")
31 (version "0.60.6.1")
32 (source
33 (origin
34 (method url-fetch)
35 (uri (string-append "mirror://gnu/aspell/aspell-"
36 version ".tar.gz"))
37 (sha256
38 (base32
39 "1qgn5psfyhbrnap275xjfrzppf5a83fb67gpql0kfqv37al869gm"))))
40 (build-system gnu-build-system)
41 (arguments
42 `(#:phases
43 (modify-phases %standard-phases
44 (add-after 'install 'wrap-aspell
45 (lambda* (#:key outputs #:allow-other-keys)
46 (let ((bin/aspell (string-append (assoc-ref outputs "out")
47 "/bin/aspell")))
48 (wrap-program bin/aspell
49 '("ASPELL_CONF" "" =
50 ("${ASPELL_CONF:-\"dict-dir ${GUIX_PROFILE:-$HOME/.guix-profile}/lib/aspell\"}")))))))))
51 (inputs `(("perl" ,perl)))
52 (home-page "http://aspell.net/")
53 (synopsis "Spell checker")
54 (description
55 "Aspell is a spell-checker which can be used either as a library or as
56 a standalone program. Notable features of Aspell include its full support of
57 documents written in the UTF-8 encoding and its ability to use multiple
58 dictionaries, including personal ones.")
59 (license lgpl2.1+)))
60
61 \f
62 ;;;
63 ;;; Dictionaries.
64 ;;;
65 ;;; Use 'export ASPELL_CONF="dict-dir $HOME/.guix-profile/lib/aspell"' to use them.
66 ;;;
67
68 (define* (aspell-dictionary dict-name full-name
69 #:key version sha256 (prefix "aspell6-"))
70 (package
71 (name (string-append "aspell-dict-" dict-name))
72 (version version)
73 (source (origin
74 (method url-fetch)
75 (uri (string-append "mirror://gnu/aspell/dict/" dict-name
76 "/" prefix dict-name "-"
77 version ".tar.bz2"))
78 (sha256 sha256)))
79 (build-system gnu-build-system)
80 (arguments
81 `(#:phases (alist-replace
82 'configure
83 (lambda* (#:key outputs #:allow-other-keys)
84 (let ((out (assoc-ref outputs "out")))
85 (zero? (system* "./configure"))))
86 %standard-phases)
87 #:make-flags (let ((out (assoc-ref %outputs "out")))
88 (list (string-append "dictdir=" out "/lib/aspell")
89 (string-append "datadir=" out "/lib/aspell")))
90 #:tests? #f))
91 (native-inputs `(("aspell" ,aspell)
92 ("which" ,which)))
93 (synopsis (string-append full-name " dictionary for GNU Aspell")) ; XXX: i18n
94 (description
95 "This package provides a dictionary for the GNU Aspell spell checker.")
96 (license gpl2+)
97 (home-page "http://aspell.net/")))
98
99
100 (define-public aspell-dict-en
101 (aspell-dictionary "en" "English"
102 #:version "2016.01.19-0"
103 #:sha256
104 (base32
105 "01h4cl4lngp6mcfbyb47cjrc2gspyg2519dvknd97ki896nx7vcn")))
106
107 (define-public aspell-dict-eo
108 (aspell-dictionary "eo" "Esperanto"
109 #:version "2.1.20000225a-2"
110 #:sha256
111 (base32
112 "09vf0mbiicbmyb4bwb7v7lgpabnylg0wy7m3hlhl5rjdda6x3lj1")))
113
114 (define-public aspell-dict-es
115 (aspell-dictionary "es" "Spanish"
116 #:version "1.11-2"
117 #:sha256
118 (base32
119 "1k5g328ac1hdpp6fsg57d8md6i0aqcwlszp3gbmp5706wyhpydmd")))
120
121 (define-public aspell-dict-fr
122 (aspell-dictionary "fr" "French"
123 #:version "0.50-3"
124 #:prefix "aspell-"
125 #:sha256
126 (base32
127 "14ffy9mn5jqqpp437kannc3559bfdrpk7r36ljkzjalxa53i0hpr")))
128
129 (define-public aspell-dict-ru
130 (aspell-dictionary "ru" "Russian"
131 #:version "0.99f7-1"
132 #:sha256
133 (base32
134 "0ip6nq43hcr7vvzbv4lwwmlwgfa60hrhsldh9xy3zg2prv6bcaaw")))
135
136 (define-public aspell-dict-it
137 (aspell-dictionary "it" "Italian"
138 #:version "2.2_20050523-0"
139 #:sha256
140 (base32
141 "1gdf7bc1a0kmxsmphdqq8pl01h667mjsj6hihy6kqy14k5qdq69v")))
142
143 (define-public aspell-dict-nl
144 (aspell-dictionary "nl" "Dutch"
145 #:version "0.50-2"
146 #:prefix "aspell-"
147 #:sha256
148 (base32
149 "0ffb87yjsh211hllpc4b9khqqrblial4pzi1h9r3v465z1yhn3j4")))