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