gnu: emacs-default-encrypt: Update source URI.
[jackhill/guix/guix.git] / gnu / packages / mail.scm
CommitLineData
a661e420 1;;; GNU Guix --- Functional package management for GNU
05aa576b 2;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
ee2b2d2f 3;;; Copyright © 2014, 2015, 2017 Mark H Weaver <mhw@netris.org>
29a7c98a 4;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net>
98e9e22f 5;;; Copyright © 2014 Sou Bunnbu <iyzsong@gmail.com>
f58f767b 6;;; Copyright © 2014 Julien Lepiller <julien@lepiller.eu>
66cc3ab2 7;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
17dd4329 8;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
f6292baf 9;;; Copyright © 2015, 2016 Eric Bavier <bavier@member.fsf.org>
2e88d113 10;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
a047122c 11;;; Copyright © 2015, 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
34dd26af 12;;; Copyright © 2016 Christopher Allan Webber <cwebber@dustycloud.org>
8a75c589 13;;; Copyright © 2016 Al McElrath <hello@yrns.org>
823e2ed4 14;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
e90819c4 15;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org>
99404fff 16;;; Copyright © 2016 Alex Kost <alezost@gmail.com>
a2cb16b0 17;;; Copyright © 2016 Troy Sankey <sankeytms@gmail.com>
b0eb2af2 18;;; Copyright © 2016, 2017 ng0 <contact.ng0@cryptolab.net>
24262239 19;;; Copyright © 2016 Clément Lassieur <clement@lassieur.org>
ed428a58 20;;; Copyright © 2016, 2017 Arun Isaac <arunisaac@systemreboot.net>
5d87088c 21;;; Copyright © 2016 John Darrington <jmd@gnu.org>
7a6213cb 22;;; Copyright © 2016 Marius Bakke <mbakke@fastmail.com>
3e9750c3 23;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
6800c797 24;;; Copyright © 2017 Kyle Meyer <kyle@kyleam.com>
a661e420
LC
25;;;
26;;; This file is part of GNU Guix.
27;;;
28;;; GNU Guix is free software; you can redistribute it and/or modify it
29;;; under the terms of the GNU General Public License as published by
30;;; the Free Software Foundation; either version 3 of the License, or (at
31;;; your option) any later version.
32;;;
33;;; GNU Guix is distributed in the hope that it will be useful, but
34;;; WITHOUT ANY WARRANTY; without even the implied warranty of
35;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
36;;; GNU General Public License for more details.
37;;;
38;;; You should have received a copy of the GNU General Public License
39;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
40
1fdd3ee2 41(define-module (gnu packages mail)
59a43334 42 #:use-module (gnu packages)
b0eb2af2 43 #:use-module (gnu packages aspell)
d983a14f 44 #:use-module (gnu packages autotools)
d2938d59 45 #:use-module (gnu packages base)
e8435c4d 46 #:use-module (gnu packages backup)
ee886454 47 #:use-module (gnu packages bash)
f8ae32a2 48 #:use-module (gnu packages bison)
944a5cdd 49 #:use-module (gnu packages crypto)
f58f767b 50 #:use-module (gnu packages curl)
4fd6bf53 51 #:use-module (gnu packages cyrus-sasl)
81ce19f4 52 #:use-module (gnu packages databases)
d983a14f 53 #:use-module (gnu packages dejagnu)
8a3741e6 54 #:use-module (gnu packages django)
8b53366c 55 #:use-module (gnu packages dns)
7a6213cb 56 #:use-module (gnu packages documentation)
d2938d59 57 #:use-module (gnu packages emacs)
e8435c4d 58 #:use-module (gnu packages enchant)
e8435c4d 59 #:use-module (gnu packages ghostscript)
d2938d59 60 #:use-module (gnu packages glib)
e8435c4d 61 #:use-module (gnu packages gnome)
524e1df6 62 #:use-module (gnu packages gnupg)
152ffe7c 63 #:use-module (gnu packages groff)
d6e941bc 64 #:use-module (gnu packages gsasl)
e8435c4d 65 #:use-module (gnu packages gtk)
1ffa7090 66 #:use-module (gnu packages guile)
f8ae32a2 67 #:use-module (gnu packages flex)
b0eb2af2 68 #:use-module (gnu packages kerberos)
e8435c4d 69 #:use-module (gnu packages libcanberra)
8b53366c 70 #:use-module (gnu packages libevent)
d6e941bc 71 #:use-module (gnu packages libidn)
d983a14f 72 #:use-module (gnu packages linux)
152ffe7c 73 #:use-module (gnu packages lua)
d983a14f 74 #:use-module (gnu packages m4)
1ffa7090 75 #:use-module (gnu packages ncurses)
b0eb2af2 76 #:use-module (gnu packages openldap)
66cc3ab2 77 #:use-module (gnu packages pcre)
13f04f48 78 #:use-module (gnu packages perl)
3919a31a 79 #:use-module (gnu packages python)
1ffa7090 80 #:use-module (gnu packages readline)
d2938d59 81 #:use-module (gnu packages search)
1ffa7090 82 #:use-module (gnu packages texinfo)
681a6588
MW
83 #:use-module (gnu packages compression)
84 #:use-module (gnu packages glib)
85 #:use-module (gnu packages pkg-config)
a7e59c50 86 #:use-module (gnu packages flex)
1bd3f849 87 #:use-module (gnu packages gdb)
6cf27c89 88 #:use-module (gnu packages man)
3e9750c3 89 #:use-module (gnu packages ruby)
1bd3f849 90 #:use-module (gnu packages samba)
6cf27c89 91 #:use-module (gnu packages screen)
b0eb2af2 92 #:use-module (gnu packages tcl)
a7fd7b68 93 #:use-module (gnu packages tls)
be0c5733
DM
94 #:use-module (gnu packages networking)
95 #:use-module (gnu packages web)
f58f767b 96 #:use-module (gnu packages xml)
e8435c4d 97 #:use-module (gnu packages xorg)
7596ddf3 98 #:use-module (gnu packages docbook)
d983a14f 99 #:use-module ((guix licenses)
61c30e9d 100 #:select (gpl2 gpl2+ gpl3 gpl3+ lgpl2.1 lgpl2.1+ lgpl3+
24262239 101 non-copyleft (expat . license:expat) bsd-3
8b53366c 102 public-domain bsd-4 isc (openssl . license:openssl)
b0eb2af2 103 bsd-2 x11-style agpl3 asl2.0))
a661e420
LC
104 #:use-module (guix packages)
105 #:use-module (guix download)
f8ae32a2 106 #:use-module (guix git-download)
29a7c98a 107 #:use-module (guix utils)
681a6588 108 #:use-module (guix build-system gnu)
ebda902f 109 #:use-module (guix build-system perl)
24262239
CL
110 #:use-module (guix build-system python)
111 #:use-module (guix build-system trivial))
a661e420
LC
112
113(define-public mailutils
114 (package
115 (name "mailutils")
7ea52385 116 (version "3.2")
a661e420
LC
117 (source (origin
118 (method url-fetch)
119 (uri (string-append "mirror://gnu/mailutils/mailutils-"
120 version ".tar.bz2"))
121 (sha256
122 (base32
7ea52385 123 "0c06yj5hgqibi24ib9sx865kq6i1h18wn201g6iwcfbpi2a7psdm"))))
a661e420
LC
124 (build-system gnu-build-system)
125 (arguments
de75f0b1
EF
126 '(#:phases
127 (modify-phases %standard-phases
128 (add-before 'build 'pre-build
129 (lambda _
130 ;; Use the right file name for `cat'.
131 (substitute* "testsuite/lib/mailutils.exp"
132 (("/bin/cat")
133 (which "cat")))
14253017 134
de75f0b1
EF
135 ;; Tests try to invoke 'maidag' such that it looks up the
136 ;; 'root' user, which does not exist in the build
137 ;; environment.
138 (substitute* "maidag/tests/testsuite"
139 (("root <") "nobody <")
140 (("spool/root") "spool/nobody")
141 (("root@localhost") "nobody@localhost"))
14253017 142
de75f0b1
EF
143 ;; The 'pipeact.at' tests generate a shell script; make
144 ;; sure it uses the right shell.
145 (substitute* '("sieve/tests/testsuite"
146 "mh/tests/testsuite")
147 (("#! /bin/sh")
148 (string-append "#!" (which "sh"))))
14253017 149
de75f0b1
EF
150 (substitute* "mh/tests/testsuite"
151 (("moreproc: /bin/cat")
152 (string-append "moreproc: " (which "cat"))))
14253017 153
de75f0b1
EF
154 ;; XXX: The comsatd tests rely on being able to open
155 ;; /dev/tty, but that gives ENODEV in the build
156 ;; environment. Thus, ignore test failures here.
157 (substitute* "comsat/tests/Makefile.in"
158 (("\\$\\(SHELL\\) \\$\\(TESTSUITE\\)" all)
159 (string-append "-" all)))
14253017 160
de75f0b1
EF
161 #t)))
162 ;; TODO: Add `--with-sql'.
abe5d2dc 163 #:configure-flags '("--sysconfdir=/etc")
a661e420
LC
164 #:parallel-tests? #f))
165 (inputs
166 `(("dejagnu" ,dejagnu)
167 ("m4" ,m4)
168 ("texinfo" ,texinfo)
169 ("guile" ,guile-2.0)
170 ("gnutls" ,gnutls)
171 ("ncurses" ,ncurses)
abe5d2dc 172 ("readline" ,readline)
a661e420 173 ("linux-pam" ,linux-pam)
3246cc91 174 ("libltdl" ,libltdl)
01eafd38 175 ("gdbm" ,gdbm)))
6fd52309 176 (home-page "https://mailutils.org")
f50d2669 177 (synopsis "Utilities and library for reading and serving mail")
a661e420 178 (description
79c311b8
LC
179 "GNU Mailutils is a collection of programs for managing, viewing and
180processing electronic mail. It contains both utilities and server daemons
181and all operate in a protocol-agnostic way. The underlying libraries are
182also available, simplifying the addition of mail capabilities to new
183software.")
a661e420
LC
184 (license
185 ;; Libraries are under LGPLv3+, and programs under GPLv3+.
186 (list gpl3+ lgpl3+))))
d983a14f
AE
187
188(define-public fetchmail
189 (package
190 (name "fetchmail")
191 (version "6.3.26")
192 (source (origin
193 (method url-fetch)
194 (uri (string-append "mirror://sourceforge/fetchmail/branch_6.3/fetchmail-"
195 version ".tar.xz"))
196 (sha256
197 (base32
198 "0l78ayvi9dm8hd190gl139cs2xqsrf7r9ncilslw20mgvd6cbd3r"))))
199 (build-system gnu-build-system)
200 (inputs
201 `(("openssl" ,openssl)))
202 (arguments
203 `(#:configure-flags (list (string-append "--with-ssl="
204 (assoc-ref %build-inputs "openssl")))))
07af3e5e 205 (home-page "http://www.fetchmail.info/")
ae2189a9 206 (synopsis "Remote-mail retrieval and forwarding utility")
d983a14f
AE
207 (description
208 "Fetchmail is a full-featured, robust, well-documented remote-mail
209retrieval and forwarding utility intended to be used over on-demand
210TCP/IP links (such as SLIP or PPP connections). It supports every
211remote-mail protocol now in use on the Internet: POP2, POP3, RPOP, APOP,
212KPOP, all flavors of IMAP, ETRN, and ODMR. It can even support IPv6
213and IPSEC.
214
215Fetchmail retrieves mail from remote mail servers and forwards it via SMTP,
216so it can then be read by normal mail user agents such as mutt, elm
217or BSD Mail. It allows all your system MTA's filtering, forwarding, and
218aliasing facilities to work just as they would on normal mail.")
219 (license gpl2+))) ; most files are actually public domain or x11
13f04f48
AE
220
221(define-public mutt
222 (package
223 (name "mutt")
a047122c 224 (version "1.8.0")
13f04f48
AE
225 (source (origin
226 (method url-fetch)
d82633d0
AE
227 (uri (string-append "ftp://ftp.mutt.org/pub/mutt/mutt-"
228 version ".tar.gz"))
13f04f48
AE
229 (sha256
230 (base32
a047122c 231 "1axdcylyv0p194y6lj1jx127g5yc74zqzzxdc014cjw02bd1x125"))
fc1adab1 232 (patches (search-patches "mutt-store-references.patch"))))
13f04f48
AE
233 (build-system gnu-build-system)
234 (inputs
4fd6bf53 235 `(("cyrus-sasl" ,cyrus-sasl)
b0bb0136 236 ("gdbm" ,gdbm)
524e1df6 237 ("gpgme" ,gpgme)
4fd6bf53 238 ("ncurses" ,ncurses)
13f04f48
AE
239 ("openssl" ,openssl)
240 ("perl" ,perl)))
241 (arguments
242 `(#:configure-flags '("--enable-smtp"
243 "--enable-imap"
244 "--enable-pop"
524e1df6 245 "--enable-gpgme"
b0bb0136 246 "--enable-hcache" ; for header caching
0323fe80 247 "--enable-sidebar"
13f04f48 248 "--with-ssl"
4fd6bf53 249 "--with-sasl"
13f04f48
AE
250 ;; so that mutt does not check whether the path
251 ;; exists, which it does not in the chroot
252 "--with-mailpath=/var/mail")))
253 (home-page "http://www.mutt.org/")
254 (synopsis "Mail client")
255 (description
256 "Mutt is a small but very powerful text-based mail client for Unix
257operating systems.")
258 (license gpl2+)))
681a6588 259
7596ddf3 260(define-public neomutt
261 (package
262 (inherit mutt)
263 (name "neomutt")
469609a9 264 (version "20170306")
7596ddf3 265 (source
266 (origin
267 (method url-fetch)
268 (uri (string-append "https://github.com/" name "/" name
269 "/archive/" name "-" version ".tar.gz"))
270 (file-name (string-append name "-" version ".tar.gz"))
271 (sha256
272 (base32
469609a9 273 "0qwcbjm9j1hgzmybw15w53pvfbqcdf47d4sw21s6r2yaj8kx1hag"))))
7596ddf3 274 (inputs
275 `(("cyrus-sasl" ,cyrus-sasl)
276 ("gdbm" ,gdbm)
277 ("gpgme" ,gpgme)
278 ("ncurses" ,ncurses)
279 ("gnutls" ,gnutls)
280 ("openssl" ,openssl) ;For smime
281 ("perl" ,perl)
5c95465e 282 ("kyotocabinet" ,kyotocabinet)
7596ddf3 283 ("libxslt" ,libxslt)
284 ("libidn" ,libidn)
285 ("libxml2" ,libxml2)
5c95465e 286 ("lmdb" ,lmdb)
7596ddf3 287 ("docbook-xsl" ,docbook-xsl)
288 ("notmuch" ,notmuch)))
289 (native-inputs
290 `(("autoconf" ,autoconf)
291 ("automake" ,automake)
292 ("pkg-config" ,pkg-config)))
293 (arguments
294 `(#:configure-flags
295 (list "--enable-smtp"
296 "--enable-imap"
297 "--enable-pop"
298 "--enable-gpgme"
299
300 ;; database, implies header caching
91c87241 301 "--without-tokyocabinet"
7596ddf3 302 "--without-qdbm"
303 "--without-bdb"
5c95465e 304 "--with-lmdb"
305 (string-append "--with-kyotocabinet="
306 (assoc-ref %build-inputs "kyotocabinet"))
7596ddf3 307 "--with-gdbm"
308
309 "--with-gnutls"
310 "--without-ssl"
311 "--with-sasl"
312
313 "--with-regex"
314 "--enable-smime"
315 "--enable-notmuch"
316 "--with-idn"
317
318 ;; If we do not set this, neomutt wants to check
319 ;; whether the path exists, which it does not
320 ;; in the chroot. The workaround is this.
321 "--with-mailpath=/var/mail"
322
323 "--with-external-dotlock"
324 "--enable-nntp"
325 "--enable-compressed"
326
327 (string-append "--with-curses="
328 (assoc-ref %build-inputs "ncurses")))
329 #:phases
330 (modify-phases %standard-phases
331 (add-after 'unpack 'autoconf
332 (lambda _
333 (zero? (system* "sh" "autoreconf" "-vfi")))))))
334 (home-page "https://www.neomutt.org/")
335 (synopsis "Command-line mail reader based on Mutt")
336 (description
337 "NeoMutt is a command-line mail reader which is based on mutt.
338It adds a large amount of features to mutt, and they all find their way
339into mutt, so it is not a fork but a large set of feature patches.")))
340
681a6588
MW
341(define-public gmime
342 (package
343 (name "gmime")
5ecd6717 344 (version "2.6.23")
681a6588
MW
345 (source (origin
346 (method url-fetch)
75630043 347 (uri (string-append "mirror://gnome/sources/gmime/"
29a7c98a 348 (version-major+minor version)
681a6588
MW
349 "/gmime-" version ".tar.xz"))
350 (sha256
351 (base32
5ecd6717 352 "0slzlzcr3h8jikpz5a5amqd0csqh2m40gdk910ws2hnaf5m6hjbi"))))
681a6588
MW
353 (build-system gnu-build-system)
354 (native-inputs
355 `(("pkg-config" ,pkg-config)
356 ("gnupg" ,gnupg))) ; for tests only
357 (inputs `(("glib" ,glib)
358 ("gpgme" ,gpgme)
359 ("zlib" ,zlib)))
360 (arguments
361 `(#:phases
cc955356
EF
362 (modify-phases %standard-phases
363 (add-after
364 'unpack 'patch-paths-in-tests
365 (lambda _
366 ;; The test programs run several programs using 'system' with
ae83dcf6 367 ;; hard-coded paths. Here we patch them all.
368 ;; We use ISO-8859-1 here because test-iconv.c contains
cc955356
EF
369 ;; raw byte sequences in several different encodings.
370 (with-fluids ((%default-port-encoding #f))
371 (substitute* (find-files "tests" "\\.c$")
372 (("(system *\\(\")(/[^ ]*)" all pre prog-path)
373 (let* ((base (basename prog-path))
ae83dcf6 374 (prog (which base)))
cc955356
EF
375 (string-append pre
376 (or prog (error "not found: " base))))))))))))
681a6588
MW
377 (home-page "http://spruce.sourceforge.net/gmime/")
378 (synopsis "MIME message parser and creator library")
379 (description
380 "GMime provides a core library and set of utilities which may be used for
381the creation and parsing of messages using the Multipurpose Internet Mail
382Extension (MIME).")
383 (license (list lgpl2.1+ gpl2+ gpl3+))))
384
a7e59c50
LC
385(define-public bogofilter
386 (package
387 (name "bogofilter")
388 (version "1.2.4")
389 (source (origin
390 (method url-fetch)
391 (uri (string-append "mirror://sourceforge/bogofilter/bogofilter-"
392 version "/bogofilter-"
393 version ".tar.bz2"))
394 (sha256
395 (base32
396 "1d56n2m9inm8gnzm88aa27xl2a7sp7aff3484vmflpqkinjqf0p1"))))
397 (build-system gnu-build-system)
398 (arguments
c55fa42b
EF
399 '(#:phases
400 (modify-phases %standard-phases
401 (add-before 'check 'pre-check
402 (lambda _
403 (substitute* "src/tests/t.frame"
404 (("GREP=/bin/grep")
405 (string-append "GREP=" (which "grep") "\n")))
406 #t)))))
a7e59c50
LC
407 (native-inputs `(("flex" ,flex)))
408 (inputs `(("bdb" ,bdb)))
409 (home-page "http://bogofilter.sourceforge.net/")
410 (synopsis "Mail classifier based on a Bayesian filter")
411 (description
412 "Bogofilter is a mail filter that classifies mail as spam or ham
413 (non-spam) by a statistical analysis of the message's header and
414content (body). The program is able to learn from the user's classifications
415and corrections. It is based on a Bayesian filter.")
416 (license gpl2)))
417
3919a31a
EB
418(define-public offlineimap
419 (package
420 (name "offlineimap")
301f12ec 421 (version "7.0.14")
3919a31a
EB
422 (source (origin
423 (method url-fetch)
424 (uri (string-append "https://github.com/OfflineIMAP/offlineimap/"
425 "archive/v" version ".tar.gz"))
f586c877 426 (file-name (string-append name "-" version ".tar.gz"))
3919a31a
EB
427 (sha256
428 (base32
301f12ec 429 "0i5dvygps1ai2qwgamab8kngrp0c5m3bgaw0jk34l8ypsk54wj8r"))))
3919a31a 430 (build-system python-build-system)
7a6213cb 431 (native-inputs
4b0e6367 432 `(("asciidoc" ,asciidoc)))
a4ea25d3
EF
433 (inputs `(("python2-pysqlite" ,python2-pysqlite)
434 ("python2-six" ,python2-six)))
3919a31a
EB
435 (arguments
436 ;; The setup.py script expects python-2.
437 `(#:python ,python-2
438 ;; Tests require a modifiable IMAP account.
42aa73b3
EF
439 #:tests? #f
440 #:phases
441 (modify-phases %standard-phases
7a6213cb
MB
442 (add-after 'build 'build-documentation
443 (lambda _
444 (substitute* "docs/Makefile"
445 ;; Prevent xmllint and xsltproc from downloading a DTD file.
446 (("a2x -v") "a2x --no-xmllint --xsltproc-opts=--nonet -v"))
447 (zero? (system* "make" "-C" "docs" "man"))))
448 (add-after 'install 'install-documentation
449 (lambda* (#:key outputs #:allow-other-keys)
450 (let* ((out (assoc-ref outputs "out"))
451 (man (string-append out "/share/man")))
452 (install-file "docs/offlineimap.1" (string-append man "/man1"))
453 (install-file "docs/offlineimapui.7" (string-append man "/man7"))
454 #t)))
455 (add-after 'install-documentation 'wrap-binary
456 (lambda* (#:key outputs #:allow-other-keys)
42aa73b3
EF
457 (let* ((out (assoc-ref outputs "out"))
458 (bin (string-append out "/bin/offlineimap")))
459 (wrap-program bin
460 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH"))))
461 #t))))))
3919a31a 462 (home-page "http://www.offlineimap.org")
31e98ca6 463 (synopsis "Sync emails between two repositories")
3919a31a
EB
464 (description
465 "OfflineImap synchronizes emails between two repositories, so that you
466can read the same mailbox from multiple computers. It supports IMAP as REMOTE
467repository and Maildir/IMAP as LOCAL repository.")
7886e23b 468 (license gpl2+)))
3919a31a 469
3e9750c3
TD
470(define-public emacs-mew
471 (package
472 (name "emacs-mew")
473 (version "6.7")
474 (source (origin
475 (method url-fetch)
476 (uri (string-append "http://mew.org/Release/mew-"
477 version ".tar.gz"))
478 (sha256
479 (base32
480 "03fzky2kz73vgx4cbps2psbbnrgqgkk5q7jwfldisymkzr9iz03y"))))
481 (native-inputs
482 `(("emacs" ,emacs)))
483 (propagated-inputs
484 `(("ruby-sqlite3" ,ruby-sqlite3) ; optional for the database of messages
485 ("ruby" ,ruby))) ; to set GEM_PATH so ruby-sqlite3 is found at runtime
486 (build-system gnu-build-system)
487 (arguments
488 (let ((elisp-dir "/share/emacs/site-lisp/guix.d/mew")
489 (icon-dir "/share/mew"))
490 `(#:modules ((guix build gnu-build-system)
491 (guix build utils)
492 (guix build emacs-utils))
493 #:imported-modules (,@%gnu-build-system-modules
494 (guix build emacs-utils))
495 #:configure-flags
496 (list (string-append "--with-elispdir=" %output ,elisp-dir)
497 (string-append "--with-etcdir=" %output ,icon-dir))
498 #:phases
499 (modify-phases %standard-phases
500 (add-after 'configure 'patch-mew-icon-directory
501 (lambda* (#:key outputs #:allow-other-keys)
502 (emacs-substitute-sexps "mew-key.el"
503 ("(def.* mew-icon-directory"
504 `(progn
505 (add-to-list 'image-load-path 'mew-icon-directory)
506 ,(string-append (assoc-ref outputs "out") ,icon-dir))))
507 #t))
508 (add-after 'install 'generate-autoloads
509 (lambda* (#:key outputs #:allow-other-keys)
510 (emacs-generate-autoloads
511 "mew" (string-append (assoc-ref outputs "out") ,elisp-dir))
512 #t)))
513 #:tests? #f)))
514 (home-page "http://www.mew.org")
515 (synopsis "Emacs e-mail client")
516 (description "Mew (Messaging in the Emacs World) is a user interface
517for text messages, multimedia messages (MIME), news articles and
518security functionality including PGP, S/MIME, SSH, and SSL.")
519 (license bsd-3)))
520
d2938d59
EB
521(define-public mu
522 (package
523 (name "mu")
e7b9da24 524 (version "0.9.18")
d2938d59
EB
525 (source (origin
526 (method url-fetch)
e7b9da24
RW
527 (uri (string-append "https://github.com/djcb/mu/releases/"
528 "download/" version "/mu-"
d2938d59
EB
529 version ".tar.gz"))
530 (sha256
531 (base32
e7b9da24 532 "02g82zvxfgn17wzy846bfxj0izjj7yklhwdnhwxy1y2kin4fqnb5"))))
d2938d59
EB
533 (build-system gnu-build-system)
534 (native-inputs
535 `(("pkg-config" ,pkg-config)
9fd571a2 536 ("glib" ,glib "bin") ; for gtester
e62e975b 537 ("emacs" ,emacs-minimal)))
d2938d59
EB
538 ;; TODO: Add webkit and gtk to build the mug GUI.
539 (inputs
540 `(("xapian" ,xapian)
d2938d59
EB
541 ("guile" ,guile-2.0)
542 ("glib" ,glib)
543 ("gmime" ,gmime)
544 ("tzdata" ,tzdata))) ;for mu/test/test-mu-query.c
545 (arguments
704f2196
AK
546 `(#:modules ((guix build gnu-build-system)
547 (guix build utils)
548 (guix build emacs-utils))
549 #:imported-modules (,@%gnu-build-system-modules
550 (guix build emacs-utils))
551 #:phases
99404fff 552 (modify-phases %standard-phases
e62e975b 553 (add-after 'unpack 'patch-configure
789bda83
AK
554 ;; By default, elisp code goes to "share/emacs/site-lisp/mu4e",
555 ;; so our Emacs package can't find it. Setting "--with-lispdir"
556 ;; configure flag doesn't help because "mu4e" will be added to
557 ;; the lispdir anyway, so we have to modify "configure.ac".
558 (lambda _
e62e975b
RW
559 (substitute* "configure"
560 (("^ +lispdir=\"\\$\\{lispdir\\}/mu4e/\".*") ""))
789bda83 561 #t))
99404fff
AK
562 (add-before 'check 'check-tz-setup
563 (lambda* (#:key inputs #:allow-other-keys)
564 ;; For mu/test/test-mu-query.c
565 (setenv "TZDIR"
566 (string-append (assoc-ref inputs "tzdata")
567 "/share/zoneinfo"))
704f2196
AK
568 #t))
569 (add-after 'install 'install-emacs-autoloads
570 (lambda* (#:key outputs #:allow-other-keys)
571 (emacs-generate-autoloads
572 "mu4e"
573 (string-append (assoc-ref outputs "out")
574 "/share/emacs/site-lisp"))
99404fff 575 #t)))))
d2938d59
EB
576 (home-page "http://www.djcbsoftware.nl/code/mu/")
577 (synopsis "Quickly find emails")
578 (description
579 "Mu is a tool for dealing with e-mail messages stored in the
580Maildir-format. Mu's purpose in life is to help you to quickly find the
581messages you need; in addition, it allows you to view messages, extract
582attachments, create new maildirs, and so on.")
583 (license gpl3+)))
584
a2cb16b0
TS
585(define-public alot
586 (package
587 (name "alot")
fe3b8862 588 (version "0.4")
a2cb16b0
TS
589 (source (origin
590 (method url-fetch)
1b94f182
TS
591 ;; package author intends on distributing via github rather
592 ;; than pypi:
593 ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331
a2cb16b0
TS
594 (uri (string-append "https://github.com/pazz/alot/archive/"
595 version ".tar.gz"))
596 (file-name (string-append "alot-" version ".tar.gz"))
597 (sha256
598 (base32
fe3b8862 599 "0sl1kl2fhkv208llnbny4blcvrfdk4vx6bcw5pnyh9ylwb0pipi2"))))
a2cb16b0
TS
600 (build-system python-build-system)
601 (arguments
602 `(#:tests? #f ; no tests
fe3b8862
MB
603 ;; python 3 is currently unsupported, more info:
604 ;; https://github.com/pazz/alot/blob/master/docs/source/faq.rst
a2cb16b0
TS
605 #:python ,python-2))
606 (inputs
607 `(("python2-magic" ,python2-magic)
608 ("python2-configobj" ,python2-configobj)
609 ("python2-twisted" ,python2-twisted)
610 ("python2-urwid" ,python2-urwid)
611 ("python2-urwidtrees" ,python2-urwidtrees)
612 ("python2-pygpgme" ,python2-pygpgme)
613 ("python2-notmuch" ,python2-notmuch)))
614 (home-page "https://github.com/pazz/alot")
615 (synopsis "Commandline MUA using notmuch")
616 (description
617 "Alot is an experimental terminal mail user agent (MUA) based on
618@code{notmuch} mail. It is written in Python using the @code{urwid} toolkit.")
619 (license gpl3+)))
620
0350a8bb
HG
621(define-public notifymuch
622 (let
623 ((commit "9d4aaf54599282ce80643b38195ff501120807f0")
624 (revision "1"))
625 (package
626 (name "notifymuch")
627 (version (string-append "0.1-" revision "." (string-take commit 7)))
628 (source
629 (origin
630 (method git-fetch)
631 (uri (git-reference
632 (url "https://github.com/kspi/notifymuch.git")
633 (commit commit)))
634 (sha256
635 (base32
636 "1lssr7iv43mp5v6nzrfbqlfzx8jcc7m636wlfyhhnd8ydd39n6k4"))
637 (file-name (string-append name "-" version "-checkout"))))
638 (build-system python-build-system)
639 (inputs
640 `(("python-notmuch" ,python-notmuch)
641 ("python-pygobject" ,python-pygobject)
642 ("gobject-introspection" ,gobject-introspection)
643 ("libnotify" ,libnotify)
644 ("gtk+" ,gtk+)))
645 (arguments
646 `(#:phases
647 (modify-phases %standard-phases
648 (add-after 'install 'wrap-binary
649 (lambda* (#:key outputs #:allow-other-keys)
650 (let* ((out (assoc-ref outputs "out"))
651 (bin (string-append out "/bin/notifymuch")))
652 (wrap-program bin
653 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH")))
654 `("GI_TYPELIB_PATH" ":" prefix
655 (,(getenv "GI_TYPELIB_PATH")
656 ,(string-append out "/lib/girepository-1.0")))))
657 #t)))))
658 (home-page "https://github.com/kspi/notifymuch")
659 (synopsis "Displays notifications for changes in the notmuch email database")
660 (description "notifymuch displays desktop notifications for messages in
661the notmuch database. The notifications are sent using libnotify to a
662notification daemon. The query to find messages to send a notification about
663is configurable, and a notification for the same message will not be send
664within a configurable period (defaults to 48 hours). To use notifymuch, run
665@command{notifymuch} after new mail is indexed, this can be automated by
666invoking @command{notifymuch} from the post-new hook.")
667 (license gpl3))))
668
1bd3f849
DT
669(define-public notmuch
670 (package
671 (name "notmuch")
6800c797 672 (version "0.24.1")
1bd3f849
DT
673 (source (origin
674 (method url-fetch)
866fade9 675 (uri (string-append "https://notmuchmail.org/releases/notmuch-"
1bd3f849
DT
676 version ".tar.gz"))
677 (sha256
678 (base32
6800c797 679 "18rw0rim6zxhnr2nggial029x4raaxqcgf9klfbdhv89qvi7s4gs"))))
1bd3f849
DT
680 (build-system gnu-build-system)
681 (arguments
6cf27c89 682 '(#:make-flags (list "V=1") ; Verbose test output.
eb537f57 683 #:phases (modify-phases %standard-phases
6cf27c89
MB
684 (add-after 'unpack 'patch-notmuch-lib.el
685 (lambda _
686 (substitute* "emacs/notmuch-lib.el"
687 (("/bin/sh") (which "sh")))
688 #t))
eb537f57
DT
689 (replace 'configure
690 (lambda* (#:key outputs #:allow-other-keys)
691 (setenv "CC" "gcc")
692 (setenv "CONFIG_SHELL" (which "sh"))
ee886454 693
eb537f57
DT
694 (let ((out (assoc-ref outputs "out")))
695 (zero? (system* "./configure"
6cf27c89
MB
696 (string-append "--prefix=" out))))))
697 (add-before 'check 'prepare-test-environment
698 (lambda _
699 (setenv "TEST_CC" "gcc")
700 ;; Patch various inline shell invocations.
701 (substitute* (find-files "test" "\\.sh$")
702 (("/bin/sh") (which "sh")))
703 #t)))))
1bd3f849 704 (native-inputs
2c5b91dc 705 `(("bash-completion" ,bash-completion)
6cf27c89 706 ("emacs" ,emacs-no-x) ; Minimal lacks libxml, needed for some tests.
2c5b91dc 707 ("pkg-config" ,pkg-config)
ee886454 708 ("python" ,python-2)
eb537f57 709 ("python-docutils" ,python2-docutils)
6cf27c89
MB
710 ("python-sphinx" ,python2-sphinx)
711
712 ;; The following are required for tests only.
713 ("which" ,which)
714 ("dtach" ,dtach)
715 ("gnupg" ,gnupg)
716 ("man" ,man-db)
717 ("perl" ,perl)))
1bd3f849 718 (inputs
2c5b91dc 719 `(("glib" ,glib)
1bd3f849
DT
720 ("gmime" ,gmime)
721 ("talloc" ,talloc)
722 ("xapian" ,xapian)
723 ("zlib" ,zlib)))
540d6cc7 724 (home-page "https://notmuchmail.org/")
1bd3f849
DT
725 (synopsis "Thread-based email index, search, and tagging")
726 (description
727 "Notmuch is a command-line based program for indexing, searching, read-
728ing, and tagging large collections of email messages.")
729 (license gpl3+)))
730
8a75c589
AM
731(define-public notmuch-addrlookup-c
732 (package
733 (name "notmuch-addrlookup-c")
734 (version "7")
735 (source (origin
736 (method url-fetch)
737 (uri (string-append
738 "https://github.com/aperezdc/" name "/archive/v"
739 version ".tar.gz"))
740 (file-name (string-append name "-" version ".tar.gz"))
741 (sha256
742 (base32
743 "0rslg2ifgyhl6asv3yr1f62m9xjfcinv7i6qb07h2k217jqlmrri"))))
744 (build-system gnu-build-system)
745 (arguments
746 '(#:tests? #f ; no tests
747 #:make-flags (list "CC=gcc"
748 (string-append "PREFIX="
749 (assoc-ref %outputs "out")))
750 #:phases (modify-phases %standard-phases
751 (delete 'configure)
752 ;; Remove vim code completion config, it's not needed to
753 ;; build (or be patched).
754 (add-before 'patch-source-shebangs 'delete-ycm-file
755 (lambda _ (delete-file ".ycm_extra_conf.py")))
756 (replace 'install
757 (lambda* (#:key outputs #:allow-other-keys)
758 (let ((bin (string-append
759 (assoc-ref outputs "out") "/bin")))
760 (install-file "notmuch-addrlookup" bin)))))))
761 (native-inputs
762 `(("pkg-config" ,pkg-config)))
763 (inputs
764 `(("glib" ,glib)
765 ("notmuch" ,notmuch)))
766 (home-page "https://github.com/aperezdc/notmuch-addrlookup-c")
767 (synopsis "Address lookup tool for Notmuch")
768 (description "This is an address lookup tool using a Notmuch database,
769useful for email address completion.")
770 (license license:expat)))
771
4b6909bc
TS
772(define-public python-notmuch
773 (package
774 (name "python-notmuch")
540d6cc7 775 (version (package-version notmuch))
4b6909bc
TS
776 ;; Notmuch python bindings are now unavailable on pypi. The
777 ;; bindings are distributed via the notmuch release tarball.
778 (source (package-source notmuch))
779 (build-system python-build-system)
780 (inputs `(("notmuch" ,notmuch)))
781 (arguments
782 `(#:tests? #f ; no "test" target
783 #:phases
784 (modify-phases %standard-phases
785 ;; This python package lives in a subdirectory of the notmuch source
786 ;; tree, so chdir into it before building.
787 (add-after 'unpack 'enter-python-dir
788 (lambda _ (chdir "bindings/python") #t))
789 ;; Make sure the correct notmuch shared library gets loaded.
790 (add-before 'build 'set-libnotmuch-file-name
791 (lambda* (#:key inputs #:allow-other-keys)
792 (let ((notmuch (assoc-ref inputs "notmuch")))
793 (substitute* "notmuch/globals.py"
794 (("libnotmuch\\.so\\.")
795 (string-append notmuch "/lib/libnotmuch.so.")))
796 #t))))))
540d6cc7 797 (home-page (package-home-page notmuch))
4b6909bc
TS
798 (synopsis "Python bindings of the Notmuch mail indexing library")
799 (description
800 "This package provides Python bindings to use the Notmuch mail indexing
801and search library.")
802 (license gpl3+)))
803
1c74da21 804(define-public python2-notmuch
caa6fc89 805 (package-with-python2 python-notmuch))
1c74da21 806
98e9e22f
SB
807(define-public getmail
808 (package
809 (name "getmail")
837ca0f0 810 (version "4.52.0")
98e9e22f
SB
811 (source
812 (origin
813 (method url-fetch)
814 (uri (string-append "http://pyropus.ca/software/getmail/old-versions/"
815 name "-" version ".tar.gz"))
816 (sha256
817 (base32
837ca0f0 818 "0pzplrlxwbxydvfw4kkwn60l40hk1h5sxawaa6pi0k75c220k4ni"))))
98e9e22f
SB
819 (build-system python-build-system)
820 (arguments
821 `(#:tests? #f ; no tests
822 #:python ,python-2))
823 (home-page "http://pyropus.ca/software/getmail/")
824 (synopsis "Mail retriever")
825 (description
826 "A flexible, extensible mail retrieval system with support for
827POP3, IMAP4, SSL variants of both, maildirs, mboxrd files, external MDAs,
828arbitrary message filtering, single-user and domain-mailboxes, and many other
829useful features.")
830
831 ;; License is specified in file '__init__.py'.
832 (license gpl2)))
833
f58f767b
JL
834(define-public libetpan
835 (package
836 (name "libetpan")
c1748912 837 (version "1.7.2")
f58f767b
JL
838 (source (origin
839 (method url-fetch)
840 (uri (string-append "https://github.com/dinhviethoa/" name
841 "/archive/" version ".tar.gz"))
f586c877 842 (file-name (string-append name "-" version ".tar.gz"))
f58f767b 843 (sha256
c1748912 844 (base32 "081ixgj3skglq9i7v0jb835lmfx21zi4i5b7997igwr0lj174y9j"))))
f58f767b
JL
845 (build-system gnu-build-system)
846 (native-inputs `(("autoconf" ,(autoconf-wrapper))
847 ("automake" ,automake)
3246cc91 848 ("libtool" ,libtool)
f58f767b
JL
849 ("pkg-config" ,pkg-config)))
850 (propagated-inputs
851 ;; 'libetpan-config --libs' returns '-lssl -lcrypto -lsasl2', so these
852 ;; libraries need to be propagated.
853 `(("cyrus-sasl" ,cyrus-sasl)
854 ("openssl" ,openssl)))
855 (inputs
856 `(("curl" ,curl)
c1748912
EF
857 ("expat" ,expat)
858 ("zlib" ,zlib)))
f58f767b 859 (arguments
602460ea
EF
860 '(#:phases
861 (modify-phases %standard-phases
862 (add-after 'unpack 'autogen
863 (lambda _
864 (setenv "NOCONFIGURE" "true")
865 (zero? (system* "sh" "autogen.sh")))))
f58f767b
JL
866 #:configure-flags
867 '("--disable-static" "--disable-db")))
868 (home-page "http://www.etpan.org/libetpan.html")
869 (synopsis "Portable middleware for email access")
870 (description
871 "The purpose of this mail library is to provide a portable, efficient
872framework for different kinds of mail access: IMAP, SMTP, POP and NNTP. It
873provides an API for C language. It's the low-level API used by MailCore and
874MailCore 2.")
166191b3 875 (license (non-copyleft "file://COPYING"))))
f58f767b 876
ee6e780b
DM
877(define-public compface
878 (package
879 (name "compface")
880 (version "1.5.2")
881 (source (origin
882 (method url-fetch)
883 (uri (string-append "https://ftp.heanet.ie/mirrors/"
884 "ftp.xemacs.org/aux/"
885 name "-" version ".tar.gz"))
886 (sha256
887 (base32
888 "09b89wg63hg502hsz592cd2h87wdprb1dq1k1y07n89hym2q56d6"))))
889 (build-system gnu-build-system)
890 (arguments
891 `(#:tests? #f))
892 (synopsis "Portrait image compressor")
893 (description "This packages takes your 48x48x1 portrait image and
894compresses it.")
895 (home-page "http://www.cs.indiana.edu/pub/faces/")
896 (license (x11-style "file://README"))))
897
e8435c4d
JL
898(define-public claws-mail
899 (package
900 (name "claws-mail")
20413597 901 (version "3.15.0")
e8435c4d
JL
902 (source (origin
903 (method url-fetch)
904 (uri (string-append
762b1971 905 "http://www.claws-mail.org/releases/" name "-" version
6ea4b094 906 ".tar.xz"))
e8435c4d 907 (sha256
ec92806a 908 (base32
20413597 909 "0bnwd3l04y6j1nw3h861rdy6k6lyjzsi51j04d33vbpq8c6jskaf"))))
e8435c4d
JL
910 (build-system gnu-build-system)
911 (native-inputs `(("pkg-config" ,pkg-config)))
912 (inputs `(("bogofilter" ,bogofilter)
913 ("curl" ,curl)
914 ("dbus-glib" ,dbus-glib)
e8435c4d
JL
915 ("enchant" ,enchant)
916 ("expat" ,expat)
917 ("ghostscript" ,ghostscript)
918 ("hicolor-icon-theme" ,hicolor-icon-theme)
919 ("gnupg" ,gnupg)
920 ("gnutls" ,gnutls)
921 ("gpgme" ,gpgme)
922 ("gtk" ,gtk+-2)
923 ("libarchive" ,libarchive)
924 ("libcanberra" ,libcanberra)
925 ("libetpan" ,libetpan)
926 ("libnotify" ,libnotify)
927 ("libsm" ,libsm)
928 ("libxml2" ,libxml2)
929 ("perl" ,perl)
f6292baf
EB
930 ("python-2" ,python-2)
931 ("mime-info" ,shared-mime-info)))
e8435c4d
JL
932 (arguments
933 '(#:configure-flags
f6292baf
EB
934 '("--enable-gnutls" "--enable-pgpmime-plugin" "--enable-enchant")
935 #:phases (modify-phases %standard-phases
936 (add-before 'build 'patch-mime
937 (lambda* (#:key inputs #:allow-other-keys)
938 (substitute* "src/procmime.c"
939 (("/usr/share/mime/globs")
940 (string-append (assoc-ref inputs "mime-info")
941 "/share/mime/globs"))))))))
e8435c4d
JL
942 (synopsis "GTK-based Email client")
943 (description
944 "Claws-Mail is an email client (and news reader) based on GTK+. The
945appearance and interface are designed to be familiar to new users coming from
946other popular email clients, as well as experienced users. Almost all commands
947are accessible with the keyboard. Plus, Claws-Mail is extensible via addons
948which can add many functionalities to the base client.")
949 (home-page "http://www.claws-mail.org/")
950 (license gpl3+))) ; most files are actually public domain or x11
951
d6e941bc
952(define-public msmtp
953 (package
954 (name "msmtp")
899358d1 955 (version "1.6.6")
d6e941bc
956 (source
957 (origin
958 (method url-fetch)
d23d1ddf
LF
959 (uri (string-append "mirror://sourceforge/msmtp/msmtp/" version
960 "/msmtp-" version ".tar.xz"))
961 (sha256
962 (base32
899358d1 963 "0ppvww0sb09bnsrpqnvlrn8vx231r24xn2iiwpy020mxc8gxn5fs"))))
d6e941bc
964 (build-system gnu-build-system)
965 (inputs
966 `(("libidn" ,libidn)
72d8b5ba 967 ("libsecret" ,libsecret)
d6e941bc
968 ("gnutls" ,gnutls)
969 ("zlib" ,zlib)
970 ("gsasl" ,gsasl)))
971 (native-inputs
972 `(("pkg-config" ,pkg-config)))
973 (home-page "http://msmtp.sourceforge.net/")
974 (arguments
975 `(#:configure-flags (list "--with-libgsasl"
976 "--with-libidn"
823e2ed4
LF
977 "--with-tls=gnutls")
978 #:phases
979 (modify-phases %standard-phases
980 (add-after 'install 'install-msmtpq
981 (lambda* (#:key outputs #:allow-other-keys)
982 (let* ((out (assoc-ref outputs "out"))
983 (bin (string-append out "/bin"))
984 (doc (string-append out "/share/doc/msmtp"))
985 (msmtpq (string-append "scripts/msmtpq")))
986 (install-file (string-append msmtpq "/msmtpq") bin)
987 (install-file (string-append msmtpq "/msmtp-queue") bin)
988 (install-file (string-append msmtpq "/README.msmtpq") doc)
989 #t))))))
d6e941bc
990 (synopsis
991 "Simple and easy to use SMTP client with decent sendmail compatibility")
992 (description
993 "msmtp is an SMTP client. In the default mode, it transmits a mail to
994an SMTP server (for example at a free mail provider) which takes care of further
995delivery.")
996 (license gpl3+)))
997
66cc3ab2
TUBK
998(define-public exim
999 (package
1000 (name "exim")
4a95b388 1001 (version "4.87.1")
66cc3ab2
TUBK
1002 (source
1003 (origin
1004 (method url-fetch)
fc6fdc05
LF
1005 (uri (list (string-append "ftp://ftp.exim.org/pub/exim/exim4/exim-"
1006 version ".tar.bz2")
1007 (string-append "ftp://ftp.exim.org/pub/exim/exim4/old/exim-"
1008 version ".tar.bz2")))
66cc3ab2 1009 (sha256
513f8ab4 1010 (base32
4a95b388 1011 "050m2gjzpc6vyik458h1j0vi8bxplkzjsyndkyd2y394i569kdyl"))))
66cc3ab2
TUBK
1012 (build-system gnu-build-system)
1013 (inputs
1014 `(("bdb" ,bdb)
1015 ("gnutls" ,gnutls)
1016 ("gzip" ,gzip)
1017 ("bzip2" ,bzip2)
1018 ("xz" ,xz)
66cc3ab2
TUBK
1019 ("perl" ,perl)
1020 ("libxt" ,libxt)
1021 ("libxaw" ,libxaw)))
1022 (native-inputs
42773138
EF
1023 `(("pcre" ,pcre "bin")
1024 ("perl" ,perl)))
66cc3ab2
TUBK
1025 (arguments
1026 '(#:phases
1027 (alist-replace
1028 'configure
1029 ;; We'd use #:make-flags but the top-level Makefile calls others
1030 ;; recursively, so just set all variables this way.
1031 (lambda* (#:key outputs inputs #:allow-other-keys)
1032 (substitute* '("Makefile" "OS/Makefile-Default")
1033 (("(RM_COMMAND=).*" all var)
1034 (string-append var "rm\n")))
1035 (copy-file "src/EDITME" "Local/Makefile")
1036 (copy-file "exim_monitor/EDITME" "Local/eximon.conf")
1037 (let ((out (assoc-ref outputs "out"))
1038 (gzip (assoc-ref inputs "gzip"))
1039 (bzip2 (assoc-ref inputs "bzip2"))
1040 (xz (assoc-ref inputs "xz")))
1041 (substitute* '("Local/Makefile")
1042 (("(BIN_DIRECTORY=).*" all var)
1043 (string-append var out "/bin\n"))
1044 (("(CONFIGURE_FILE=).*" all var)
1045 (string-append var out "/etc/exim.conf\n"))
1046 (("(EXIM_USER=).*" all var)
1047 (string-append var "nobody\n"))
1048 (("(FIXED_NEVER_USERS=).*" all var)
1049 (string-append var "\n")) ;XXX no root in build environment
1050 (("(COMPRESS_COMMAND=).*" all var)
1051 (string-append var gzip "/bin/gzip\n"))
1052 (("(ZCAT_COMMAND=).*" all var)
1053 (string-append var gzip "/bin/zcat\n")))
1054 ;; This file has hardcoded names for tools despite the zcat
1055 ;; configuration above.
1056 (substitute* '("src/exigrep.src")
1057 (("'zcat'") (string-append "'" gzip "/bin/zcat'"))
1058 (("'bzcat'") (string-append "'" bzip2 "/bin/bzcat'"))
1059 (("'xzcat'") (string-append "'" xz "/bin/xzcat'"))
1060 (("'lzma'") (string-append "'" xz "/bin/lzma'")))))
1061 (alist-cons-before
1062 'build 'fix-sh-paths
1063 (lambda* (#:key inputs #:allow-other-keys)
1064 (substitute* '("scripts/lookups-Makefile" "scripts/reversion")
1065 (("SHELL=/bin/sh") "SHELL=sh"))
1066 (substitute* '("scripts/Configure-config.h")
1067 (("\\| /bin/sh") "| sh"))
1068 (let ((bash (assoc-ref inputs "bash")))
1069 (substitute* '("scripts/Configure-eximon")
1070 (("#!/bin/sh") (string-append "#!" bash "/bin/sh")))))
1071 %standard-phases))
1072 #:make-flags '("INSTALL_ARG=-no_chown")
1073 ;; No 'check' target.
1074 #:tests? #f))
1075 (home-page "http://www.exim.org/")
1076 (synopsis
1077 "Message Transfer Agent (MTA) developed at the University of Cambridge")
1078 (description
1079 "Exim is a message transfer agent (MTA) developed at the University of
1080Cambridge for use on Unix systems connected to the Internet. In style it is
1081similar to Smail 3, but its facilities are more general. There is a great
1082deal of flexibility in the way mail can be routed, and there are extensive
1083facilities for checking incoming mail.")
1084 (license gpl2+)))
1085
7d2b784b
MW
1086(define-public dovecot
1087 (package
1088 (name "dovecot")
0adb47bd 1089 (version "2.2.29")
7d2b784b
MW
1090 (source
1091 (origin
1092 (method url-fetch)
c8608faf 1093 (uri (string-append "https://www.dovecot.org/releases/"
7d2b784b
MW
1094 (version-major+minor version) "/"
1095 name "-" version ".tar.gz"))
0adb47bd
LF
1096 (patches (search-patches "dovecot-fix-failing-test.patch"))
1097 (sha256
1098 (base32
1099 "19irf7b5mjqq68mrpdd38gxc0zp2nqib942kjp3aif3f2acylffr"))))
7d2b784b
MW
1100 (build-system gnu-build-system)
1101 (native-inputs
1102 `(("pkg-config" ,pkg-config)))
1103 (inputs
1104 `(("openssl" ,openssl)
1105 ("zlib" ,zlib)
1106 ("bzip2" ,bzip2)
fd5c70f8
AW
1107 ("sqlite" ,sqlite)
1108 ("linux-pam" ,linux-pam)))
7d2b784b
MW
1109 (arguments
1110 `(#:configure-flags '("--sysconfdir=/etc"
1111 "--localstatedir=/var")
1112 #:phases (modify-phases %standard-phases
1113 (add-before
1114 'configure 'pre-configure
1115 (lambda _
1116 ;; Simple hack to avoid installing in /etc
1117 (substitute* '("doc/Makefile.in"
1118 "doc/example-config/Makefile.in")
1119 (("pkgsysconfdir = .*")
1120 "pkgsysconfdir = /tmp/etc"))
072f1e22
EF
1121 #t))
1122 (add-after
1123 'unpack 'patch-other-shebangs
1124 (lambda _
1125 (substitute*
1126 "src/lib-program-client/test-program-client-local.c"
1127 (("/bin/echo") (which "echo"))
1128 (("/bin/cat") (which "cat"))
1129 (("/bin/false") (which "false")))
7d2b784b 1130 #t)))))
c8608faf 1131 (home-page "https://www.dovecot.org")
7d2b784b
MW
1132 (synopsis "Secure POP3/IMAP server")
1133 (description
1134 "Dovecot is a mail server whose major goals are security and reliability.
1135It supports mbox/Maildir and its own dbox/mdbox formats.")
1136 ;; Most source files are covered by either lgpl2.1 or expat. The SHA code
1137 ;; is covered by a variant of BSD-3, and UnicodeData.txt is covered by the
1138 ;; Unicode, Inc. License Agreement for Data Files and Software.
1139 (license (list lgpl2.1 license:expat (non-copyleft "file://COPYING")))))
1140
944a5cdd 1141(define-public dovecot-trees
cf47a8a5 1142 (package
1143 (name "dovecot-trees")
1144 (version "2.1.0")
1145 (source
1146 (origin
1147 (method url-fetch)
1148 (uri (string-append "https://0xacab.org/riseuplabs/trees/repository/"
1149 "archive.tar.gz?ref=v" version))
1150 (file-name (string-append name "-" version ".tar.gz"))
1151 (sha256
1152 (base32
1153 "0rkk10b1bsjz979sc864vpgcdchy7yxwmyv4ik50lar1h6awdnrf"))))
1154 (build-system gnu-build-system)
1155 (native-inputs
1156 `(("automake" ,automake)
1157 ("autoconf" ,autoconf)
1158 ("libtool" ,libtool)
1159 ("dovecot" ,dovecot)
1160 ("pkg-config" ,pkg-config)))
1161 (inputs
1162 `(("libsodium" ,libsodium)))
1163 (arguments
1164 `(#:tests? #f ;No tests exist.
1165 #:configure-flags (list (string-append "--with-dovecot="
1166 (assoc-ref %build-inputs "dovecot")
1167 "/lib/dovecot"))
1168 #:phases
1169 (modify-phases %standard-phases
1170 (add-before 'configure 'autogen
1171 (lambda _
1172 (zero? (system* "./autogen.sh")))))))
1173 (home-page "https://0xacab.org/riseuplabs/trees")
1174 (synopsis "NaCL-based Dovecot email storage encryption plugin")
1175 (description
1176 "Technology for Resting Email Encrypted Storage (TREES) is a NaCL-based
944a5cdd 1177Dovecot encryption plugin. This plugin adds individually encrypted mail
1178storage to the Dovecot IMAP server. It is inspired by Posteo's scrambler
1179which uses OpenSSL and RSA keypairs. TREES works in a similar way, but uses
1180the Sodium crypto library (based on NaCL).
1181
1182How it works:
1183@enumerate
1184@item On IMAP log in, the user's cleartext password is passed to the plugin.
1185@item The plugin creates an argon2 digest from the password.
1186@item This password digest is used as a symmetric secret to decrypt a libsodium secretbox.
1187@item Inside the secretbox is stored a Curve25519 private key.
1188@item The Curve25519 private key is used to decrypt each individual message,
1189using lidsodium sealed boxes.
1190@item New mail is encrypted as it arrives using the Curve25519 public key.
1191@end enumerate\n")
cf47a8a5 1192 (license agpl3)))
944a5cdd 1193
a4651f64 1194(define-public dovecot-libsodium-plugin
1195 (let ((commit "044de73c01c35385df0105f6b387bec5d5317ce7")
1196 (revision "1"))
1197 (package
1198 (name "dovecot-libsodium-plugin")
1199 (version (string-append "0.0.0-" revision "." (string-take commit 7)))
1200 (source
1201 (origin
1202 (method git-fetch)
1203 (uri (git-reference
1204 (url "https://github.com/LuckyFellow/dovecot-libsodium-plugin")
1205 (commit commit)))
1206 (file-name (string-append name "-" version "-checkout"))
1207 (sha256
1208 (base32
1209 "13h07l7xy713zchnj2p9fhvq7fdl4zy1ai94li3ygkqjjj8hrgas"))))
1210 (build-system gnu-build-system)
1211 (native-inputs
1212 `(("automake" ,automake)
1213 ("autoconf" ,autoconf)
1214 ("libtool" ,libtool)
1215 ("dovecot" ,dovecot)
1216 ("pkg-config" ,pkg-config)))
1217 (inputs
1218 `(("libsodium" ,libsodium)))
1219 (arguments
1220 `(#:tests? #f ;No tests exist.
1221 #:configure-flags (list (string-append "--with-dovecot="
1222 (assoc-ref %build-inputs "dovecot")
1223 "/lib/dovecot"))
1224 #:phases
1225 (modify-phases %standard-phases
1226 (add-before 'configure 'autogen
1227 (lambda _
1228 (zero? (system* "./autogen.sh")))))))
1229 (home-page "https://github.com/LuckyFellow/dovecot-libsodium-plugin")
1230 (synopsis "Libsodium password hashing schemes plugin for Dovecot")
1231 (description
1232 "@code{dovecot-libsodium-plugin} provides libsodium password
1233hashing schemes plugin for @code{Dovecot}.")
1234 (license gpl3+))))
1235
81ce19f4
1236(define-public isync
1237 (package
1238 (name "isync")
2c3d13fe 1239 (version "1.2.1")
81ce19f4
1240 (source
1241 (origin
1242 (method url-fetch)
1243 (uri (string-append "mirror://sourceforge/isync/isync/"
1244 version "/isync-" version ".tar.gz"))
1245 (sha256 (base32
2c3d13fe 1246 "1bij6nm06ghkg98n2pdyacam2fyg5y8f7ajw0d5653m0r4ldw5p7"))))
81ce19f4
1247 (build-system gnu-build-system)
1248 (inputs
1249 `(("bdb" ,bdb)
1250 ("openssl" ,openssl)))
1251 (home-page "http://isync.sourceforge.net/")
1252 (synopsis "Mailbox synchronization program")
1253 (description
1254 "isync/mbsync is command line tool for two-way synchronization of
1255mailboxes. Currently Maildir and IMAP are supported types.")
1256 (license gpl2+)))
1257
26b8de19
EB
1258(define-public perl-email-abstract
1259 (package
1260 (name "perl-email-abstract")
1261 (version "3.008")
1262 (source
1263 (origin
1264 (method url-fetch)
1265 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1266 "Email-Abstract-" version ".tar.gz"))
1267 (sha256
1268 (base32
1269 "0h42rhvp769wb421cpbbg6v6xjp8iv86mvz70pqgfgf4nsn6jwgw"))))
1270 (build-system perl-build-system)
1271 (propagated-inputs
1272 `(("perl-email-simple" ,perl-email-simple)
a2190ccc 1273 ("perl-module-pluggable" ,perl-module-pluggable)
26b8de19
EB
1274 ("perl-mro-compat" ,perl-mro-compat)))
1275 (home-page "http://search.cpan.org/dist/Email-Abstract")
1276 (synopsis "Interface to mail representations")
1277 (description "Email::Abstract provides module writers with the ability to
1278write simple, representation-independent mail handling code.")
1279 (license (package-license perl))))
1280
ebda902f
EB
1281(define-public perl-email-address
1282 (package
1283 (name "perl-email-address")
151bba2b 1284 (version "1.908")
ebda902f
EB
1285 (source
1286 (origin
1287 (method url-fetch)
1288 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1289 "Email-Address-" version ".tar.gz"))
1290 (sha256
1291 (base32
151bba2b 1292 "0i6ljdvpy279hpbqf6lgv4figr376rb2sh4yphj86xkdzsyn1y75"))))
ebda902f
EB
1293 (build-system perl-build-system)
1294 (home-page "http://search.cpan.org/dist/Email-Address")
1295 (synopsis "Email address parsing and creation")
1296 (description "Email::Address implements a regex-based RFC 2822 parser that
1297locates email addresses in strings and returns a list of Email::Address
1298objects found. Alternatively you may construct objects manually.")
1299 (license (package-license perl))))
1300
aa86a3be
EB
1301(define-public perl-email-date-format
1302 (package
1303 (name "perl-email-date-format")
1304 (version "1.005")
1305 (source
1306 (origin
1307 (method url-fetch)
1308 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1309 "Email-Date-Format-" version ".tar.gz"))
1310 (sha256
1311 (base32
1312 "012ivfwpnbl3wr50f9c6f4azhdlxnm31pdn72528g79v61z6372p"))))
1313 (build-system perl-build-system)
1314 (home-page "http://search.cpan.org/dist/Email-Date-Format")
1315 (synopsis "Produce RFC 2822 date strings")
1316 (description "Email::Date::Format provides a means for generating an RFC
13172822 compliant datetime string.")
1318 (license (package-license perl))))
1319
08bf7095
EB
1320(define-public perl-email-messageid
1321 (package
1322 (name "perl-email-messageid")
1fb37ef0 1323 (version "1.406")
08bf7095
EB
1324 (source
1325 (origin
1326 (method url-fetch)
1327 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1328 "Email-MessageID-" version ".tar.gz"))
1329 (sha256
1330 (base32
1fb37ef0 1331 "1f22sdnfq169qw1l0lg7y74pmiam7j9v95bggjnf3q4mygdmshpc"))))
08bf7095
EB
1332 (build-system perl-build-system)
1333 (home-page "http://search.cpan.org/dist/Email-MessageID")
1334 (synopsis "Generate world unique message-ids")
1335 (description "Email::MessageID generates recommended message-ids to
1336identify a message uniquely.")
1337 (license (package-license perl))))
1338
0a4c49f6
EB
1339(define-public perl-email-mime
1340 (package
1341 (name "perl-email-mime")
e26f2c67 1342 (version "1.940")
0a4c49f6
EB
1343 (source
1344 (origin
1345 (method url-fetch)
1346 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1347 "Email-MIME-" version ".tar.gz"))
1348 (sha256
1349 (base32
e26f2c67 1350 "0pnxbr16cn5qy96xqhp9zmd94ashc9ivqh10qbgbc3f637a0mfir"))))
0a4c49f6
EB
1351 (build-system perl-build-system)
1352 (propagated-inputs
1353 `(("perl-email-address" ,perl-email-address)
1354 ("perl-email-messageid" ,perl-email-messageid)
1355 ("perl-email-mime-contenttype" ,perl-email-mime-contenttype)
1356 ("perl-email-mime-encodings" ,perl-email-mime-encodings)
1357 ("perl-email-simple" ,perl-email-simple)
1358 ("perl-mime-types" ,perl-mime-types)))
1359 (home-page "http://search.cpan.org/dist/Email-MIME")
1360 (synopsis "MIME message handling")
1361 (description "Email::MIME is an extension of the Email::Simple module, to
1362handle MIME encoded messages. It takes a message as a string, splits it up
1363into its constituent parts, and allows you access to various parts of the
1364message. Headers are decoded from MIME encoding.")
1365 (license (package-license perl))))
1366
55025bb5
EB
1367(define-public perl-email-mime-contenttype
1368 (package
1369 (name "perl-email-mime-contenttype")
a883ba02 1370 (version "1.018")
55025bb5
EB
1371 (source
1372 (origin
1373 (method url-fetch)
1374 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1375 "Email-MIME-ContentType-" version ".tar.gz"))
1376 (sha256
1377 (base32
a883ba02 1378 "1y8hpwm7p5a9y2azy0cgvlv2i2d0nj66ajfa0fj51wdq4w9cs23m"))))
55025bb5
EB
1379 (build-system perl-build-system)
1380 (native-inputs
1381 `(("perl-capture-tiny" ,perl-capture-tiny)))
1382 (home-page "http://search.cpan.org/dist/Email-MIME-ContentType")
1383 (synopsis "Parse MIME Content-Type headers")
1384 (description "Email::MIME::ContentType parses a MIME Content-Type
1385header.")
1386 (license (package-license perl))))
1387
02e29936
EB
1388(define-public perl-email-mime-encodings
1389 (package
1390 (name "perl-email-mime-encodings")
1391 (version "1.315")
1392 (source
1393 (origin
1394 (method url-fetch)
1395 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1396 "Email-MIME-Encodings-" version ".tar.gz"))
1397 (sha256
1398 (base32
1399 "0p5b8g9gh35m8fqrpx60g4bp98rvwd02n5b0vm9wh7mk0xah8wac"))))
1400 (build-system perl-build-system)
1401 (native-inputs
1402 `(("perl-capture-tiny" ,perl-capture-tiny)))
1403 (home-page "http://search.cpan.org/dist/Email-MIME-Encodings")
1404 (synopsis "Unified interface to MIME encoding and decoding")
1405 (description "This module wraps MIME::Base64 and MIME::QuotedPrint.")
1406 (license (package-license perl))))
1407
a24c5420
EB
1408(define-public perl-email-sender
1409 (package
1410 (name "perl-email-sender")
1b49fc8f 1411 (version "1.300028")
a24c5420
EB
1412 (source
1413 (origin
1414 (method url-fetch)
1415 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1416 "Email-Sender-" version ".tar.gz"))
1417 (sha256
1418 (base32
1b49fc8f 1419 "0c5dv1x9856nryj5mcbgb67a4irmadz80g0qnf4van3bd8wbj72a"))))
a24c5420
EB
1420 (build-system perl-build-system)
1421 (native-inputs
1422 `(("perl-capture-tiny" ,perl-capture-tiny)))
1423 (propagated-inputs
1424 `(("perl-email-abstract" ,perl-email-abstract)
1425 ("perl-email-address" ,perl-email-address)
1426 ("perl-email-simple" ,perl-email-simple)
1427 ("perl-list-moreutils" ,perl-list-moreutils)
1428 ("perl-module-runtime" ,perl-module-runtime)
1429 ("perl-moo" ,perl-moo)
1430 ("perl-moox-types-mooselike" ,perl-moox-types-mooselike)
1431 ("perl-sub-exporter" ,perl-sub-exporter)
1432 ("perl-throwable" ,perl-throwable)
1433 ("perl-try-tiny" ,perl-try-tiny)))
1434 (home-page "http://search.cpan.org/dist/Email-Sender")
1435 (synopsis "Perl library for sending email")
1436 (description "Email::Sender replaces the old and sometimes problematic
1437Email::Send library.")
1438 (license (package-license perl))))
1439
151ef3ed
EB
1440(define-public perl-email-simple
1441 (package
1442 (name "perl-email-simple")
f751b759 1443 (version "2.213")
151ef3ed
EB
1444 (source
1445 (origin
1446 (method url-fetch)
1447 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1448 "Email-Simple-" version ".tar.gz"))
1449 (sha256
1450 (base32
f751b759 1451 "1ibwsng63gvqqc6r2135mjwfdzazxkb1x8q7f87wqcbjcjfpmffd"))))
151ef3ed
EB
1452 (build-system perl-build-system)
1453 (propagated-inputs
1454 `(("perl-email-date-format" ,perl-email-date-format)))
1455 (home-page "http://search.cpan.org/dist/Email-Simple")
1456 (synopsis "Parsing of RFC 2822 messages")
1457 (description "Email::Simple provides simple parsing of RFC 2822 message
1458format and headers.")
1459 (license (package-license perl))))
1460
f5dceecb
AW
1461(define-public libesmtp
1462 (package
1463 (name "libesmtp")
1464 (version "1.0.6")
1465 (source
1466 (origin
1467 (method url-fetch)
049e02ea
LF
1468 (uri (list (string-append "https://pkgs.fedoraproject.org/repo/pkgs/"
1469 "libesmtp/libesmtp-" version ".tar.bz2/"
1470 "bf3915e627fd8f35524a8fdfeed979c8/libesmtp-"
1471 version ".tar.bz2")
1472 ;; XXX This site is offline, so we fetch Fedora's cached copy
1473 ;; of the source tarball.
1474 (string-append "http://www.stafford.uklinux.net/libesmtp/libesmtp-"
1475 version ".tar.bz2")))
f5dceecb
AW
1476 (sha256
1477 (base32
1478 "02zbniyz7qys1jmx3ghx21kxmns1wc3hmv80gp7ag7yra9f1m9nh"))))
1479 (build-system gnu-build-system)
1480 (propagated-inputs
1481 `(("openssl" ,openssl)))
1482 (home-page "http://www.stafford.uklinux.net/libesmtp/")
1483 (synopsis "Library for sending mail via remote hosts using SMTP")
1484 (description "libESMTP is an SMTP client which manages posting (or
1485submission of) electronic mail via a preconfigured Mail Transport Agent (MTA).
1486It may be used as part of a Mail User Agent (MUA) or other program that must
1487be able to post electronic mail where mail functionality may not be that
1488program's primary purpose.")
1489 (license (list lgpl2.1+ gpl2+))))
1490
f8ae32a2
AW
1491(define-public esmtp
1492 (package
1493 (name "esmtp")
1494 (version "1.2")
1495 (source
1496 (origin
1497 (method git-fetch)
1498 (uri (git-reference
1499 (url "https://github.com/andywingo/esmtp.git")
1500 (commit "01bf9fc")))
1501 (sha256
1502 (base32
1503 "1ay282rrl92h0m0m8z5zzjnwiiagi7c78aq2qvhia5mw7prwfyw2"))
1504 (file-name (string-append name "-" version "-checkout"))))
1505 (arguments
1506 `(#:phases (modify-phases %standard-phases
1507 (add-before
1508 'configure 'autoconf
1509 (lambda _ (zero? (system* "autoreconf" "-vfi")))))))
1510 (build-system gnu-build-system)
1511 (native-inputs
1512 `(("bison" ,bison)
1513 ("flex" ,flex)
1514 ("autoconf" ,autoconf)
1515 ("automake" ,automake)
1516 ("libtool" ,libtool)))
1517 (inputs
718c5dd6 1518 `(("libesmtp" ,libesmtp)))
3b3b60d0 1519 (home-page "https://sourceforge.net/projects/esmtp/")
f8ae32a2
AW
1520 (synopsis "Relay-only mail transfer agent (MTA)")
1521 (description "Esmtp is a simple relay-only mail transfer agent built using
1522libESMTP. It sends e-mail via a remote SMTP server using credentials from the
1523user's @file{$HOME/.esmtprc} configuration file; see the @command{esmtprc} man
1524page for more on configuration. This package also provides minimal
1525compatibility shims for the @command{sendmail}, @command{mailq}, and
1526@command{newaliases} commands.")
1527 (license gpl2+)))
1528
34dd26af
CAW
1529(define-public fdm
1530 (package
1531 (name "fdm")
1532 (version "1.9")
1533 (source (origin
1534 (method url-fetch)
1535 (uri (string-append "https://github.com/nicm/fdm/releases/download/"
1536 version "/fdm-"
1537 version ".tar.gz"))
1538 (file-name (string-append name "-" version ".tar.gz"))
1539 (sha256
1540 (base32 "054rscijahiza5f9qha79rg3siji3bk5mk10f8c2vqx7m4w6qh8n"))))
1541 (build-system gnu-build-system)
1542 (inputs
1543 `(("tdb" ,tdb)
1544 ("openssl" ,openssl)
1545 ("zlib" ,zlib)))
1546 (home-page "https://github.com/nicm/fdm")
1547 (synopsis "Mail Retrieval Agent (MRA) and Mail Delivery Agent (MDA)")
1548 (description "fdm is a program designed to fetch mail from POP3
1549or IMAP servers, or receive local mail from stdin, and
1550deliver it in various ways.")
1551 (license
1552 ;; Why point to a source file? Well, all the individual files have a
1553 ;; copy of this license in their headers, but there's no seprate file
1554 ;; with that information.
16966d5b 1555 (non-copyleft "https://github.com/nicm/fdm/blob/master/command.c"))))
34dd26af 1556
e90819c4
LG
1557
1558(define-public procmail
1559 (package
1560 (name "procmail")
1561 (version "3.22")
1562 (source
1563 (origin
1564 (method url-fetch)
1565 (uri (string-append
1566 "ftp://ftp.fu-berlin.de/pub/unix/mail/procmail/procmail-"
1567 version
1568 ".tar.gz"))
1569 (sha256
1570 (base32
1571 "05z1c803n5cppkcq99vkyd5myff904lf9sdgynfqngfk9nrpaz08"))
1572 ;; The following patch fixes an ambiguous definition of
1573 ;; getline() in formail.c. The patch is provided by Debian as
1574 ;; patch 24.
1d982d78
LF
1575 (patches (search-patches "procmail-ambiguous-getline-debian.patch"
1576 "procmail-CVE-2014-3618.patch"))))
e90819c4
LG
1577 (arguments
1578 `(#:phases (modify-phases %standard-phases
1579 (replace 'configure
1580 (lambda _
1581 (substitute* "Makefile"
1582 (("/bin/sh")
1583 (which "sh"))
1584 (("/usr")
1585 (assoc-ref %outputs "out"))
1586 (("/bin/rm")
1587 (which "rm")))
1588 #t)))
1589 #:tests? #f)) ;; There are no tests indicating a successful
1590 ;; build. Some tests of basic locking mechanisms provided by the
8f65585b 1591 ;; file system are performed during 'make install'. However, these
e90819c4
LG
1592 ;; are performed before the actual build process.
1593 (build-system gnu-build-system)
05aa576b 1594 (inputs `(("exim" ,exim)))
e90819c4
LG
1595 (home-page "http://www.procmail.org/")
1596 (synopsis "Versatile mail delivery agent (MDA)")
1597 (description "Procmail is a mail delivery agent (MDA) featuring support
1598for a variety of mailbox formats such as mbox, mh and maildir. Incoming mail
1599can be sorted into separate files/directories and arbitrary commands can be
1600executed on mail arrival. Procmail is considered stable, but is no longer
1601maintained.")
1602 (license gpl2+))) ;; procmail allows to choose the
1603 ;; nonfree Artistic License 1.0
1604 ;; as alternative to the GPL2+.
1605 ;; This option is not listed here.
e90819c4 1606
61c30e9d
LF
1607(define-public khard
1608 (package
1609 (name "khard")
a57495e2 1610 (version "0.11.3")
61c30e9d
LF
1611 (source (origin
1612 (method url-fetch)
1613 (uri (pypi-uri name version))
1614 (sha256
1615 (base32
a57495e2 1616 "1v66khq5w17xdbkpb00pf9xbl84dlzx4lq286fvzskb949b3y4yn"))))
61c30e9d
LF
1617 (build-system python-build-system)
1618 (arguments
a57495e2 1619 `(#:phases
61c30e9d 1620 (modify-phases %standard-phases
61c30e9d
LF
1621 (add-after 'install 'install-doc
1622 (lambda* (#:key outputs #:allow-other-keys)
1623 (let* ((out (assoc-ref outputs "out"))
1624 (doc (string-append out "/share/doc/khard")))
e9eafae2
MB
1625 (copy-recursively "misc/khard" doc)
1626 #t))))
1627 ;; FIXME: check phase fails with
1628 ;; "Config file /tmp/.config/khard/khard.conf not available"
1629 #:tests? #f))
61c30e9d 1630 (propagated-inputs
a57495e2
LF
1631 `(("python-vobject" ,python-vobject)
1632 ("python-pyyaml" ,python-pyyaml)
1633 ("python-atomicwrites" ,python-atomicwrites)
1634 ("python-configobj" ,python-configobj)))
61c30e9d
LF
1635 (synopsis "Console address book using CardDAV")
1636 (description "Khard is an address book for the console. It creates, reads,
1637modifies and removes CardDAV address book entries at your local machine. For
1638synchronizing with a remote address book, @command{vdirsyncer} is recommended.
1639Khard can also be used from within the email client @command{mutt}.")
1640 (home-page "https://github.com/scheibler/khard")
1641 (license gpl3+)))
be0c5733
DM
1642
1643(define-public perl-mail-spf
1644 (package
1645 (name "perl-mail-spf")
1646 (version "v2.9.0")
1647 (source
1648 (origin
1649 (method url-fetch)
1650 (uri (string-append
1651 "mirror://cpan/authors/id/J/JM/JMEHNLE/mail-spf/Mail-SPF-"
1652 version
1653 ".tar.gz"))
1654 (sha256
1655 (base32
1656 "0qk1rfgfm5drj4iyniiabrasrpqv570vzhgz66lwgb67y4amkjv1"))))
1657 (build-system perl-build-system)
1658 (native-inputs
1659 `(("perl-module-build" ,perl-module-build)
1660 ("perl-net-dns-resolver-programmable"
1661 ,perl-net-dns-resolver-programmable)))
1662 (arguments
1663 `(#:phases (modify-phases %standard-phases
1664 (add-before 'configure 'modify-Build.PL
1665 (lambda* (#:key outputs #:allow-other-keys)
1666 (substitute* "Build.PL"
1667 (("'/usr/sbin'") (string-append "'"
1668 (assoc-ref outputs "out")
1669 "/sbin'")))
1670 #t)))))
1671 (inputs
1672 `(("perl-error" ,perl-error)
1673 ("perl-net-dns" ,perl-net-dns)
1674 ("perl-netaddr-ip" ,perl-netaddr-ip)
1675 ("perl-uri" ,perl-uri)))
1676 (home-page
1677 "http://search.cpan.org/dist/Mail-SPF")
1678 (synopsis
1679 "Perl implementation of Sender Policy Framework")
1680 (description "Mail::SPF is the Sender Policy Framework implemented
1681in Perl.")
1682 (license bsd-3)))
24262239
CL
1683
1684(define-public mb2md
1685 (package
1686 (name "mb2md")
1687 (version "3.20")
1688 (source (origin
1689 (method url-fetch)
1690 (uri (string-append
1691 "http://batleth.sapienti-sat.org/projects/mb2md/mb2md-"
1692 version ".pl.gz"))
1693 (sha256
1694 (base32
1695 "0bvkky3c90738h3skd2f1b2yy5xzhl25cbh9w2dy97rs86ssjidg"))))
1696 (build-system trivial-build-system)
1697 (arguments
1698 '(#:modules ((guix build utils))
1699 #:builder
1700 (begin
1701 (use-modules (guix build utils))
1702 (let* ((source (assoc-ref %build-inputs "source"))
1703 (out (assoc-ref %outputs "out"))
1704 (bin (string-append out "/bin"))
1705 (perl (assoc-ref %build-inputs "perl"))
1706 (gzip (assoc-ref %build-inputs "gzip"))
1707 (perl-timedate (assoc-ref %build-inputs "perl-timedate"))
1708 (perl5lib (string-append perl-timedate "/lib/perl5/site_perl")))
1709 (mkdir-p bin)
1710 (with-directory-excursion bin
1711 (copy-file source "mb2md.gz")
1712 (system* (string-append gzip "/bin/gzip") "-d" "mb2md.gz")
1713 (substitute* "mb2md"
1714 (("#!/usr/bin/perl")
1715 (string-append "#!/usr/bin/perl -I " perl5lib)))
1716 (patch-shebang "mb2md" (list (string-append perl "/bin")))
1717 (chmod "mb2md" #o555))
1718 #t))))
1719 (native-inputs `(("gzip", gzip)))
1720 (inputs `(("perl" ,perl)
1721 ("perl-timedate" ,perl-timedate)))
1722 (home-page "http://batleth.sapienti-sat.org/projects/mb2md/")
1723 (synopsis "Mbox to maildir converter")
1724 (description
1725 "Mb2md is a Perl script that takes one or more mbox format files and
1726converts them to maildir format directories.")
1727 (license public-domain)))
e0d7b421
AI
1728
1729(define-public mpop
1730 (package
1731 (name "mpop")
5837e699 1732 (version "1.2.6")
e0d7b421
AI
1733 (source
1734 (origin
1735 (method url-fetch)
175c9103
LF
1736 (uri (string-append "mirror://sourceforge/mpop/mpop/" version
1737 "/mpop-" version ".tar.xz"))
e0d7b421
AI
1738 (sha256
1739 (base32
5837e699 1740 "0p1ix63jh64dibrlccch8q7gxl9nn18wd2qpyr5z1h4gs2fpmv4z"))))
e0d7b421
AI
1741 (build-system gnu-build-system)
1742 (inputs
1743 `(("gnutls" ,gnutls)
1744 ("libidn" ,libidn)))
1745 (native-inputs
1746 `(("pkg-config" ,pkg-config)))
1747 (arguments
1748 `(#:configure-flags (list "--with-tls=gnutls")))
1749 (home-page "http://mpop.sourceforge.net/")
1750 (synopsis "POP3 mail client")
1751 (description "mpop is a small and fast POP3 client suitable as a
1752fetchmail replacement.
1753
1754mpop supports multiple accounts, header based mail filtering, delivery
1755to mbox files, maildir folders or a Mail Delivery Agent (MDA),
1756TLS/SSL, several authentication methods, Internationalized Domain
1757Names (IDN) and SOCKS proxies.")
1758 (license gpl3+)))
74c0282c 1759
1760(define-public mhonarc
1761 (package
1762 (name "mhonarc")
1763 (version "2.6.19")
1764 (source
1765 (origin
1766 (method url-fetch)
1767 (uri (string-append "mirror://cpan/authors/id/E/EH/EHOOD/MHonArc-"
1768 version ".tar.gz"))
1769 (sha256
1770 (base32
1771 "0ll3v93yji334zqp6xfzfxc0127pmjcznmai1l5q6dzawrs2igzq"))))
1772 (build-system perl-build-system)
1773 (home-page "https://www.mhonarc.org/")
1774 (synopsis "Create HTML archives of mail/news messages")
1775 (description
1776 "MHonArc is a Perl mail-to-HTML converter. MHonArc
1777provides HTML mail archiving with index, mail thread linking,
1778etc; plus other capabilities including support for MIME and
1779powerful user customization features.")
1780 (license gpl2+)))
5d87088c
JD
1781
1782
1783(define-public sendmail
1784 (package
1785 (name "sendmail")
1786 (version "8.15.2")
1787 (source
1788 (origin
1789 (method url-fetch)
1790 (uri (string-append
1791 "ftp://ftp.sendmail.org/pub/sendmail/sendmail."
1792 version ".tar.gz"))
1793 (sha256
1794 (base32
1795 "0fdl9ndmspqspdlmghzxlaqk56j3yajk52d7jxcg21b7sxglpy94"))))
1796 (build-system gnu-build-system)
1797 (arguments
1798 `(#:phases
1799 (modify-phases %standard-phases
1800 (add-before 'build 'replace-/bin/sh
1801 (lambda _
1802 (substitute*
1803 (append
1804 (list "smrsh/smrsh.c" "sendmail/conf.c" "contrib/mailprio"
1805 "contrib/mmuegel" "devtools/bin/configure.sh")
1806 (find-files "." ".*\\.m4")
1807 (find-files "." ".*\\.cf"))
19527952 1808 (("/bin/sh") (which "sh")))
5d87088c
JD
1809
1810 (substitute* "devtools/bin/Build"
19527952 1811 (("SHELL=/bin/sh") (string-append "SHELL=" (which "sh"))))
5d87088c
JD
1812 #t))
1813 (replace 'configure
1814 (lambda _
1815
1816 ;; Render harmless any attempts to chown or chgrp
1817 (substitute* "devtools/bin/install.sh"
1818 (("owner=\\$2") "owner=''")
1819 (("group=\\$2") "group=''"))
1820
1821 (with-output-to-file "devtools/Site/site.config.m4"
1822 (lambda ()
1823 (format #t "
1824define(`confCC', `gcc')
1825define(`confOPTIMIZE', `-g -O2')
1826define(`confLIBS', `-lresolv')
1827define(`confINSTALL', `~a/devtools/bin/install.sh')
1828define(`confDEPEND_TYPE', `CC-M')
1829define(`confINST_DEP', `')
1830" (getcwd))))))
1831 (replace 'build
1832 (lambda _
1833 (and (zero? (system* "sh" "Build"))
1834 (with-directory-excursion "cf/cf"
1835 (begin
1836 (copy-file "generic-linux.mc" "sendmail.mc")
1837 (zero? (system* "sh" "Build" "sendmail.cf")))))))
1838 (add-before 'install 'pre-install
1839 (lambda _
1840 (let ((out (assoc-ref %outputs "out")))
1841 (mkdir-p (string-append out "/usr/bin"))
1842 (mkdir-p (string-append out "/usr/sbin"))
1843 (mkdir-p (string-append out "/etc/mail"))
1844 (setenv "DESTDIR" out)
1845 (with-directory-excursion "cf/cf"
1846 (zero? (system* "sh" "Build" "install-cf")))))))
1847 ;; There is no make check. There are some post installation tests, but those
1848 ;; require root privileges
1849 #:tests? #f))
1850 (inputs
1851 `(("m4" ,m4)
1852 ("perl" ,perl)))
1853 (home-page "http://sendmail.org")
1854 (synopsis
1855 "Highly configurable Mail Transfer Agent (MTA)")
1856 (description
1857 "Sendmail is a mail transfer agent (MTA) originally developed by Eric
1858Allman. It is highly configurable and supports many delivery methods and many
1859transfer protocols.")
1860 (license (non-copyleft "file://LICENSE"
1861 "See LICENSE in the distribution."))))
1862
8b53366c 1863(define-public opensmtpd
1864 (package
1865 (name "opensmtpd")
eb4b3e4b 1866 (version "6.0.2p1")
8b53366c 1867 (source (origin
1868 (method url-fetch)
1869 (uri (string-append "https://www.opensmtpd.org/archives/"
1870 name "-" version ".tar.gz"))
1871 (sha256
1872 (base32
eb4b3e4b 1873 "1b4h64w45hpmfq5721smhg4s0shs64gbcjqjpx3fbiw4hz8bdy9a"))))
8b53366c 1874 (build-system gnu-build-system)
1875 (inputs
1876 `(("bdb" ,bdb)
1877 ("libressl" ,libressl)
1878 ("libevent" ,libevent)
1879 ("libasr" ,libasr)
1880 ("linux-pam" ,linux-pam)
1881 ("zlib" ,zlib)))
1882 (native-inputs
d7da7604
SB
1883 `(("bison" ,bison)
1884 ("groff" ,groff)))
8b53366c 1885 (arguments
ae1e2133
SB
1886 `(#:configure-flags
1887 (list "--with-table-db" "--localstatedir=/var"
1888 "--with-user-smtpd=smtpd" "--with-user-queue=smtpq"
1889 "--with-group-queue=smtpq"
1890 "--with-path-socket=/var/run"
1891 "--with-path-CAfile=/etc/ssl/certs/ca-certificates.crt")
8b53366c 1892 #:phases
1893 (modify-phases %standard-phases
1894 ;; OpenSMTPD provides a single utility smtpctl to control the daemon and
1895 ;; the local submission subsystem. To accomodate systems that require
1896 ;; historical interfaces such as sendmail, newaliases or makemap, the
1897 ;; smtpctl utility can operate in compatibility mode if called with the
1898 ;; historical name.
1899 (add-after 'install 'install-compabilitymode
1900 (lambda _
1901 (let* ((out (assoc-ref %outputs "out"))
1902 (sbin (string-append out "/sbin/")))
1903 (for-each (lambda (cmd)
1904 (symlink "smtpctl" (string-append sbin cmd)))
1905 '("makemap" "sendmail" "send-mail"
1906 "newaliases" "mailq")))
1907 #t)))))
1908 (synopsis "Lightweight SMTP daemon")
1909 (description
1910 "OpenSMTPD is an implementation of the server-side SMTP protocol, with
1911some additional standard extensions. It allows ordinary machines to exchange
1912e-mails with other systems speaking the SMTP protocol.")
1913 (home-page "https://www.opensmtpd.org")
1914 (license (list bsd-2 bsd-3 bsd-4 (non-copyleft "file://COPYING")
19262a71 1915 public-domain isc license:openssl))))
152ffe7c 1916
1917(define-public opensmtpd-extras
1918 (package
1919 (name "opensmtpd-extras")
1920 (version "5.7.1")
1921 (source (origin
1922 (method url-fetch)
1923 (uri (string-append "https://www.opensmtpd.org/archives/"
1924 name "-" version ".tar.gz"))
1925 (sha256
1926 (base32
1927 "1kld4hxgz792s0cb2gl7m2n618ikzqkj88w5dhaxdrxg4x2c4vdm"))))
1928 (build-system gnu-build-system)
1929 (inputs
1930 `(("libressl" ,libressl)
1931 ("libevent" ,libevent)
1932 ("libasr" ,libasr)
1933 ("python-2" ,python-2)
1934 ("opensmtpd" ,opensmtpd)
1935 ("perl" ,perl)
1936 ("lua" ,lua)
1937 ("postgresql" ,postgresql)
1938 ("sqlite" ,sqlite)
1939 ("linux-pam" ,linux-pam)))
1940 (native-inputs
1941 `(("bison" ,bison)
1942 ("pkg-config" ,pkg-config)
1943 ("groff" ,groff)
1944 ("automake" ,automake)
1945 ("autoconf" ,autoconf)))
1946 (arguments
1947 `(;; We have to configure it like this because the default checks for for example
1948 ;; python in /usr/local/bin, /usr/bin and fails otherwise.
1949 #:configure-flags (list
1950 "--with-filter-clamav" "--with-filter-dkim-signer"
1951 "--with-filter-dnsbl" "--with-filter-lua"
1952 "--with-filter-monkey" "--with-filter-pause"
1953 "--with-filter-perl" "--with-filter-python"
1954 "--with-filter-regex" "--with-filter-spamassassin"
1955 "--with-filter-stub" "--with-filter-trace"
1956 "--with-filter-void"
1957
1958 "--with-queue-null" "--with-queue-python"
1959 "--with-queue-ram" "--with-queue-stub"
1960
1961 "--with-scheduler-python" "--with-scheduler-ram"
1962 "--with-scheduler-stub"
1963
1964 "--with-table-ldap" ; "--with-table-mysql"
1965 "--with-table-passwd" "--with-table-postgres"
1966 "--with-table-python" "--with-table-socketmap"
1967 "--with-table-sqlite" "--with-table-stub"
1968 ;;"--with-table-redis" ; TODO: package hiredis
1969
1970 "--with-user=smtpd" "--with-privsep-user=smtpd"
1971 "--localstatedir=/var" "--sysconfdir=/etc"
1972 "--with-lua-type=lua" ; can use lua or luajit
1973
1974 (string-append "--with-python="
1975 (assoc-ref %build-inputs "python-2"))
1976 (string-append "--with-lua="
1977 (assoc-ref %build-inputs "lua")))))
19262a71
LC
1978 (license (list bsd-2 bsd-3 bsd-4
1979 public-domain isc license:openssl))
152ffe7c 1980 (synopsis "Extra tables, filters, and various other addons for OpenSMTPD")
1981 (description
1982 "This package provides extra tables, filters, and various other addons
1983for OpenSMTPD to extend its functionality.")
1984 (home-page "https://www.opensmtpd.org")))
6d3dda4f 1985
1986(define-public python-mailmanclient
1987 (package
1988 (name "python-mailmanclient")
1989 (version "1.0.1")
1990 (source
1991 (origin
1992 (method url-fetch)
1993 (uri (pypi-uri "mailmanclient" version))
1994 (sha256
1995 (base32
1996 "1cfjh45fgbsax5hjj2inq9nk33dhdvh63xhysc8dhnqidgqgm8c5"))))
1997 (build-system python-build-system)
1998 (arguments
1999 `(#:tests? #f)) ; Requires mailman running
f22efa01 2000 (propagated-inputs
6d3dda4f 2001 `(("python-six" ,python-six)
2002 ("python-httplib2" ,python-httplib2)))
2003 (home-page "https://launchpad.net/mailman.client")
2004 (synopsis "Python bindings for the Mailman 3 REST API")
2005 (description
2006 "The mailmanclient library provides official Python bindings for
2007the GNU Mailman 3 REST API.")
6d3dda4f 2008 (license lgpl3+)))
2009
2010(define-public python2-mailmanclient
5c31f4aa 2011 (package-with-python2 python-mailmanclient))
3163a289 2012
2013(define-public mlmmj
2014 (package
2015 (name "mlmmj")
2016 (version "1.2.19.0")
2017 (source
2018 (origin
2019 (method url-fetch)
2020 (uri (string-append "http://mlmmj.org/releases/mlmmj-"
2021 version ".tar.bz2"))
2022 (sha256
2023 (base32
2024 "1piwvcxkqadjwk5x8jicaiyz9nngmaj3w13ghdqgaki32xd7zk9v"))))
2025 (build-system gnu-build-system)
2026 (inputs
2027 `(("perl" ,perl))) ; For "contrib/web/"
2028 (native-inputs
2029 `(("pkg-config" ,pkg-config)))
2030 (arguments
2031 `(#:configure-flags
2032 ;; mlmmj-receive-strip is a replacement for mlmmj-receive
2033 ;; It opens the files control/mimedeny and control/mimestrip to get a list
2034 ;; of mimetypes for parts of multipart/mime messages that should be denied
2035 ;; or stripped. The parts then get stripped directly when the mail is
2036 ;; received. mlmmj-receive-strip also appends an extra header
2037 ;; X-ThisMailContainsUnwantedMimeParts: Y when the mail contains unwanted
2038 ;; mime parts
2039 (list "--enable-receive-strip")
2040 #:phases
2041 (modify-phases %standard-phases
2042 (add-before 'install 'install-contrib
2043 (lambda* (#:key outputs #:allow-other-keys)
2044 (let* ((out (assoc-ref outputs "out"))
2045 (share (string-append out "/share/mlmmj"))
2046 (contrib (string-append share "/contrib/web"))
2047 (texts (string-append share "/listtexts")))
2048 (copy-recursively "contrib/web/" contrib)
2049 (copy-recursively "listtexts" texts)
2050 (rename-file texts (string-append share "/texts"))
2051 #t))))))
2052 (home-page "http://mlmmj.org")
2053 (synopsis "Mailing list managing made joyful")
2054 (description
2055 "Mlmmj is a simple and slim mailing list manager (MLM) inspired by ezmlm.
2056It works with many different Mail Transport Agents (MTAs) and is simple for a
2057system adminstrator to install, configure and integrate with other software.
2058As it uses very few resources, and requires no daemons, it is ideal for
2059installation on systems where resources are limited. Its features include:
2060@enumerate
2061@item Archive, Custom headers / footer,
2062@item Fully automated bounce handling (similar to ezmlm),
2063@item Complete requeueing functionality, Moderation functionality, Subject prefix,
2064@item Subscribers only posting, Regular expression access control,
2065@item Functionality to retrieve old posts, Web interface, Digests,
2066@item No-mail subscription, VERP support,
2067@item Delivery Status Notification (RFC1891) support,
2068@item Rich and customisable texts for automated operations.
2069@end enumerate\n")
2070 (license license:expat)))
3a263368 2071
8a3741e6 2072(define-public python-django-mailman3
2073 (package
2074 (name "python-django-mailman3")
2075 (version "1.0.1")
2076 (source
2077 (origin
2078 (method url-fetch)
2079 (uri (pypi-uri "django-mailman3" version))
2080 (sha256
2081 (base32
2082 "1adxyh8knw9knjlh73xq0jpn5adml0ck4alsv0swakm95wfyx46z"))))
2083 (build-system python-build-system)
2084 (inputs
99a8c8bd 2085 `(("python-django" ,python-django)))
8a3741e6 2086 (propagated-inputs
2087 `(("python-requests" ,python-requests)
2088 ("python-requests-oauthlib" ,python-requests-oauthlib)
2089 ("python-openid" ,python-openid)
2090 ("python-mailmanclient" ,python-mailmanclient)
2091 ("python-django-allauth" ,python-django-allauth)
2092 ("python-django-gravatar2" ,python-django-gravatar2)
2093 ("python-pytz" ,python-pytz)))
2094 (home-page "https://gitlab.com/mailman/django-mailman3")
2095 (synopsis "Django library for Mailman UIs")
2096 (description
2097 "Libraries and templates for Django-based interfaces
2098interacting with Mailman.")
2099 (license gpl3+)))
2100
2101(define-public python2-django-mailman3
2102 (let ((base (package-with-python2
2103 python-django-mailman3)))
2104 (package
2105 (inherit base)
2106 (propagated-inputs
2107 `(("python2-openid" ,python2-openid)
2108 ,@(package-propagated-inputs base))))))
2109
d99a2add 2110(define-public postorius
2111 (package
2112 (name "postorius")
2113 (version "1.0.3")
2114 (source
2115 (origin
2116 (method url-fetch)
2117 (uri (pypi-uri "postorius" version "+post2.tar.gz"))
2118 (file-name (string-append name "-" version ".tar.gz"))
2119 (sha256
2120 (base32
2121 "1wymcpv2icjjy8h1ni52p6dr7wwxf71ivqgbqhzx4i82yqphcaq5"))))
2122 (build-system python-build-system)
2123 (arguments
2124 `(; One test dependency relies on Persona, which was shut down in
2125 ;; November 2016.
2126 #:tests? #f
2127 ;; The part of the frontend of Mailman is still python 2.7.
2128 #:python ,python-2))
2129 (inputs
2130 `(("python2-django" ,python2-django)
2131 ("python2-django-mailman3" ,python2-django-mailman3)
2132 ("python2-mailmanclient" ,python2-mailmanclient)))
2133 (home-page "https://gitlab.com/mailman/postorius")
2134 (synopsis "Web user interface for GNU Mailman")
2135 (description
2136 "Postorius is a Django app which provides a web user interface
2137to access GNU Mailman.")
2138 (license (list gpl3+ lgpl3+))))
2139
3a263368 2140(define-public blists
2141 (package
2142 (name "blists")
2143 (version "1.0")
2144 (source
2145 (origin
2146 (method url-fetch)
2147 (uri (string-append "http://download.openwall.net/pub/projects/"
2148 "blists/blists-" version ".tar.gz"))
2149 (sha256
2150 (base32
2151 "1gp51kmb8yv8d693wcpdslmwlbw5w2kgz4kxhrcaf7y89w8wy4qd"))))
2152 (build-system gnu-build-system)
2153 (arguments
2154 `(#:tests? #f ; No tests
2155 #:phases
2156 (modify-phases %standard-phases
2157 (delete 'configure)
2158 (replace 'install
2159 (lambda* (#:key outputs #:allow-other-keys)
2160 (let* ((out (assoc-ref outputs "out"))
2161 (bin (string-append out "/bin")))
2162 (install-file "bindex" bin)
2163 (install-file "bit" bin)
2164 #t))))))
2165 (home-page "http://www.openwall.com/blists/")
2166 (synopsis "Web interface to mailing list archives")
2167 (description
2168 "Blists is a web interface to mailing list archives that works off
2169indexed mbox files. There are two programs: @code{bindex} and @code{bit}.
2170@code{bindex} generates or updates the index file (incremental updates
2171are supported). @code{bit} is a CGI/SSI program that generates web pages
2172on the fly. Both programs are written in C and are very fast.")
2173 (license license:expat)))
ed428a58
AI
2174
2175(define-public swaks
2176 (package
2177 (name "swaks")
2178 (version "20170101.0")
2179 (source
2180 (origin
2181 (method url-fetch)
2182 (uri (string-append
2183 "http://jetmore.org/john/code/swaks/files/swaks-"
2184 version ".tar.gz"))
2185 (sha256
2186 (base32
2187 "0pli4mlhasnqqxmmxalwyg3x7n2vhcbgsnp2xgddamjavv82vrl4"))))
2188 (build-system perl-build-system)
2189 (inputs
2190 `(("perl-net-dns" ,perl-net-dns)
2191 ("perl-net-ssleay" ,perl-net-ssleay)))
2192 (arguments
2193 `(#:tests? #f ; No tests
2194 #:phases
2195 (modify-phases %standard-phases
2196 (delete 'configure)
2197 (replace 'build
2198 (lambda _
2199 (zero? (system* "pod2man" "doc/ref.pod" "swaks.1"))))
2200 (replace 'install
2201 (lambda* (#:key outputs #:allow-other-keys)
2202 (let ((out (assoc-ref outputs "out")))
2203 (install-file "swaks" (string-append out "/bin"))
2204 (install-file "swaks.1" (string-append out "/share/man/man1")))
2205 #t))
2206 (add-after 'install 'wrap-program
2207 (lambda* (#:key outputs #:allow-other-keys)
2208 (wrap-program (string-append (assoc-ref outputs "out")
2209 "/bin/swaks")
2210 `("PERL5LIB" ":" = (,(getenv "PERL5LIB"))))
2211 #t)))))
2212 (home-page "http://jetmore.org/john/code/swaks/")
2213 (synopsis "Featureful SMTP test tool")
2214 (description "Swaks is a flexible, scriptable, transaction-oriented SMTP
2215test tool. It handles SMTP features and extensions such as TLS,
2216authentication, and pipelining; multiple versions of the SMTP protocol
2217including SMTP, ESMTP, and LMTP; and multiple transport methods including
2218unix-domain sockets, internet-domain sockets, and pipes to spawned processes.
2219Options can be specified in environment variables, configuration files, and
2220the command line allowing maximum configurability and ease of use for
2221operators and scripters.")
2222 (license gpl2+)))
b0eb2af2 2223
2224(define-public alpine
2225 (package
2226 (name "alpine")
2227 (version "2.21")
2228 (source
2229 (origin
2230 (method url-fetch)
2231 ;; There are two versions: the plain continuation of Alpine without extra
2232 ;; patches and the version which adds extra fixes. Every distro uses
2233 ;; the patched version, and so do we to not break expectations.
2234 ;; http://patches.freeiz.com/alpine/readme/README.patches
2235 (uri (string-append "http://patches.freeiz.com/alpine/patches/alpine-"
2236 version "/alpine-" version ".tar.xz"))
2237 (sha256
2238 (base32
2239 "1k9hcfjywfk3mpsl71hjza3nk6icgf1b6xxzgx10kdzg5yci5x5m"))))
2240 (build-system gnu-build-system)
2241 (arguments
2242 `(#:make-flags (list "CC=gcc")
2243 #:configure-flags (list (string-append "--with-ssl-include-dir="
2244 (assoc-ref %build-inputs "openssl")
2245 "/include/openssl")
2246 (string-append "--with-ssl-dir="
2247 (assoc-ref %build-inputs "openssl"))
2248 (string-append "--with-ssl-certs-dir="
2249 "/etc/ssl/certs/")
2250 (string-append "--with-ssl-lib-dir="
2251 (assoc-ref %build-inputs "openssl")
2252 "/lib")
2253 (string-append "--with-interactive-spellcheck="
2254 (assoc-ref %build-inputs "aspell")
2255 "/bin/aspell"))
2256 #:phases
2257 (modify-phases %standard-phases
2258 (add-after 'unpack 'make-reproducible
2259 (lambda _
2260 ;; This removes time-dependent code to make alpine reproducible.
2261 (substitute* "pico/blddate.c"
2262 (("%02d-%s-%d") "1970-01-01"))
2263 (substitute* (list "alpine/Makefile.in"
2264 "web/src/alpined.d/Makefile.in")
2265 (("`date`") "1970-01-01"))
2266 #t)))))
2267 (inputs
2268 `(("ncurses" ,ncurses)
2269 ("openssl" ,openssl)
2270 ("gnutls" ,gnutls)
2271 ("openldap" ,openldap)
2272 ("cyrus-sasl" ,cyrus-sasl)
2273 ("mit-krb5" ,mit-krb5)
2274 ("aspell" ,aspell)
2275 ("tcl" ,tcl)
2276 ("linux-pam" ,linux-pam)))
2277 (home-page "http://patches.freeiz.com/alpine/")
2278 (synopsis "Alternatively Licensed Program for Internet News and Email")
2279 (description
2280 "Alpine is a text-based mail and news client. Alpine includes several
2281tools and applications:
2282@enumerate
2283@item alpine, the Alpine mailer
2284@item pico, the standalone text editor, GNU nano's predecessor
2285@item pilot, the standalone file system navigator
2286@end enumerate\n")
2287 (license asl2.0)))