gnu: mailutils: Update to 3.10.
[jackhill/guix/guix.git] / gnu / packages / mail.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2014, 2015, 2017 Mark H Weaver <mhw@netris.org>
4 ;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net>
5 ;;; Copyright © 2014 Sou Bunnbu <iyzsong@gmail.com>
6 ;;; Copyright © 2014, 2019 Julien Lepiller <julien@lepiller.eu>
7 ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
8 ;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
9 ;;; Copyright © 2015, 2016, 2018 Eric Bavier <bavier@member.fsf.org>
10 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
11 ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
12 ;;; Copyright © 2016 Christopher Allan Webber <cwebber@dustycloud.org>
13 ;;; Copyright © 2016 Al McElrath <hello@yrns.org>
14 ;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
15 ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org>
16 ;;; Copyright © 2016 Alex Kost <alezost@gmail.com>
17 ;;; Copyright © 2016, 2017 Troy Sankey <sankeytms@gmail.com>
18 ;;; Copyright © 2016, 2017, 2018 Nikita <nikita@n0.is>
19 ;;; Copyright © 2016 Clément Lassieur <clement@lassieur.org>
20 ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Arun Isaac <arunisaac@systemreboot.net>
21 ;;; Copyright © 2016 John Darrington <jmd@gnu.org>
22 ;;; Copyright © 2016, 2018 Marius Bakke <mbakke@fastmail.com>
23 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
24 ;;; Copyright © 2017 Kyle Meyer <kyle@kyleam.com>
25 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
26 ;;; Copyright © 2017, 2018, 2020 Rene Saavedra <pacoon@protonmail.com>
27 ;;; Copyright © 2018, 2019, 2020 Pierre Langlois <pierre.langlois@gmx.com>
28 ;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
29 ;;; Copyright © 2018 Gábor Boskovits <boskovits@gmail.com>
30 ;;; Copyright © 2018, 2019, 2020 Ricardo Wurmus <rekado@elephly.net>
31 ;;; Copyright © 2019 Tanguy Le Carrour <tanguy@bioneland.org>
32 ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
33 ;;; Copyright © 2020 Justus Winter <justus@sequoia-pgp.org>
34 ;;; Copyright © 2020 Eric Brown <ecbrown@ericcbrown.com>
35 ;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
36 ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
37 ;;;
38 ;;; This file is part of GNU Guix.
39 ;;;
40 ;;; GNU Guix is free software; you can redistribute it and/or modify it
41 ;;; under the terms of the GNU General Public License as published by
42 ;;; the Free Software Foundation; either version 3 of the License, or (at
43 ;;; your option) any later version.
44 ;;;
45 ;;; GNU Guix is distributed in the hope that it will be useful, but
46 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
47 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
48 ;;; GNU General Public License for more details.
49 ;;;
50 ;;; You should have received a copy of the GNU General Public License
51 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
52
53 (define-module (gnu packages mail)
54 #:use-module (gnu packages)
55 #:use-module (gnu packages admin)
56 #:use-module (gnu packages aspell)
57 #:use-module (gnu packages autotools)
58 #:use-module (gnu packages backup)
59 #:use-module (gnu packages base)
60 #:use-module (gnu packages bash)
61 #:use-module (gnu packages bison)
62 #:use-module (gnu packages calendar)
63 #:use-module (gnu packages check)
64 #:use-module (gnu packages compression)
65 #:use-module (gnu packages crypto)
66 #:use-module (gnu packages curl)
67 #:use-module (gnu packages cyrus-sasl)
68 #:use-module (gnu packages databases)
69 #:use-module (gnu packages dbm)
70 #:use-module (gnu packages dejagnu)
71 #:use-module (gnu packages django)
72 #:use-module (gnu packages dns)
73 #:use-module (gnu packages docbook)
74 #:use-module (gnu packages documentation)
75 #:use-module (gnu packages emacs)
76 #:use-module (gnu packages enchant)
77 #:use-module (gnu packages gdb)
78 #:use-module (gnu packages gettext)
79 #:use-module (gnu packages ghostscript)
80 #:use-module (gnu packages glib)
81 #:use-module (gnu packages gnome)
82 #:use-module (gnu packages gnupg)
83 #:use-module (gnu packages groff)
84 #:use-module (gnu packages gsasl)
85 #:use-module (gnu packages gtk)
86 #:use-module (gnu packages guile)
87 #:use-module (gnu packages guile-xyz)
88 #:use-module (gnu packages flex)
89 #:use-module (gnu packages haskell-xyz)
90 #:use-module (gnu packages kerberos)
91 #:use-module (gnu packages libcanberra)
92 #:use-module (gnu packages libevent)
93 #:use-module (gnu packages libidn)
94 #:use-module (gnu packages libunistring)
95 #:use-module (gnu packages libunwind)
96 #:use-module (gnu packages linux)
97 #:use-module (gnu packages lsof)
98 #:use-module (gnu packages lua)
99 #:use-module (gnu packages m4)
100 #:use-module (gnu packages man)
101 #:use-module (gnu packages ncurses)
102 #:use-module (gnu packages networking)
103 #:use-module (gnu packages openldap)
104 #:use-module (gnu packages onc-rpc)
105 #:use-module (gnu packages pcre)
106 #:use-module (gnu packages perl)
107 #:use-module (gnu packages perl-check)
108 #:use-module (gnu packages perl-web)
109 #:use-module (gnu packages pkg-config)
110 #:use-module (gnu packages python)
111 #:use-module (gnu packages python-check)
112 #:use-module (gnu packages python-crypto)
113 #:use-module (gnu packages python-web)
114 #:use-module (gnu packages python-xyz)
115 #:use-module (gnu packages readline)
116 #:use-module (gnu packages ruby)
117 #:use-module (gnu packages search)
118 #:use-module (gnu packages serialization)
119 #:use-module (gnu packages samba)
120 #:use-module (gnu packages screen)
121 #:use-module (gnu packages sphinx)
122 #:use-module (gnu packages sqlite)
123 #:use-module (gnu packages tcl)
124 #:use-module (gnu packages texinfo)
125 #:use-module (gnu packages time)
126 #:use-module (gnu packages tls)
127 #:use-module (gnu packages version-control)
128 #:use-module (gnu packages w3m)
129 #:use-module (gnu packages web)
130 #:use-module (gnu packages webkit)
131 #:use-module (gnu packages xdisorg)
132 #:use-module (gnu packages xorg)
133 #:use-module (gnu packages xml)
134 #:use-module ((guix licenses) #:prefix license:)
135 #:use-module (guix packages)
136 #:use-module (guix download)
137 #:use-module (guix git-download)
138 #:use-module (guix utils)
139 #:use-module (guix build-system gnu)
140 #:use-module (guix build-system guile)
141 #:use-module (guix build-system perl)
142 #:use-module (guix build-system python)
143 #:use-module (guix build-system trivial)
144 #:use-module (srfi srfi-1)
145 #:use-module (ice-9 match))
146
147 (define-public anubis
148 (package
149 (name "anubis")
150 ;; This 4.2.90 alpha release adds support for Guile 3 and has fixes for
151 ;; other issues.
152 (version "4.2.90")
153 (source
154 (origin
155 (method url-fetch)
156 (uri (string-append "https://alpha.gnu.org/gnu/anubis/anubis-"
157 version ".tar.gz"))
158 (sha256
159 (base32
160 "0dvm6acl32dv8bixx9z50gzwfp6kj4kxnn1j3dcwjlp7sasjp41s"))))
161 (build-system gnu-build-system)
162 (native-inputs
163 `(("automake" ,automake)
164 ("autoconf" ,autoconf)
165 ("gettext" ,gettext-minimal)
166 ("m4" ,m4))) ;for the test suite
167 (inputs
168 `(("gdbm" ,gdbm)
169 ("gnutls" ,gnutls)
170 ("gpgme" ,gpgme)
171 ("gsasl" ,gsasl)
172 ("guile" ,guile-3.0)
173 ("libgcrypt" ,libgcrypt) ;gnutls support depends on libgcrypt
174 ("libgpg-error" ,libgpg-error)))
175 (outputs '("out" "debug"))
176 (synopsis "SMTP message submission daemon")
177 (description "Anubis is a daemon that sits between the Mail User
178 Agent (MUA) and the Mail Transfer Agent (MTA). When a mail is sent by a user
179 in the MUA, it is first passed to Anubis, which performs additional processing
180 to the message before passing it on for delivery by the MTA. Anubis may, for
181 example, modify the message headers or body, or encrypt or sign the message.")
182 (home-page "https://www.gnu.org/software/anubis/manual/")
183 (license license:gpl3+)))
184
185 (define-public mailutils
186 (package
187 (name "mailutils")
188 (version "3.10")
189 (source (origin
190 (method url-fetch)
191 (uri (string-append "mirror://gnu/mailutils/mailutils-"
192 version ".tar.xz"))
193 (sha256
194 (base32
195 "17smrxjdgbbzbzakik30vj46q4iib85ksqhb82jr4vjp57akszh9"))))
196 (build-system gnu-build-system)
197 (arguments
198 `(#:phases
199 (modify-phases %standard-phases
200 (add-before 'check 'prepare-test-suite
201 (lambda _
202 ;; Use the right file name for `cat'.
203 (substitute* "testsuite/lib/mailutils.exp"
204 (("/bin/cat")
205 (which "cat")))
206
207 ;; Tests try to invoke 'mda' such that it looks up the
208 ;; 'root' user, which does not exist in the build
209 ;; environment.
210 (substitute* '("mda/mda/tests/testsuite"
211 "mda/lmtpd/tests/testsuite")
212 (("root <") "nobody <")
213 (("spool/root") "spool/nobody")
214 (("root@localhost") "nobody@localhost"))
215
216 ;; The 'pipeact.at' tests generate a shell script; make
217 ;; sure it uses the right shell.
218 (substitute* '("sieve/tests/testsuite"
219 "mh/tests/testsuite")
220 (("#! /bin/sh")
221 (string-append "#!" (which "sh"))))
222
223 (substitute* "mh/tests/testsuite"
224 (("moreproc: /bin/cat")
225 (string-append "moreproc: " (which "cat"))))
226
227 ;; XXX: The comsatd tests rely on being able to open
228 ;; /dev/tty, but that gives ENODEV in the build
229 ;; environment. Thus, ignore test failures here.
230 (substitute* "comsat/tests/Makefile.in"
231 (("\\$\\(SHELL\\) \\$\\(TESTSUITE\\)" all)
232 (string-append "-" all)))
233
234 ;; XXX: The ‘moderator: program discard’ test does not specify
235 ;; an explicit From: but does expect an exact match. But why are
236 ;; all other tests unaffected?
237 (substitute* "sieve/tests/testsuite"
238 (("gray@")
239 "nixbld@"))
240
241 ;; 'frm' tests expect write access to $HOME.
242 (setenv "HOME" (getcwd))
243
244 ;; Avoid the message "I'm going to create the standard MH path
245 ;; for you", which would lead to one test failure (when diffing
246 ;; stdout of 'fmtcheck'.)
247 (call-with-output-file ".mh_profile"
248 (lambda (port)
249 (format port "Path: ~a/Mail-for-tests~%"
250 (getcwd))))
251
252 #t)))
253 ;; TODO: Add `--with-sql'.
254 #:configure-flags
255 (list "--sysconfdir=/etc"
256
257 ;; Add "/X.Y" to the installation directory.
258 (string-append "--with-guile-site-dir="
259 (assoc-ref %outputs "out")
260 "/share/guile/site/"
261 ,(match (assoc "guile"
262 (package-inputs this-package))
263 (("guile" guile)
264 (version-major+minor
265 (package-version guile))))))
266
267 #:parallel-tests? #f))
268 (native-inputs
269 `(("perl" ,perl) ;for 'gylwrap'
270 ("texinfo" ,texinfo)
271 ("dejagnu" ,dejagnu)))
272 (inputs
273 `(("m4" ,m4)
274 ("guile" ,guile-3.0)
275 ("gsasl" ,gsasl)
276 ("gnutls" ,gnutls)
277 ("ncurses" ,ncurses)
278 ("readline" ,readline)
279 ("linux-pam" ,linux-pam)
280 ("libltdl" ,libltdl)
281 ("gdbm" ,gdbm)
282
283 ;; Required for SEARCH CHARSET.
284 ("libiconv" ,libiconv)
285 ("libunistring" ,libunistring)))
286 (home-page "https://mailutils.org")
287 (synopsis "Utilities and library for reading and serving mail")
288 (description
289 "GNU Mailutils is a collection of programs for managing, viewing and
290 processing electronic mail. It contains both utilities and server daemons
291 and all operate in a protocol-agnostic way. The underlying libraries are
292 also available, simplifying the addition of mail capabilities to new
293 software.")
294 (license
295 ;; Libraries are under LGPLv3+, and programs under GPLv3+.
296 (list license:gpl3+ license:lgpl3+))))
297
298 (define-public guile2.2-mailutils
299 (package
300 (inherit mailutils)
301 (name "guile2.2-mailutils")
302 (inputs
303 `(("guile" ,guile-2.2)
304 ,@(alist-delete "guile" (package-inputs mailutils))))))
305
306 (define-public guile3.0-mailutils
307 (deprecated-package "guile3.0-mailutils" mailutils))
308
309 (define-public nullmailer
310 (package
311 (name "nullmailer")
312 (version "2.2")
313 (source
314 (origin
315 (method url-fetch)
316 (uri (list
317 (string-append "https://untroubled.org/nullmailer/"
318 "nullmailer-" version ".tar.gz")
319 ;; Previous releases are moved to this subdirectory.
320 (string-append "https://untroubled.org/nullmailer/archive/"
321 "nullmailer-" version ".tar.gz")))
322 (sha256
323 (base32 "0md8cf90fl2yf3zh9njjy42a673v4j4ygyq95xg7fzkygdigm1lq"))))
324 (build-system gnu-build-system)
325 (arguments
326 `(#:configure-flags
327 (list "--enable-tls"
328 "--localstatedir=/var"
329 "--sysconfdir=/etc")
330 #:phases
331 (modify-phases %standard-phases
332 (add-before 'check 'patch-test-FHS-file-names
333 (lambda _
334 (with-directory-excursion "test"
335 (substitute* (list "functions.in"
336 "tests/send")
337 ;; Fix some shebangs later generated on the fly.
338 (("/bin/sh") (which "bash"))))
339 #t))
340 (add-before 'check 'pass-PATH-to-tests
341 ;; ‘runtest’ launches each test through ‘env -’, clearing $PATH. The
342 ;; tests then source ‘functions’, which first demands a working $PATH
343 ;; only to clobber it later. Pass our $PATH to the test environment
344 ;; and don't touch it after that.
345 (lambda _
346 (with-directory-excursion "test"
347 (substitute* "runtests"
348 (("env - bash")
349 (string-append "env - PATH=\"" (getenv "PATH") "\" bash")))
350 (substitute* "functions.in"
351 (("export PATH=.*") "")))
352 #t))
353 (add-before 'check 'delete-failing-tests
354 (lambda _
355 (with-directory-excursion "test/tests"
356 (for-each delete-file
357 (list
358 ;; XXX ‘nullmailer-inject: nullmailer-queue failed: 15’
359 "inject/queue"
360 ;; XXX These require the not-yet-packaged tcpserver.
361 "protocols" "smtp-auth")))
362 #t))
363 (add-before 'install 'skip-install-data-local
364 ;; Don't attempt to install run-time files outside of the store.
365 (lambda _
366 (substitute* "Makefile"
367 ((" install-data-local") ""))
368 #t)))))
369 (native-inputs
370 ;; For tests.
371 `(("daemontools" ,daemontools))) ; for svc
372 (inputs
373 `(("gnutls" ,gnutls)))
374 (home-page "https://untroubled.org/nullmailer/")
375 (synopsis "Simple relay-only mail transfer agent")
376 (description
377 "Nullmailer is a simple replacement @acronym{MTA, Mail Transfer Agent} for
378 hosts that receive no local mail and only relay mail to a fixed set of smart
379 relays. It's useful for systems such as Web servers that must be able to send
380 email notifications, without having to run a full-blown MTA such as sendmail
381 or qmail.
382
383 Nullmailer is designed to be simple to configure, easy to extend, and secure.
384 It requires little ongoing administration. The included @command{sendmail}
385 emulator front-end should allow most (if not all) sendmail-compatible programs
386 to run without any changes.")
387 (license (list license:lgpl2.1+ ; lib/cli++/ (but some files lack headers)
388 license:gpl2+)))) ; everything else
389
390 (define-public fetchmail
391 (package
392 (name "fetchmail")
393 (version "6.4.8")
394 (source
395 (origin
396 (method url-fetch)
397 (uri (string-append "mirror://sourceforge/fetchmail/branch_"
398 (version-major+minor version) "/"
399 "fetchmail-" version ".tar.xz"))
400 (sha256
401 (base32 "1g893dr3982vrqzxybmflnqfmd1q6yipd9krvxn0avhlrrp97k96"))))
402 (build-system gnu-build-system)
403 (inputs
404 `(("openssl" ,openssl)))
405 (arguments
406 `(#:configure-flags
407 (list (string-append "--with-ssl="
408 (assoc-ref %build-inputs "openssl")))))
409 (home-page "https://www.fetchmail.info/")
410 (synopsis "Remote-mail retrieval and forwarding utility")
411 (description
412 "Fetchmail is a full-featured, robust, well-documented remote-mail
413 retrieval and forwarding utility intended to be used over on-demand
414 TCP/IP links (such as SLIP or PPP connections). It supports every
415 remote-mail protocol now in use on the Internet: POP2, POP3, RPOP, APOP,
416 KPOP, all flavors of IMAP, ETRN, and ODMR. It can even support IPv6
417 and IPSEC.
418
419 Fetchmail retrieves mail from remote mail servers and forwards it via SMTP,
420 so it can then be read by normal mail user agents such as mutt, elm
421 or BSD Mail. It allows all your system MTA's filtering, forwarding, and
422 aliasing facilities to work just as they would on normal mail.")
423 (license license:gpl2+))) ; most files are actually public domain or x11
424
425 (define-public mutt
426 (package
427 (name "mutt")
428 (version "1.14.6")
429 (source (origin
430 (method url-fetch)
431 (uri (list
432 (string-append "https://bitbucket.org/mutt/mutt/downloads/"
433 "mutt-" version ".tar.gz")
434 (string-append "http://ftp.mutt.org/pub/mutt/mutt-"
435 version ".tar.gz")))
436 (sha256
437 (base32
438 "0i0q6vwhnb1grimsrpmz8maw255rh9k0laijzxkry6xqa80jm5s7"))
439 (patches (search-patches "mutt-store-references.patch"))))
440 (build-system gnu-build-system)
441 (inputs
442 `(("cyrus-sasl" ,cyrus-sasl)
443 ("gdbm" ,gdbm)
444 ("gpgme" ,gpgme)
445 ("libidn2" ,libidn2)
446 ("ncurses" ,ncurses)
447 ("openssl" ,openssl)
448 ("perl" ,perl)
449 ("sqlite" ,sqlite)))
450 (arguments
451 `(#:configure-flags '("--enable-smtp"
452 "--enable-imap"
453 "--enable-pop"
454 "--enable-gpgme"
455 "--enable-hcache" ; for header caching
456 "--enable-sidebar"
457 "--enable-autocrypt"
458 "--with-ssl"
459 "--with-sasl"
460 "--with-sqlite3" ; required for Autocrypt
461 "--with-idn2" ; recommended for Autocrypt
462 ;; So that mutt does not check whether the path
463 ;; exists, which it does not in the chroot.
464 "--with-mailpath=/var/mail")))
465 (home-page "http://www.mutt.org/")
466 (synopsis "Mail client")
467 (description
468 "Mutt is a small but very powerful text-based mail client for Unix
469 operating systems.")
470 (license license:gpl2+)))
471
472 (define-public neomutt
473 (package
474 (name "neomutt")
475 (version "20200313")
476 (source
477 (origin
478 (method git-fetch)
479 (uri (git-reference
480 (url "https://github.com/neomutt/neomutt")
481 (commit version)))
482 (file-name (git-file-name name version))
483 (sha256
484 (base32 "1k4k07l6h5krc3fx928qvdq3ssw9fxn95aj7k885xlckd2i1lnb5"))))
485 (build-system gnu-build-system)
486 (inputs
487 `(("cyrus-sasl" ,cyrus-sasl)
488 ("gdbm" ,gdbm)
489 ("gpgme" ,gpgme)
490 ("ncurses" ,ncurses)
491 ("gnutls" ,gnutls)
492 ("openssl" ,openssl) ; for S/MIME
493 ("perl" ,perl)
494 ("kyotocabinet" ,kyotocabinet)
495 ("libxslt" ,libxslt)
496 ("libidn2" ,libidn2)
497 ("libxml2" ,libxml2)
498 ("lmdb" ,lmdb)
499 ("notmuch" ,notmuch)))
500 (native-inputs
501 `(("automake" ,automake)
502 ("gettext-minimal" ,gettext-minimal)
503 ("pkg-config" ,pkg-config)
504 ("docbook-xsl" ,docbook-xsl)
505 ("docbook-xml" ,docbook-xml-4.2)
506 ("w3m" ,w3m)
507 ("tcl" ,tcl)))
508 (arguments
509 `(#:test-target "test"
510 #:configure-flags
511 (list "--gpgme"
512
513 ;; Database, implies header caching.
514 "--disable-tokyocabinet"
515 "--disable-qdbm"
516 "--disable-bdb"
517 "--lmdb"
518 "--kyotocabinet"
519
520 "--gdbm"
521
522 "--gnutls"
523 "--disable-ssl"
524 "--sasl"
525 (string-append "--with-sasl="
526 (assoc-ref %build-inputs "cyrus-sasl"))
527
528
529 "--smime"
530 "--notmuch"
531 "--disable-idn"
532 "--idn2"
533
534 ;; If we do not set this, neomutt wants to check
535 ;; whether the path exists, which it does not
536 ;; in the chroot.
537 "--with-mailpath=/var/mail"
538
539 "--with-ui=ncurses"
540 (string-append "--with-ncurses="
541 (assoc-ref %build-inputs "ncurses"))
542 (string-append "--prefix="
543 (assoc-ref %outputs "out"))
544 "--debug")
545 #:phases
546 (modify-phases %standard-phases
547 ;; TODO: autosetup is meant to be included in the source,
548 ;; but we should package autosetup and use our own version of it.
549 (replace 'configure
550 (lambda* (#:key outputs inputs configure-flags #:allow-other-keys)
551 (let* ((out (assoc-ref outputs "out"))
552 (flags `(,@configure-flags))
553 (bash (which "bash")))
554 (setenv "SHELL" bash)
555 (setenv "CONFIG_SHELL" bash)
556 (apply invoke bash
557 (string-append (getcwd) "/configure")
558 flags)))))))
559 (home-page "https://neomutt.org/")
560 (synopsis "Command-line mail reader based on Mutt")
561 (description
562 "NeoMutt is a command-line mail reader which is based on mutt.
563 It adds a large amount of new and improved features to mutt.")
564 (license license:gpl2+)))
565
566 (define-public gmime
567 (package
568 (name "gmime")
569 (version "3.2.7")
570 (source (origin
571 (method url-fetch)
572 (uri (string-append "mirror://gnome/sources/gmime/"
573 (version-major+minor version)
574 "/gmime-" version ".tar.xz"))
575 (sha256
576 (base32
577 "0i3xfc84qn1z99i70q68kbnp9rmgqrnprqb418ba52s6g9j9dsia"))))
578 (build-system gnu-build-system)
579 (native-inputs
580 `(("pkg-config" ,pkg-config)
581 ("gnupg" ,gnupg))) ; for tests only
582 (inputs `(("glib" ,glib)
583 ("gpgme" ,gpgme)
584 ("zlib" ,zlib)))
585 (arguments
586 `(#:phases
587 (modify-phases %standard-phases
588 (add-after
589 'unpack 'patch-paths-in-tests
590 (lambda _
591 ;; The test programs run several programs using 'system' with
592 ;; hard-coded paths. Here we patch them all.
593 ;; We use ISO-8859-1 here because test-iconv.c contains
594 ;; raw byte sequences in several different encodings.
595 (with-fluids ((%default-port-encoding #f))
596 (substitute* (find-files "tests" "\\.c$")
597 (("(system *\\(\")(/[^ ]*)" all pre prog-path)
598 (let* ((base (basename prog-path))
599 (prog (which base)))
600 (string-append pre
601 (or prog (error "not found: " base)))))))
602 #t)))))
603 (home-page "http://spruce.sourceforge.net/gmime/")
604 (synopsis "MIME message parser and creator library")
605 (description
606 "GMime provides a core library and set of utilities which may be used for
607 the creation and parsing of messages using the Multipurpose Internet Mail
608 Extension (MIME).")
609 (license (list license:lgpl2.1+ license:gpl2+ license:gpl3+))))
610
611 ;; Some packages are not ready for GMime 3 yet.
612 (define-public gmime-2.6
613 (package
614 (inherit gmime)
615 (version "2.6.23")
616 (source (origin
617 (method url-fetch)
618 (uri (string-append "mirror://gnome/sources/gmime/"
619 (version-major+minor version)
620 "/gmime-" version ".tar.xz"))
621 (sha256
622 (base32
623 "0slzlzcr3h8jikpz5a5amqd0csqh2m40gdk910ws2hnaf5m6hjbi"))))))
624
625 (define-public bogofilter
626 (package
627 (name "bogofilter")
628 (version "1.2.5")
629 (source
630 (origin
631 (method url-fetch)
632 (uri (string-append "mirror://sourceforge/bogofilter/bogofilter-stable/"
633 "bogofilter-" version ".tar.xz"))
634 (sha256
635 (base32 "1sl9xrnnlk2sn8gmibhn8li09vnansjbxb9l1182qmgz7cvs2j1j"))))
636 (build-system gnu-build-system)
637 (arguments
638 '(#:phases
639 (modify-phases %standard-phases
640 (add-before 'check 'pre-check
641 (lambda _
642 (substitute* "src/tests/t.frame"
643 (("GREP=/bin/grep")
644 (string-append "GREP=" (which "grep") "\n")))
645 #t)))))
646 (native-inputs `(("flex" ,flex)))
647 (inputs `(("bdb" ,bdb)))
648 (home-page "https://bogofilter.sourceforge.io/")
649 (synopsis "Mail classifier based on a Bayesian filter")
650 (description
651 "Bogofilter is a mail filter that classifies mail as spam or ham
652 (non-spam) by a statistical analysis of the message's header and
653 content (body). The program is able to learn from the user's classifications
654 and corrections. It is based on a Bayesian filter.")
655 (license license:gpl3+)))
656
657 (define-public offlineimap
658 (package
659 (name "offlineimap")
660 (version "7.2.4")
661 (source (origin
662 (method git-fetch)
663 (uri (git-reference
664 (url "https://github.com/OfflineIMAP/offlineimap")
665 (commit (string-append "v" version))))
666 (file-name (git-file-name name version))
667 (sha256
668 (base32
669 "0h5q5nk2p2vx86w6rrbs7v70h81dpqqr68x6l3klzl3m0yj9agb1"))))
670 (build-system python-build-system)
671 (native-inputs
672 `(("asciidoc" ,asciidoc)))
673 (inputs `(("python2-pysqlite" ,python2-pysqlite)
674 ("python2-six" ,python2-six)))
675 (arguments
676 ;; The setup.py script expects python-2.
677 `(#:python ,python-2
678 ;; Tests require a modifiable IMAP account.
679 #:tests? #f
680 #:phases
681 (modify-phases %standard-phases
682 (add-after 'build 'build-documentation
683 (lambda _
684 (substitute* "docs/Makefile"
685 ;; Prevent xmllint and xsltproc from downloading a DTD file.
686 (("a2x -v") "a2x --no-xmllint --xsltproc-opts=--nonet -v"))
687 (invoke "make" "-C" "docs" "man")))
688 (add-after 'install 'install-documentation
689 (lambda* (#:key outputs #:allow-other-keys)
690 (let* ((out (assoc-ref outputs "out"))
691 (man (string-append out "/share/man")))
692 (install-file "docs/offlineimap.1" (string-append man "/man1"))
693 (install-file "docs/offlineimapui.7" (string-append man "/man7"))
694 #t))))))
695 (home-page "https://www.offlineimap.org")
696 (synopsis "Sync emails between two repositories")
697 (description
698 "OfflineImap synchronizes emails between two repositories, so that you
699 can read the same mailbox from multiple computers. It supports IMAP as REMOTE
700 repository and Maildir/IMAP as LOCAL repository.")
701 (license license:gpl2+)))
702
703 (define-public emacs-mew
704 (package
705 (name "emacs-mew")
706 (version "6.8")
707 (source (origin
708 (method url-fetch)
709 (uri (string-append "https://mew.org/Release/mew-"
710 version ".tar.gz"))
711 (sha256
712 (base32
713 "0ixzyq33l6j34410kqav3lwn2wx171zvqd3irvns2jvhrbww8i6g"))))
714 (native-inputs
715 `(("emacs" ,emacs)))
716 (propagated-inputs
717 `(("ruby-sqlite3" ,ruby-sqlite3) ; optional for the database of messages
718 ("ruby" ,ruby))) ; to set GEM_PATH so ruby-sqlite3 is found at runtime
719 (build-system gnu-build-system)
720 (arguments
721 (let ((elisp-dir "/share/emacs/site-lisp")
722 (icon-dir "/share/mew"))
723 `(#:modules ((guix build gnu-build-system)
724 (guix build utils)
725 (guix build emacs-utils))
726 #:imported-modules (,@%gnu-build-system-modules
727 (guix build emacs-utils))
728 #:configure-flags
729 (list (string-append "--with-elispdir=" %output ,elisp-dir)
730 (string-append "--with-etcdir=" %output ,icon-dir))
731 #:phases
732 (modify-phases %standard-phases
733 (add-after 'configure 'patch-mew-icon-directory
734 (lambda* (#:key outputs #:allow-other-keys)
735 (emacs-substitute-sexps "mew-key.el"
736 ("(def.* mew-icon-directory"
737 `(progn
738 (add-to-list 'image-load-path 'mew-icon-directory)
739 ,(string-append (assoc-ref outputs "out") ,icon-dir))))
740 #t))
741 (add-after 'install 'generate-autoloads
742 (lambda* (#:key outputs #:allow-other-keys)
743 (emacs-generate-autoloads
744 "mew" (string-append (assoc-ref outputs "out") ,elisp-dir))
745 #t)))
746 #:tests? #f)))
747 (home-page "https://mew.org")
748 (synopsis "Emacs e-mail client")
749 (description "Mew (Messaging in the Emacs World) is a user interface
750 for text messages, multimedia messages (MIME), news articles and
751 security functionality including PGP, S/MIME, SSH, and SSL.")
752 (license license:bsd-3)))
753
754 (define-public mu
755 (package
756 (name "mu")
757 (version "1.4.13")
758 (source (origin
759 (method url-fetch)
760 (uri (string-append "https://github.com/djcb/mu/releases/"
761 "download/" version "/"
762 "mu-" version ".tar.xz"))
763 (sha256
764 (base32
765 "13kfpr77qrnp3i5qnb5zd03frd3fdviggnl50973gdk0hr7m0smj"))))
766 (build-system gnu-build-system)
767 (native-inputs
768 `(("pkg-config" ,pkg-config)
769 ("glib" ,glib "bin") ; for gtester
770 ("emacs" ,emacs-minimal)
771 ("tzdata" ,tzdata-for-tests))) ; for mu/test/test-mu-query.c
772 (inputs
773 `(("xapian" ,xapian)
774 ("guile" ,guile-2.2)
775 ("glib" ,glib)
776 ("gmime" ,gmime)))
777 (arguments
778 `(#:modules ((guix build gnu-build-system)
779 (guix build utils)
780 (guix build emacs-utils))
781 #:imported-modules (,@%gnu-build-system-modules
782 (guix build emacs-utils))
783 #:phases
784 (modify-phases %standard-phases
785 (add-after 'unpack 'patch-configure
786 ;; By default, elisp code goes to "share/emacs/site-lisp/mu4e",
787 ;; so our Emacs package can't find it. Setting "--with-lispdir"
788 ;; configure flag doesn't help because "mu4e" will be added to
789 ;; the lispdir anyway, so we have to modify "configure.ac".
790 (lambda _
791 (substitute* "configure"
792 (("^ +lispdir=\"\\$\\{lispdir\\}/mu4e/\".*") "")
793 ;; Use latest Guile
794 (("guile-2.0") "guile-2.2"))
795 (substitute* '("guile/Makefile.in"
796 "guile/mu/Makefile.in")
797 (("share/guile/site/2.0/") "share/guile/site/2.2/"))
798 #t))
799 (add-after 'unpack 'patch-bin-sh-in-tests
800 (lambda _
801 (substitute* '("guile/tests/test-mu-guile.c"
802 "mu/test-mu-cmd.c"
803 "mu/test-mu-cmd-cfind.c"
804 "mu/test-mu-query.c"
805 "mu/test-mu-threads.c")
806 (("/bin/sh") (which "sh")))
807 #t))
808 (add-before 'install 'fix-ffi
809 (lambda* (#:key outputs #:allow-other-keys)
810 (substitute* "guile/mu.scm"
811 (("\"libguile-mu\"")
812 (format #f "\"~a/lib/libguile-mu\""
813 (assoc-ref outputs "out"))))
814 #t))
815 (add-before 'check 'check-tz-setup
816 (lambda* (#:key inputs #:allow-other-keys)
817 ;; For mu/test/test-mu-query.c
818 (setenv "TZDIR"
819 (string-append (assoc-ref inputs "tzdata")
820 "/share/zoneinfo"))
821 #t))
822 (add-after 'install 'install-emacs-autoloads
823 (lambda* (#:key outputs #:allow-other-keys)
824 (emacs-generate-autoloads
825 "mu4e"
826 (string-append (assoc-ref outputs "out")
827 "/share/emacs/site-lisp"))
828 #t)))))
829 (home-page "https://www.djcbsoftware.nl/code/mu/")
830 (synopsis "Quickly find emails")
831 (description
832 "Mu is a tool for dealing with e-mail messages stored in the
833 Maildir-format. Mu's purpose in life is to help you to quickly find the
834 messages you need; in addition, it allows you to view messages, extract
835 attachments, create new maildirs, and so on.")
836 (license license:gpl3+)))
837
838 (define-public alot
839 (package
840 (name "alot")
841 (version "0.5.1")
842 (source (origin
843 (method url-fetch)
844 ;; package author intends on distributing via github rather
845 ;; than pypi:
846 ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331
847 (uri (string-append "https://github.com/pazz/alot/archive/"
848 version ".tar.gz"))
849 (file-name (string-append "alot-" version ".tar.gz"))
850 (sha256
851 (base32
852 "0wax30hjzmkqfml7hig1dqw1v1y63yc0cgbzl96x58b9h2ggqx3a"))))
853 (build-system python-build-system)
854 (arguments
855 `(;; python 3 is currently unsupported, more info:
856 ;; https://github.com/pazz/alot/blob/master/docs/source/faq.rst
857 #:python ,python-2))
858 (native-inputs
859 `(("python2-mock" ,python2-mock)))
860 (inputs
861 `(("python2-magic" ,python2-magic)
862 ("python2-configobj" ,python2-configobj)
863 ("python2-twisted" ,python2-twisted)
864 ("python2-urwid" ,python2-urwid)
865 ("python2-urwidtrees" ,python2-urwidtrees)
866 ("python2-pygpgme" ,python2-pygpgme)
867 ("python2-notmuch" ,python2-notmuch)))
868 (home-page "https://github.com/pazz/alot")
869 (synopsis "Command-line MUA using @code{notmuch}")
870 (description
871 "Alot is an experimental terminal mail user agent (@dfn{MUA}) based on
872 @code{notmuch} mail. It is written in Python using the @code{urwid} toolkit.")
873 (license license:gpl3+)))
874
875 (define-public notifymuch
876 (let
877 ((commit "9d4aaf54599282ce80643b38195ff501120807f0")
878 (revision "1"))
879 (package
880 (name "notifymuch")
881 (version (string-append "0.1-" revision "." (string-take commit 7)))
882 (source
883 (origin
884 (method git-fetch)
885 (uri (git-reference
886 (url "https://github.com/kspi/notifymuch")
887 (commit commit)))
888 (sha256
889 (base32
890 "1lssr7iv43mp5v6nzrfbqlfzx8jcc7m636wlfyhhnd8ydd39n6k4"))
891 (file-name (string-append name "-" version "-checkout"))))
892 (build-system python-build-system)
893 (inputs
894 `(("python-notmuch" ,python-notmuch)
895 ("python-pygobject" ,python-pygobject)
896 ("gobject-introspection" ,gobject-introspection)
897 ("libnotify" ,libnotify)
898 ("gtk+" ,gtk+)))
899 (arguments
900 `(#:phases
901 (modify-phases %standard-phases
902 (add-after 'install 'wrap-binary
903 (lambda* (#:key outputs #:allow-other-keys)
904 (let* ((out (assoc-ref outputs "out"))
905 (bin (string-append out "/bin/notifymuch")))
906 (wrap-program bin
907 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH")))
908 `("GI_TYPELIB_PATH" ":" prefix
909 (,(getenv "GI_TYPELIB_PATH")
910 ,(string-append out "/lib/girepository-1.0")))))
911 #t)))))
912 (home-page "https://github.com/kspi/notifymuch")
913 (synopsis "Displays notifications for changes in the notmuch email database")
914 (description "notifymuch displays desktop notifications for messages in
915 the notmuch database. The notifications are sent using libnotify to a
916 notification daemon. The query to find messages to send a notification about
917 is configurable, and a notification for the same message will not be send
918 within a configurable period (defaults to 48 hours). To use notifymuch, run
919 @command{notifymuch} after new mail is indexed, this can be automated by
920 invoking @command{notifymuch} from the post-new hook.")
921 (license license:gpl3))))
922
923 (define-public notmuch
924 (package
925 (name "notmuch")
926 (version "0.29.3")
927 (source (origin
928 (method url-fetch)
929 (uri (string-append "https://notmuchmail.org/releases/notmuch-"
930 version ".tar.xz"))
931 (sha256
932 (base32
933 "0dfwa38vgnxk9cvvpza66szjgp8lir6iz6yy0cry9593lywh9xym"))))
934 (build-system gnu-build-system)
935 (arguments
936 `(#:modules ((guix build gnu-build-system)
937 ((guix build emacs-build-system) #:prefix emacs:)
938 (guix build utils))
939 #:imported-modules (,@%gnu-build-system-modules
940 (guix build emacs-build-system)
941 (guix build emacs-utils))
942 #:make-flags
943 (list "V=1" ; verbose test output
944 "NOTMUCH_TEST_TIMEOUT=1h") ; don't fail on slow machines
945 #:phases (modify-phases %standard-phases
946 (add-after 'unpack 'patch-notmuch-lib.el
947 (lambda _
948 (substitute* "emacs/notmuch-lib.el"
949 (("/bin/sh") (which "sh")))
950 #t))
951 (replace 'configure
952 (lambda* (#:key outputs #:allow-other-keys)
953 (setenv "CC" "gcc")
954 (setenv "CONFIG_SHELL" (which "sh"))
955
956 (let* ((out (assoc-ref outputs "out"))
957 (elisp
958 (string-append out "/share/emacs/site-lisp/")))
959 (invoke "./configure"
960 (string-append "--prefix=" out)
961 (string-append "--emacslispdir=" elisp)
962 (string-append "--emacsetcdir=" elisp)))))
963 (add-before 'check 'prepare-test-environment
964 (lambda _
965 (setenv "TEST_CC" "gcc")
966 ;; Patch various inline shell invocations.
967 (substitute* (find-files "test" "\\.sh$")
968 (("/bin/sh") (which "sh")))
969 #t))
970 (add-after 'install 'make-autoloads
971 (assoc-ref emacs:%standard-phases 'make-autoloads)))))
972 (native-inputs
973 `(("bash-completion" ,bash-completion)
974 ("emacs" ,emacs-no-x) ; -minimal lacks libxml, needed for some tests
975 ("pkg-config" ,pkg-config)
976 ("python" ,python)
977 ("python-docutils" ,python-docutils)
978 ("sphinx" ,python-sphinx)
979
980 ;; The following are required for tests only.
981 ("which" ,which)
982 ("dtach" ,dtach)
983 ("gnupg" ,gnupg)
984 ("man" ,man-db)
985 ("perl" ,perl)))
986 (inputs
987 `(("glib" ,glib)
988 ("gmime" ,gmime)
989 ("talloc" ,talloc)
990 ("xapian" ,xapian)
991 ("zlib" ,zlib)))
992 (home-page "https://notmuchmail.org/")
993 (synopsis "Thread-based email index, search, and tagging")
994 (description
995 "Notmuch is a command-line based program for indexing, searching, read-
996 ing, and tagging large collections of email messages.")
997 (license license:gpl3+)))
998
999 (define-public notmuch-addrlookup-c
1000 (package
1001 (name "notmuch-addrlookup-c")
1002 (version (string-append "9"))
1003 (source (origin
1004 (method git-fetch)
1005 (uri (git-reference
1006 (url "https://github.com/aperezdc/notmuch-addrlookup-c")
1007 (commit (string-append "v" version))))
1008 (file-name (string-append name "-" version "-checkout"))
1009 (sha256
1010 (base32
1011 "1j3zdx161i1x4w0nic14ix5i8hd501rb31daf8api0k8855sx4rc"))))
1012 (build-system gnu-build-system)
1013 (arguments
1014 '(#:tests? #f ; no tests
1015 #:make-flags (list "CC=gcc")
1016 #:phases (modify-phases %standard-phases
1017 (delete 'configure)
1018 ;; Remove vim code completion config, it's not needed to
1019 ;; build (or be patched).
1020 (add-before 'patch-source-shebangs 'delete-ycm-file
1021 (lambda _ (delete-file ".ycm_extra_conf.py")))
1022 (replace 'install
1023 (lambda* (#:key outputs #:allow-other-keys)
1024 (let ((bin (string-append
1025 (assoc-ref outputs "out") "/bin")))
1026 (install-file "notmuch-addrlookup" bin)))))))
1027 (native-inputs
1028 `(("pkg-config" ,pkg-config)))
1029 (inputs
1030 `(("glib" ,glib)
1031 ("notmuch" ,notmuch)))
1032 (home-page "https://github.com/aperezdc/notmuch-addrlookup-c")
1033 (synopsis "Address lookup tool for Notmuch")
1034 (description "This is an address lookup tool using a Notmuch database,
1035 useful for email address completion.")
1036 (license license:expat)))
1037
1038 (define-public python-notmuch
1039 (package
1040 (name "python-notmuch")
1041 (version (package-version notmuch))
1042 ;; Notmuch python bindings are now unavailable on pypi. The
1043 ;; bindings are distributed via the notmuch release tarball.
1044 (source (package-source notmuch))
1045 (build-system python-build-system)
1046 (inputs `(("notmuch" ,notmuch)))
1047 (arguments
1048 `(#:tests? #f ; no "test" target
1049 #:phases
1050 (modify-phases %standard-phases
1051 ;; This python package lives in a subdirectory of the notmuch source
1052 ;; tree, so chdir into it before building.
1053 (add-after 'unpack 'enter-python-dir
1054 (lambda _ (chdir "bindings/python") #t))
1055 ;; Make sure the correct notmuch shared library gets loaded.
1056 (add-before 'build 'set-libnotmuch-file-name
1057 (lambda* (#:key inputs #:allow-other-keys)
1058 (let ((notmuch (assoc-ref inputs "notmuch")))
1059 (substitute* "notmuch/globals.py"
1060 (("libnotmuch\\.so\\.")
1061 (string-append notmuch "/lib/libnotmuch.so.")))
1062 #t))))))
1063 (home-page (package-home-page notmuch))
1064 (synopsis "Python bindings of the Notmuch mail indexing library")
1065 (description
1066 "This package provides Python bindings to use the Notmuch mail indexing
1067 and search library.")
1068 (license license:gpl3+)))
1069
1070 (define-public python2-notmuch
1071 (package-with-python2 python-notmuch))
1072
1073 (define-public muchsync
1074 (package
1075 (name "muchsync")
1076 (version "5")
1077 (source
1078 (origin
1079 (method url-fetch)
1080 (uri (string-append "http://www.muchsync.org/src/"
1081 "muchsync-" version ".tar.gz"))
1082 (sha256
1083 (base32 "1k2m44pj5i6vfhp9icdqs42chsp208llanc666p3d9nww8ngq2lb"))))
1084 (build-system gnu-build-system)
1085 (native-inputs
1086 `(("ghc-pandoc" ,ghc-pandoc)
1087 ("pkg-config" ,pkg-config)))
1088 (inputs
1089 `(("libcrypto" ,openssl)
1090 ("notmuch" ,notmuch)
1091 ("sqlite" ,sqlite)
1092 ("xapian" ,xapian)))
1093 (home-page "http://www.muchsync.org/")
1094 (synopsis "Synchronize notmuch mail across machines")
1095 (description
1096 "Muchsync brings Notmuch to all of your computers by synchronizing your
1097 mail messages and Notmuch tags across machines. The protocol is heavily
1098 pipelined to work efficiently over high-latency networks such as mobile
1099 broadband. Muchsync supports arbitrary pairwise synchronization among
1100 replicas. A version-vector-based algorithm allows it to exchange only the
1101 minimum information necessary to bring replicas up to date regardless of which
1102 pairs have previously synchronized.")
1103 (license license:gpl2+)))
1104
1105 (define-public getmail
1106 (package
1107 (name "getmail")
1108 (version "5.14")
1109 (source
1110 (origin
1111 (method url-fetch)
1112 (uri (string-append "http://pyropus.ca/software/getmail/old-versions/"
1113 "getmail-" version ".tar.gz"))
1114 (sha256
1115 (base32 "1hcrd9h4g12f5gvl1djsbchcjry02ghq4icdr897s8v48pkrzagk"))))
1116 (build-system python-build-system)
1117 (arguments
1118 `(#:tests? #f ; no tests
1119 #:python ,python-2))
1120 (home-page "http://pyropus.ca/software/getmail/")
1121 (synopsis "Mail retriever")
1122 (description
1123 "A flexible, extensible mail retrieval system with support for
1124 POP3, IMAP4, SSL variants of both, maildirs, mboxrd files, external MDAs,
1125 arbitrary message filtering, single-user and domain-mailboxes, and many other
1126 useful features.")
1127
1128 ;; License is specified in file '__init__.py'.
1129 (license license:gpl2)))
1130
1131 (define-public libetpan
1132 (package
1133 (name "libetpan")
1134 (version "1.9.3")
1135 (source (origin
1136 (method git-fetch)
1137 (uri (git-reference
1138 (url "https://github.com/dinhviethoa/libetpan.git")
1139 (commit version)))
1140 (file-name (git-file-name name version))
1141 (sha256
1142 (base32 "19g4qskg71jv7sxfxsdkjmrxk9mk5kf9b6fhw06g6wvm3205n95f"))))
1143 (build-system gnu-build-system)
1144 (native-inputs `(("autoconf" ,autoconf-wrapper)
1145 ("automake" ,automake)
1146 ("libtool" ,libtool)
1147 ("pkg-config" ,pkg-config)))
1148 (propagated-inputs
1149 ;; 'libetpan-config --libs' returns '-lssl -lcrypto -lsasl2', so these
1150 ;; libraries need to be propagated.
1151 `(("cyrus-sasl" ,cyrus-sasl)
1152 ("openssl" ,openssl)))
1153 (inputs
1154 `(("curl" ,curl)
1155 ("expat" ,expat)
1156 ("zlib" ,zlib)))
1157 (arguments
1158 '(#:configure-flags
1159 '("--disable-static" "--disable-db")))
1160 (home-page "https://www.etpan.org/libetpan.html")
1161 (synopsis "Portable middleware for email access")
1162 (description
1163 "The purpose of this mail library is to provide a portable, efficient
1164 framework for different kinds of mail access: IMAP, SMTP, POP and NNTP. It
1165 provides an API for C language. It's the low-level API used by MailCore and
1166 MailCore 2.")
1167 (license license:bsd-3)))
1168
1169 (define-public compface
1170 (package
1171 (name "compface")
1172 (version "1.5.2")
1173 (source (origin
1174 (method url-fetch)
1175 (uri (string-append "https://ftp.heanet.ie/mirrors/"
1176 "ftp.xemacs.org/aux/"
1177 "compface-" version ".tar.gz"))
1178 (sha256
1179 (base32
1180 "09b89wg63hg502hsz592cd2h87wdprb1dq1k1y07n89hym2q56d6"))))
1181 (build-system gnu-build-system)
1182 (arguments
1183 `(#:tests? #f))
1184 (synopsis "Portrait image compressor")
1185 (description "This package takes your 48x48x1 portrait image and
1186 compresses it.")
1187 (home-page "https://legacy.cs.indiana.edu/ftp/faces/")
1188 (license (license:x11-style "file://README"))))
1189
1190 (define-public claws-mail
1191 (package
1192 (name "claws-mail")
1193 (version "3.17.6")
1194 (source (origin
1195 (method url-fetch)
1196 (uri (string-append
1197 "https://www.claws-mail.org/releases/claws-mail-" version
1198 ".tar.xz"))
1199 (sha256
1200 (base32
1201 "1s05qw0r0gqwvvkxvrrwbjkbi61dvilixiwrpgcq21qc9csc9r0m"))))
1202 (build-system gnu-build-system)
1203 (native-inputs `(("pkg-config" ,pkg-config)))
1204 (inputs `(("bogofilter" ,bogofilter)
1205 ("curl" ,curl)
1206 ("dbus-glib" ,dbus-glib)
1207 ("enchant" ,enchant)
1208 ("expat" ,expat)
1209 ("ghostscript" ,ghostscript)
1210 ("hicolor-icon-theme" ,hicolor-icon-theme)
1211 ("gnupg" ,gnupg)
1212 ("gnutls" ,gnutls)
1213 ("gpgme" ,gpgme)
1214 ("gtk" ,gtk+-2)
1215 ("libarchive" ,libarchive)
1216 ("libcanberra" ,libcanberra)
1217 ("libetpan" ,libetpan)
1218 ("libical" ,libical)
1219 ("libnotify" ,libnotify)
1220 ("libsm" ,libsm)
1221 ("libxml2" ,libxml2)
1222 ("perl" ,perl)
1223 ("python-2" ,python-2)
1224 ("mime-info" ,shared-mime-info)
1225 ("startup-notification" ,startup-notification)))
1226 (arguments
1227 '(#:configure-flags
1228 '("--enable-gnutls" "--enable-pgpmime-plugin" "--enable-enchant"
1229 "--enable-ldap")
1230 #:make-flags
1231 ;; Disable updating icon cache since it's done by the profile hook.
1232 ;; Conflict with other packages in the profile would be inevitable
1233 ;; otherwise.
1234 '("gtk_update_icon_cache=true")
1235 #:phases (modify-phases %standard-phases
1236 (add-before 'build 'patch-mime
1237 (lambda* (#:key inputs #:allow-other-keys)
1238 (substitute* "src/procmime.c"
1239 (("/usr/share/mime/globs")
1240 (string-append (assoc-ref inputs "mime-info")
1241 "/share/mime/globs"))))))))
1242 (synopsis "GTK-based Email client")
1243 (description
1244 "Claws-Mail is an email client (and news reader) based on GTK+. The
1245 appearance and interface are designed to be familiar to new users coming from
1246 other popular email clients, as well as experienced users. Almost all commands
1247 are accessible with the keyboard. Plus, Claws-Mail is extensible via addons
1248 which can add many functionalities to the base client.")
1249 (home-page "https://www.claws-mail.org/")
1250 (license license:gpl3+))) ; most files are actually public domain or x11
1251
1252 (define-public msmtp
1253 (package
1254 (name "msmtp")
1255 (version "1.8.11")
1256 (source
1257 (origin
1258 (method url-fetch)
1259 (uri (string-append "https://marlam.de/msmtp/releases/"
1260 "/msmtp-" version ".tar.xz"))
1261 (sha256
1262 (base32 "0q0fg235qk448l1xjcwyxr7vcpzk6w57jzhjbkb0m7nffyhhypzj"))))
1263 (build-system gnu-build-system)
1264 (inputs
1265 `(("libsecret" ,libsecret)
1266 ("gnutls" ,gnutls)
1267 ("zlib" ,zlib)
1268 ("gsasl" ,gsasl)))
1269 (native-inputs
1270 `(("pkg-config" ,pkg-config)))
1271 (home-page "https://marlam.de/msmtp/")
1272 (arguments
1273 `(#:configure-flags (list "--with-libgsasl"
1274 "--with-libidn"
1275 "--with-tls=gnutls")
1276 #:phases
1277 (modify-phases %standard-phases
1278 (add-after 'install 'install-additional-files
1279 (lambda* (#:key outputs #:allow-other-keys)
1280 (let* ((out (assoc-ref outputs "out"))
1281 (bin (string-append out "/bin"))
1282 (doc (string-append out "/share/doc/msmtp"))
1283 (msmtpq "scripts/msmtpq")
1284 (vimfiles (string-append out "/share/vim/vimfiles/plugin")))
1285 (install-file (string-append msmtpq "/msmtpq") bin)
1286 (install-file (string-append msmtpq "/msmtp-queue") bin)
1287 (install-file (string-append msmtpq "/README.msmtpq") doc)
1288 (install-file "scripts/vim/msmtp.vim" vimfiles)
1289 ;; Don't rely on netcat being in the PATH to test for a
1290 ;; connection, instead try tp ing debian.org.
1291 (substitute* (string-append bin "/msmtpq")
1292 (("EMAIL_CONN_TEST=n") "EMAIL_CONN_TEST=p"))
1293 #t))))))
1294 (synopsis
1295 "Simple and easy to use SMTP client with decent sendmail compatibility")
1296 (description
1297 "msmtp is an SMTP client. In the default mode, it transmits a mail to
1298 an SMTP server (for example at a free mail provider) which takes care of further
1299 delivery.")
1300 (license license:gpl3+)))
1301
1302 (define-public exim
1303 (package
1304 (name "exim")
1305 (version "4.94")
1306 (source
1307 (origin
1308 (method url-fetch)
1309 (uri (let ((file-name (string-append "exim-" version ".tar.xz")))
1310 (list (string-append "https://ftp.exim.org/pub/exim/exim4/"
1311 file-name)
1312 ;; ‘Fix’ releases (exim-x.y.z.f) are kept separately.
1313 (string-append "https://ftp.exim.org/pub/exim/exim4/fixes/"
1314 file-name)
1315 ;; After a new non-fix release, the old one is moved here.
1316 (string-append "https://ftp.exim.org/pub/exim/exim4/old/"
1317 file-name))))
1318 (sha256
1319 (base32 "1nsb2i5mqxfz1sl1bmbxmpb2qiaf3wffhfiw4j9vfpagy3xfhzpp"))))
1320 (build-system gnu-build-system)
1321 (inputs
1322 `(("bdb" ,bdb-5.3) ; ‘#error Version 6 and later BDB API is not supported’
1323 ("gnutls" ,gnutls/dane)
1324 ("gzip" ,gzip)
1325 ("bzip2" ,bzip2)
1326 ("xz" ,xz)
1327 ("perl" ,perl)
1328 ("libnsl" ,libnsl)
1329 ("libxt" ,libxt)
1330 ("libxaw" ,libxaw)))
1331 (native-inputs
1332 `(("pcre" ,pcre "bin")
1333 ("perl" ,perl)
1334 ("pkg-config" ,pkg-config)))
1335 (arguments
1336 '(#:phases
1337 (modify-phases %standard-phases
1338 (replace 'configure
1339 ;; We'd use #:make-flags but the top-level Makefile calls others
1340 ;; recursively, so just set all variables this way.
1341 (lambda* (#:key outputs inputs #:allow-other-keys)
1342 (substitute* '("Makefile" "OS/Makefile-Default")
1343 (("(RM_COMMAND=).*" all var)
1344 (string-append var "rm\n")))
1345 (copy-file "src/EDITME" "Local/Makefile")
1346 (copy-file "exim_monitor/EDITME" "Local/eximon.conf")
1347 (let ((out (assoc-ref outputs "out"))
1348 (gzip (assoc-ref inputs "gzip"))
1349 (bzip2 (assoc-ref inputs "bzip2"))
1350 (xz (assoc-ref inputs "xz")))
1351 (substitute* '("Local/Makefile")
1352 (("(BIN_DIRECTORY=).*" all var)
1353 (string-append var out "/bin\n"))
1354 (("(CONFIGURE_FILE=).*" all var)
1355 (string-append var out "/etc/exim.conf\n"))
1356 (("(EXIM_USER=).*" all var)
1357 (string-append var "nobody\n"))
1358 (("(FIXED_NEVER_USERS=).*" all var)
1359 (string-append var "\n")) ; XXX no root in build environment
1360 (("(COMPRESS_COMMAND=).*" all var)
1361 (string-append var gzip "/bin/gzip\n"))
1362 (("(ZCAT_COMMAND=).*" all var)
1363 (string-append var gzip "/bin/zcat\n"))
1364 (("# (USE_GNUTLS(|_PC)=.*)" all line)
1365 (string-append line "\n")))
1366 ;; This file has hard-coded relative file names for tools despite
1367 ;; the zcat configuration above.
1368 (substitute* '("src/exigrep.src")
1369 (("'zcat'") (string-append "'" gzip "/bin/zcat'"))
1370 (("'bzcat'") (string-append "'" bzip2 "/bin/bzcat'"))
1371 (("'xzcat'") (string-append "'" xz "/bin/xzcat'"))
1372 (("'lzma'") (string-append "'" xz "/bin/lzma'"))))
1373 #t))
1374 (add-before 'build 'fix-sh-paths
1375 (lambda* (#:key inputs #:allow-other-keys)
1376 (substitute* '("scripts/lookups-Makefile" "scripts/reversion")
1377 (("SHELL=/bin/sh") "SHELL=sh"))
1378 (substitute* '("scripts/Configure-config.h")
1379 (("\\| /bin/sh") "| sh"))
1380 (let ((bash (assoc-ref inputs "bash")))
1381 (substitute* '("scripts/Configure-eximon")
1382 (("#!/bin/sh") (string-append "#!" bash "/bin/sh"))))
1383 #t))
1384 (add-before 'build 'build-reproducibly
1385 (lambda _
1386 ;; The ‘compilation number’ is incremented for every build from the
1387 ;; same source tree. It appears to vary over different (parallel?)
1388 ;; builds. Make it a ‘constant number’ instead.
1389 (substitute* "src/version.c"
1390 (("#include \"cnumber.h\"") "1")))))
1391 #:make-flags
1392 (list "CC=gcc"
1393 "INSTALL_ARG=-no_chown")
1394 ;; No 'check' target. There is a test suite in test/, which assumes that
1395 ;; certain build options were (not) used and that it can freely ‘sudo’.
1396 #:tests? #f))
1397 (home-page "https://www.exim.org/")
1398 (synopsis
1399 "Message Transfer Agent (MTA) developed at the University of Cambridge")
1400 (description
1401 "Exim is a message transfer agent (MTA) developed at the University of
1402 Cambridge for use on Unix systems connected to the Internet. In style it is
1403 similar to Smail 3, but its facilities are more general. There is a great
1404 deal of flexibility in the way mail can be routed, and there are extensive
1405 facilities for checking incoming mail.")
1406 (license license:gpl2+)))
1407
1408 (define-public dovecot
1409 (package
1410 (name "dovecot")
1411 (version "2.3.11.3")
1412 (source
1413 (origin
1414 (method url-fetch)
1415 (uri (string-append "https://www.dovecot.org/releases/"
1416 (version-major+minor version) "/"
1417 "dovecot-" version ".tar.gz"))
1418 (sha256
1419 (base32 "1p5gp8jbavcsaara5mfn5cbrnlxssajnchczbgmmfzr7228fmnfk"))))
1420 (build-system gnu-build-system)
1421 (native-inputs
1422 `(("pkg-config" ,pkg-config)))
1423 (inputs
1424 `(("bzip2" ,bzip2)
1425 ("libsodium" ,libsodium) ; extra password algorithms
1426 ;; FIXME: The 'test-backtrace' tests fail on arm when using glibc's
1427 ;; backtrace_symbol() function so fallback to using libunwind.
1428 ,@(if (target-arm?)
1429 `(("libunwind" ,libunwind))
1430 '())
1431 ("linux-pam" ,linux-pam)
1432 ("lz4" ,lz4)
1433 ("openssl" ,openssl)
1434 ("sqlite" ,sqlite)
1435 ("zlib" ,zlib)))
1436 (arguments
1437 `(#:configure-flags '("--sysconfdir=/etc"
1438 "--localstatedir=/var"
1439 "--with-sqlite") ; not auto-detected
1440 #:phases
1441 (modify-phases %standard-phases
1442 (add-after 'unpack 'patch-file-names
1443 (lambda _
1444 (substitute* "src/lib-program-client/test-program-client-local.c"
1445 (("(/bin/| )cat") (which "cat"))
1446 (("/bin/echo") (which "echo"))
1447 (("/bin/false") (which "false"))
1448 (("/bin/sh") (which "bash"))
1449 (("head") (which "head"))
1450 (("sleep") (which "sleep")))
1451 (substitute* (list "src/lib-smtp/test-bin/sendmail-exit-1.sh"
1452 "src/lib-smtp/test-bin/sendmail-success.sh")
1453 (("cat") (which "cat")))
1454 #t))
1455 (replace 'install
1456 (lambda* (#:key make-flags #:allow-other-keys)
1457 ;; Simple hack to avoid installing a trivial README in /etc.
1458 (apply invoke "make" "install" "sysconfdir=/tmp/bogus"
1459 make-flags))))))
1460 (home-page "https://www.dovecot.org")
1461 (synopsis "Secure POP3/IMAP server")
1462 (description
1463 "Dovecot is a mail server whose major goals are security and reliability.
1464 It supports mbox/Maildir and its own dbox/mdbox formats.")
1465 ;; Most source files are covered by either lgpl2.1 or expat. The SHA code
1466 ;; is covered by a variant of BSD-3, and UnicodeData.txt is covered by the
1467 ;; Unicode, Inc. License Agreement for Data Files and Software.
1468 (license (list license:lgpl2.1 license:expat
1469 (license:non-copyleft "file://COPYING")))))
1470
1471 (define-public dovecot-trees
1472 (package
1473 (name "dovecot-trees")
1474 (version "2.1.0")
1475 (source
1476 (origin
1477 (method url-fetch)
1478 (uri (string-append "https://0xacab.org/riseuplabs/trees/repository/"
1479 "archive.tar.gz?ref=v" version))
1480 (file-name (string-append name "-" version ".tar.gz"))
1481 (sha256
1482 (base32
1483 "0rkk10b1bsjz979sc864vpgcdchy7yxwmyv4ik50lar1h6awdnrf"))
1484 (patches
1485 (search-patches "dovecot-trees-support-dovecot-2.3.patch"))))
1486 (build-system gnu-build-system)
1487 (native-inputs
1488 `(("automake" ,automake)
1489 ("autoconf" ,autoconf)
1490 ("libtool" ,libtool)
1491 ("dovecot" ,dovecot)
1492 ("pkg-config" ,pkg-config)))
1493 (inputs
1494 `(("libsodium" ,libsodium)))
1495 (arguments
1496 `(#:tests? #f ;No tests exist.
1497 #:configure-flags (list (string-append "--with-dovecot="
1498 (assoc-ref %build-inputs "dovecot")
1499 "/lib/dovecot"))))
1500 (home-page "https://0xacab.org/riseuplabs/trees")
1501 (synopsis "NaCL-based Dovecot email storage encryption plugin")
1502 (description
1503 "Technology for Resting Email Encrypted Storage (TREES) is a NaCL-based
1504 Dovecot encryption plugin. This plugin adds individually encrypted mail
1505 storage to the Dovecot IMAP server. It is inspired by Posteo's scrambler
1506 which uses OpenSSL and RSA keypairs. TREES works in a similar way, but uses
1507 the Sodium crypto library (based on NaCL).
1508
1509 How it works:
1510 @enumerate
1511 @item On IMAP log in, the user's cleartext password is passed to the plugin.
1512 @item The plugin creates an argon2 digest from the password.
1513 @item This password digest is used as a symmetric secret to decrypt a libsodium secretbox.
1514 @item Inside the secretbox is stored a Curve25519 private key.
1515 @item The Curve25519 private key is used to decrypt each individual message,
1516 using libsodium sealed boxes.
1517 @item New mail is encrypted as it arrives using the Curve25519 public key.
1518 @end enumerate\n")
1519 (license license:agpl3)))
1520
1521 (define-public dovecot-libsodium-plugin
1522 (let ((commit "044de73c01c35385df0105f6b387bec5d5317ce7")
1523 (revision "1"))
1524 (package
1525 (name "dovecot-libsodium-plugin")
1526 (version (string-append "0.0.0-" revision "." (string-take commit 7)))
1527 (source
1528 (origin
1529 (method git-fetch)
1530 (uri (git-reference
1531 (url "https://github.com/LuckyFellow/dovecot-libsodium-plugin")
1532 (commit commit)))
1533 (file-name (string-append name "-" version "-checkout"))
1534 (sha256
1535 (base32
1536 "13h07l7xy713zchnj2p9fhvq7fdl4zy1ai94li3ygkqjjj8hrgas"))))
1537 (build-system gnu-build-system)
1538 (native-inputs
1539 `(("automake" ,automake)
1540 ("autoconf" ,autoconf)
1541 ("libtool" ,libtool)
1542 ("dovecot" ,dovecot)
1543 ("pkg-config" ,pkg-config)))
1544 (inputs
1545 `(("libsodium" ,libsodium)))
1546 (arguments
1547 `(#:tests? #f ;No tests exist.
1548 #:configure-flags (list (string-append "--with-dovecot="
1549 (assoc-ref %build-inputs "dovecot")
1550 "/lib/dovecot"))))
1551 (home-page "https://github.com/LuckyFellow/dovecot-libsodium-plugin")
1552 (synopsis "Libsodium password hashing schemes plugin for Dovecot")
1553 (description
1554 "@code{dovecot-libsodium-plugin} provides a libsodium password
1555 hashing scheme (such as scrypt) plug-in for @code{Dovecot}.")
1556 (license license:gpl3+))))
1557
1558 (define-public isync
1559 (package
1560 (name "isync")
1561 (version "1.3.3")
1562 (source
1563 (origin
1564 (method url-fetch)
1565 (uri (string-append "mirror://sourceforge/isync/isync/"
1566 version "/isync-" version ".tar.gz"))
1567 (sha256 (base32
1568 "10n8ykag0q3ws6fc15xqyg3v980v5nq3kzpablly2rh2z7vkn8gj"))))
1569 (build-system gnu-build-system)
1570 (native-inputs
1571 `(("perl" ,perl)))
1572 (inputs
1573 `(("bdb" ,bdb)
1574 ("cyrus-sasl" ,cyrus-sasl)
1575 ("openssl" ,openssl-1.0)
1576 ("zlib" ,zlib)))
1577 (home-page "https://isync.sourceforge.io/")
1578 (synopsis "Mailbox synchronization program")
1579 (description
1580 "isync/mbsync is a command-line tool for two-way synchronization of
1581 mailboxes. Currently Maildir and IMAP are supported types.")
1582 (license license:gpl2+)))
1583
1584 (define-public perl-email-abstract
1585 (package
1586 (name "perl-email-abstract")
1587 (version "3.008")
1588 (source
1589 (origin
1590 (method url-fetch)
1591 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1592 "Email-Abstract-" version ".tar.gz"))
1593 (sha256
1594 (base32
1595 "0h42rhvp769wb421cpbbg6v6xjp8iv86mvz70pqgfgf4nsn6jwgw"))))
1596 (build-system perl-build-system)
1597 (propagated-inputs
1598 `(("perl-email-simple" ,perl-email-simple)
1599 ("perl-module-pluggable" ,perl-module-pluggable)
1600 ("perl-mro-compat" ,perl-mro-compat)))
1601 (home-page "https://metacpan.org/release/Email-Abstract")
1602 (synopsis "Interface to mail representations")
1603 (description "Email::Abstract provides module writers with the ability to
1604 write simple, representation-independent mail handling code.")
1605 (license license:perl-license)))
1606
1607 (define-public perl-email-address
1608 (package
1609 (name "perl-email-address")
1610 (version "1.912")
1611 (source
1612 (origin
1613 (method url-fetch)
1614 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1615 "Email-Address-" version ".tar.gz"))
1616 (sha256
1617 (base32 "1vzr0vx4zsw4zbc9xdffc31wnkc1raqmyfiyws06fbyck197i8qg"))))
1618 (build-system perl-build-system)
1619 (home-page "https://metacpan.org/release/Email-Address")
1620 (synopsis "Email address parsing and creation")
1621 (description "Email::Address implements a regex-based RFC 2822 parser that
1622 locates email addresses in strings and returns a list of Email::Address
1623 objects found. Alternatively you may construct objects manually.")
1624 (license license:perl-license)))
1625
1626 (define-public perl-email-address-xs
1627 (package
1628 (name "perl-email-address-xs")
1629 (version "1.04")
1630 (source
1631 (origin
1632 (method url-fetch)
1633 (uri (string-append "mirror://cpan/authors/id/P/PA/PALI/"
1634 "Email-Address-XS-" version ".tar.gz"))
1635 (sha256
1636 (base32
1637 "0gjrrl81z3sfwavgx5kwjd87gj44mlnbbqsm3dgdv1xllw26spwr"))))
1638 (build-system perl-build-system)
1639 (home-page "https://metacpan.org/release/Email-Address-XS")
1640 (synopsis "Parse and format RFC 5322 email addresses and groups")
1641 (description
1642 "Email::Address::XS implements RFC 5322 parser and formatter of email
1643 addresses and groups. Unlike Email::Address, this module does not use regular
1644 expressions for parsing but instead is implemented in XS and uses shared code
1645 from Dovecot IMAP server.")
1646 (license license:perl-license)))
1647
1648 (define-public perl-email-date-format
1649 (package
1650 (name "perl-email-date-format")
1651 (version "1.005")
1652 (source
1653 (origin
1654 (method url-fetch)
1655 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1656 "Email-Date-Format-" version ".tar.gz"))
1657 (sha256
1658 (base32
1659 "012ivfwpnbl3wr50f9c6f4azhdlxnm31pdn72528g79v61z6372p"))))
1660 (build-system perl-build-system)
1661 (home-page "https://metacpan.org/release/Email-Date-Format")
1662 (synopsis "Produce RFC 2822 date strings")
1663 (description "Email::Date::Format provides a means for generating an RFC
1664 2822 compliant datetime string.")
1665 (license license:perl-license)))
1666
1667 (define-public perl-email-messageid
1668 (package
1669 (name "perl-email-messageid")
1670 (version "1.406")
1671 (source
1672 (origin
1673 (method url-fetch)
1674 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1675 "Email-MessageID-" version ".tar.gz"))
1676 (sha256
1677 (base32
1678 "1f22sdnfq169qw1l0lg7y74pmiam7j9v95bggjnf3q4mygdmshpc"))))
1679 (build-system perl-build-system)
1680 (home-page "https://metacpan.org/release/Email-MessageID")
1681 (synopsis "Generate world unique message-ids")
1682 (description "Email::MessageID generates recommended message-ids to
1683 identify a message uniquely.")
1684 (license license:perl-license)))
1685
1686 (define-public perl-email-mime
1687 (package
1688 (name "perl-email-mime")
1689 (version "1.946")
1690 (source
1691 (origin
1692 (method url-fetch)
1693 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1694 "Email-MIME-" version ".tar.gz"))
1695 (sha256
1696 (base32
1697 "0z1k3i0lzp2k421gc8f3wq0jbqflkbw2xqd2k7n7pmv56417kvk8"))))
1698 (build-system perl-build-system)
1699 (propagated-inputs
1700 `(("perl-email-address" ,perl-email-address)
1701 ("perl-email-messageid" ,perl-email-messageid)
1702 ("perl-email-mime-contenttype" ,perl-email-mime-contenttype)
1703 ("perl-email-mime-encodings" ,perl-email-mime-encodings)
1704 ("perl-email-simple" ,perl-email-simple)
1705 ("perl-mime-types" ,perl-mime-types)
1706 ("perl-module-runtime" ,perl-module-runtime)))
1707 (home-page "https://metacpan.org/release/Email-MIME")
1708 (synopsis "MIME message handling")
1709 (description "Email::MIME is an extension of the Email::Simple module, to
1710 handle MIME encoded messages. It takes a message as a string, splits it up
1711 into its constituent parts, and allows you access to various parts of the
1712 message. Headers are decoded from MIME encoding.")
1713 (license license:perl-license)))
1714
1715 (define-public perl-email-mime-contenttype
1716 (package
1717 (name "perl-email-mime-contenttype")
1718 (version "1.022")
1719 (source
1720 (origin
1721 (method url-fetch)
1722 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1723 "Email-MIME-ContentType-" version ".tar.gz"))
1724 (sha256
1725 (base32
1726 "042kxhs3bp1ab9z0mbr1wy21ld4lxd6v2a2mmrashqnsn2075fws"))))
1727 (build-system perl-build-system)
1728 (native-inputs
1729 `(("perl-capture-tiny" ,perl-capture-tiny)))
1730 (home-page "https://metacpan.org/release/Email-MIME-ContentType")
1731 (synopsis "Parse MIME Content-Type headers")
1732 (description "Email::MIME::ContentType parses a MIME Content-Type
1733 header.")
1734 (license license:perl-license)))
1735
1736 (define-public perl-email-mime-encodings
1737 (package
1738 (name "perl-email-mime-encodings")
1739 (version "1.315")
1740 (source
1741 (origin
1742 (method url-fetch)
1743 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1744 "Email-MIME-Encodings-" version ".tar.gz"))
1745 (sha256
1746 (base32
1747 "0p5b8g9gh35m8fqrpx60g4bp98rvwd02n5b0vm9wh7mk0xah8wac"))))
1748 (build-system perl-build-system)
1749 (native-inputs
1750 `(("perl-capture-tiny" ,perl-capture-tiny)))
1751 (home-page "https://metacpan.org/release/Email-MIME-Encodings")
1752 (synopsis "Unified interface to MIME encoding and decoding")
1753 (description "This module wraps MIME::Base64 and MIME::QuotedPrint.")
1754 (license license:perl-license)))
1755
1756 (define-public perl-email-sender
1757 (package
1758 (name "perl-email-sender")
1759 (version "1.300034")
1760 (source
1761 (origin
1762 (method url-fetch)
1763 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1764 "Email-Sender-" version ".tar.gz"))
1765 (sha256
1766 (base32 "14aj9kqa9dr2bdhzn2qvjj2mffj8wjb5397z8qw7qg057fk3ib05"))))
1767 (build-system perl-build-system)
1768 (native-inputs
1769 `(("perl-capture-tiny" ,perl-capture-tiny)))
1770 (propagated-inputs
1771 `(("perl-email-abstract" ,perl-email-abstract)
1772 ("perl-email-address" ,perl-email-address)
1773 ("perl-email-simple" ,perl-email-simple)
1774 ("perl-list-moreutils" ,perl-list-moreutils)
1775 ("perl-module-runtime" ,perl-module-runtime)
1776 ("perl-moo" ,perl-moo)
1777 ("perl-moox-types-mooselike" ,perl-moox-types-mooselike)
1778 ("perl-sub-exporter" ,perl-sub-exporter)
1779 ("perl-throwable" ,perl-throwable)
1780 ("perl-try-tiny" ,perl-try-tiny)))
1781 (home-page "https://metacpan.org/release/Email-Sender")
1782 (synopsis "Perl library for sending email")
1783 (description "Email::Sender replaces the old and sometimes problematic
1784 Email::Send library.")
1785 (license license:perl-license)))
1786
1787 (define-public perl-email-simple
1788 (package
1789 (name "perl-email-simple")
1790 (version "2.216")
1791 (source
1792 (origin
1793 (method url-fetch)
1794 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1795 "Email-Simple-" version ".tar.gz"))
1796 (sha256
1797 (base32
1798 "1m4brbjvalyp5kjqslqv4155dzwg977shxin208i7lc8236n6pyq"))))
1799 (build-system perl-build-system)
1800 (propagated-inputs
1801 `(("perl-email-date-format" ,perl-email-date-format)))
1802 (home-page "https://metacpan.org/release/Email-Simple")
1803 (synopsis "Parsing of RFC 2822 messages")
1804 (description "Email::Simple provides simple parsing of RFC 2822 message
1805 format and headers.")
1806 (license license:perl-license)))
1807
1808 (define-public libesmtp
1809 (package
1810 (name "libesmtp")
1811 (version "1.0.6")
1812 (source
1813 (origin
1814 (method url-fetch)
1815 (uri (list (string-append "https://pkgs.fedoraproject.org/repo/pkgs/"
1816 "libesmtp/libesmtp-" version ".tar.bz2/"
1817 "bf3915e627fd8f35524a8fdfeed979c8/libesmtp-"
1818 version ".tar.bz2")
1819 ;; XXX This site is offline, so we fetch Fedora's cached copy
1820 ;; of the source tarball.
1821 (string-append "http://www.stafford.uklinux.net/libesmtp/libesmtp-"
1822 version ".tar.bz2")))
1823 (sha256
1824 (base32
1825 "02zbniyz7qys1jmx3ghx21kxmns1wc3hmv80gp7ag7yra9f1m9nh"))))
1826 (build-system gnu-build-system)
1827 (propagated-inputs
1828 `(("openssl" ,openssl)))
1829 (home-page "http://www.stafford.uklinux.net/libesmtp/")
1830 (synopsis "Library for sending mail via remote hosts using SMTP")
1831 (description "libESMTP is an SMTP client which manages posting (or
1832 submission of) electronic mail via a preconfigured Mail Transport Agent (MTA).
1833 It may be used as part of a Mail User Agent (MUA) or other program that must
1834 be able to post electronic mail where mail functionality may not be that
1835 program's primary purpose.")
1836 (license (list license:lgpl2.1+ license:gpl2+))))
1837
1838 (define-public esmtp
1839 (package
1840 (name "esmtp")
1841 (version "1.2")
1842 (source
1843 (origin
1844 (method git-fetch)
1845 (uri (git-reference
1846 (url "https://github.com/andywingo/esmtp")
1847 (commit "01bf9fc")))
1848 (sha256
1849 (base32
1850 "1ay282rrl92h0m0m8z5zzjnwiiagi7c78aq2qvhia5mw7prwfyw2"))
1851 (file-name (string-append name "-" version "-checkout"))))
1852 (arguments
1853 `(#:phases (modify-phases %standard-phases
1854 (replace 'bootstrap
1855 (lambda _ (invoke "autoreconf" "-vfi"))))))
1856 (build-system gnu-build-system)
1857 (native-inputs
1858 `(("bison" ,bison)
1859 ("flex" ,flex)
1860 ("autoconf" ,autoconf)
1861 ("automake" ,automake)
1862 ("libtool" ,libtool)))
1863 (inputs
1864 `(("libesmtp" ,libesmtp)))
1865 (home-page "https://sourceforge.net/projects/esmtp/")
1866 (synopsis "Relay-only mail transfer agent (MTA)")
1867 (description "Esmtp is a simple relay-only mail transfer agent built using
1868 libESMTP. It sends e-mail via a remote SMTP server using credentials from the
1869 user's @file{$HOME/.esmtprc} configuration file; see the @command{esmtprc} man
1870 page for more on configuration. This package also provides minimal
1871 compatibility shims for the @command{sendmail}, @command{mailq}, and
1872 @command{newaliases} commands.")
1873 (license license:gpl2+)))
1874
1875 (define-public fdm
1876 (package
1877 (name "fdm")
1878 (version "2.0")
1879 (source (origin
1880 (method url-fetch)
1881 (uri (string-append "https://github.com/nicm/fdm/releases/download/"
1882 version "/fdm-" version ".tar.gz"))
1883 (sha256
1884 (base32 "196fs1z8y7p12wmqn1bylzz94szl58yv2aby3p30nmwjnyv8rch6"))))
1885 (build-system gnu-build-system)
1886 (inputs
1887 `(("tdb" ,tdb)
1888 ("openssl" ,openssl)
1889 ("zlib" ,zlib)))
1890 (home-page "https://github.com/nicm/fdm")
1891 (synopsis "Mail Retrieval Agent (MRA) and Mail Delivery Agent (MDA)")
1892 (description "fdm is a program designed to fetch mail from POP3
1893 or IMAP servers, or receive local mail from stdin, and
1894 deliver it in various ways.")
1895 (license
1896 ;; Why point to a source file? Well, all the individual files have a
1897 ;; copy of this license in their headers, but there's no seprate file
1898 ;; with that information.
1899 (license:non-copyleft
1900 "https://github.com/nicm/fdm/blob/master/command.c"))))
1901
1902
1903 (define-public procmail
1904 (package
1905 (name "procmail")
1906 (version "3.22")
1907 (source
1908 (origin
1909 (method url-fetch)
1910 (uri (string-append
1911 "ftp://ftp.fu-berlin.de/pub/unix/mail/procmail/procmail-"
1912 version
1913 ".tar.gz"))
1914 (sha256
1915 (base32
1916 "05z1c803n5cppkcq99vkyd5myff904lf9sdgynfqngfk9nrpaz08"))
1917 ;; The following patch fixes an ambiguous definition of
1918 ;; getline() in formail.c. The patch is provided by Debian as
1919 ;; patch 24.
1920 (patches (search-patches "procmail-ambiguous-getline-debian.patch"
1921 "procmail-CVE-2014-3618.patch"
1922 "procmail-CVE-2017-16844.patch"))))
1923 (arguments
1924 `(#:phases (modify-phases %standard-phases
1925 (replace 'configure
1926 (lambda _
1927 (substitute* "Makefile"
1928 (("/bin/sh")
1929 (which "sh"))
1930 (("/usr")
1931 (assoc-ref %outputs "out"))
1932 (("/bin/rm")
1933 (which "rm")))
1934 #t)))
1935 #:tests? #f)) ;; There are no tests indicating a successful
1936 ;; build. Some tests of basic locking mechanisms provided by the
1937 ;; file system are performed during 'make install'. However, these
1938 ;; are performed before the actual build process.
1939 (build-system gnu-build-system)
1940 (inputs `(("exim" ,exim)))
1941 (home-page "http://www.procmail.org/")
1942 (synopsis "Versatile mail delivery agent (MDA)")
1943 (description "Procmail is a mail delivery agent (MDA) featuring support
1944 for a variety of mailbox formats such as mbox, mh and maildir. Incoming mail
1945 can be sorted into separate files/directories and arbitrary commands can be
1946 executed on mail arrival. Procmail is considered stable, but is no longer
1947 maintained.")
1948 (license license:gpl2+))) ;; procmail allows to choose the
1949 ;; nonfree Artistic License 1.0
1950 ;; as alternative to the GPL2+.
1951 ;; This option is not listed here.
1952
1953 (define-public khard
1954 (package
1955 (name "khard")
1956 (version "0.17.0")
1957 (source (origin
1958 (method url-fetch)
1959 (uri (pypi-uri name version))
1960 (sha256
1961 (base32
1962 "062nv4xkfsjc11k9m52dh6xjn9z68a4a6x1s8z05wwv4jbp1lkhn"))))
1963 (build-system python-build-system)
1964 (arguments
1965 `(#:phases
1966 (modify-phases %standard-phases
1967 (add-after 'install 'install-completions
1968 (lambda* (#:key outputs #:allow-other-keys)
1969 (let* ((out (assoc-ref outputs "out"))
1970 (zsh (string-append out "/share/zsh/site-functions")))
1971 (copy-recursively "misc/zsh" zsh)
1972 #t))))))
1973 (native-inputs
1974 `(("python-setuptools-scm" ,python-setuptools-scm)))
1975 (inputs
1976 `(("python-atomicwrites" ,python-atomicwrites)
1977 ("python-configobj" ,python-configobj)
1978 ("python-ruamel.yaml" ,python-ruamel.yaml)
1979 ("python-unidecode" ,python-unidecode)
1980 ("python-vobject" ,python-vobject)))
1981 (synopsis "Console address book using CardDAV")
1982 (description "Khard is an address book for the console. It creates, reads,
1983 modifies and removes CardDAV address book entries at your local machine. For
1984 synchronizing with a remote address book, @command{vdirsyncer} is recommended.
1985 Khard can also be used from within the email client @command{mutt}.")
1986 (home-page "https://github.com/scheibler/khard")
1987 (license license:gpl3+)))
1988
1989 (define-public perl-mail-spf
1990 (package
1991 (name "perl-mail-spf")
1992 (version "2.9.0")
1993 (source
1994 (origin
1995 (method url-fetch)
1996 (uri (string-append
1997 "mirror://cpan/authors/id/J/JM/JMEHNLE/mail-spf/Mail-SPF-v"
1998 version
1999 ".tar.gz"))
2000 (sha256
2001 (base32 "0qk1rfgfm5drj4iyniiabrasrpqv570vzhgz66lwgb67y4amkjv1"))))
2002 (build-system perl-build-system)
2003 (native-inputs
2004 `(("perl-module-build" ,perl-module-build)
2005 ("perl-net-dns-resolver-programmable"
2006 ,perl-net-dns-resolver-programmable)))
2007 (arguments
2008 `(#:phases
2009 (modify-phases %standard-phases
2010 (add-before 'configure 'modify-Build.PL
2011 (lambda* (#:key outputs #:allow-other-keys)
2012 (substitute* "Build.PL"
2013 (("'/usr/sbin'") (string-append "'"
2014 (assoc-ref outputs "out")
2015 "/sbin'")))
2016 #t)))))
2017 (inputs
2018 `(("perl-error" ,perl-error)
2019 ("perl-net-dns" ,perl-net-dns)
2020 ("perl-netaddr-ip" ,perl-netaddr-ip)
2021 ("perl-uri" ,perl-uri)))
2022 (home-page "https://metacpan.org/release/Mail-SPF")
2023 (synopsis "Perl implementation of Sender Policy Framework")
2024 (description "Mail::SPF is the Sender Policy Framework implemented
2025 in Perl.")
2026 (license license:bsd-3)))
2027
2028 (define-public perl-mail-authenticationresults
2029 (package
2030 (name "perl-mail-authenticationresults")
2031 (version "1.20180923")
2032 (source (origin
2033 (method url-fetch)
2034 (uri (string-append
2035 "mirror://cpan/authors/id/M/MB/MBRADSHAW/"
2036 "Mail-AuthenticationResults-" version ".tar.gz"))
2037 (sha256
2038 (base32
2039 "1g1wym9vcbhldwvi4w5pl0fhd4jh2icj975awf4wr5xmkli9mxbz"))))
2040 (build-system perl-build-system)
2041 (native-inputs
2042 `(("perl-test-exception" ,perl-test-exception)))
2043 (home-page "https://metacpan.org/release/Mail-AuthenticationResults")
2044 (synopsis "Object Oriented Authentication-Results Headers")
2045 (description "Mail::AuthenticationResults parses the message header field
2046 that indicates the message authentication status as per RFC7601. This module
2047 is not fully compliant with the RFC but it tries to implement most styles of
2048 Authentication-Results header seen in the wild.")
2049 (license license:perl-license)))
2050
2051 (define-public perl-mail-dkim
2052 (package
2053 (name "perl-mail-dkim")
2054 (version "0.58")
2055 (source (origin
2056 (method url-fetch)
2057 (uri (string-append
2058 "mirror://cpan/authors/id/M/MB/MBRADSHAW/Mail-DKIM-"
2059 version
2060 ".tar.gz"))
2061 (sha256
2062 (base32
2063 "0cgkal65qqcy57b21lgij90ba36wl66byw9i76g5yhwaa8ms8hqa"))))
2064 (build-system perl-build-system)
2065 (propagated-inputs
2066 `(("perl-crypt-openssl-rsa" ,perl-crypt-openssl-rsa)
2067 ("perl-mail-authenticationresults" ,perl-mail-authenticationresults)
2068 ("perl-mailtools" ,perl-mailtools)
2069 ("perl-net-dns" ,perl-net-dns)))
2070 (native-inputs
2071 `(("perl-net-dns-resolver-mock" ,perl-net-dns-resolver-mock)
2072 ("perl-test-requiresinternet" ,perl-test-requiresinternet)
2073 ("perl-yaml-libyaml" ,perl-yaml-libyaml)))
2074 (home-page "https://metacpan.org/release/Mail-DKIM")
2075 (synopsis "Signs/verifies Internet mail with DKIM/DomainKey signatures")
2076 (description "Mail::DKIM is a Perl module that implements the new Domain
2077 Keys Identified Mail (DKIM) standard, and the older Yahoo! DomainKeys standard,
2078 both of which sign and verify emails using digital signatures and DNS records.
2079 Mail-DKIM can be used by any Perl program that wants to provide support for
2080 DKIM and/or DomainKeys.")
2081 (license license:gpl3+)))
2082
2083 (define-public dkimproxy
2084 (package
2085 (name "dkimproxy")
2086 (version "1.4.1")
2087 (source (origin
2088 (method url-fetch)
2089 (uri (string-append
2090 "mirror://sourceforge/dkimproxy/dkimproxy/"
2091 version "/dkimproxy-" version ".tar.gz"))
2092 (sha256
2093 (base32
2094 "1gc5c7lg2qrlck7b0lvjfqr824ch6jkrzkpsn0gjvlzg7hfmld75"))
2095 (patches
2096 (search-patches "dkimproxy-add-ipv6-support.patch"))))
2097 (build-system gnu-build-system)
2098 (arguments
2099 `(#:phases
2100 (modify-phases %standard-phases
2101 (add-after 'install 'make-wrapper
2102 (lambda* (#:key inputs outputs #:allow-other-keys)
2103 (let* ((out (assoc-ref outputs "out"))
2104 (wrap.pl (lambda (scripts keys)
2105 (for-each
2106 (lambda (script)
2107 (wrap-program (string-append out script)
2108 `("PERL5LIB" ":" prefix
2109 ,(map (λ (input)
2110 (string-append
2111 (assoc-ref inputs input)
2112 "/lib/perl5/site_perl"))
2113 keys))))
2114 scripts))))
2115 (wrap.pl (list "/bin/dkimproxy.in"
2116 "/bin/dkimproxy.out")
2117 (list "perl-crypt-openssl-rsa"
2118 "perl-io-socket-inet6"
2119 "perl-mailtools"
2120 "perl-mail-authenticationresults"
2121 "perl-mail-dkim"
2122 "perl-net-dns"
2123 "perl-net-server"
2124 "perl-socket6"))
2125 (wrap.pl (list "/bin/dkim_responder.pl")
2126 (list "perl-crypt-openssl-rsa"
2127 "perl-mail-dkim"
2128 "perl-mailtools"
2129 "perl-mime-tools"
2130 "perl-net-dns"
2131 "perl-timedate"))
2132 #t))))))
2133 (inputs
2134 `(("perl" ,perl)
2135 ("perl-crypt-openssl-rsa" ,perl-crypt-openssl-rsa)
2136 ("perl-io-socket-inet6" ,perl-io-socket-inet6)
2137 ("perl-mailtools" ,perl-mailtools)
2138 ("perl-mail-authenticationresults" ,perl-mail-authenticationresults)
2139 ("perl-mail-dkim" ,perl-mail-dkim)
2140 ("perl-mime-tools" ,perl-mime-tools)
2141 ("perl-net-dns" ,perl-net-dns)
2142 ("perl-net-server" ,perl-net-server)
2143 ("perl-socket6" ,perl-socket6)
2144 ("perl-timedate" ,perl-timedate)))
2145 (home-page "http://dkimproxy.sourceforge.net/")
2146 (synopsis "SMTP proxy to sign and verify Internet mail with DKIM headers")
2147 (description
2148 "DKIMproxy is an SMTP proxy that signs and verifies Internet mail using the
2149 @code{Mail::DKIM} Perl module. It comprises two separate proxies: an outbound
2150 proxy for signing outgoing email, and an inbound proxy for verifying signatures
2151 of incoming messages.
2152
2153 It was designed for Postfix, but can be used to add DKIM support to nearly any
2154 existing mail server. With Postfix, the proxies can operate as either
2155 @code{Before-Queue} or @code{After-Queue} content filters.")
2156 (license license:gpl2+)))
2157
2158 (define-public mb2md
2159 (package
2160 (name "mb2md")
2161 (version "3.20")
2162 (source (origin
2163 (method url-fetch)
2164 (uri (string-append
2165 "http://batleth.sapienti-sat.org/projects/mb2md/mb2md-"
2166 version ".pl.gz"))
2167 (sha256
2168 (base32
2169 "0bvkky3c90738h3skd2f1b2yy5xzhl25cbh9w2dy97rs86ssjidg"))))
2170 (build-system trivial-build-system)
2171 (arguments
2172 '(#:modules ((guix build utils))
2173 #:builder
2174 (begin
2175 (use-modules (guix build utils))
2176 (let* ((source (assoc-ref %build-inputs "source"))
2177 (out (assoc-ref %outputs "out"))
2178 (bin (string-append out "/bin"))
2179 (perl (assoc-ref %build-inputs "perl"))
2180 (gzip (assoc-ref %build-inputs "gzip"))
2181 (perl-timedate (assoc-ref %build-inputs "perl-timedate"))
2182 (perl5lib (string-append perl-timedate "/lib/perl5/site_perl")))
2183 (mkdir-p bin)
2184 (with-directory-excursion bin
2185 (copy-file source "mb2md.gz")
2186 (invoke (string-append gzip "/bin/gzip") "-d" "mb2md.gz")
2187 (substitute* "mb2md"
2188 (("#!/usr/bin/perl")
2189 (string-append "#!/usr/bin/perl -I " perl5lib)))
2190 (patch-shebang "mb2md" (list (string-append perl "/bin")))
2191 (chmod "mb2md" #o555))
2192 #t))))
2193 (native-inputs `(("gzip" ,gzip)))
2194 (inputs `(("perl" ,perl)
2195 ("perl-timedate" ,perl-timedate)))
2196 (home-page "http://batleth.sapienti-sat.org/projects/mb2md/")
2197 (synopsis "Mbox to maildir converter")
2198 (description
2199 "Mb2md is a Perl script that takes one or more mbox format files and
2200 converts them to maildir format directories.")
2201 (license license:public-domain)))
2202
2203 (define-public mpop
2204 (package
2205 (name "mpop")
2206 (version "1.4.10")
2207 (source
2208 (origin
2209 (method url-fetch)
2210 (uri (string-append "https://marlam.de/mpop/releases/"
2211 "mpop-" version ".tar.xz"))
2212 (sha256
2213 (base32 "1243hazpiwgvz2m3p48cdh0yw1019i6xjxgc7qyhmxcdy0inb6wy"))))
2214 (build-system gnu-build-system)
2215 (inputs
2216 `(("gnutls" ,gnutls)))
2217 (native-inputs
2218 `(("pkg-config" ,pkg-config)))
2219 (home-page "https://marlam.de/mpop/")
2220 (synopsis "POP3 mail client")
2221 (description "mpop is a small and fast POP3 client suitable as a
2222 fetchmail replacement.
2223
2224 mpop supports multiple accounts, header based mail filtering, delivery
2225 to mbox files, maildir folders or an @acronym{MDA, Mail Delivery Agent},
2226 TLS/SSL, several authentication methods, @acronym{IDN, Internationalized Domain
2227 Names} and SOCKS proxies.")
2228 (license license:gpl3+)))
2229
2230 (define-public mhonarc
2231 (package
2232 (name "mhonarc")
2233 (version "2.6.19")
2234 (source
2235 (origin
2236 (method url-fetch)
2237 (uri (string-append "mirror://cpan/authors/id/E/EH/EHOOD/MHonArc-"
2238 version ".tar.gz"))
2239 (sha256
2240 (base32
2241 "0ll3v93yji334zqp6xfzfxc0127pmjcznmai1l5q6dzawrs2igzq"))))
2242 (build-system perl-build-system)
2243 (home-page "https://www.mhonarc.org/")
2244 (synopsis "Create HTML archives of mail/news messages")
2245 (description
2246 "MHonArc is a Perl mail-to-HTML converter. MHonArc
2247 provides HTML mail archiving with index, mail thread linking,
2248 etc; plus other capabilities including support for MIME and
2249 powerful user customization features.")
2250 (license license:gpl2+)))
2251
2252
2253 (define-public sendmail
2254 (package
2255 (name "sendmail")
2256 (version "8.15.2")
2257 (source
2258 (origin
2259 (method url-fetch)
2260 (uri (string-append
2261 "ftp://ftp.sendmail.org/pub/sendmail/sendmail."
2262 version ".tar.gz"))
2263 (sha256
2264 (base32
2265 "0fdl9ndmspqspdlmghzxlaqk56j3yajk52d7jxcg21b7sxglpy94"))))
2266 (build-system gnu-build-system)
2267 (arguments
2268 `(#:phases
2269 (modify-phases %standard-phases
2270 (add-before 'build 'replace-/bin/sh
2271 (lambda _
2272 (substitute*
2273 (append
2274 (list "smrsh/smrsh.c" "sendmail/conf.c" "contrib/mailprio"
2275 "contrib/mmuegel" "devtools/bin/configure.sh")
2276 (find-files "." ".*\\.m4")
2277 (find-files "." ".*\\.cf"))
2278 (("/bin/sh") (which "sh")))
2279
2280 (substitute* "devtools/bin/Build"
2281 (("SHELL=/bin/sh") (string-append "SHELL=" (which "sh"))))
2282 #t))
2283 (replace 'configure
2284 (lambda _
2285
2286 ;; Render harmless any attempts to chown or chgrp
2287 (substitute* "devtools/bin/install.sh"
2288 (("owner=\\$2") "owner=''")
2289 (("group=\\$2") "group=''"))
2290
2291 (with-output-to-file "devtools/Site/site.config.m4"
2292 (lambda ()
2293 (format #t "
2294 define(`confCC', `gcc')
2295 define(`confOPTIMIZE', `-g -O2')
2296 define(`confLIBS', `-lresolv')
2297 define(`confINSTALL', `~a/devtools/bin/install.sh')
2298 define(`confDEPEND_TYPE', `CC-M')
2299 define(`confINST_DEP', `')
2300 " (getcwd))))
2301 #t))
2302 (replace 'build
2303 (lambda _
2304 (invoke "sh" "Build")
2305 (with-directory-excursion "cf/cf"
2306 (copy-file "generic-linux.mc" "sendmail.mc")
2307 (invoke "sh" "Build" "sendmail.cf"))
2308 #t))
2309 (add-before 'install 'pre-install
2310 (lambda _
2311 (let ((out (assoc-ref %outputs "out")))
2312 (mkdir-p (string-append out "/usr/bin"))
2313 (mkdir-p (string-append out "/usr/sbin"))
2314 (mkdir-p (string-append out "/etc/mail"))
2315 (setenv "DESTDIR" out)
2316 (with-directory-excursion "cf/cf"
2317 (invoke "sh" "Build" "install-cf"))
2318 #t))))
2319 ;; There is no make check. There are some post installation tests, but those
2320 ;; require root privileges
2321 #:tests? #f))
2322 (inputs
2323 `(("m4" ,m4)
2324 ("perl" ,perl)))
2325 (home-page "http://sendmail.org")
2326 (synopsis
2327 "Highly configurable Mail Transfer Agent (MTA)")
2328 (description
2329 "Sendmail is a mail transfer agent (MTA) originally developed by Eric
2330 Allman. It is highly configurable and supports many delivery methods and many
2331 transfer protocols.")
2332 (license (license:non-copyleft "file://LICENSE"
2333 "See LICENSE in the distribution."))))
2334
2335 (define-public opensmtpd
2336 (package
2337 (name "opensmtpd")
2338 (version "6.7.1p1")
2339 (source
2340 (origin
2341 (method url-fetch)
2342 (uri (string-append "https://www.opensmtpd.org/archives/"
2343 "opensmtpd-" version ".tar.gz"))
2344 (sha256
2345 (base32 "1jh8vxfajm1mvp1v5yh6llrhjzv0n9fgab88mlwllwqynhcfjy3l"))))
2346 (build-system gnu-build-system)
2347 (inputs
2348 `(("bdb" ,bdb)
2349 ("libasr" ,libasr)
2350 ("libevent" ,libevent)
2351 ("libressl" ,libressl) ; recommended, and supports e.g. ECDSA
2352 ("linux-pam" ,linux-pam)
2353 ("zlib" ,zlib)))
2354 (native-inputs
2355 `(("bison" ,bison)
2356 ("groff" ,groff))) ; for man pages
2357 (arguments
2358 `(#:configure-flags
2359 (list "--localstatedir=/var"
2360 ;; This is the default only if it exists at build time—it doesn't.
2361 "--with-path-socket=/var/run"
2362 "--with-path-CAfile=/etc/ssl/certs/ca-certificates.crt"
2363 "--with-user-smtpd=smtpd"
2364 "--with-user-queue=smtpq" "--with-group-queue=smtpq"
2365 "--with-auth-pam"
2366 "--with-table-db")
2367 #:phases
2368 (modify-phases %standard-phases
2369 ;; See: https://github.com/OpenSMTPD/OpenSMTPD/issues/1069.
2370 (add-after 'unpack 'fix-smtpctl-encrypt-bug
2371 (lambda _
2372 (substitute* "smtpd/smtpctl.c"
2373 (("\"encrypt\", \"--\",")
2374 "\"encrypt\","))
2375 #t))
2376 ;; Fix some incorrectly hard-coded external tool file names.
2377 (add-after 'unpack 'patch-FHS-file-names
2378 (lambda _
2379 (substitute* "smtpd/smtpctl.c"
2380 ;; ‘gzcat’ is auto-detected at compile time, but ‘cat’ isn't.
2381 (("/bin/cat") (which "cat")))
2382 (substitute* "smtpd/mda_unpriv.c"
2383 (("/bin/sh") (which "sh")))
2384 #t))
2385 ;; OpenSMTPD provides a single smtpctl utility to control both the
2386 ;; daemon and the local submission subsystem. To accomodate systems
2387 ;; that require historical interfaces such as sendmail, newaliases or
2388 ;; makemap, smtpctl operates in compatibility mode if called with the
2389 ;; historical name.
2390 (add-after 'install 'install-compability-links
2391 (lambda* (#:key outputs #:allow-other-keys)
2392 (let* ((out (assoc-ref outputs "out"))
2393 (sbin (string-append out "/sbin/")))
2394 (for-each (lambda (command)
2395 (symlink "smtpctl" (string-append sbin command)))
2396 (list "mailq" "makemap" "newaliases"
2397 "send-mail" "sendmail")))
2398 #t)))))
2399 (synopsis "Lightweight SMTP daemon")
2400 (description
2401 "OpenSMTPD is an implementation of server-side @acronym{SMTP, Simple Mail
2402 Transfer Protocol}, with some additional standard extensions. It allows
2403 ordinary machines to exchange e-mails with other systems speaking the SMTP
2404 protocol, or to deliver them to local users.
2405
2406 In order to simplify the use of SMTP, OpenSMTPD implements a smaller set of
2407 functionality than those available in other SMTP daemons. The objective is to
2408 provide enough features to satisfy typical usage at the risk of unsuitability
2409 to esoteric or niche requirements.")
2410 (home-page "https://www.opensmtpd.org")
2411 (license (list license:bsd-2 license:bsd-3 license:bsd-4
2412 (license:non-copyleft "file://COPYING")
2413 license:public-domain license:isc license:openssl))))
2414
2415 (define-public opensmtpd-extras
2416 (package
2417 (name "opensmtpd-extras")
2418 (version "6.7.1")
2419 (source (origin
2420 (method url-fetch)
2421 (uri (string-append "https://www.opensmtpd.org/archives/"
2422 "opensmtpd-extras-" version ".tar.gz"))
2423 (sha256
2424 (base32
2425 "1b1mx71bvmv92lbm08wr2p60g3qhikvv3n15zsr6dcwbk9aqahzq"))))
2426 (build-system gnu-build-system)
2427 (native-inputs
2428 `(("pkg-config" ,pkg-config)))
2429 (inputs
2430 `(("libressl" ,libressl)
2431 ("libevent" ,libevent)
2432 ("mysql" ,mysql)
2433 ("opensmtpd" ,opensmtpd)
2434 ("postgresql" ,postgresql)
2435 ("python" ,python-2)
2436 ("sqlite" ,sqlite)))
2437 (arguments
2438 `(#:configure-flags
2439 (list "--sysconfdir=/etc"
2440 "--localstatedir=/var"
2441
2442 "--with-queue-null"
2443 "--with-queue-python"
2444 "--with-queue-ram"
2445 "--with-queue-stub"
2446
2447 "--with-table-ldap"
2448 "--with-table-mysql"
2449 "--with-table-postgres"
2450 ;; "--with-table-redis" ; TODO: package hiredis
2451 "--with-table-socketmap"
2452 "--with-table-passwd"
2453 "--with-table-python"
2454 "--with-table-sqlite"
2455 "--with-table-stub"
2456
2457 "--with-scheduler-ram"
2458 "--with-scheduler-stub"
2459 "--with-scheduler-python"
2460
2461 "--with-user-smtpd=smtpd"
2462
2463 ;; We have to configure it like this because the default checks for
2464 ;; for example Python in /usr/{,local/}bin and fails otherwise.
2465 (string-append "--with-python="
2466 (assoc-ref %build-inputs "python")))))
2467 (home-page "https://www.opensmtpd.org")
2468 (synopsis "Extra tables, filters, and various other addons for OpenSMTPD")
2469 (description
2470 "This package provides extra tables, filters, and various other addons
2471 for OpenSMTPD to extend its functionality.")
2472 (license (list license:bsd-2 license:bsd-3 ; openbsd-compat
2473 license:isc)))) ; everything else
2474
2475 (define-public mailman
2476 (package
2477 (name "mailman")
2478 (version "3.3.1")
2479 (source
2480 (origin
2481 (method url-fetch)
2482 (uri (pypi-uri "mailman" version))
2483 (sha256
2484 (base32
2485 "0idfiv48jjgc0jq4731094ddhraqq8bxnwmjk6sg5ask0jss9kxq"))))
2486 (build-system python-build-system)
2487 (propagated-inputs
2488 `(("gunicorn" ,gunicorn)
2489 ("python-aiosmtpd" ,python-aiosmtpd)
2490 ("python-alembic" ,python-alembic)
2491 ("python-atpublic" ,python-atpublic)
2492 ("python-authheaders" ,python-authheaders)
2493 ("python-authres" ,python-authres)
2494 ("python-click" ,python-click)
2495 ("python-dateutil" ,python-dateutil)
2496 ("python-dnspython" ,python-dnspython)
2497 ("python-falcon" ,python-falcon)
2498 ("python-flufl-bounce" ,python-flufl-bounce)
2499 ("python-flufl-i18n" ,python-flufl-i18n)
2500 ("python-flufl-lock" ,python-flufl-lock)
2501 ("python-importlib-resources" ,python-importlib-resources)
2502 ("python-lazr-config" ,python-lazr-config)
2503 ("python-passlib" ,python-passlib)
2504 ("python-requests" ,python-requests)
2505 ("python-sqlalchemy" ,python-sqlalchemy)
2506 ("python-zope-component" ,python-zope-component)
2507 ("python-zope-configuration" ,python-zope-configuration)
2508 ("python-zope-event" ,python-zope-event)
2509 ("python-zope-interface" ,python-zope-interface)))
2510 (native-inputs
2511 `(("python-nose" ,python-nose)))
2512 (home-page "https://www.list.org")
2513 (synopsis "Mailing list manager")
2514 (description
2515 "GNU Mailman is software for managing email discussion and mailing
2516 lists. Both users and administrators generally perform their actions in a
2517 web interface, although email and command-line interfaces are also provided.
2518 The system features built-in archiving, automatic bounce processing, content
2519 filtering, digest delivery, and more.")
2520 (license license:gpl3+)))
2521
2522 (define-public python-mailmanclient
2523 (package
2524 (name "python-mailmanclient")
2525 (version "3.3.1")
2526 (source
2527 (origin
2528 (method url-fetch)
2529 (uri (pypi-uri "mailmanclient" version))
2530 (sha256
2531 (base32
2532 "0pjgzpvhdb6ql8asb20xr8d01m646zpghmcp9fmscks0n1k4di4g"))))
2533 (build-system python-build-system)
2534 (arguments
2535 `(#:tests? #f)) ; Requires mailman running
2536 (propagated-inputs
2537 `(("python-requests" ,python-requests)))
2538 ;(native-inputs
2539 ; `(("mailman" ,mailman)
2540 ; ("python-falcon" ,python-falcon)
2541 ; ("python-pytest" ,python-pytest)
2542 ; ("python-pytest-services" ,python-pytest-services)))
2543 (home-page "https://www.list.org/")
2544 (synopsis "Python bindings for the Mailman 3 REST API")
2545 (description
2546 "The mailmanclient library provides official Python bindings for
2547 the GNU Mailman 3 REST API.")
2548 (properties `((python2-variant . ,(delay python2-mailmanclient))))
2549 (license license:lgpl3+)))
2550
2551 ;; This is the last version which supports Python-2.
2552 (define-public python2-mailmanclient
2553 (let ((base (package-with-python2
2554 (strip-python2-variant python-mailmanclient))))
2555 (package
2556 (inherit base)
2557 (version "3.1.1")
2558 (source
2559 (origin
2560 (method url-fetch)
2561 (uri (pypi-uri "mailmanclient" version))
2562 (sha256
2563 (base32
2564 "0fdfs5g3pf30v2i7w18pdkv9xnfxmfcv66mzv56dck0a1igq07m3"))))
2565 (propagated-inputs
2566 `(("python2-six" ,python2-six)
2567 ("python2-httplib2" ,python2-httplib2))))))
2568
2569 (define-public mlmmj
2570 (package
2571 (name "mlmmj")
2572 (version "1.3.0")
2573 (source
2574 (origin
2575 (method url-fetch)
2576 (uri (string-append "http://mlmmj.org/releases/mlmmj-"
2577 version ".tar.bz2"))
2578 (sha256
2579 (base32
2580 "0hpj10qad821ci11si8xc2qnmkzfn90y13s43fm4fca38f0qjp8w"))))
2581 (build-system gnu-build-system)
2582 (inputs
2583 `(("perl" ,perl))) ; For "contrib/web/"
2584 (native-inputs
2585 `(("pkg-config" ,pkg-config)))
2586 (arguments
2587 `(#:configure-flags
2588 ;; mlmmj-receive-strip is a replacement for mlmmj-receive
2589 ;; It opens the files control/mimedeny and control/mimestrip to get a list
2590 ;; of mimetypes for parts of multipart/mime messages that should be denied
2591 ;; or stripped. The parts then get stripped directly when the mail is
2592 ;; received. mlmmj-receive-strip also appends an extra header
2593 ;; X-ThisMailContainsUnwantedMimeParts: Y when the mail contains unwanted
2594 ;; mime parts
2595 (list "--enable-receive-strip")
2596 #:phases
2597 (modify-phases %standard-phases
2598 (add-before 'install 'install-contrib
2599 (lambda* (#:key outputs #:allow-other-keys)
2600 (let* ((out (assoc-ref outputs "out"))
2601 (share (string-append out "/share/mlmmj"))
2602 (contrib (string-append share "/contrib/web"))
2603 (texts (string-append share "/listtexts")))
2604 (copy-recursively "contrib/web/" contrib)
2605 (copy-recursively "listtexts" texts)
2606 (rename-file texts (string-append share "/texts"))
2607 #t))))))
2608 (home-page "http://mlmmj.org")
2609 (synopsis "Mailing list managing made joyful")
2610 (description
2611 "Mlmmj is a simple and slim mailing list manager (MLM) inspired by ezmlm.
2612 It works with many different Mail Transport Agents (MTAs) and is simple for a
2613 system administrator to install, configure and integrate with other software.
2614 As it uses very few resources, and requires no daemons, it is ideal for
2615 installation on systems where resources are limited. Its features include:
2616 @enumerate
2617 @item Archive, Custom headers / footer,
2618 @item Fully automated bounce handling (similar to ezmlm),
2619 @item Complete requeueing functionality, Moderation functionality, Subject prefix,
2620 @item Subscribers only posting, Regular expression access control,
2621 @item Functionality to retrieve old posts, Web interface, Digests,
2622 @item No-mail subscription, VERP support,
2623 @item Delivery Status Notification (RFC1891) support,
2624 @item Rich and customisable texts for automated operations.
2625 @end enumerate\n")
2626 (license license:expat)))
2627
2628 (define-public python-django-mailman3
2629 (package
2630 (name "python-django-mailman3")
2631 (version "1.3.4")
2632 (source
2633 (origin
2634 (method url-fetch)
2635 (uri (pypi-uri "django-mailman3" version))
2636 (sha256
2637 (base32
2638 "1yrm7wpjy34xai72vn2vkhc9131cdrbqy08rrabf36kynj5vcdvy"))))
2639 (build-system python-build-system)
2640 (arguments
2641 '(#:phases
2642 (modify-phases %standard-phases
2643 (replace 'check
2644 (lambda _
2645 (setenv "DJANGO_SETTINGS_MODULE"
2646 "django_mailman3.tests.settings_test")
2647 (invoke "django-admin" "test"
2648 "--pythonpath=."))))))
2649 (propagated-inputs
2650 `(("python-django" ,python-django)
2651 ("python-django-allauth" ,python-django-allauth)
2652 ("python-django-gravatar2" ,python-django-gravatar2)
2653 ("python-mailmanclient" ,python-mailmanclient)
2654 ("python-pytz" ,python-pytz)))
2655 (native-inputs
2656 `(("python-mock" ,python-mock)))
2657 (home-page "https://gitlab.com/mailman/django-mailman3")
2658 (synopsis "Django library to help interaction with Mailman")
2659 (description
2660 "This package contains libraries and templates for Django-based interfaces
2661 interacting with Mailman.")
2662 (properties `((python2-variant . ,(delay python2-django-mailman3))))
2663 (license license:gpl3+)))
2664
2665 ;; This is the last version to support Python-2.
2666 (define-public python2-django-mailman3
2667 (package
2668 (name "python2-django-mailman3")
2669 (version "1.1.0")
2670 (source
2671 (origin
2672 (method url-fetch)
2673 (uri (pypi-uri "django-mailman3" version))
2674 (sha256
2675 (base32
2676 "1xjdkgfjwhgyrp5nxw65dcpcsr98ygj6856sp0bwkrmyxpd1xxk2"))))
2677 (build-system python-build-system)
2678 (arguments
2679 `(#:phases
2680 (modify-phases %standard-phases
2681 (replace 'check
2682 (lambda _
2683 (invoke "django-admin"
2684 "test"
2685 "--settings=django_mailman3.tests.settings_test"
2686 "django_mailman3"))))
2687 #:python ,python-2))
2688 (inputs
2689 `(("python2-django" ,python2-django)))
2690 (propagated-inputs
2691 `(("python2-requests" ,python2-requests)
2692 ("python2-requests-oauthlib" ,python2-requests-oauthlib)
2693 ("python2-openid" ,python2-openid)
2694 ("python2-mailmanclient" ,python2-mailmanclient)
2695 ("python2-django-allauth" ,python2-django-allauth)
2696 ("python2-django-gravatar2" ,python2-django-gravatar2)
2697 ("python2-pytz" ,python2-pytz)))
2698 (home-page "https://gitlab.com/mailman/django-mailman3")
2699 (synopsis "Django library for Mailman UIs")
2700 (description
2701 "Libraries and templates for Django-based interfaces
2702 interacting with Mailman.")
2703 (license license:gpl3+)))
2704
2705 (define-public python-mailman-hyperkitty
2706 (package
2707 (name "python-mailman-hyperkitty")
2708 (version "1.1.0")
2709 (source
2710 (origin
2711 (method url-fetch)
2712 (uri (pypi-uri "mailman-hyperkitty" version))
2713 (sha256
2714 (base32
2715 "1lfqa9admhvdv71f528jmz2wl0i5cv77v6l64px2pm4zqr9ckkjx"))
2716 (patches
2717 (list
2718 (origin
2719 ;; see: https://gitlab.com/mailman/mailman-hyperkitty/issues/17
2720 ;; fixes test_archive_message_unserializable
2721 (method url-fetch)
2722 (uri "https://salsa.debian.org/mailman-team/mailman-hyperkitty/raw/debian/1.1.0-9/debian/patches/0002-Skip-the-test_archive_message_unserializable.patch")
2723 (sha256
2724 (base32
2725 "0p1fwm46c4bl81lvsg3kjhn2r1lwgkpgxamb3xyqn7h9qdrw10hw")))))))
2726 (build-system python-build-system)
2727 (propagated-inputs
2728 `(("python-requests" ,python-requests)
2729 ("python-zope-interface" ,python-zope-interface)))
2730 (inputs
2731 `(("mailman" ,mailman)))
2732 (native-inputs
2733 `(("python-mock" ,python-mock)
2734 ("python-nose" ,python-nose)
2735 ("python-nose2" ,python-nose2)))
2736 (home-page "https://gitlab.com/mailman/mailman-hyperkitty/")
2737 (synopsis "Mailman archiver plugin for HyperKitty")
2738 (description
2739 "Mailman3 allows emails sent to its mailing lists to be archived by any
2740 software provided that there is a plugin (loadable by Mailman3) designed to
2741 communicate with it properly. This module contains a Mailman3 archiver plugin
2742 which sends emails to HyperKitty, the official Mailman3 web archiver.")
2743 (license license:gpl3+)))
2744
2745 (define-public python-hyperkitty
2746 (package
2747 (name "python-hyperkitty")
2748 (version "1.3.3")
2749 (source
2750 (origin
2751 (method url-fetch)
2752 (uri (pypi-uri "HyperKitty" version))
2753 (sha256
2754 (base32
2755 "0p85r9q6mn5as5b39xp9hkkipnk0156acx540n2ygk3qb3jd4a5n"))))
2756 (build-system python-build-system)
2757 (arguments
2758 '(#:phases
2759 (modify-phases %standard-phases
2760 (replace 'check
2761 (lambda _
2762 ;; It is unclear why this test fails.
2763 (substitute* "hyperkitty/tests/commands/test_import.py"
2764 (("def test_bad_content_type_part_two")
2765 "@SkipTest\n def test_bad_content_type_part_two"))
2766 (setenv "PYTHONPATH" (string-append ".:" (getenv "PYTHONPATH")))
2767 (invoke "example_project/manage.py" "test"
2768 "--settings=hyperkitty.tests.settings_test"))))))
2769 (propagated-inputs
2770 `(("python-dateutil" ,python-dateutil)
2771 ("python-django" ,python-django)
2772 ("python-django-compressor" ,python-django-compressor)
2773 ("python-django-extensions" ,python-django-extensions)
2774 ("python-django-gravatar2" ,python-django-gravatar2)
2775 ("python-django-haystack" ,python-django-haystack)
2776 ("python-django-mailman3" ,python-django-mailman3)
2777 ("python-django-q" ,python-django-q)
2778 ("python-djangorestframework" ,python-djangorestframework)
2779 ("python-flufl-lock" ,python-flufl-lock)
2780 ("python-mailmanclient" ,python-mailmanclient)
2781 ("python-networkx" ,python-networkx)
2782 ("python-pytz" ,python-pytz)
2783 ("python-robot-detection" ,python-robot-detection)))
2784 (native-inputs
2785 `(("python-beautifulsoup4" ,python-beautifulsoup4)
2786 ("python-elasticsearch" ,python-elasticsearch)
2787 ("python-isort" ,python-isort)
2788 ("python-mock" ,python-mock)
2789 ("python-whoosh" ,python-whoosh)))
2790 (home-page "https://gitlab.com/mailman/hyperkitty")
2791 (synopsis "Web interface to access GNU Mailman v3 archives")
2792 (description
2793 "The hyperkitty Django app provides a web user interface to access GNU
2794 Mailman3 archives, and manage it. This interface uses django, and requires
2795 some configuration.")
2796 (license license:gpl3))) ; Some files are gpl2+
2797
2798 (define-public postorius
2799 (package
2800 (name "postorius")
2801 (version "1.3.3")
2802 (source
2803 (origin
2804 (method url-fetch)
2805 (uri (pypi-uri "postorius" version))
2806 (sha256
2807 (base32
2808 "08jn23gblbkfl09qlykbpsmp39mmach3sl69h1j5cd5kkx839rwa"))))
2809 (build-system python-build-system)
2810 (arguments
2811 '(#:phases
2812 (modify-phases %standard-phases
2813 (replace 'check
2814 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
2815 (add-installed-pythonpath inputs outputs)
2816 (if tests?
2817 (invoke "python" "example_project/manage.py" "test"
2818 "--settings=test_settings" "postorius")
2819 #t))))
2820 #:tests? #f)) ; Tests try to run a mailman instance to test against.
2821 (inputs
2822 `(("python-django" ,python-django)
2823 ("python-django-mailman3" ,python-django-mailman3)
2824 ("python-mailmanclient" ,python-mailmanclient)
2825 ("python-readme-renderer" ,python-readme-renderer)))
2826 (native-inputs
2827 `(("python-beautifulsoup4" ,python-beautifulsoup4)
2828 ("python-isort" ,python-isort)
2829 ("python-mock" ,python-mock)
2830 ("python-vcrpy" ,python-vcrpy)))
2831 (home-page "https://gitlab.com/mailman/postorius")
2832 (synopsis "Web user interface for GNU Mailman")
2833 (description
2834 "Postorius is a Django app which provides a web user interface
2835 to access GNU Mailman.")
2836 (license (list license:gpl3+ license:lgpl3+))))
2837
2838 (define-public blists
2839 (package
2840 (name "blists")
2841 (version "2.0")
2842 (source
2843 (origin
2844 (method url-fetch)
2845 (uri (string-append "http://download.openwall.net/pub/projects/"
2846 "blists/blists-" version ".tar.gz"))
2847 (sha256
2848 (base32
2849 "1xll5wn7py3bbncbwrj172f56nz75c9gwfsa80rwd96ss9gfmp3c"))))
2850 (build-system gnu-build-system)
2851 (arguments
2852 `(#:tests? #f ; No tests
2853 #:phases
2854 (modify-phases %standard-phases
2855 (delete 'configure)
2856 (replace 'install
2857 (lambda* (#:key outputs #:allow-other-keys)
2858 (let* ((out (assoc-ref outputs "out"))
2859 (bin (string-append out "/bin")))
2860 (install-file "bindex" bin)
2861 (install-file "bit" bin)
2862 #t))))))
2863 (home-page "http://www.openwall.com/blists/")
2864 (synopsis "Web interface to mailing list archives")
2865 (description
2866 "Blists is a web interface to mailing list archives that works off
2867 indexed mbox files. There are two programs: @code{bindex} and @code{bit}.
2868 @code{bindex} generates or updates the index file (incremental updates
2869 are supported). @code{bit} is a CGI/SSI program that generates web pages
2870 on the fly. Both programs are written in C and are very fast.")
2871 (license license:expat)))
2872
2873 (define-public swaks
2874 (package
2875 (name "swaks")
2876 (version "20190914.0")
2877 (source
2878 (origin
2879 (method url-fetch)
2880 (uri (string-append
2881 "https://jetmore.org/john/code/swaks/files/swaks-"
2882 version ".tar.gz"))
2883 (sha256
2884 (base32
2885 "12awq5z4sdd54cxprj834zajxhkpy4jwhzf1fhigcx1zbhdaacsp"))))
2886 (build-system perl-build-system)
2887 (inputs
2888 `(("perl-net-dns" ,perl-net-dns)
2889 ("perl-net-ssleay" ,perl-net-ssleay)))
2890 (arguments
2891 `(#:tests? #f ; No tests
2892 #:phases
2893 (modify-phases %standard-phases
2894 (delete 'configure)
2895 (replace 'build
2896 (lambda _
2897 (invoke "pod2man" "doc/ref.pod" "swaks.1")))
2898 (replace 'install
2899 (lambda* (#:key outputs #:allow-other-keys)
2900 (let ((out (assoc-ref outputs "out")))
2901 (install-file "swaks" (string-append out "/bin"))
2902 (install-file "swaks.1" (string-append out "/share/man/man1")))
2903 #t))
2904 (add-after 'install 'wrap-program
2905 (lambda* (#:key outputs #:allow-other-keys)
2906 (wrap-program (string-append (assoc-ref outputs "out")
2907 "/bin/swaks")
2908 `("PERL5LIB" ":" = (,(getenv "PERL5LIB"))))
2909 #t)))))
2910 (home-page "https://jetmore.org/john/code/swaks/")
2911 (synopsis "Featureful SMTP test tool")
2912 (description "Swaks is a flexible, scriptable, transaction-oriented SMTP
2913 test tool. It handles SMTP features and extensions such as TLS,
2914 authentication, and pipelining; multiple versions of the SMTP protocol
2915 including SMTP, ESMTP, and LMTP; and multiple transport methods including
2916 unix-domain sockets, internet-domain sockets, and pipes to spawned processes.
2917 Options can be specified in environment variables, configuration files, and
2918 the command line allowing maximum configurability and ease of use for
2919 operators and scripters.")
2920 (license license:gpl2+)))
2921
2922 (define-public alpine
2923 (package
2924 (name "alpine")
2925 ;; Upstream doesn't use git tags, but does ‘tag’ their releases in the
2926 ;; commit message. Hence the lack of GIT-VERSIONing despite using a commit
2927 ;; ID below. Don't forget to update it…
2928 (version "2.22")
2929 (source
2930 (origin
2931 (method git-fetch)
2932 ;; There are two versions: the plain continuation of Alpine without extra
2933 ;; patches and the version which adds extra fixes. Every distro uses
2934 ;; the patched version, and so do we to not break expectations.
2935 ;; http://alpine.freeiz.com/alpine/readme/README.patches
2936 (uri (git-reference
2937 (url "http://repo.or.cz/alpine.git")
2938 (commit "b50297779a4becb9ceca9c6b5b375d526fe3df78")))
2939 (file-name (git-file-name name version))
2940 (sha256
2941 (base32 "06js44fvdl7l33hfd4lsxpcd1cz3c0h796cswyzz0lkrzx89yl48"))
2942 (modules '((guix build utils)))
2943 (snippet
2944 '(begin
2945 ;; Remove pre-built binaries scattered across the source repository.
2946 (for-each delete-file (find-files "." "\\.(dll|exe)"))
2947 #t))))
2948 (build-system gnu-build-system)
2949 (arguments
2950 `(#:make-flags
2951 (list (string-append "CC=" ,(cc-for-target)))
2952 #:configure-flags (list (string-append "--with-ssl-include-dir="
2953 (assoc-ref %build-inputs "openssl")
2954 "/include/openssl")
2955 (string-append "--with-ssl-dir="
2956 (assoc-ref %build-inputs "openssl"))
2957 (string-append "--with-ssl-certs-dir="
2958 "/etc/ssl/certs/")
2959 (string-append "--with-ssl-lib-dir="
2960 (assoc-ref %build-inputs "openssl")
2961 "/lib")
2962 (string-append "--with-interactive-spellcheck="
2963 (assoc-ref %build-inputs "aspell")
2964 "/bin/aspell")
2965 "--with-date-stamp=Thu 1 Jan 01:00:01 CET 1970")
2966 #:phases
2967 (modify-phases %standard-phases
2968 (add-after 'unpack 'assume-shadow-passwords
2969 ;; Alpine's configure script confuses ‘shadow password support’ with
2970 ;; ‘/etc/shadow exists in the build environment’. It does not.
2971 (lambda _
2972 (substitute* "configure"
2973 (("test -f /etc/shadow") "true"))
2974 #t))
2975 (add-after 'unpack 'make-reproducible
2976 (lambda _
2977 ;; This removes time-dependent code to make alpine reproducible.
2978 (substitute* "pico/blddate.c"
2979 (("%02d-%s-%d") "1970-01-01"))
2980 #t)))))
2981 (inputs
2982 `(("ncurses" ,ncurses)
2983 ("openssl" ,openssl)
2984 ("gnutls" ,gnutls)
2985 ("openldap" ,openldap)
2986 ("cyrus-sasl" ,cyrus-sasl)
2987 ("mit-krb5" ,mit-krb5)
2988 ("aspell" ,aspell)
2989 ("tcl" ,tcl)
2990 ("linux-pam" ,linux-pam)))
2991 (home-page "https://repo.or.cz/alpine.git")
2992 (synopsis "Alternatively Licensed Program for Internet News and Email")
2993 (description
2994 "Alpine is a text-based mail and news client. Alpine includes several
2995 tools and applications:
2996 @enumerate
2997 @item alpine, the Alpine mailer
2998 @item pico, the standalone text editor, GNU nano's predecessor
2999 @item pilot, the standalone file system navigator
3000 @end enumerate\n")
3001 (license license:asl2.0)))
3002
3003 (define-public balsa
3004 (package
3005 (name "balsa")
3006 (version "2.6.1")
3007 (source
3008 (origin
3009 (method url-fetch)
3010 (uri (string-append "https://pawsa.fedorapeople.org/balsa/"
3011 "balsa-" version ".tar.bz2"))
3012 (sha256
3013 (base32 "1xkxx801p7sbfkn0bh3cz85wra4xf1z1zhjqqc80z1z1nln7fhb4"))))
3014 (build-system gnu-build-system)
3015 (arguments
3016 `(#:configure-flags
3017 '(;; Balsa tries to install additional MIME icons
3018 ;; under gtk+ directory.
3019 "--enable-extra-mimeicons=no"
3020 "--with-gtksourceview"
3021 "--with-canberra"
3022 "--with-spell-checker=gtkspell"
3023 "--with-gpgme"
3024 "--with-sqlite"
3025 "--with-compface"
3026 "--with-ldap")))
3027 (inputs
3028 `(("cyrus-sasl" ,cyrus-sasl)
3029 ("enchant" ,enchant)
3030 ("gdk-pixbuf" ,gdk-pixbuf)
3031 ("gmime" ,gmime)
3032 ("gnutls" ,gnutls)
3033 ("gpgme" ,gpgme)
3034 ("gtk+" ,gtk+)
3035 ("gtksourceview" ,gtksourceview-3)
3036 ("gtkspell3" ,gtkspell3)
3037 ("libcanberra" ,libcanberra)
3038 ("libesmtp" ,libesmtp)
3039 ("libical" ,libical)
3040 ("libnotify" ,libnotify)
3041 ("libsecret" ,libsecret)
3042 ("openldap" ,openldap)
3043 ("sqlite" ,sqlite)
3044 ("webkitgtk" ,webkitgtk)))
3045 (native-inputs
3046 `(("compface" ,compface)
3047 ("glib" ,glib "bin")
3048 ("intltool" ,intltool)
3049 ("pkg-config" ,pkg-config)
3050 ("yelp-tools" ,yelp-tools)))
3051 (home-page "https://pawsa.fedorapeople.org/balsa")
3052 (synopsis "E-mail client for GNOME")
3053 (description "Balsa is a highly configurable and robust mail client for
3054 the GNOME desktop. It supports both POP3 and IMAP servers as well as the
3055 mbox, maildir and mh local mailbox formats. Balsa also supports SMTP and/or
3056 the use of a local MTA such as Sendmail.")
3057 (license license:gpl3+)))
3058
3059 (define-public afew
3060 (package
3061 (name "afew")
3062 (version "1.2.0")
3063 (source
3064 (origin
3065 (method url-fetch)
3066 (uri (pypi-uri "afew" version))
3067 (sha256
3068 (base32
3069 "121w7bd53xyibllxxbfykjj76n81kn1vgjqd22izyh67y8qyyk5r"))))
3070 (build-system python-build-system)
3071 (inputs
3072 `(("python-chardet" ,python-chardet)
3073 ("python-notmuch" ,python-notmuch)))
3074 (native-inputs
3075 `(("python-setuptools-scm" ,python-setuptools-scm)))
3076 (home-page "https://github.com/afewmail/afew")
3077 (synopsis "Initial tagging script for notmuch mail")
3078 (description "afew is an initial tagging script for notmuch mail. It
3079 provides automatic tagging each time new mail is registered with notmuch. It
3080 can add tags based on email headers or Maildir folders and can handle spam and
3081 killed threads.")
3082 (license license:isc)))
3083
3084 (define-public pan
3085 (package
3086 (name "pan")
3087 (version "0.146")
3088 (source
3089 (origin
3090 (method url-fetch)
3091 (uri (string-append "http://pan.rebelbase.com/download/releases/"
3092 version "/source/" name "-" version ".tar.bz2"))
3093 (sha256
3094 (base32 "17agd27sn4a7nahvkpg0w39kv74njgdrrygs74bbvpaj8rk2hb55"))))
3095 (arguments
3096 `(#:configure-flags '("--with-gtk3" "--with-gtkspell" "--with-gnutls"
3097 "--enable-libnotify" "--enable-manual"
3098 "--enable-gkr")
3099 #:phases
3100 (modify-phases %standard-phases
3101 (add-before 'configure 'patch-gpg2
3102 (lambda* (#:key inputs #:allow-other-keys)
3103 (substitute* "pan/usenet-utils/gpg.cc"
3104 (("\"gpg2\"") (string-append "\""
3105 (assoc-ref inputs "gnupg")
3106 "/bin/gpg\"")))
3107 #t)))))
3108 (inputs
3109 `(("gmime" ,gmime-2.6)
3110 ("gnupg" ,gnupg)
3111 ("gnutls" ,gnutls)
3112 ("gtk+" ,gtk+)
3113 ("gtkspell3" ,gtkspell3)
3114 ("libnotify" ,libnotify)
3115 ("libsecret" ,libsecret)
3116 ("libxml2" ,libxml2)
3117 ("zlib" ,zlib)))
3118 (native-inputs
3119 `(("gettext-minimal" ,gettext-minimal)
3120 ("itstool" ,itstool)
3121 ("pkg-config" ,pkg-config)))
3122 (build-system gnu-build-system)
3123 (home-page "http://pan.rebelbase.com/")
3124 (synopsis "Pan newsreader")
3125 (description "@code{pan} is a Usenet newsreader that's good at both text
3126 and binaries. It supports offline reading, scoring and killfiles, yEnc, NZB,
3127 PGP handling, multiple servers, and secure connections.")
3128 ;; License of the docs: fdl-1.1; Others: gpl2.
3129 (license (list license:fdl1.1+ license:gpl2))))
3130
3131 (define-public imapfilter
3132 (package
3133 (name "imapfilter")
3134 (version "2.6.16")
3135 (source
3136 (origin
3137 (method git-fetch)
3138 (uri (git-reference
3139 (url "https://github.com/lefcha/imapfilter")
3140 (commit (string-append "v" version))))
3141 (file-name (git-file-name name version))
3142 (sha256
3143 (base32 "0f65sg6hhv6778fxwsz4hvarbm97dsb8jj0mg7a9qs273r35pqck"))))
3144 (build-system gnu-build-system)
3145 (arguments
3146 `(#:tests? #f
3147 #:make-flags
3148 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
3149 "CC=gcc")
3150 #:phases
3151 (modify-phases %standard-phases
3152 (delete 'configure)))) ; no configure script
3153 (native-inputs
3154 `(("lua" ,lua)
3155 ("pcre" ,pcre)
3156 ("openssl" ,openssl)))
3157 (home-page "https://github.com/lefcha/imapfilter")
3158 (synopsis "IMAP mail filtering utility")
3159 (description "IMAPFilter is a mail filtering utility. It connects
3160 to remote mail servers using IMAP, sends searching queries to the server and
3161 processes mailboxes based on the results. It can be used to delete, copy,
3162 move, flag, etc. messages residing in mailboxes at the same or different mail
3163 servers. The 4rev1 and 4 versions of IMAP are supported.")
3164 (license license:expat)))
3165
3166 (define-public urlscan
3167 (package
3168 (name "urlscan")
3169 (version "0.9.5")
3170 (source
3171 (origin
3172 (method url-fetch)
3173 (uri (pypi-uri "urlscan" version))
3174 (sha256
3175 (base32 "07vcwirap0p4dkqrqblfn1q017slgd8m6qyijvbi3gxnr09pbyx2"))))
3176 (build-system python-build-system)
3177 (propagated-inputs
3178 `(("python-urwid" ,python-urwid)))
3179 (home-page "https://github.com/firecat53/urlscan")
3180 (synopsis "View/select the URLs in an email message or file")
3181 (description
3182 "Urlscan is a small program that is designed to integrate with the
3183 Mutt mail reader to allow you to easily launch a Web browser for URLs
3184 contained in email messages. It parses an email message or file and scans it
3185 for URLs and email addresses. It then displays the URLs and their context
3186 within the message, and allows you to choose one or more URLs to send to your
3187 Web browser. Alternatively, it send a list of all URLs to standard output.
3188 It is a replacement for the @command{urlview} program.")
3189 (license license:gpl2)))
3190
3191 (define-public tnef
3192 (package
3193 (name "tnef")
3194 (version "1.4.18")
3195 (source
3196 (origin
3197 (method git-fetch)
3198 (uri (git-reference
3199 (url "https://github.com/verdammelt/tnef")
3200 (commit version)))
3201 (sha256
3202 (base32 "104g48mcm00bgiyzas2vf86331w7bnw7h3bc11ib4lp7rz6zqfck"))
3203 (file-name (git-file-name name version))))
3204 (build-system gnu-build-system)
3205 (native-inputs
3206 `(("autoconf" ,autoconf)
3207 ("automake" ,automake)))
3208 (arguments `(#:parallel-tests? #f)) ;tests are side-effect'y
3209 (home-page "https://github.com/verdammelt/tnef")
3210 (synopsis "Unpack @code{application/ms-tnef} attachments")
3211 (description
3212 "TNEF is a tar-like program that unpacks MIME attachments of type
3213 @code{application/ms-tnef}.")
3214 (license license:gpl2+)))
3215
3216 (define-public mumi
3217 (let ((commit "5a578328199bab51a147fbadbce12c8d06959ed6")
3218 (revision "2"))
3219 (package
3220 (name "mumi")
3221 (version (git-version "0.0.1" revision commit))
3222 (source (origin
3223 (method git-fetch)
3224 (uri (git-reference
3225 (url "https://git.elephly.net/software/mumi.git")
3226 (commit commit)))
3227 (file-name (git-file-name name version))
3228 (sha256
3229 (base32
3230 "0hngv82gd19l4q7nnbf97r120z1yagsmkp0x3lc8haza5q4mc12c"))))
3231 (build-system gnu-build-system)
3232 (arguments
3233 `(#:modules ((guix build gnu-build-system)
3234 ((guix build guile-build-system)
3235 #:select (target-guile-effective-version))
3236 (guix build utils))
3237 #:imported-modules ((guix build guile-build-system)
3238 ,@%gnu-build-system-modules)
3239
3240 #:configure-flags '("--localstatedir=/var")
3241
3242 #:phases
3243 (modify-phases %standard-phases
3244 (add-after 'install 'wrap-executable
3245 (lambda* (#:key outputs #:allow-other-keys)
3246 (let* ((out (assoc-ref outputs "out"))
3247 (bin (string-append out "/bin"))
3248 (version (target-guile-effective-version))
3249 (scm (string-append out "/share/guile/site/" version))
3250 (go (string-append out "/lib/guile/" version
3251 "/site-ccache")))
3252 (wrap-program (string-append bin "/mumi")
3253 `("GUILE_LOAD_PATH" ":" prefix
3254 (,scm ,(getenv "GUILE_LOAD_PATH")))
3255 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
3256 (,go ,(getenv "GUILE_LOAD_COMPILED_PATH"))))
3257 #t))))))
3258 (inputs
3259 `(("guile-email" ,guile-email)
3260 ("guile-fibers" ,guile-fibers)
3261 ("guile-gcrypt" ,guile-gcrypt)
3262 ("guile-json" ,guile-json-3)
3263 ("guile-redis" ,guile-redis)
3264 ("guile-syntax-highlight" ,guile-syntax-highlight)
3265 ("guile-webutils" ,guile-webutils)
3266 ("guile-xapian" ,guile-xapian)
3267 ("guile" ,guile-3.0)
3268 ("mailutils" ,mailutils)))
3269 (native-inputs
3270 `(("autoconf" ,autoconf)
3271 ("automake" ,automake)
3272 ("pkg-config" ,pkg-config)))
3273 (home-page "https://git.elephly.net/software/mumi.git")
3274 (synopsis "Debbugs web interface")
3275 (description "Mumi is a Debbugs web interface.")
3276 (license license:agpl3+))))
3277
3278 (define-public ytnef
3279 (package
3280 (name "ytnef")
3281 (version "1.9.3")
3282 (source (origin
3283 (method git-fetch)
3284 (uri (git-reference
3285 (url "https://github.com/Yeraze/ytnef")
3286 (commit (string-append "v" version))))
3287 (file-name (git-file-name name version))
3288 (sha256
3289 (base32
3290 "07h48s5qf08503pp9kafqbwipdqghiif22ghki7z8j67gyp04l6l"))))
3291 (build-system gnu-build-system)
3292 (native-inputs
3293 `(("autoconf" ,autoconf)
3294 ("automake" ,automake)
3295 ("libtool" ,libtool)))
3296 (home-page "https://github.com/Yeraze/ytnef/")
3297 (synopsis "TNEF stream reader for winmail.dat files")
3298 (description "This package provides a TNEF stream reader library and
3299 related tools to process winmail.dat files.")
3300 (license license:gpl2+)))
3301
3302 (define-public public-inbox
3303 (package
3304 (name "public-inbox")
3305 (version "1.5.0")
3306 (source
3307 (origin (method git-fetch)
3308 (uri (git-reference
3309 (url "https://public-inbox.org")
3310 (commit (string-append "v" version))))
3311 (sha256
3312 (base32
3313 "03zj7shdl3vibs7k5lr673bwcf8j1xx8is3mjz34ca4cdh6p5j2k"))
3314 (file-name (git-file-name name version))))
3315 (build-system perl-build-system)
3316 (arguments
3317 '(#:phases
3318 (modify-phases %standard-phases
3319 (add-before 'configure 'qualify-paths
3320 (lambda _
3321 ;; Use absolute paths for 'xapian-compact'.
3322 (let ((xapian-compact (which "xapian-compact")))
3323 (substitute* "script/public-inbox-compact"
3324 (("xapian-compact") xapian-compact)))
3325 #t))
3326 (add-before 'check 'pre-check
3327 (lambda _
3328 (substitute* "t/spawn.t"
3329 (("\\['env'\\]") (string-append "['" (which "env") "']")))
3330 (substitute* "t/ds-leak.t"
3331 (("/bin/sh") (which "sh")))
3332 (invoke "./certs/create-certs.perl")
3333 ;; XXX: This test fails due to zombie process is not reaped by
3334 ;; the builder.
3335 (substitute* "t/httpd-unix.t"
3336 (("^SKIP: \\{") "SKIP: { skip('Guix');"))
3337 #t))
3338 (add-after 'install 'wrap-programs
3339 (lambda* (#:key inputs outputs #:allow-other-keys)
3340 (let ((out (assoc-ref outputs "out")))
3341 (for-each
3342 (lambda (prog)
3343 (wrap-program prog
3344 ;; Let those scripts find their perl modules.
3345 `("PERL5LIB" ":" prefix
3346 (,(string-append out "/lib/perl5/site_perl")
3347 ,(getenv "PERL5LIB")))
3348 ;; 'git' is invoked in various files of the PublicInbox
3349 ;; perl module.
3350 `("PATH" ":" prefix
3351 (,(string-append (assoc-ref inputs "git") "/bin")))))
3352 (find-files (string-append out "/bin"))))
3353 #t)))))
3354 (native-inputs
3355 `(("xapian" ,xapian)
3356 ;; For testing.
3357 ("lsof" ,lsof)
3358 ("openssl" ,openssl)))
3359 (inputs
3360 `(("git" ,git)
3361 ("perl-dbd-sqlite" ,perl-dbd-sqlite)
3362 ("perl-dbi" ,perl-dbi)
3363 ("perl-email-address-xs" ,perl-email-address-xs)
3364 ("perl-email-mime-contenttype" ,perl-email-mime-contenttype)
3365 ("perl-email-mime" ,perl-email-mime)
3366 ("perl-email-simple" ,perl-email-simple)
3367 ("perl-net-server" ,perl-net-server)
3368 ("perl-filesys-notify-simple" ,perl-filesys-notify-simple)
3369 ("perl-plack-middleware-deflater" ,perl-plack-middleware-deflater)
3370 ("perl-plack-middleware-reverseproxy" ,perl-plack-middleware-reverseproxy)
3371 ("perl-plack" ,perl-plack)
3372 ("perl-search-xapian" ,perl-search-xapian)
3373 ("perl-timedate" ,perl-timedate)
3374 ("perl-uri-escape" ,perl-uri-escape)
3375 ;; For testing.
3376 ("perl-ipc-run" ,perl-ipc-run)
3377 ("perl-xml-feed" ,perl-xml-feed)))
3378 (home-page "https://public-inbox.org/README.html")
3379 (synopsis "Archive mailing lists in git repositories")
3380 (description
3381 "public-inbox implements the sharing of an email inbox via git to
3382 complement or replace traditional mailing lists. Readers may read via NNTP,
3383 Atom feeds or HTML archives.")
3384 (license license:agpl3+)))
3385
3386 (define-public sylpheed
3387 (package
3388 (name "sylpheed")
3389 (version "3.7.0")
3390 (source (origin
3391 (method url-fetch)
3392 (uri (string-append "https://sylpheed.sraoss.jp/sylpheed/v3.7/"
3393 name "-" version ".tar.xz"))
3394 (sha256
3395 (base32
3396 "0j9y5vdzch251s264diw9clrn88dn20bqqkwfmis9l7m8vmwasqd"))))
3397 (build-system gnu-build-system)
3398 (native-inputs
3399 `(("pkg-config" ,pkg-config)))
3400 (inputs
3401 `(("bogofilter" ,bogofilter)
3402 ("compface" ,compface)
3403 ("gnupg" ,gnupg-1)
3404 ("gpgme" ,gpgme)
3405 ("gtk+-2.0" ,gtk+-2)
3406 ("gtkspell" ,gtkspell3)
3407 ("libnsl" ,libnsl)
3408 ("openldap" ,openldap)
3409 ("openssl" ,openssl)))
3410 (home-page "https://sylpheed.sraoss.jp/en/")
3411 (synopsis "Lightweight GTK+ email client")
3412 (description
3413 "Sylpheed is a simple, lightweight but featureful, and easy-to-use e-mail
3414 client. Sylpheed provides intuitive user-interface. Sylpheed is also
3415 designed for keyboard-oriented operation.")
3416 (license license:gpl2+)))
3417
3418 (define-public python-authres
3419 (package
3420 (name "python-authres")
3421 (version "1.2.0")
3422 (source
3423 (origin
3424 (method url-fetch)
3425 (uri (pypi-uri "authres" version))
3426 (sha256
3427 (base32
3428 "1dr5zpqnb54h4f5ax8334l1dcp8j9083d7v4vdi1xqkwmnavklck"))))
3429 (build-system python-build-system)
3430 (arguments
3431 '(#:phases
3432 (modify-phases %standard-phases
3433 (replace 'check
3434 ;; Run doctests as described in the README.
3435 (lambda _
3436 (invoke "python" "-m" "authres" "-v"))))))
3437 (home-page "https://launchpad.net/authentication-results-python")
3438 (synopsis "Email Authentication Results Header Module")
3439 (description
3440 "This module can be used to generate and parse RFC 5451/7001/7601
3441 Authentication-Results headers. It also supports Authentication Results
3442 extensions:
3443 @itemize
3444 @item RFC 5617 DKIM/ADSP
3445 @item RFC 6008 DKIM signature identification (header.b)
3446 @item RFC 6212 Vouch By Reference (VBR)
3447 @item RFC 6577 Sender Policy Framework (SPF)
3448 @item RFC 7281 Authentication-Results Registration for S/MIME
3449 @item RFC 7293 The Require-Recipient-Valid-Since Header Field
3450 @item RFC 7489 Domain-based Message Authentication, Reporting, and Conformance (DMARC)
3451 @item Authenticated Recieved Chain (ARC) (draft-ietf-dmarc-arc-protocol-08)
3452 @end itemize
3453 Note: RFC 7601 obsoletes RFC 5451, 6577, 7001, and 7410. Authres supports the
3454 current standard. No backward compatibility issues have been noted.")
3455 (license license:asl2.0)))
3456
3457 (define-public python-dkimpy
3458 (package
3459 (name "python-dkimpy")
3460 (version "1.0.5")
3461 (source
3462 (origin
3463 (method url-fetch)
3464 (uri (pypi-uri "dkimpy" version))
3465 (sha256
3466 (base32 "088iz5cqjqh4c7141d94pvn13bh25aizqlrifwv6fs5g16zj094s"))))
3467 (build-system python-build-system)
3468 (arguments
3469 '(#:phases
3470 (modify-phases %standard-phases
3471 (add-after 'patch-source-shebangs 'patch-more-source
3472 (lambda* (#:key inputs #:allow-other-keys)
3473 (let ((openssl (assoc-ref inputs "openssl")))
3474 (substitute* "dkim/dknewkey.py"
3475 (("/usr/bin/openssl") (string-append openssl "/bin/openssl"))))
3476 #t))
3477 (replace 'check
3478 (lambda _
3479 (invoke "python" "test.py"))))))
3480 (propagated-inputs
3481 `(("python-dnspython" ,python-dnspython)))
3482 (native-inputs
3483 `(("python-authres" ,python-authres)
3484 ("python-pynacl" ,python-pynacl)))
3485 (inputs
3486 `(("openssl" ,openssl)))
3487 (home-page "https://launchpad.net/dkimpy")
3488 (synopsis "DKIM (DomainKeys Identified Mail)")
3489 (description "Python module that implements @dfn{DKIM} (DomainKeys
3490 Identified Mail) email signing and verification (RFC6376). It also provides
3491 helper scripts for command line signing and verification. It supports DKIM
3492 signing/verifying of ed25519-sha256 signatures (RFC 8463). It also supports
3493 the RFC 8617 Authenticated Received Chain (ARC) protocol.")
3494 (license license:bsd-3)))
3495
3496 (define-public python-authheaders
3497 (package
3498 (name "python-authheaders")
3499 (version "0.13.0")
3500 (source
3501 (origin
3502 (method url-fetch)
3503 (uri (pypi-uri "authheaders" version))
3504 (sha256
3505 (base32
3506 "14k6i72k5f8dyvps8vc0aq0cczc8lvqpgjfjzsy6qqychjvjcmwk"))))
3507 (build-system python-build-system)
3508 (propagated-inputs
3509 `(("python-authres" ,python-authres)
3510 ("python-dkimpy" ,python-dkimpy)
3511 ("python-dnspython" ,python-dnspython)
3512 ("python-publicsuffix2" ,python-publicsuffix2)))
3513 (home-page "https://github.com/ValiMail/authentication-headers")
3514 (synopsis "Library wrapping email authentication header verification and generation")
3515 (description
3516 "This is a Python library for the generation of email authentication
3517 headers. The library can perform DKIM, SPF, and DMARC validation, and the
3518 results are packaged into the Authentication-Results header. The library can
3519 DKIM and ARC sign messages and output the corresponding signature headers.")
3520 ;; The package's metadata claims it were MIT licensed, but the source file
3521 ;; headers disagree. MPL-2 for the public suffix list.
3522 (license (list license:zpl2.1 license:zlib license:mpl2.0))))
3523
3524 (define-public python-aiosmtpd
3525 (package
3526 (name "python-aiosmtpd")
3527 (version "1.2.1")
3528 (source
3529 (origin
3530 (method git-fetch)
3531 (uri (git-reference
3532 (url "https://github.com/aio-libs/aiosmtpd")
3533 (commit version)))
3534 (sha256
3535 (base32 "14c30dm6jzxiblnsah53fdv68vqhxwvb9x0aq9bc4vcdas747vr7"))
3536 (file-name (git-file-name name version))))
3537 (build-system python-build-system)
3538 (arguments
3539 '(#:phases
3540 (modify-phases %standard-phases
3541 (add-after 'unpack 'delete-failing-tests
3542 (lambda _
3543 ;; This test uses an expired certificate.
3544 (delete-file "aiosmtpd/tests/test_smtps.py")
3545 #t))
3546 (replace 'check
3547 (lambda _
3548 (invoke "python" "-m" "nose2" "-v"))))))
3549 (native-inputs
3550 `(("python-flufl-testing" ,python-flufl-testing)
3551 ("python-nose2" ,python-nose2)))
3552 (propagated-inputs
3553 `(("python-atpublic" ,python-atpublic)))
3554 (home-page "https://aiosmtpd.readthedocs.io/")
3555 (synopsis "Asyncio based SMTP server")
3556 (description
3557 "This project is a reimplementation of the Python stdlib @code{smtpd.py}
3558 based on asyncio.")
3559 (license (list license:asl2.0
3560 license:lgpl3)))) ; only for setup_helpers.py