1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2014, 2015, 2017, 2020 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, 2021 Efraim Flashner <efraim@flashner.co.il>
12 ;;; Copyright © 2016 Christine Lemmer-Webber <cwebber@dustycloud.org>
13 ;;; Copyright © 2016 Al McElrath <hello@yrns.org>
14 ;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 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, 2021 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–2021 Tobias Geerinckx-Rice <me@tobias.gr>
26 ;;; Copyright © 2017, 2018, 2020 Rene Saavedra <pacoon@protonmail.com>
27 ;;; Copyright © 2018, 2019, 2020, 2021 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, 2021 Ricardo Wurmus <rekado@elephly.net>
31 ;;; Copyright © 2019, 2020 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, 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com>
36 ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
37 ;;; Copyright © 2020, 2021 Alexey Abramov <levenson@mmer.org>
38 ;;; Copyright © 2020 Tim Gesthuizen <tim.gesthuizen@yahoo.de>
39 ;;; Copyright © 2020, 2021 Alexandru-Sergiu Marton <brown121407@posteo.ro>
40 ;;; Copyright © 2020 Oleg Pykhalov <go.wigust@gmail.com>
41 ;;; Copyright © 2020 B. Wilson <elaexuotee@wilsonb.com>
42 ;;; Copyright © 2020 divoplade <d@divoplade.fr>
43 ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com>
44 ;;; Copyright © 2021 Xinglu Chen <public@yoctocell.xyz>
45 ;;; Copyright © 2021 Benoit Joly <benoit@benoitj.ca>
47 ;;; This file is part of GNU Guix.
49 ;;; GNU Guix is free software; you can redistribute it and/or modify it
50 ;;; under the terms of the GNU General Public License as published by
51 ;;; the Free Software Foundation; either version 3 of the License, or (at
52 ;;; your option) any later version.
54 ;;; GNU Guix is distributed in the hope that it will be useful, but
55 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
56 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
57 ;;; GNU General Public License for more details.
59 ;;; You should have received a copy of the GNU General Public License
60 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
62 (define-module (gnu packages mail)
63 #:use-module (guix utils)
64 #:use-module (gnu packages)
65 #:use-module (gnu packages admin)
66 #:use-module (gnu packages aspell)
67 #:use-module (gnu packages autotools)
68 #:use-module (gnu packages backup)
69 #:use-module (gnu packages base)
70 #:use-module (gnu packages bash)
71 #:use-module (gnu packages bison)
72 #:use-module (gnu packages boost)
73 #:use-module (gnu packages calendar)
74 #:use-module (gnu packages check)
75 #:use-module (gnu packages compression)
76 #:use-module (gnu packages crypto)
77 #:use-module (gnu packages curl)
78 #:use-module (gnu packages cyrus-sasl)
79 #:use-module (gnu packages databases)
80 #:use-module (gnu packages dbm)
81 #:use-module (gnu packages dejagnu)
82 #:use-module (gnu packages django)
83 #:use-module (gnu packages dns)
84 #:use-module (gnu packages docbook)
85 #:use-module (gnu packages documentation)
86 #:use-module (gnu packages emacs)
87 #:use-module (gnu packages enchant)
88 #:use-module (gnu packages file)
89 #:use-module (gnu packages fontutils)
90 #:use-module (gnu packages freedesktop)
91 #:use-module (gnu packages gdb)
92 #:use-module (gnu packages gettext)
93 #:use-module (gnu packages ghostscript)
94 #:use-module (gnu packages glib)
95 #:use-module (gnu packages golang)
96 #:use-module (gnu packages gnome)
97 #:use-module (gnu packages gnupg)
98 #:use-module (gnu packages groff)
99 #:use-module (gnu packages gsasl)
100 #:use-module (gnu packages gtk)
101 #:use-module (gnu packages guile)
102 #:use-module (gnu packages guile-xyz)
103 #:use-module (gnu packages flex)
104 #:use-module (gnu packages haskell-xyz)
105 #:use-module (gnu packages icu4c)
106 #:use-module (gnu packages kerberos)
107 #:use-module (gnu packages language)
108 #:use-module (gnu packages libcanberra)
109 #:use-module (gnu packages libevent)
110 #:use-module (gnu packages libidn)
111 #:use-module (gnu packages libunistring)
112 #:use-module (gnu packages libunwind)
113 #:use-module (gnu packages linux)
114 #:use-module (gnu packages lsof)
115 #:use-module (gnu packages lua)
116 #:use-module (gnu packages m4)
117 #:use-module (gnu packages man)
118 #:use-module (gnu packages ncurses)
119 #:use-module (gnu packages nettle)
120 #:use-module (gnu packages networking)
121 #:use-module (gnu packages ninja)
122 #:use-module (gnu packages openldap)
123 #:use-module (gnu packages onc-rpc)
124 #:use-module (gnu packages pcre)
125 #:use-module (gnu packages pdf)
126 #:use-module (gnu packages perl)
127 #:use-module (gnu packages perl-check)
128 #:use-module (gnu packages perl-web)
129 #:use-module (gnu packages pkg-config)
130 #:use-module (gnu packages protobuf)
131 #:use-module (gnu packages python)
132 #:use-module (gnu packages python-check)
133 #:use-module (gnu packages python-crypto)
134 #:use-module (gnu packages python-web)
135 #:use-module (gnu packages python-xyz)
136 #:use-module (gnu packages ragel)
137 #:use-module (gnu packages regex)
138 #:use-module (gnu packages rdf)
139 #:use-module (gnu packages readline)
140 #:use-module (gnu packages ruby)
141 #:use-module (gnu packages search)
142 #:use-module (gnu packages serialization)
143 #:use-module (gnu packages samba)
144 #:use-module (gnu packages screen)
145 #:use-module (gnu packages sphinx)
146 #:use-module (gnu packages sqlite)
147 #:use-module (gnu packages tcl)
148 #:use-module (gnu packages texinfo)
149 #:use-module (gnu packages time)
150 #:use-module (gnu packages tls)
151 #:use-module (gnu packages version-control)
152 #:use-module (gnu packages w3m)
153 #:use-module (gnu packages web)
154 #:use-module (gnu packages webkit)
155 #:use-module (gnu packages xdisorg)
156 #:use-module (gnu packages xorg)
157 #:use-module (gnu packages xml)
158 #:use-module ((guix licenses) #:prefix license:)
159 #:use-module (guix packages)
160 #:use-module (guix deprecation)
161 #:use-module (guix download)
162 #:use-module (guix git-download)
163 #:use-module (guix svn-download)
164 #:use-module (guix utils)
165 #:use-module (guix build-system cmake)
166 #:use-module (guix build-system glib-or-gtk)
167 #:use-module (guix build-system go)
168 #:use-module (guix build-system gnu)
169 #:use-module (guix build-system go)
170 #:use-module (guix build-system guile)
171 #:use-module (guix build-system emacs)
172 #:use-module (guix build-system meson)
173 #:use-module (guix build-system perl)
174 #:use-module (guix build-system python)
175 #:use-module (guix build-system trivial)
176 #:use-module (srfi srfi-1)
177 #:use-module (ice-9 match))
186 (uri (string-append "https://abook.sourceforge.io/devel/abook-" version ".tar.gz"))
188 (base32 "1yf0ifyjhq2r003pnpn92mn0924bn9yxjifxxj2ldcsgd7w0vagh"))))
189 (build-system gnu-build-system)
192 (modify-phases %standard-phases
193 ;; Fix "undefined reference to `field_id'" errors.
194 (add-after 'unpack 'fix-build-with-recent-gcc
196 (substitute* '("database.c" "database.h")
197 (("^inline int" all) (string-append "extern " all)))))
198 ;; Fix following error during bootstrap: "gettext infrastructure
199 ;; mismatch: using a Makefile.in.in from gettext version 0.18 but the
200 ;; autoconf macros are from gettext version 0.20".
201 (add-before 'bootstrap 'fix-gettext-macro-version
203 (substitute* "po/Makefile.in.in"
208 (invoke "automake" "--add-missing")
209 (invoke "autoconf"))))))
211 `(("autoconf" ,autoconf)
212 ("automake" ,automake)
213 ("gettext" ,gettext-minimal)))
215 `(("ncurses" ,ncurses)
216 ("readline" ,readline)))
217 (home-page "https://abook.sourceforge.io/")
218 (synopsis "Text-based address book")
220 "Abook is a text-based address book program designed to use with the Mutt
222 (license license:gpl2)))
224 (define-public anubis
227 ;; This 4.2.90 alpha release adds support for Guile 3 and has fixes for
233 (uri (string-append "https://alpha.gnu.org/gnu/anubis/anubis-"
237 "0dvm6acl32dv8bixx9z50gzwfp6kj4kxnn1j3dcwjlp7sasjp41s"))))
238 (build-system gnu-build-system)
240 `(("automake" ,automake)
241 ("autoconf" ,autoconf)
242 ("gettext" ,gettext-minimal)
243 ("m4" ,m4))) ;for the test suite
250 ("libgcrypt" ,libgcrypt) ;gnutls support depends on libgcrypt
251 ("libgpg-error" ,libgpg-error)))
252 (outputs '("out" "debug"))
253 (synopsis "SMTP message submission daemon")
254 (description "Anubis is a daemon that sits between the Mail User
255 Agent (MUA) and the Mail Transfer Agent (MTA). When a mail is sent by a user
256 in the MUA, it is first passed to Anubis, which performs additional processing
257 to the message before passing it on for delivery by the MTA. Anubis may, for
258 example, modify the message headers or body, or encrypt or sign the message.")
259 (home-page "https://www.gnu.org/software/anubis/manual/")
260 (license license:gpl3+)))
262 (define-public mailutils
268 (uri (string-append "mirror://gnu/mailutils/mailutils-"
272 "1iwl82d6aa2acsdxbqh1s5xx44sg83b4yxqik408m1s9rcfrf86r"))
274 (search-patches "mailutils-variable-lookup.patch"))))
275 (build-system gnu-build-system)
278 (modify-phases %standard-phases
279 (add-before 'check 'prepare-test-suite
281 ;; Use the right file name for `cat'.
282 (substitute* "testsuite/lib/mailutils.exp"
286 ;; Tests try to invoke 'mda' such that it looks up the
287 ;; 'root' user, which does not exist in the build
289 (substitute* '("mda/mda/tests/testsuite"
290 "mda/lmtpd/tests/testsuite")
291 (("root <") "nobody <")
292 (("spool/root") "spool/nobody")
293 (("root@localhost") "nobody@localhost"))
295 ;; The 'pipeact.at' tests generate a shell script; make
296 ;; sure it uses the right shell.
297 (substitute* '("sieve/tests/testsuite"
299 "libmailutils/tests/lock.at")
301 (string-append "#!" (which "sh"))))
303 (substitute* "mh/tests/testsuite"
304 (("moreproc: /bin/cat")
305 (string-append "moreproc: " (which "cat"))))
307 ;; XXX: The comsatd tests rely on being able to open
308 ;; /dev/tty, but that gives ENODEV in the build
309 ;; environment. Thus, ignore test failures here.
310 (substitute* "comsat/tests/Makefile.in"
311 (("\\$\\(SHELL\\) \\$\\(TESTSUITE\\)" all)
312 (string-append "-" all)))
314 ;; XXX: The ‘moderator: program discard’ test does not specify
315 ;; an explicit From: but does expect an exact match. But why are
316 ;; all other tests unaffected?
317 (substitute* "sieve/tests/testsuite"
321 ;; 'frm' tests expect write access to $HOME.
322 (setenv "HOME" (getcwd))
324 ;; Avoid the message "I'm going to create the standard MH path
325 ;; for you", which would lead to one test failure (when diffing
326 ;; stdout of 'fmtcheck'.)
327 (call-with-output-file ".mh_profile"
329 (format port "Path: ~a/Mail-for-tests~%"
332 (substitute* "imap4d/tests/testclient.c"
334 (string-append "\"" (which "sh") "\""))))))
336 (list "--sysconfdir=/etc"
338 ;; Add "/X.Y" to the installation directory.
339 (string-append "--with-guile-site-dir="
340 (assoc-ref %outputs "out")
342 ,(match (assoc "guile"
343 (package-inputs this-package))
346 (package-version guile))))))))
348 ;; Regeneration of the build system is triggered by touching the
349 ;; 'libmailutils/tests/lock.at' file.
350 `(("autoconf" ,autoconf)
351 ("automake" ,automake)
352 ("gettext" ,gettext-minimal)
355 ("perl" ,perl) ;for 'gylwrap'
357 ("dejagnu" ,dejagnu)))
359 `(("guile" ,guile-3.0)
363 ("readline" ,readline)
364 ("linux-pam" ,linux-pam)
367 ;; Required for SEARCH CHARSET.
368 ("libiconv" ,libiconv)
369 ("libunistring" ,libunistring)))
370 (home-page "https://mailutils.org")
371 (synopsis "Utilities and library for reading and serving mail")
373 "GNU Mailutils is a collection of programs for managing, viewing and
374 processing electronic mail. It contains both utilities and server daemons
375 and all operate in a protocol-agnostic way. The underlying libraries are
376 also available, simplifying the addition of mail capabilities to new
377 software. GNU Mailutils provides the following commands:
386 @item mailutils-config
396 ;; Libraries are under LGPLv3+, and programs under GPLv3+.
397 (list license:gpl3+ license:lgpl3+))))
399 (define-public go-gitlab.com-shackra-goimapnotify
400 (let ((commit "832bc7112db9b28e28d69e90b91ea6c005244c9b")
403 (name "go-gitlab.com-shackra-goimapnotify")
404 (version (git-version "0.0.0" revision commit))
408 (url "https://gitlab.com/shackra/goimapnotify")
410 (file-name (git-file-name name version))
413 "1h27kshx4vwl5k6vc2szsq3d701fzs4gczjypz907f8hj0lrnjmy"))))
414 (build-system go-build-system)
416 `(#:import-path "gitlab.com/shackra/goimapnotify"))
418 `(("go-github-com-emersion-go-imap" ,go-github-com-emersion-go-imap)
419 ("go-github-com-emersion-go-imap-idle" ,go-github-com-emersion-go-imap-idle)
420 ("go-github-com-emersion-go-sasl" ,go-github-com-emersion-go-sasl)
421 ("go-github-com-sirupsen-logrus" ,go-github-com-sirupsen-logrus)
422 ("go-golang-org-x-text" ,go-golang-org-x-text)))
423 (synopsis "Execute scripts on IMAP mailbox changes.")
425 "Script to execute scripts on IMAP mailbox changes (new/deleted/updated
426 messages) using IDLE. Implemented in Go.")
427 (home-page "https://gitlab.com/shackra/goimapnotify")
428 (license license:gpl3+))))
430 (define-public guile2.2-mailutils
433 (name "guile2.2-mailutils")
435 `(("guile" ,guile-2.2)
436 ,@(alist-delete "guile" (package-inputs mailutils))))))
438 (define-public guile3.0-mailutils
439 (deprecated-package "guile3.0-mailutils" mailutils))
441 (define-public nullmailer
449 (string-append "https://untroubled.org/nullmailer/"
450 "nullmailer-" version ".tar.gz")
451 ;; Previous releases are moved to this subdirectory.
452 (string-append "https://untroubled.org/nullmailer/archive/"
453 "nullmailer-" version ".tar.gz")))
455 (base32 "0md8cf90fl2yf3zh9njjy42a673v4j4ygyq95xg7fzkygdigm1lq"))))
456 (build-system gnu-build-system)
460 "--localstatedir=/var"
463 (modify-phases %standard-phases
464 (add-before 'check 'patch-test-FHS-file-names
466 (with-directory-excursion "test"
467 (substitute* (list "functions.in"
469 ;; Fix some shebangs later generated on the fly.
470 (("/bin/sh") (which "bash"))))
472 (add-before 'check 'pass-PATH-to-tests
473 ;; ‘runtest’ launches each test through ‘env -’, clearing $PATH. The
474 ;; tests then source ‘functions’, which first demands a working $PATH
475 ;; only to clobber it later. Pass our $PATH to the test environment
476 ;; and don't touch it after that.
478 (with-directory-excursion "test"
479 (substitute* "runtests"
481 (string-append "env - PATH=\"" (getenv "PATH") "\" bash")))
482 (substitute* "functions.in"
483 (("export PATH=.*") "")))
485 (add-before 'check 'delete-failing-tests
487 (with-directory-excursion "test/tests"
488 (for-each delete-file
490 ;; XXX ‘nullmailer-inject: nullmailer-queue failed: 15’
492 ;; XXX These require the not-yet-packaged tcpserver.
493 "protocols" "smtp-auth")))
495 (add-before 'install 'skip-install-data-local
496 ;; Don't attempt to install run-time files outside of the store.
498 (substitute* "Makefile"
499 ((" install-data-local") ""))
503 `(("daemontools" ,daemontools))) ; for svc
505 `(("gnutls" ,gnutls)))
506 (home-page "https://untroubled.org/nullmailer/")
507 (synopsis "Simple relay-only mail transfer agent")
509 "Nullmailer is a simple replacement @acronym{MTA, Mail Transfer Agent} for
510 hosts that receive no local mail and only relay mail to a fixed set of smart
511 relays. It's useful for systems such as Web servers that must be able to send
512 email notifications, without having to run a full-blown MTA such as sendmail
515 Nullmailer is designed to be simple to configure, easy to extend, and secure.
516 It requires little ongoing administration. The included @command{sendmail}
517 emulator front-end should allow most (if not all) sendmail-compatible programs
518 to run without any changes.")
519 (license (list license:lgpl2.1+ ; lib/cli++/ (but some files lack headers)
520 license:gpl2+)))) ; everything else
522 (define-public fetchmail
529 (uri (string-append "mirror://sourceforge/fetchmail/branch_"
530 (version-major+minor version) "/"
531 "fetchmail-" version ".tar.xz"))
533 (base32 "07cxr5137hvrk8jfgn4wd6sq9361c3d40w8krnjxm8fpmwf9qiba"))))
534 (build-system gnu-build-system)
536 `(("openssl" ,openssl)))
539 (list (string-append "--with-ssl="
540 (assoc-ref %build-inputs "openssl")))))
541 (home-page "https://www.fetchmail.info/")
542 (synopsis "Remote-mail retrieval and forwarding utility")
544 "Fetchmail is a full-featured, robust, well-documented remote-mail
545 retrieval and forwarding utility intended to be used over on-demand
546 TCP/IP links (such as SLIP or PPP connections). It supports every
547 remote-mail protocol now in use on the Internet: POP2, POP3, RPOP, APOP,
548 KPOP, all flavors of IMAP, ETRN, and ODMR. It can even support IPv6
551 Fetchmail retrieves mail from remote mail servers and forwards it via SMTP,
552 so it can then be read by normal mail user agents such as mutt, elm
553 or BSD Mail. It allows all your system MTA's filtering, forwarding, and
554 aliasing facilities to work just as they would on normal mail.")
555 (license license:gpl2+))) ; most files are actually public domain or x11
564 (string-append "https://bitbucket.org/mutt/mutt/downloads/"
565 "mutt-" version ".tar.gz")
566 (string-append "http://ftp.mutt.org/pub/mutt/mutt-"
570 "0jjjvqkqmpj55v111p1a1i2ry7mpd1bpphn1bhvlr18rgw7xdrja"))
571 (patches (search-patches "mutt-store-references.patch"))))
572 (build-system gnu-build-system)
574 `(("cyrus-sasl" ,cyrus-sasl)
583 `(#:configure-flags '("--enable-smtp"
587 "--enable-hcache" ; for header caching
592 "--with-sqlite3" ; required for Autocrypt
593 "--with-idn2" ; recommended for Autocrypt
594 ;; So that mutt does not check whether the path
595 ;; exists, which it does not in the chroot.
596 "--with-mailpath=/var/mail")))
597 (home-page "http://www.mutt.org/")
598 (synopsis "Mail client")
600 "Mutt is a small but very powerful text-based mail client for Unix
602 (license license:gpl2+)))
604 (define-public neomutt
612 (url "https://github.com/neomutt/neomutt")
614 (file-name (git-file-name name version))
616 (base32 "15kr9nvb4j8lx5rl2yapv231rbp4sbn709vv82pfhx5717x3yf00"))))
617 (build-system gnu-build-system)
619 `(("cyrus-sasl" ,cyrus-sasl)
624 ("openssl" ,openssl) ; for S/MIME
626 ("kyotocabinet" ,kyotocabinet)
631 ("notmuch" ,notmuch)))
633 `(("automake" ,automake)
634 ("gettext-minimal" ,gettext-minimal)
635 ("pkg-config" ,pkg-config)
636 ("docbook-xsl" ,docbook-xsl)
637 ("docbook-xml" ,docbook-xml-4.2)
641 ;; Test file data for the unit tests included in the neomutt source.
642 ("neomutt-test-files"
643 ,(let ((commit "8629adab700a75c54e8e28bf05ad092503a98f75"))
647 (url "https://github.com/neomutt/neomutt-test-files")
649 (file-name (git-file-name "neomutt-test-files" commit))
651 (base32 "1ci04nqkab9mh60zzm66sd6mhsr6lya8wp92njpbvafc86vvwdlr")))))))
653 `(#:test-target "test"
657 ;; Database, implies header caching.
658 "--disable-tokyocabinet"
669 (string-append "--with-sasl="
670 (assoc-ref %build-inputs "cyrus-sasl"))
678 ;; If we do not set this, neomutt wants to check
679 ;; whether the path exists, which it does not
681 "--with-mailpath=/var/mail"
684 (string-append "--with-ncurses="
685 (assoc-ref %build-inputs "ncurses"))
686 (string-append "--prefix="
687 (assoc-ref %outputs "out"))
690 (modify-phases %standard-phases
691 ;; TODO: autosetup is meant to be included in the source,
692 ;; but we should package autosetup and use our own version of it.
694 (lambda* (#:key outputs inputs configure-flags #:allow-other-keys)
695 (let* ((out (assoc-ref outputs "out"))
696 (flags `(,@configure-flags))
697 (bash (which "bash")))
698 (setenv "SHELL" bash)
699 (setenv "CONFIG_SHELL" bash)
701 (string-append (getcwd) "/configure")
703 (add-before 'check 'prepare-test-files
704 (lambda* (#:key inputs #:allow-other-keys)
705 (copy-recursively (assoc-ref inputs "neomutt-test-files") "tests")
706 (with-directory-excursion "tests"
707 (setenv "NEOMUTT_TEST_DIR" (getcwd)) ; must be absolute
708 (invoke "bash" "setup.sh")
710 (home-page "https://neomutt.org/")
711 (synopsis "Command-line mail reader based on Mutt")
713 "NeoMutt is a command-line mail reader which is based on mutt.
714 It adds a large amount of new and improved features to mutt.")
715 (license license:gpl2+)))
723 (uri (string-append "mirror://gnome/sources/gmime/"
724 (version-major+minor version)
725 "/gmime-" version ".tar.xz"))
728 "0i3xfc84qn1z99i70q68kbnp9rmgqrnprqb418ba52s6g9j9dsia"))))
729 (build-system gnu-build-system)
731 `(("pkg-config" ,pkg-config)
732 ("gnupg" ,gnupg) ; for tests only
733 ("gobject-introspection" ,gobject-introspection)))
734 (inputs `(("glib" ,glib)
739 (list "--enable-introspection=yes")
741 (modify-phases %standard-phases
743 'unpack 'patch-paths-in-tests
745 ;; The test programs run several programs using 'system' with
746 ;; hard-coded paths. Here we patch them all.
747 ;; We use ISO-8859-1 here because test-iconv.c contains
748 ;; raw byte sequences in several different encodings.
749 (with-fluids ((%default-port-encoding #f))
750 (substitute* (find-files "tests" "\\.c$")
751 (("(system *\\(\")(/[^ ]*)" all pre prog-path)
752 (let* ((base (basename prog-path))
755 (or prog (error "not found: " base)))))))
757 (home-page "http://spruce.sourceforge.net/gmime/")
758 (synopsis "MIME message parser and creator library")
760 "GMime provides a core library and set of utilities which may be used for
761 the creation and parsing of messages using the Multipurpose Internet Mail
763 (license (list license:lgpl2.1+ license:gpl2+ license:gpl3+))))
765 ;; Some packages are not ready for GMime 3 yet.
766 (define-public gmime-2.6
772 (uri (string-append "mirror://gnome/sources/gmime/"
773 (version-major+minor version)
774 "/gmime-" version ".tar.xz"))
777 "0slzlzcr3h8jikpz5a5amqd0csqh2m40gdk910ws2hnaf5m6hjbi"))))))
779 (define-public altermime
785 (uri (string-append "http://pldaniels.com/altermime/altermime-"
789 "15zxg6spcmd35r6xbidq2fgcg2nzyv1sbbqds08lzll70mqx4pj7"))))
790 (build-system gnu-build-system)
792 `(#:make-flags (list "CC=gcc"
793 (string-append "PREFIX=" (assoc-ref %outputs "out")))
794 #:tests? #f ; there are none
796 (modify-phases %standard-phases
798 (add-after 'unpack 'fix-bugs
800 (substitute* "MIME_headers.c"
801 (("hinfo->filename, sizeof\\(hinfo->name\\)")
802 "hinfo->filename, sizeof(hinfo->filename)")
803 (("memset\\(hinfo->defects, 0, _MIMEH_DEFECT_ARRAY_SIZE\\);")
804 "memset(hinfo->defects, 0, sizeof(hinfo->defects));"))
805 (substitute* "pldstr.c"
806 (("if \\(\\(st->start\\)&&\\(st->start != '\\\\0'\\)\\)")
807 "if ((st->start)&&(*st->start != '\\0'))"))
809 (("if \\(lineend != '\\\\0'\\)")
810 "if (*lineend != '\\0')"))
812 (add-after 'unpack 'install-to-prefix
814 (substitute* "Makefile"
815 (("/usr/local") "${PREFIX}")
816 (("cp altermime.*") "install -D -t ${PREFIX}/bin altermime\n"))
818 (add-after 'unpack 'disable-Werror
820 (substitute* "Makefile"
823 (home-page "https://pldaniels.com/altermime/")
824 (synopsis "Modify MIME-encoded messages")
826 "alterMIME is a small program which is used to alter your mime-encoded
827 mailpack. What can alterMIME do?
830 @item Insert disclaimers,
831 @item insert arbitrary X-headers,
832 @item modify existing headers,
833 @item remove attachments based on filename or content-type,
834 @item replace attachments based on filename.
837 ;; MIME_headers.c is distributed under BSD-3; the rest of the code is
838 ;; published under the alterMIME license.
839 (license (list (license:non-copyleft "file://LICENSE")
842 (define-public astroid
850 (url "https://github.com/astroidmail/astroid")
851 (commit (string-append "v" version))))
852 (file-name (git-file-name name version))
854 (base32 "11cxbva9ni98gii59xmbxh4c6idcg3mg0pgdsp1c3j0yg7ix0lj3"))
855 (modules '((guix build utils)))
858 ;; https://github.com/astroidmail/astroid/pull/685
859 (substitute* "tests/test_composed_message.cc"
860 (("\\\\n\\.\\.\\.") "\\n...\\n"))
862 (build-system cmake-build-system)
864 `(#:modules ((guix build cmake-build-system)
865 ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
868 #:imported-modules ((guix build glib-or-gtk-build-system)
869 ,@%cmake-build-system-modules)
870 #:configure-flags (list "-GNinja")
872 (modify-phases %standard-phases
873 (add-after 'unpack 'skip-markdown-test
874 ;; This test relies on the plugins and the test suite
875 ;; cannot find the Astroid module.
876 ;; gi.require_version ('Astroid', '0.2')
877 ;; ValueError: Namespace Astroid not available
879 (substitute* "tests/CMakeLists.txt"
880 ((".*markdown.*") ""))
884 (invoke "ninja" "-j" (number->string (parallel-job-count)))))
885 (add-before 'check 'start-xserver
886 (lambda* (#:key inputs #:allow-other-keys)
887 (let ((xorg-server (assoc-ref inputs "xorg-server")))
888 (setenv "HOME" (getcwd))
889 (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
890 (setenv "DISPLAY" ":1")
893 (lambda* (#:key tests? #:allow-other-keys)
895 (setenv "CTEST_OUTPUT_ON_FAILURE" "1")
896 (invoke "ctest" "."))
900 (invoke "ninja" "install")))
901 (add-after 'install 'wrap-with-GI_TYPELIB_PATH
902 (lambda* (#:key inputs outputs #:allow-other-keys)
903 (let ((out (assoc-ref outputs "out"))
904 (paths (map (match-lambda
905 ((outputs . directory)
906 (let ((girepodir (string-append
908 "/lib/girepository-1.0")))
909 (if (file-exists? girepodir)
913 (wrap-program (string-append out "/bin/astroid")
914 `("GI_TYPELIB_PATH" ":" prefix ,(filter identity paths))))
916 (add-after 'install 'glib-or-gtk-compile-schemas
917 (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-compile-schemas))
918 (add-after 'install 'glib-or-gtk-wrap
919 (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap)))))
921 `(("glib-networking" ,glib-networking)
922 ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
925 ("pkg-config" ,pkg-config)
928 ("xorg-server" ,xorg-server)))
932 ("gobject-introspection" ,gobject-introspection) ; it is referenced
937 ("protobuf" ,protobuf)
938 ("python" ,python-wrapper)
939 ("python-pygobject" ,python-pygobject)
940 ("webkitgtk" ,webkitgtk)))
942 `(("adwaita-icon-theme" ,adwaita-icon-theme))) ; Required for the thread view
943 (home-page "https://astroidmail.github.io/")
944 (synopsis "GTK frontend to the notmuch mail system")
946 "Astroid is a lightweight and fast Mail User Agent that provides a
947 graphical interface to searching, display and composing email, organized in
948 thread and tags. Astroid uses the notmuch backend for searches through tons of
949 email. Astroid searches, displays and compose emails — and relies on other
950 programs for fetching, syncing and sending email.")
951 (license (list license:gpl3+ ; 'this program'
952 license:lgpl2.1+)))) ; code from geary, gmime
954 (define-public ripmime
955 ;; Upstream does not tag or otherwise provide any releases (only a version
956 ;; number in the source)
957 (let ((commit "a556ffe08d620602475c976732e8e1a82f3169e9")
961 (version (git-version "1.4.0.10" revision commit))
965 (url "https://github.com/inflex/ripMIME")
967 (file-name (git-file-name name version))
970 "1z8ar8flvkd9q3ax4x28sj5pyq8ykk5pq249y967lj2406lxparh"))))
971 (build-system gnu-build-system)
974 (modify-phases %standard-phases
975 ;; Source has no configure script
977 ;; Buildcodes make the build non-reproducible; remove them
978 (add-after 'unpack 'strip-buildcodes
980 (substitute* "generate-buildcodes.sh"
981 (("`date \\+%s`") "0")
983 (("`uname -a`") "Guix"))
985 ;; https://github.com/inflex/ripMIME/pull/16 makes 'mkdir-p-bin-man unnecessary
986 (add-before 'install 'mkdir-p-bin-man
988 (mkdir-p (string-append (assoc-ref %outputs "out") "/bin"))
989 (mkdir-p (string-append (assoc-ref %outputs "out") "/man"))
991 ;; Makefile has no tests
993 #:make-flags (list (string-append "LOCATION=" (assoc-ref %outputs "out"))
995 (synopsis "Extract attachments from MIME-encoded email")
997 "ripMIME is a small program to extract the attached files out of a
998 MIME-encoded email package.")
999 (home-page "https://github.com/inflex/ripMIME")
1000 (license license:bsd-3))))
1002 (define-public mailcap
1003 (let* ((version "2.1.53")
1004 (tag ;; mailcap tags their releases like this: rMajor-minor-patch
1005 (string-append "r" (string-join (string-split version #\.) "-"))))
1013 (url "https://pagure.io/mailcap.git")
1015 (file-name (git-file-name name version))
1017 (base32 "14939pq7h25rh9100z72vzzx810yqg98im9gz2fbhh47iaj1wrbb"))))
1018 (build-system gnu-build-system)
1021 (modify-phases %standard-phases
1023 (add-before 'install 'set-dest-dir
1024 (lambda* (#:key outputs #:allow-other-keys)
1025 (let ((out (assoc-ref outputs "out")))
1026 (setenv "DESTDIR" out)
1027 (substitute* "Makefile"
1028 (("/usr") "")) ; This allows the man page to install.
1031 `(("python" ,python))) ; for tests
1032 (synopsis "MIME type associations for file types")
1034 "This package provides MIME type associations for file types.")
1035 (home-page "https://pagure.io/mailcap")
1036 (license (list license:expat ; mailcap.5
1037 license:public-domain))))) ; mailcap and mime.types
1039 (define-public bogofilter
1046 (uri (string-append "mirror://sourceforge/bogofilter/bogofilter-stable/"
1047 "bogofilter-" version ".tar.xz"))
1049 (base32 "1sl9xrnnlk2sn8gmibhn8li09vnansjbxb9l1182qmgz7cvs2j1j"))))
1050 (build-system gnu-build-system)
1053 (modify-phases %standard-phases
1054 (add-before 'check 'pre-check
1056 (substitute* "src/tests/t.frame"
1058 (string-append "GREP=" (which "grep") "\n")))
1060 (native-inputs `(("flex" ,flex)))
1061 (inputs `(("bdb" ,bdb)))
1062 (home-page "https://bogofilter.sourceforge.io/")
1063 (synopsis "Mail classifier based on a Bayesian filter")
1065 "Bogofilter is a mail filter that classifies mail as spam or ham
1066 (non-spam) by a statistical analysis of the message's header and
1067 content (body). The program is able to learn from the user's classifications
1068 and corrections. It is based on a Bayesian filter.")
1069 (license license:gpl3+)))
1071 (define-public offlineimap3
1072 ;; The OfflineIMAP3 fork does not yet have a release, but it's likely to be
1073 ;; 8.0.0 but the source still reports 7.3.0, see
1074 ;; https://github.com/OfflineIMAP/offlineimap3/issues/10.
1075 (let ((commit "4ca9c75c6f9a0cc8dc7b69dd6abf073e494cc0e5")
1078 (name "offlineimap3")
1079 (version (git-version "7.3.0" revision commit))
1083 (url "https://github.com/OfflineIMAP/offlineimap3")
1085 (file-name (git-file-name name version))
1088 "0nzh5dcc559jfw4yy12gc98s17w82b15zxikspc6apd8filmk9xg"))))
1089 (build-system python-build-system)
1091 `(("asciidoc" ,asciidoc)))
1093 `(("python-distro" ,python-distro)
1094 ("python-imaplib2" ,python-imaplib2)
1095 ("python-rfc6555" ,python-rfc6555)))
1097 `(;; Tests require a modifiable IMAP account.
1100 (modify-phases %standard-phases
1101 (add-after 'build 'build-documentation
1103 (substitute* "docs/Makefile"
1104 ;; Prevent xmllint and xsltproc from downloading a DTD file.
1105 (("a2x -v") "a2x --no-xmllint --xsltproc-opts=--nonet -v"))
1106 (invoke "make" "-C" "docs" "man")))
1107 (add-after 'install 'install-documentation
1108 (lambda* (#:key outputs #:allow-other-keys)
1109 (let* ((out (assoc-ref outputs "out"))
1110 (man (string-append out "/share/man")))
1111 (install-file "docs/offlineimap.1" (string-append man "/man1"))
1112 (install-file "docs/offlineimapui.7" (string-append man "/man7"))))))))
1113 (home-page "https://www.offlineimap.org")
1114 (synopsis "Sync emails between two repositories")
1116 "OfflineImap synchronizes emails between two repositories, so that you
1117 can read the same mailbox from multiple computers. It supports IMAP as REMOTE
1118 repository and Maildir/IMAP as LOCAL repository.")
1119 (license license:gpl2+))))
1121 (define-public offlineimap
1122 (deprecated-package "offlineimap" offlineimap3))
1124 (define-public emacs-mew
1130 (uri (string-append "https://mew.org/Release/mew-"
1134 "0ixzyq33l6j34410kqav3lwn2wx171zvqd3irvns2jvhrbww8i6g"))))
1136 `(("emacs" ,emacs)))
1138 `(("ruby-sqlite3" ,ruby-sqlite3) ; optional for the database of messages
1139 ("ruby" ,ruby))) ; to set GEM_PATH so ruby-sqlite3 is found at runtime
1140 (build-system gnu-build-system)
1142 (let ((elisp-dir "/share/emacs/site-lisp")
1143 (icon-dir "/share/mew"))
1144 `(#:modules ((guix build gnu-build-system)
1146 (guix build emacs-utils))
1147 #:imported-modules (,@%gnu-build-system-modules
1148 (guix build emacs-utils))
1150 (list (string-append "--with-elispdir=" %output ,elisp-dir)
1151 (string-append "--with-etcdir=" %output ,icon-dir))
1153 (modify-phases %standard-phases
1154 (add-after 'configure 'patch-mew-icon-directory
1155 (lambda* (#:key outputs #:allow-other-keys)
1156 (emacs-substitute-sexps "mew-key.el"
1157 ("(def.* mew-icon-directory"
1159 (add-to-list 'image-load-path 'mew-icon-directory)
1160 ,(string-append (assoc-ref outputs "out") ,icon-dir))))
1162 (add-after 'install 'generate-autoloads
1163 (lambda* (#:key outputs #:allow-other-keys)
1164 (emacs-generate-autoloads
1165 "mew" (string-append (assoc-ref outputs "out") ,elisp-dir))
1168 (home-page "https://mew.org")
1169 (synopsis "Emacs e-mail client")
1170 (description "Mew (Messaging in the Emacs World) is a user interface
1171 for text messages, multimedia messages (MIME), news articles and
1172 security functionality including PGP, S/MIME, SSH, and SSL.")
1173 (license license:bsd-3)))
1181 (uri (string-append "https://github.com/djcb/mu/releases/"
1182 "download/" version "/"
1183 "mu-" version ".tar.xz"))
1186 "0irqr1z1ljmij2vbj8dr8w9mbfalzikxr4s6340jjwmkmhaslh2h"))))
1187 (build-system gnu-build-system)
1189 `(("pkg-config" ,pkg-config)
1190 ("glib" ,glib "bin") ; for gtester
1191 ("emacs" ,emacs-minimal)
1192 ("tzdata" ,tzdata-for-tests))) ; for mu/test/test-mu-query.c
1194 `(("xapian" ,xapian)
1195 ("guile" ,guile-3.0)
1199 `(#:modules ((guix build gnu-build-system)
1201 (guix build emacs-utils))
1202 #:imported-modules (,@%gnu-build-system-modules
1203 (guix build emacs-utils))
1205 (modify-phases %standard-phases
1206 (add-after 'unpack 'patch-configure
1207 ;; By default, elisp code goes to "share/emacs/site-lisp/mu4e",
1208 ;; so our Emacs package can't find it. Setting "--with-lispdir"
1209 ;; configure flag doesn't help because "mu4e" will be added to
1210 ;; the lispdir anyway, so we have to modify "configure.ac".
1212 (substitute* "configure"
1213 (("^ +lispdir=\"\\$\\{lispdir\\}/mu4e/\".*") ""))))
1214 (add-after 'unpack 'patch-bin-sh-in-tests
1216 (substitute* '("guile/tests/test-mu-guile.cc"
1218 "mu/test-mu-cmd-cfind.cc"
1219 "mu/test-mu-query.cc")
1220 (("/bin/sh") (which "sh")))))
1221 (add-before 'install 'fix-ffi
1222 (lambda* (#:key outputs #:allow-other-keys)
1223 (substitute* "guile/mu.scm"
1224 (("\"libguile-mu\"")
1225 (format #f "\"~a/lib/libguile-mu\""
1226 (assoc-ref outputs "out"))))))
1227 (add-before 'check 'check-tz-setup
1228 (lambda* (#:key inputs #:allow-other-keys)
1229 ;; For mu/test/test-mu-query.c
1231 (search-input-directory inputs "share/zoneinfo"))))
1232 (add-after 'install 'install-emacs-autoloads
1233 (lambda* (#:key outputs #:allow-other-keys)
1234 (emacs-generate-autoloads
1236 (string-append (assoc-ref outputs "out")
1237 "/share/emacs/site-lisp")))))))
1238 (home-page "https://www.djcbsoftware.nl/code/mu/")
1239 (synopsis "Quickly find emails")
1241 "Mu is a tool for dealing with e-mail messages stored in the
1242 Maildir-format. Mu's purpose in life is to help you to quickly find the
1243 messages you need; in addition, it allows you to view messages, extract
1244 attachments, create new maildirs, and so on.")
1245 (license license:gpl3+)))
1253 ;; package author intends on distributing via github rather
1255 ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331
1257 (url "https://github.com/pazz/alot")
1259 (file-name (git-file-name name version))
1262 "0s94m17yph1gq9f2svipb3bbwbw1s4j3zf2xkg5h91006v8286r6"))))
1263 (build-system python-build-system)
1266 (modify-phases %standard-phases
1267 (add-before 'check 'fix-tests
1268 (lambda* (#:key inputs #:allow-other-keys)
1269 (let ((gnupg (assoc-ref inputs "gnupg")))
1270 (substitute* "tests/test_crypto.py"
1271 (("gpg2") (string-append gnupg "/bin/gpg")))
1273 (add-before 'check 'disable-failing-tests
1274 ;; FIXME: Investigate why these tests are failing.
1276 (substitute* "tests/test_helper.py"
1277 (("def test_env_set") "def _test_env_set"))
1278 (substitute* "tests/commands/test_global.py"
1279 (("def test_no_spawn_no_stdin_attached")
1280 "def _test_no_spawn_no_stdin_attached"))
1283 `(("procps" ,procps)
1284 ("python-mock" ,python-mock)))
1287 ("python-magic" ,python-magic)
1288 ("python-configobj" ,python-configobj)
1289 ("python-twisted" ,python-twisted)
1290 ("python-service-identity" ,python-service-identity)
1291 ("python-urwid" ,python-urwid)
1292 ("python-urwidtrees" ,python-urwidtrees)
1293 ("python-gpg" ,python-gpg)
1294 ("python-notmuch" ,python-notmuch)))
1295 (home-page "https://github.com/pazz/alot")
1296 (synopsis "Command-line MUA using Notmuch")
1298 "Alot is a terminal-based mail user agent based on the Notmuch mail
1299 indexer. It is written in Python using the @code{urwid} toolkit and features
1300 a modular and command prompt driven interface to provide a full mail user
1301 agent (@dfn{MUA}) experience as an alternative to the Emacs mode shipped with
1303 (license license:gpl3+)))
1305 (define-public notifymuch
1307 ((commit "9d4aaf54599282ce80643b38195ff501120807f0")
1311 (version (string-append "0.1-" revision "." (string-take commit 7)))
1316 (url "https://github.com/kspi/notifymuch")
1320 "1lssr7iv43mp5v6nzrfbqlfzx8jcc7m636wlfyhhnd8ydd39n6k4"))
1321 (file-name (string-append name "-" version "-checkout"))))
1322 (build-system python-build-system)
1324 `(("python-notmuch" ,python-notmuch)
1325 ("python-pygobject" ,python-pygobject)
1326 ("gobject-introspection" ,gobject-introspection)
1327 ("libnotify" ,libnotify)
1331 (modify-phases %standard-phases
1332 (add-after 'install 'wrap-binary
1333 (lambda* (#:key outputs #:allow-other-keys)
1334 (let* ((out (assoc-ref outputs "out"))
1335 (bin (string-append out "/bin/notifymuch")))
1337 `("GUIX_PYTHONPATH" ":" prefix (,(getenv "GUIX_PYTHONPATH")))
1338 `("GI_TYPELIB_PATH" ":" prefix
1339 (,(getenv "GI_TYPELIB_PATH")
1340 ,(string-append out "/lib/girepository-1.0")))))
1342 (home-page "https://github.com/kspi/notifymuch")
1343 (synopsis "Displays notifications for changes in the notmuch email database")
1344 (description "notifymuch displays desktop notifications for messages in
1345 the notmuch database. The notifications are sent using libnotify to a
1346 notification daemon. The query to find messages to send a notification about
1347 is configurable, and a notification for the same message will not be send
1348 within a configurable period (defaults to 48 hours). To use notifymuch, run
1349 @command{notifymuch} after new mail is indexed, this can be automated by
1350 invoking @command{notifymuch} from the post-new hook.")
1351 (license license:gpl3))))
1353 (define-public notmuch
1359 (uri (string-append "https://notmuchmail.org/releases/notmuch-"
1363 "1myylb19hj5nb1vriqng252vfjwwkgbi3gxj93pi2q1fzyw7w2lf"))))
1364 (build-system gnu-build-system)
1367 (list "V=1" ; verbose test output
1368 "NOTMUCH_TEST_TIMEOUT=1h") ; don't fail on slow machines
1369 #:phases (modify-phases %standard-phases
1371 (lambda* (#:key outputs #:allow-other-keys)
1372 (setenv "CC" ,(cc-for-target))
1373 (setenv "CONFIG_SHELL" (which "sh"))
1374 (let* ((out (assoc-ref outputs "out")))
1375 (invoke "./configure"
1376 (string-append "--prefix=" out)
1377 "--without-emacs"))))
1378 (add-before 'check 'disable-failing-tests
1379 ;; FIXME: Investigate why these tests are failing,
1380 ;; and try removing this for notmuch versions > 0.31.
1382 (substitute* "test/T356-protected-headers.sh"
1383 (("\\$NOTMUCH_GMIME_X509_CERT_VALIDITY") "0"))))
1384 (add-before 'check 'prepare-test-environment
1386 (setenv "TEST_CC" ,(cc-for-target))
1387 ;; Patch various inline shell invocations.
1388 (substitute* (find-files "test" "\\.sh$")
1389 (("/bin/sh") (which "sh"))))))))
1391 `(("bash-completion" ,bash-completion)
1392 ("pkg-config" ,pkg-config)
1394 ("python-docutils" ,python-docutils)
1395 ("sphinx" ,python-sphinx)
1396 ("texinfo" ,texinfo)
1398 ;; The following are required for tests only.
1399 ("emacs" ,emacs-no-x) ; -minimal lacks libxml, needed for some tests
1411 (home-page "https://notmuchmail.org/")
1412 (synopsis "Thread-based email index, search, and tagging")
1414 "Notmuch is a command-line based program for indexing, searching, read-
1415 ing, and tagging large collections of email messages.")
1416 (license license:gpl3+)))
1418 (define-public emacs-notmuch
1421 (name "emacs-notmuch")
1422 (build-system emacs-build-system)
1425 `(("notmuch" ,notmuch)))
1427 `(#:exclude (cons* "make-deps.el" "rstdoc.el" %default-exclude)
1429 (modify-phases %standard-phases
1430 (add-after 'unpack 'chdir
1433 (add-after 'chdir 'patch-paths
1434 (lambda* (#:key inputs #:allow-other-keys)
1435 (let ((notmuch (assoc-ref inputs "notmuch")))
1436 (substitute* "notmuch-lib.el"
1438 (string-append "\"" notmuch "/bin/notmuch\"")))))))))
1439 (synopsis "Run Notmuch within Emacs")
1441 "This package provides an Emacs-based interface to the Notmuch mail
1444 (define-public notmuch-addrlookup-c
1446 (name "notmuch-addrlookup-c")
1447 (version (string-append "9"))
1451 (url "https://github.com/aperezdc/notmuch-addrlookup-c")
1452 (commit (string-append "v" version))))
1453 (file-name (string-append name "-" version "-checkout"))
1456 "1j3zdx161i1x4w0nic14ix5i8hd501rb31daf8api0k8855sx4rc"))))
1457 (build-system gnu-build-system)
1459 '(#:tests? #f ; no tests
1460 #:make-flags (list "CC=gcc")
1461 #:phases (modify-phases %standard-phases
1463 ;; Remove vim code completion config, it's not needed to
1464 ;; build (or be patched).
1465 (add-before 'patch-source-shebangs 'delete-ycm-file
1466 (lambda _ (delete-file ".ycm_extra_conf.py")))
1468 (lambda* (#:key outputs #:allow-other-keys)
1469 (let ((bin (string-append
1470 (assoc-ref outputs "out") "/bin")))
1471 (install-file "notmuch-addrlookup" bin)))))))
1473 `(("pkg-config" ,pkg-config)))
1476 ("notmuch" ,notmuch)))
1477 (home-page "https://github.com/aperezdc/notmuch-addrlookup-c")
1478 (synopsis "Address lookup tool for Notmuch")
1479 (description "This is an address lookup tool using a Notmuch database,
1480 useful for email address completion.")
1481 (license license:expat)))
1483 (define-public python-notmuch
1485 (name "python-notmuch")
1486 (version (package-version notmuch))
1487 ;; Notmuch python bindings are now unavailable on pypi. The
1488 ;; bindings are distributed via the notmuch release tarball.
1489 (source (package-source notmuch))
1490 (build-system python-build-system)
1491 (inputs `(("notmuch" ,notmuch)))
1493 `(#:tests? #f ; no "test" target
1495 (modify-phases %standard-phases
1496 ;; This python package lives in a subdirectory of the notmuch source
1497 ;; tree, so chdir into it before building.
1498 (add-after 'unpack 'enter-python-dir
1499 (lambda _ (chdir "bindings/python") #t))
1500 ;; Make sure the correct notmuch shared library gets loaded.
1501 (add-before 'build 'set-libnotmuch-file-name
1502 (lambda* (#:key inputs #:allow-other-keys)
1503 (let ((notmuch (assoc-ref inputs "notmuch")))
1504 (substitute* "notmuch/globals.py"
1505 (("libnotmuch\\.so\\.")
1506 (string-append notmuch "/lib/libnotmuch.so.")))
1508 (home-page (package-home-page notmuch))
1509 (synopsis "Python bindings of the Notmuch mail indexing library")
1511 "This package provides Python bindings to use the Notmuch mail indexing
1512 and search library.")
1513 (license license:gpl3+)))
1515 (define-public python2-notmuch
1516 (package-with-python2 python-notmuch))
1518 (define-public muchsync
1525 (uri (string-append "http://www.muchsync.org/src/"
1526 "muchsync-" version ".tar.gz"))
1528 (base32 "1s799kx16nm5ry1fcqcc0grgxrwnnp4cnzd0hzwbkvc5v2sf6g8b"))))
1529 (build-system gnu-build-system)
1531 `(("pandoc" ,pandoc)
1532 ("pkg-config" ,pkg-config)))
1534 `(("libcrypto" ,openssl)
1535 ("notmuch" ,notmuch)
1537 ("xapian" ,xapian)))
1538 (home-page "http://www.muchsync.org/")
1539 (synopsis "Synchronize notmuch mail across machines")
1541 "Muchsync brings Notmuch to all of your computers by synchronizing your
1542 mail messages and Notmuch tags across machines. The protocol is heavily
1543 pipelined to work efficiently over high-latency networks such as mobile
1544 broadband. Muchsync supports arbitrary pairwise synchronization among
1545 replicas. A version-vector-based algorithm allows it to exchange only the
1546 minimum information necessary to bring replicas up to date regardless of which
1547 pairs have previously synchronized.")
1548 (license license:gpl2+))) ; with OpenSSL libcrypto exception
1550 (define-public getmail
1557 (uri (string-append "http://pyropus.ca/software/getmail/old-versions/"
1558 "getmail-" version ".tar.gz"))
1560 (base32 "0ahn2jyj4ka996qzs99id59pwxv6sqxp61g7drcf53rzzigq0lyl"))))
1561 (build-system python-build-system)
1563 `(#:tests? #f ; no tests
1564 #:python ,python-2))
1565 (home-page "http://pyropus.ca/software/getmail/")
1566 (synopsis "Mail retriever")
1568 "A flexible, extensible mail retrieval system with support for
1569 POP3, IMAP4, SSL variants of both, maildirs, mboxrd files, external MDAs,
1570 arbitrary message filtering, single-user and domain-mailboxes, and many other
1573 ;; License is specified in file '__init__.py'.
1574 (license license:gpl2)))
1576 (define-public libetpan
1583 (url "https://github.com/dinhviethoa/libetpan")
1585 (file-name (git-file-name name version))
1587 (base32 "0g7an003simfdn7ihg9yjv7hl2czsmjsndjrp39i7cad8icixscn"))))
1588 (build-system gnu-build-system)
1589 (native-inputs `(("autoconf" ,autoconf)
1590 ("automake" ,automake)
1591 ("libtool" ,libtool)
1592 ("pkg-config" ,pkg-config)))
1594 ;; 'libetpan-config --libs' returns '-lssl -lcrypto -lsasl2', so these
1595 ;; libraries need to be propagated.
1596 `(("cyrus-sasl" ,cyrus-sasl)
1597 ("openssl" ,openssl)))
1604 '("--disable-static" "--disable-db")))
1605 (home-page "https://www.etpan.org/libetpan.html")
1606 (synopsis "Portable middleware for email access")
1608 "The purpose of this mail library is to provide a portable, efficient
1609 framework for different kinds of mail access: IMAP, SMTP, POP and NNTP. It
1610 provides an API for C language. It's the low-level API used by MailCore and
1612 (license license:bsd-3)))
1614 (define-public compface
1620 (uri (string-append "https://ftp.heanet.ie/mirrors/"
1621 "ftp.xemacs.org/aux/"
1622 "compface-" version ".tar.gz"))
1625 "09b89wg63hg502hsz592cd2h87wdprb1dq1k1y07n89hym2q56d6"))))
1626 (build-system gnu-build-system)
1629 (synopsis "Portrait image compressor")
1630 (description "This package takes your 48x48x1 portrait image and
1632 (home-page "https://legacy.cs.indiana.edu/ftp/faces/")
1633 (license (license:x11-style "file://README"))))
1635 (define-public claws-mail
1643 (string-append "https://www.claws-mail.org/releases/claws-mail-"
1646 (base32 "0xg41rxxq2q5vhjzbh8p12s248kcljk6g7y0m6raq7nrllkbvwja"))))
1647 (build-system glib-or-gtk-build-system)
1652 "--enable-demo-plugin")
1654 ;; Disable updating icon cache since it's done by the profile hook.
1655 ;; Conflict with other packages in the profile would be inevitable
1658 "gtk_update_icon_cache=true")
1660 (modify-phases %standard-phases
1661 (add-after 'unpack 'patch-source
1662 (lambda* (#:key inputs #:allow-other-keys)
1663 ;; Use absolute paths to referenced programs.
1664 (let* ((mailutils (assoc-ref inputs "mailutils"))
1665 (inc (string-append mailutils "/bin/mu-mh/inc"))
1666 (send-mail (assoc-ref inputs "sendmail"))
1667 (sendmail (string-append send-mail "/sbin/sendmail")))
1668 (substitute* "src/common/defs.h"
1669 (("/usr/bin/mh/inc") inc)
1670 (("/usr/sbin/sendmail") sendmail)))))
1671 (add-before 'build 'patch-mime
1672 (lambda* (#:key inputs #:allow-other-keys)
1673 (substitute* "src/procmime.c"
1674 (("/usr/share/mime/globs")
1675 (search-input-directory inputs
1676 "/share/mime/globs"))))))))
1679 ;;("docbook-utils" ,docbook-utils)
1681 ("gettext-minimal" ,gettext-minimal)
1682 ("gobject-introspection" ,gobject-introspection)
1683 ("intltool" ,intltool)
1684 ("pkg-config" ,pkg-config)))
1686 `(("bogofilter" ,bogofilter)
1688 ("compface" ,compface)
1691 ("dbus-glib" ,dbus-glib)
1692 ("enchant" ,enchant)
1694 ("fontconfig" ,fontconfig)
1695 ("gdk-pixbuf+svg" ,gdk-pixbuf+svg)
1696 ("ghostscript" ,ghostscript)
1701 ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
1703 ("gumbo-parser" ,gumbo-parser)
1704 ;;("j-pilot" ,j-pilot)
1705 ("libarchive" ,libarchive)
1706 ("libcanberra" ,libcanberra)
1707 ("libetpan" ,libetpan)
1708 ("libgdata" ,libgdata)
1709 ("libical" ,libical)
1710 ("libindicator" ,libindicator)
1711 ("libnotify" ,libnotify)
1712 ("librsvg" ,librsvg)
1714 ("libsoup" ,libsoup)
1715 ("libxml2" ,libxml2)
1716 ("mailutils" ,mailutils)
1718 ("network-manager" ,network-manager)
1719 ("openldap" ,openldap)
1721 ("poppler" ,poppler)
1723 ("python-pygobject" ,python-pygobject)
1724 ("sendmail" ,sendmail)
1725 ("shared-mime-info" ,shared-mime-info)
1726 ("startup-notification" ,startup-notification)
1727 ;;("webkitgtk" ,webkitgtk)
1730 `(("dconf" ,dconf)))
1731 (synopsis "GTK-based Email client")
1732 (description "Claws-Mail is an email client (and news reader) based on GTK+.
1733 The appearance and interface are designed to be familiar to new users coming
1734 from other popular email clients, as well as experienced users. Almost all
1735 commands are accessible with the keyboard. Plus, Claws-Mail is extensible via
1736 addons which can add many functionalities to the base client.")
1737 (home-page "https://www.claws-mail.org/")
1738 (license license:gpl3+))) ; most files are actually public domain or x11
1740 (define-public msmtp
1747 (uri (string-append "https://marlam.de/msmtp/releases/"
1748 "/msmtp-" version ".tar.xz"))
1750 (base32 "1klrj2a77671xb6xa0a0iyszhjb7swxhmzpzd4qdybmzkrixqr92"))))
1751 (build-system gnu-build-system)
1753 `(("libsecret" ,libsecret)
1758 `(("pkg-config" ,pkg-config)))
1759 (home-page "https://marlam.de/msmtp/")
1761 `(#:configure-flags (list "--with-libgsasl"
1763 "--with-tls=gnutls")
1765 (modify-phases %standard-phases
1766 (add-after 'install 'install-additional-files
1767 (lambda* (#:key outputs #:allow-other-keys)
1768 (let* ((out (assoc-ref outputs "out"))
1769 (bin (string-append out "/bin"))
1770 (doc (string-append out "/share/doc/msmtp"))
1771 (msmtpq "scripts/msmtpq")
1772 (vimfiles (string-append out "/share/vim/vimfiles/plugin")))
1773 (install-file (string-append msmtpq "/msmtpq") bin)
1774 (install-file (string-append msmtpq "/msmtp-queue") bin)
1775 (install-file (string-append msmtpq "/README.msmtpq") doc)
1776 (install-file "scripts/vim/msmtp.vim" vimfiles)
1777 ;; Don't rely on netcat being in the PATH to test for a
1778 ;; connection, instead look up and ping debian.org.
1779 (substitute* (string-append bin "/msmtpq")
1780 (("EMAIL_CONN_TEST=n") "EMAIL_CONN_TEST=p"))
1783 "Simple and easy to use SMTP client with decent sendmail compatibility")
1785 "msmtp is an SMTP client. In the default mode, it transmits a mail to
1786 an SMTP server (for example at a free mail provider) which takes care of further
1788 (license license:gpl3+)))
1797 (uri (let ((file-name (string-append "exim-" version ".tar.xz")))
1798 (list (string-append "https://ftp.exim.org/pub/exim/exim4/"
1800 ;; ‘Fix’ releases (exim-x.y.z.f) are kept separately.
1801 (string-append "https://ftp.exim.org/pub/exim/exim4/fixes/"
1803 ;; After a new non-fix release, the old one is moved here.
1804 (string-append "https://ftp.exim.org/pub/exim/exim4/old/"
1807 (base32 "0x4j698gsawm8a3bz531pf1k6izyxfvry4hj5wb0aqphi7y62605"))))
1808 (build-system gnu-build-system)
1810 `(("bdb" ,bdb-5.3) ; ‘#error Version 6 and later BDB API is not supported’
1811 ("gnutls" ,gnutls/dane)
1818 ("libxaw" ,libxaw)))
1820 `(("pcre" ,pcre "bin")
1822 ("pkg-config" ,pkg-config)))
1825 (modify-phases %standard-phases
1827 ;; We'd use #:make-flags but the top-level Makefile calls others
1828 ;; recursively, so just set all variables this way.
1829 (lambda* (#:key outputs inputs #:allow-other-keys)
1830 (substitute* '("Makefile" "OS/Makefile-Default")
1831 (("(RM_COMMAND=).*" all var)
1832 (string-append var "rm\n")))
1833 (copy-file "src/EDITME" "Local/Makefile")
1834 (copy-file "exim_monitor/EDITME" "Local/eximon.conf")
1835 (let ((out (assoc-ref outputs "out"))
1836 (gzip (assoc-ref inputs "gzip"))
1837 (bzip2 (assoc-ref inputs "bzip2"))
1838 (xz (assoc-ref inputs "xz")))
1839 (substitute* '("Local/Makefile")
1840 (("(BIN_DIRECTORY=).*" all var)
1841 (string-append var out "/bin\n"))
1842 (("(CONFIGURE_FILE=).*" all var)
1843 (string-append var out "/etc/exim.conf\n"))
1844 (("(EXIM_USER=).*" all var)
1845 (string-append var "nobody\n"))
1846 (("(FIXED_NEVER_USERS=).*" all var)
1847 (string-append var "\n")) ; XXX no root in build environment
1848 (("(COMPRESS_COMMAND=).*" all var)
1849 (string-append var gzip "/bin/gzip\n"))
1850 (("(ZCAT_COMMAND=).*" all var)
1851 (string-append var gzip "/bin/zcat\n"))
1852 (("# (USE_GNUTLS(|_PC)=.*)" all line)
1853 (string-append line "\n"))
1854 (("# (AUTH_CRAM_MD5=yes)" all line) line)
1855 (("# (AUTH_DOVECOT=yes)" all line) line)
1856 (("# (AUTH_EXTERNAL=yes)" all line) line)
1857 (("# (AUTH_PLAINTEXT=yes)" all line) line)
1858 (("# (AUTH_SPA=yes)" all line) line)
1859 (("# (AUTH_TLS=yes)" all line) line))
1860 ;; This file has hard-coded relative file names for tools despite
1861 ;; the zcat configuration above.
1862 (substitute* '("src/exigrep.src")
1863 (("'zcat'") (string-append "'" gzip "/bin/zcat'"))
1864 (("'bzcat'") (string-append "'" bzip2 "/bin/bzcat'"))
1865 (("'xzcat'") (string-append "'" xz "/bin/xzcat'"))
1866 (("'lzma'") (string-append "'" xz "/bin/lzma'"))))
1868 (add-before 'build 'fix-sh-paths
1869 (lambda* (#:key inputs #:allow-other-keys)
1870 (substitute* '("scripts/lookups-Makefile" "scripts/reversion")
1871 (("SHELL=/bin/sh") "SHELL=sh"))
1872 (substitute* '("scripts/Configure-config.h")
1873 (("\\| /bin/sh") "| sh"))
1874 (let ((bash (assoc-ref inputs "bash")))
1875 (substitute* '("scripts/Configure-eximon")
1876 (("#!/bin/sh") (string-append "#!" bash "/bin/sh"))))
1878 (add-before 'build 'build-reproducibly
1880 ;; The ‘compilation number’ is incremented for every build from the
1881 ;; same source tree. It appears to vary over different (parallel?)
1882 ;; builds. Make it a ‘constant number’ instead.
1883 (substitute* "src/version.c"
1884 (("#include \"cnumber.h\"") "1")))))
1887 "INSTALL_ARG=-no_chown")
1888 ;; No 'check' target. There is a test suite in test/, which assumes that
1889 ;; certain build options were (not) used and that it can freely ‘sudo’.
1891 (home-page "https://www.exim.org/")
1893 "Message Transfer Agent (MTA) developed at the University of Cambridge")
1895 "Exim is a message transfer agent (MTA) developed at the University of
1896 Cambridge for use on Unix systems connected to the Internet. In style it is
1897 similar to Smail 3, but its facilities are more general. There is a great
1898 deal of flexibility in the way mail can be routed, and there are extensive
1899 facilities for checking incoming mail.")
1900 (license license:gpl2+)))
1902 (define-public dovecot
1905 ;; Also update dovecot-pigeonhole when updating to a new minor version.
1910 (uri (string-append "https://www.dovecot.org/releases/"
1911 (version-major+minor version) "/"
1912 "dovecot-" version ".tar.gz"))
1914 (base32 "04ngqv5mml5z0i4p7fkchp4xw2awy7x7mq2mim9frnav0m9iv9q3"))))
1915 (build-system gnu-build-system)
1917 `(("pkg-config" ,pkg-config)))
1920 ("clucene" ,clucene)
1922 ("libsodium" ,libsodium) ; extra password algorithms
1923 ("libstemmer" ,libstemmer)
1924 ;; FIXME: The 'test-backtrace' tests fail on arm when using glibc's
1925 ;; backtrace_symbol() function so fallback to using libunwind.
1927 `(("libunwind" ,libunwind))
1929 ("linux-pam" ,linux-pam)
1931 ("openssl" ,openssl)
1934 ("zstd" ,zstd "lib")))
1936 `(#:configure-flags '("--sysconfdir=/etc"
1937 "--localstatedir=/var"
1938 "--with-sqlite" ; not auto-detected
1939 "--with-lucene") ; not auto-detected
1941 (modify-phases %standard-phases
1942 (add-after 'unpack 'patch-file-names
1944 (substitute* "src/lib-program-client/test-program-client-local.c"
1945 (("(/bin/| )cat") (which "cat"))
1946 (("/bin/echo") (which "echo"))
1947 (("/bin/false") (which "false"))
1948 (("/bin/sh") (which "bash"))
1949 (("head") (which "head"))
1950 (("sleep") (which "sleep")))
1951 (substitute* (list "src/lib-smtp/test-bin/sendmail-exit-1.sh"
1952 "src/lib-smtp/test-bin/sendmail-success.sh")
1953 (("cat") (which "cat")))
1956 (lambda* (#:key make-flags #:allow-other-keys)
1957 ;; Simple hack to avoid installing a trivial README in /etc.
1958 (apply invoke "make" "install" "sysconfdir=/tmp/bogus"
1960 (home-page "https://www.dovecot.org")
1961 (synopsis "Secure POP3/IMAP server")
1963 "Dovecot is a mail server whose major goals are security and reliability.
1964 It supports mbox/Maildir and its own dbox/mdbox formats.")
1965 ;; Most source files are covered by either lgpl2.1 or expat. The SHA code
1966 ;; is covered by a variant of BSD-3, and UnicodeData.txt is covered by the
1967 ;; Unicode, Inc. License Agreement for Data Files and Software.
1968 (license (list license:lgpl2.1 license:expat
1969 (license:non-copyleft "file://COPYING")))))
1971 (define-public dovecot-pigeonhole
1972 (let ((dovecot-version (version-major+minor (package-version dovecot))))
1974 (name "dovecot-pigeonhole")
1980 "https://pigeonhole.dovecot.org/releases/" dovecot-version "/"
1981 "dovecot-" dovecot-version "-pigeonhole-" version ".tar.gz"))
1983 (base32 "0f79qsiqnhaxn7mrrfcrnsjyv6357kzb7wa0chhfd69vwa06g8sw"))
1984 (modules '((guix build utils)))
1987 ;; RFC licencing is ad-hoc and rarely free. Remove them all.
1988 (delete-file-recursively "doc/rfc")
1989 (substitute* "configure"
1990 (("doc/rfc/Makefile") ""))
1991 (substitute* "doc/Makefile.in"
1994 (build-system gnu-build-system)
1997 (list "--disable-static"
1998 "--with-dovecot-install-dirs=no"
1999 (string-append "--with-dovecot="
2000 (assoc-ref %build-inputs "dovecot")
2002 (string-append "--docdir="
2003 (assoc-ref %outputs "out")
2004 "/share/doc/" ,name "-" ,version)
2005 (string-append "--with-moduledir="
2006 (assoc-ref %outputs "out")
2009 (modify-phases %standard-phases
2010 (add-after 'unpack 'patch-file-names
2011 (lambda* (#:key outputs #:allow-other-keys)
2012 (let* ((out (assoc-ref outputs "out"))
2013 (libexec (string-append out "/libexec/dovecot")))
2014 (substitute* "src/managesieve/managesieve-settings.c"
2015 (("\\.executable = \"managesieve\"")
2016 (string-append ".executable = \"" libexec
2018 (substitute* "src/managesieve-login/managesieve-login-settings.c"
2019 (("\\.executable = \"managesieve-login\"")
2020 (string-append ".executable = \"" libexec
2021 "/managesieve-login\"")))
2024 `(("pkg-config" ,pkg-config)))
2026 `(("dovecot" ,dovecot)))
2027 (home-page "https://pigeonhole.dovecot.org")
2028 (synopsis "Dovecot Sieve mail filtering plug-in and ManageSieve service")
2030 "Pigeonhole adds support for the Sieve language (RFC 5228) and the
2031 ManageSieve protocol (RFC 5804) to the Dovecot e-mail server.
2033 @dfn{Sieve} is a language for filtering incoming mail. Messages can be
2034 forwarded or sorted into separate folders. Unwanted messages can be rejected
2035 or discarded, and, when the user is not available, the Sieve interpreter can
2036 send an automated reply.
2038 Sieve is meant to be simple, extensible, and system-independent. The
2039 intention is to make it impossible to write anything more complex (and
2040 dangerous) than simple mail filters. Unlike most other mail filtering script
2041 languages, Sieve does not allow users to execute arbitrary programmes.
2043 Through the @dfn{ManageSieve} protocol, users can remotely manage their Sieve
2044 scripts without needing file system access. The server accepts only valid
2045 scripts to prevent embarrassing errors later on.")
2046 (license license:lgpl2.1))))
2048 (define-public dovecot-trees
2050 (name "dovecot-trees")
2055 (uri (string-append "https://0xacab.org/riseuplabs/trees/repository/"
2056 "archive.tar.gz?ref=v" version))
2057 (file-name (string-append name "-" version ".tar.gz"))
2060 "0rkk10b1bsjz979sc864vpgcdchy7yxwmyv4ik50lar1h6awdnrf"))
2062 (search-patches "dovecot-trees-support-dovecot-2.3.patch"))))
2063 (build-system gnu-build-system)
2065 `(("automake" ,automake)
2066 ("autoconf" ,autoconf)
2067 ("libtool" ,libtool)
2068 ("dovecot" ,dovecot)
2069 ("pkg-config" ,pkg-config)))
2071 `(("libsodium" ,libsodium)))
2073 `(#:tests? #f ;No tests exist.
2074 #:configure-flags (list (string-append "--with-dovecot="
2075 (assoc-ref %build-inputs "dovecot")
2077 (home-page "https://0xacab.org/riseuplabs/trees")
2078 (synopsis "NaCL-based Dovecot email storage encryption plugin")
2080 "Technology for Resting Email Encrypted Storage (TREES) is a NaCL-based
2081 Dovecot encryption plugin. This plugin adds individually encrypted mail
2082 storage to the Dovecot IMAP server. It is inspired by Posteo's scrambler
2083 which uses OpenSSL and RSA key pairs. TREES works in a similar way, but uses
2084 the Sodium crypto library (based on NaCL).
2088 @item On IMAP log in, the user's cleartext password is passed to the plugin.
2089 @item The plugin creates an argon2 digest from the password.
2090 @item This password digest is used as a symmetric secret to decrypt a libsodium secretbox.
2091 @item Inside the secretbox is stored a Curve25519 private key.
2092 @item The Curve25519 private key is used to decrypt each individual message,
2093 using libsodium sealed boxes.
2094 @item New mail is encrypted as it arrives using the Curve25519 public key.
2096 (license license:agpl3)))
2098 (define-public dovecot-libsodium-plugin
2099 (let ((commit "044de73c01c35385df0105f6b387bec5d5317ce7")
2102 (name "dovecot-libsodium-plugin")
2103 (version (string-append "0.0.0-" revision "." (string-take commit 7)))
2108 (url "https://github.com/LuckyFellow/dovecot-libsodium-plugin")
2110 (file-name (string-append name "-" version "-checkout"))
2113 "13h07l7xy713zchnj2p9fhvq7fdl4zy1ai94li3ygkqjjj8hrgas"))))
2114 (build-system gnu-build-system)
2116 `(("automake" ,automake)
2117 ("autoconf" ,autoconf)
2118 ("libtool" ,libtool)
2119 ("dovecot" ,dovecot)
2120 ("pkg-config" ,pkg-config)))
2122 `(("libsodium" ,libsodium)))
2124 `(#:tests? #f ;No tests exist.
2125 #:configure-flags (list (string-append "--with-dovecot="
2126 (assoc-ref %build-inputs "dovecot")
2128 (home-page "https://github.com/LuckyFellow/dovecot-libsodium-plugin")
2129 (synopsis "Libsodium password hashing schemes plugin for Dovecot")
2131 "@code{dovecot-libsodium-plugin} provides a libsodium password
2132 hashing scheme (such as scrypt) plug-in for @code{Dovecot}.")
2133 (license license:gpl3+))))
2135 (define-public isync
2142 (uri (string-append "mirror://sourceforge/isync/isync/"
2143 version "/isync-" version ".tar.gz"))
2145 "024p3glj4p7fhrssw5sr55arls9zna1igxxrspxlfd6sbds21ixl"))))
2146 (build-system gnu-build-system)
2151 ("cyrus-sasl" ,cyrus-sasl)
2152 ("openssl" ,openssl)
2154 (home-page "https://isync.sourceforge.io/")
2155 (synopsis "Mailbox synchronization program")
2157 "isync/mbsync is a command-line tool for two-way synchronization of
2158 mailboxes. Currently Maildir and IMAP are supported types.")
2159 (license license:gpl2+)))
2161 (define-public perl-email-abstract
2163 (name "perl-email-abstract")
2168 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
2169 "Email-Abstract-" version ".tar.gz"))
2171 (base32 "1z01wbflg49nbgzl81x260cp8x6qr7xdpz3dkrg82m1fwa9742q4"))))
2172 (build-system perl-build-system)
2174 `(("perl-email-simple" ,perl-email-simple)
2175 ("perl-module-pluggable" ,perl-module-pluggable)
2176 ("perl-mro-compat" ,perl-mro-compat)))
2177 (home-page "https://metacpan.org/release/Email-Abstract")
2178 (synopsis "Interface to mail representations")
2179 (description "Email::Abstract provides module writers with the ability to
2180 write simple, representation-independent mail handling code.")
2181 (license license:perl-license)))
2183 (define-public perl-email-address
2185 (name "perl-email-address")
2190 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
2191 "Email-Address-" version ".tar.gz"))
2193 (base32 "1vzr0vx4zsw4zbc9xdffc31wnkc1raqmyfiyws06fbyck197i8qg"))))
2194 (build-system perl-build-system)
2195 (home-page "https://metacpan.org/release/Email-Address")
2196 (synopsis "Email address parsing and creation")
2197 (description "Email::Address implements a regex-based RFC 2822 parser that
2198 locates email addresses in strings and returns a list of Email::Address
2199 objects found. Alternatively you may construct objects manually.")
2200 (license license:perl-license)))
2202 (define-public perl-email-address-xs
2204 (name "perl-email-address-xs")
2209 (uri (string-append "mirror://cpan/authors/id/P/PA/PALI/"
2210 "Email-Address-XS-" version ".tar.gz"))
2213 "0gjrrl81z3sfwavgx5kwjd87gj44mlnbbqsm3dgdv1xllw26spwr"))))
2214 (build-system perl-build-system)
2215 (home-page "https://metacpan.org/release/Email-Address-XS")
2216 (synopsis "Parse and format RFC 5322 email addresses and groups")
2218 "Email::Address::XS implements RFC 5322 parser and formatter of email
2219 addresses and groups. Unlike Email::Address, this module does not use regular
2220 expressions for parsing but instead is implemented in XS and uses shared code
2221 from Dovecot IMAP server.")
2222 (license license:perl-license)))
2224 (define-public perl-email-date-format
2226 (name "perl-email-date-format")
2231 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
2232 "Email-Date-Format-" version ".tar.gz"))
2235 "012ivfwpnbl3wr50f9c6f4azhdlxnm31pdn72528g79v61z6372p"))))
2236 (build-system perl-build-system)
2237 (home-page "https://metacpan.org/release/Email-Date-Format")
2238 (synopsis "Produce RFC 2822 date strings")
2239 (description "Email::Date::Format provides a means for generating an RFC
2240 2822 compliant datetime string.")
2241 (license license:perl-license)))
2243 (define-public perl-email-messageid
2245 (name "perl-email-messageid")
2250 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
2251 "Email-MessageID-" version ".tar.gz"))
2254 "1f22sdnfq169qw1l0lg7y74pmiam7j9v95bggjnf3q4mygdmshpc"))))
2255 (build-system perl-build-system)
2256 (home-page "https://metacpan.org/release/Email-MessageID")
2257 (synopsis "Generate world unique message-ids")
2258 (description "Email::MessageID generates recommended message-ids to
2259 identify a message uniquely.")
2260 (license license:perl-license)))
2262 (define-public perl-email-mime
2264 (name "perl-email-mime")
2269 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
2270 "Email-MIME-" version ".tar.gz"))
2273 "0z1k3i0lzp2k421gc8f3wq0jbqflkbw2xqd2k7n7pmv56417kvk8"))))
2274 (build-system perl-build-system)
2276 `(("perl-email-address" ,perl-email-address)
2277 ("perl-email-messageid" ,perl-email-messageid)
2278 ("perl-email-mime-contenttype" ,perl-email-mime-contenttype)
2279 ("perl-email-mime-encodings" ,perl-email-mime-encodings)
2280 ("perl-email-simple" ,perl-email-simple)
2281 ("perl-mime-types" ,perl-mime-types)
2282 ("perl-module-runtime" ,perl-module-runtime)))
2283 (home-page "https://metacpan.org/release/Email-MIME")
2284 (synopsis "MIME message handling")
2285 (description "Email::MIME is an extension of the Email::Simple module, to
2286 handle MIME encoded messages. It takes a message as a string, splits it up
2287 into its constituent parts, and allows you access to various parts of the
2288 message. Headers are decoded from MIME encoding.")
2289 (license license:perl-license)))
2291 (define-public perl-email-mime-contenttype
2293 (name "perl-email-mime-contenttype")
2298 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
2299 "Email-MIME-ContentType-" version ".tar.gz"))
2302 "042kxhs3bp1ab9z0mbr1wy21ld4lxd6v2a2mmrashqnsn2075fws"))))
2303 (build-system perl-build-system)
2305 `(("perl-capture-tiny" ,perl-capture-tiny)))
2306 (home-page "https://metacpan.org/release/Email-MIME-ContentType")
2307 (synopsis "Parse MIME Content-Type headers")
2308 (description "Email::MIME::ContentType parses a MIME Content-Type
2310 (license license:perl-license)))
2312 (define-public perl-email-mime-encodings
2314 (name "perl-email-mime-encodings")
2319 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
2320 "Email-MIME-Encodings-" version ".tar.gz"))
2323 "0p5b8g9gh35m8fqrpx60g4bp98rvwd02n5b0vm9wh7mk0xah8wac"))))
2324 (build-system perl-build-system)
2326 `(("perl-capture-tiny" ,perl-capture-tiny)))
2327 (home-page "https://metacpan.org/release/Email-MIME-Encodings")
2328 (synopsis "Unified interface to MIME encoding and decoding")
2329 (description "This module wraps MIME::Base64 and MIME::QuotedPrint.")
2330 (license license:perl-license)))
2332 (define-public perl-email-sender
2334 (name "perl-email-sender")
2335 (version "1.300035")
2339 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
2340 "Email-Sender-" version ".tar.gz"))
2342 (base32 "0yfssp3rqdx1dmgvnygarzgkpkhqm28r5sd0gh87ksk8yxndhjql"))))
2343 (build-system perl-build-system)
2345 `(("perl-capture-tiny" ,perl-capture-tiny)))
2347 `(("perl-email-abstract" ,perl-email-abstract)
2348 ("perl-email-address" ,perl-email-address)
2349 ("perl-email-simple" ,perl-email-simple)
2350 ("perl-list-moreutils" ,perl-list-moreutils)
2351 ("perl-module-runtime" ,perl-module-runtime)
2352 ("perl-moo" ,perl-moo)
2353 ("perl-moox-types-mooselike" ,perl-moox-types-mooselike)
2354 ("perl-sub-exporter" ,perl-sub-exporter)
2355 ("perl-throwable" ,perl-throwable)
2356 ("perl-try-tiny" ,perl-try-tiny)))
2357 (home-page "https://metacpan.org/release/Email-Sender")
2358 (synopsis "Perl library for sending email")
2359 (description "Email::Sender replaces the old and sometimes problematic
2360 Email::Send library.")
2361 (license license:perl-license)))
2363 (define-public perl-email-simple
2365 (name "perl-email-simple")
2370 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
2371 "Email-Simple-" version ".tar.gz"))
2374 "1m4brbjvalyp5kjqslqv4155dzwg977shxin208i7lc8236n6pyq"))))
2375 (build-system perl-build-system)
2377 `(("perl-email-date-format" ,perl-email-date-format)))
2378 (home-page "https://metacpan.org/release/Email-Simple")
2379 (synopsis "Parsing of RFC 2822 messages")
2380 (description "Email::Simple provides simple parsing of RFC 2822 message
2381 format and headers.")
2382 (license license:perl-license)))
2384 (define-public libesmtp
2392 (url "https://github.com/libesmtp/libESMTP")
2393 (commit (string-append "v" version))))
2394 (file-name (git-file-name name version))
2396 (base32 "1bhh8hlsl9597x0bnfl563k2c09b61qnkb9mfyqcmzlq63m1zw5y"))))
2397 (build-system meson-build-system)
2399 `(("openssl" ,openssl)))
2400 (home-page "http://www.stafford.uklinux.net/libesmtp/")
2401 (synopsis "Library for sending mail via remote hosts using SMTP")
2403 "libESMTP is an @acronym{SMTP, Simple Mail Transfer Protocol} client that
2404 manages posting (or submission of) electronic mail via a preconfigured
2405 @acronym{MTA, Mail Transport Agent}.
2407 It may be used as part of a @acronym{MUA, Mail User Agent}, or other program
2408 that must be able to post electronic mail where mail functionality may not be
2409 that program's primary purpose.
2411 libESMTP's high-level API shields developers from the complexity of SMTP. It
2412 transparently handles many SMTP extensions including authentication,
2413 @acronym{TLS, Transport-Level Security}, and PIPELINING for performance. Even
2414 without a pipelining server, libESMTP offers much better performance than would
2415 be expected from a simple client.")
2416 (license (list license:lgpl2.1+ license:gpl2+))))
2418 (define-public esmtp
2426 (url "https://github.com/andywingo/esmtp")
2427 (commit "01bf9fc")))
2430 "1ay282rrl92h0m0m8z5zzjnwiiagi7c78aq2qvhia5mw7prwfyw2"))
2431 (file-name (string-append name "-" version "-checkout"))
2432 (patches (search-patches "esmtp-add-lesmtp.patch"))))
2434 `(#:phases (modify-phases %standard-phases
2436 (lambda _ (invoke "autoreconf" "-vfi"))))))
2437 (build-system gnu-build-system)
2441 ("autoconf" ,autoconf)
2442 ("automake" ,automake)
2443 ("libtool" ,libtool)))
2445 `(("libesmtp" ,libesmtp)))
2446 (home-page "https://sourceforge.net/projects/esmtp/")
2447 (synopsis "Relay-only mail transfer agent (MTA)")
2448 (description "Esmtp is a simple relay-only mail transfer agent built using
2449 libESMTP. It sends e-mail via a remote SMTP server using credentials from the
2450 user's @file{$HOME/.esmtprc} configuration file; see the @command{esmtprc} man
2451 page for more on configuration. This package also provides minimal
2452 compatibility shims for the @command{sendmail}, @command{mailq}, and
2453 @command{newaliases} commands.")
2454 (license license:gpl2+)))
2462 (uri (string-append "https://github.com/nicm/fdm/releases/download/"
2463 version "/fdm-" version ".tar.gz"))
2465 (base32 "196fs1z8y7p12wmqn1bylzz94szl58yv2aby3p30nmwjnyv8rch6"))))
2466 (build-system gnu-build-system)
2469 ("openssl" ,openssl)
2471 (home-page "https://github.com/nicm/fdm")
2472 (synopsis "Mail Retrieval Agent (MRA) and Mail Delivery Agent (MDA)")
2473 (description "fdm is a program designed to fetch mail from POP3
2474 or IMAP servers, or receive local mail from stdin, and
2475 deliver it in various ways.")
2477 ;; Why point to a source file? Well, all the individual files have a
2478 ;; copy of this license in their headers, but there's no seprate file
2479 ;; with that information.
2480 (license:non-copyleft
2481 "https://github.com/nicm/fdm/blob/master/command.c"))))
2484 (define-public procmail
2492 "ftp://ftp.fu-berlin.de/pub/unix/mail/procmail/procmail-"
2497 "05z1c803n5cppkcq99vkyd5myff904lf9sdgynfqngfk9nrpaz08"))
2498 ;; The following patch fixes an ambiguous definition of
2499 ;; getline() in formail.c. The patch is provided by Debian as
2501 (patches (search-patches "procmail-ambiguous-getline-debian.patch"
2502 "procmail-CVE-2014-3618.patch"
2503 "procmail-CVE-2017-16844.patch"))))
2505 `(#:phases (modify-phases %standard-phases
2508 (substitute* "Makefile"
2512 (assoc-ref %outputs "out"))
2516 #:tests? #f)) ;; There are no tests indicating a successful
2517 ;; build. Some tests of basic locking mechanisms provided by the
2518 ;; file system are performed during 'make install'. However, these
2519 ;; are performed before the actual build process.
2520 (build-system gnu-build-system)
2521 (inputs `(("exim" ,exim)))
2522 (home-page "http://www.procmail.org/")
2523 (synopsis "Versatile mail delivery agent (MDA)")
2524 (description "Procmail is a mail delivery agent (MDA) featuring support
2525 for a variety of mailbox formats such as mbox, mh and maildir. Incoming mail
2526 can be sorted into separate files/directories and arbitrary commands can be
2527 executed on mail arrival. Procmail is considered stable, but is no longer
2529 (license license:gpl2+))) ;; procmail allows to choose the
2530 ;; nonfree Artistic License 1.0
2531 ;; as alternative to the GPL2+.
2532 ;; This option is not listed here.
2534 (define-public khard
2540 (uri (pypi-uri name version))
2543 "062nv4xkfsjc11k9m52dh6xjn9z68a4a6x1s8z05wwv4jbp1lkhn"))))
2544 (build-system python-build-system)
2547 (modify-phases %standard-phases
2548 (add-after 'install 'install-completions
2549 (lambda* (#:key outputs #:allow-other-keys)
2550 (let* ((out (assoc-ref outputs "out"))
2551 (zsh (string-append out "/share/zsh/site-functions")))
2552 (copy-recursively "misc/zsh" zsh)
2555 `(("python-setuptools-scm" ,python-setuptools-scm)))
2557 `(("python-atomicwrites" ,python-atomicwrites)
2558 ("python-configobj" ,python-configobj)
2559 ("python-ruamel.yaml" ,python-ruamel.yaml)
2560 ("python-unidecode" ,python-unidecode)
2561 ("python-vobject" ,python-vobject)))
2562 (synopsis "Console address book using CardDAV")
2563 (description "Khard is an address book for the console. It creates, reads,
2564 modifies and removes CardDAV address book entries at your local machine. For
2565 synchronizing with a remote address book, @command{vdirsyncer} is recommended.
2566 Khard can also be used from within the email client @command{mutt}.")
2567 (home-page "https://github.com/scheibler/khard")
2568 (license license:gpl3+)))
2570 (define-public perl-mail-spf
2572 (name "perl-mail-spf")
2578 "mirror://cpan/authors/id/J/JM/JMEHNLE/mail-spf/Mail-SPF-v"
2582 (base32 "0qk1rfgfm5drj4iyniiabrasrpqv570vzhgz66lwgb67y4amkjv1"))))
2583 (build-system perl-build-system)
2585 `(("perl-module-build" ,perl-module-build)
2586 ("perl-net-dns-resolver-programmable"
2587 ,perl-net-dns-resolver-programmable)))
2590 (modify-phases %standard-phases
2591 (add-before 'configure 'modify-Build.PL
2592 (lambda* (#:key outputs #:allow-other-keys)
2593 (substitute* "Build.PL"
2594 (("'/usr/sbin'") (string-append "'"
2595 (assoc-ref outputs "out")
2599 `(("perl-error" ,perl-error)
2600 ("perl-net-dns" ,perl-net-dns)
2601 ("perl-netaddr-ip" ,perl-netaddr-ip)
2602 ("perl-uri" ,perl-uri)))
2603 (home-page "https://metacpan.org/release/Mail-SPF")
2604 (synopsis "Perl implementation of Sender Policy Framework")
2605 (description "Mail::SPF is the Sender Policy Framework implemented
2607 (license license:bsd-3)))
2609 (define-public perl-mail-authenticationresults
2611 (name "perl-mail-authenticationresults")
2612 (version "1.20180923")
2616 "mirror://cpan/authors/id/M/MB/MBRADSHAW/"
2617 "Mail-AuthenticationResults-" version ".tar.gz"))
2620 "1g1wym9vcbhldwvi4w5pl0fhd4jh2icj975awf4wr5xmkli9mxbz"))))
2621 (build-system perl-build-system)
2623 `(("perl-test-exception" ,perl-test-exception)))
2624 (home-page "https://metacpan.org/release/Mail-AuthenticationResults")
2625 (synopsis "Object Oriented Authentication-Results Headers")
2626 (description "Mail::AuthenticationResults parses the message header field
2627 that indicates the message authentication status as per RFC7601. This module
2628 is not fully compliant with the RFC but it tries to implement most styles of
2629 Authentication-Results header seen in the wild.")
2630 (license license:perl-license)))
2632 (define-public perl-mail-dkim
2634 (name "perl-mail-dkim")
2635 (version "1.20200907")
2639 "mirror://cpan/authors/id/M/MB/MBRADSHAW/Mail-DKIM-"
2644 "1x8v4pa0447c1xqri1jn96i8vlyjpl6jmz63nb1vifbp16yi3zxb"))))
2645 (build-system perl-build-system)
2647 `(("perl-crypt-openssl-rsa" ,perl-crypt-openssl-rsa)
2648 ("perl-mail-authenticationresults" ,perl-mail-authenticationresults)
2649 ("perl-mailtools" ,perl-mailtools)
2650 ("perl-net-dns" ,perl-net-dns)))
2652 `(("perl-net-dns-resolver-mock" ,perl-net-dns-resolver-mock)
2653 ("perl-test-requiresinternet" ,perl-test-requiresinternet)
2654 ("perl-yaml-libyaml" ,perl-yaml-libyaml)))
2655 (home-page "https://metacpan.org/release/Mail-DKIM")
2656 (synopsis "Signs/verifies Internet mail with DKIM/DomainKey signatures")
2657 (description "Mail::DKIM is a Perl module that implements the new Domain
2658 Keys Identified Mail (DKIM) standard, and the older Yahoo! DomainKeys standard,
2659 both of which sign and verify emails using digital signatures and DNS records.
2660 Mail-DKIM can be used by any Perl program that wants to provide support for
2661 DKIM and/or DomainKeys.")
2662 (license license:gpl3+)))
2664 (define-public dkimproxy
2671 "mirror://sourceforge/dkimproxy/dkimproxy/"
2672 version "/dkimproxy-" version ".tar.gz"))
2675 "1gc5c7lg2qrlck7b0lvjfqr824ch6jkrzkpsn0gjvlzg7hfmld75"))
2677 (search-patches "dkimproxy-add-ipv6-support.patch"))))
2678 (build-system gnu-build-system)
2681 (modify-phases %standard-phases
2682 (add-after 'install 'make-wrapper
2683 (lambda* (#:key inputs outputs #:allow-other-keys)
2684 (let* ((out (assoc-ref outputs "out"))
2685 (wrap.pl (lambda (scripts keys)
2688 (wrap-program (string-append out script)
2689 `("PERL5LIB" ":" prefix
2692 (assoc-ref inputs input)
2693 "/lib/perl5/site_perl"))
2696 (wrap.pl (list "/bin/dkimproxy.in"
2697 "/bin/dkimproxy.out")
2698 (list "perl-crypt-openssl-rsa"
2699 "perl-io-socket-inet6"
2701 "perl-mail-authenticationresults"
2706 (wrap.pl (list "/bin/dkim_responder.pl")
2707 (list "perl-crypt-openssl-rsa"
2716 ("perl-crypt-openssl-rsa" ,perl-crypt-openssl-rsa)
2717 ("perl-io-socket-inet6" ,perl-io-socket-inet6)
2718 ("perl-mailtools" ,perl-mailtools)
2719 ("perl-mail-authenticationresults" ,perl-mail-authenticationresults)
2720 ("perl-mail-dkim" ,perl-mail-dkim)
2721 ("perl-mime-tools" ,perl-mime-tools)
2722 ("perl-net-dns" ,perl-net-dns)
2723 ("perl-net-server" ,perl-net-server)
2724 ("perl-socket6" ,perl-socket6)
2725 ("perl-timedate" ,perl-timedate)))
2726 (home-page "http://dkimproxy.sourceforge.net/")
2727 (synopsis "SMTP proxy to sign and verify Internet mail with DKIM headers")
2729 "DKIMproxy is an SMTP proxy that signs and verifies Internet mail using the
2730 @code{Mail::DKIM} Perl module. It comprises two separate proxies: an outbound
2731 proxy for signing outgoing email, and an inbound proxy for verifying signatures
2732 of incoming messages.
2734 It was designed for Postfix, but can be used to add DKIM support to nearly any
2735 existing mail server. With Postfix, the proxies can operate as either
2736 @code{Before-Queue} or @code{After-Queue} content filters.")
2737 (license license:gpl2+)))
2739 (define-public mb2md
2746 "http://batleth.sapienti-sat.org/projects/mb2md/mb2md-"
2750 "0bvkky3c90738h3skd2f1b2yy5xzhl25cbh9w2dy97rs86ssjidg"))))
2751 (build-system trivial-build-system)
2753 '(#:modules ((guix build utils))
2756 (use-modules (guix build utils))
2757 (let* ((source (assoc-ref %build-inputs "source"))
2758 (out (assoc-ref %outputs "out"))
2759 (bin (string-append out "/bin"))
2760 (perl (assoc-ref %build-inputs "perl"))
2761 (gzip (assoc-ref %build-inputs "gzip"))
2762 (perl-timedate (assoc-ref %build-inputs "perl-timedate"))
2763 (perl5lib (string-append perl-timedate "/lib/perl5/site_perl")))
2765 (with-directory-excursion bin
2766 (copy-file source "mb2md.gz")
2767 (invoke (string-append gzip "/bin/gzip") "-d" "mb2md.gz")
2768 (substitute* "mb2md"
2769 (("#!/usr/bin/perl")
2770 (string-append "#!/usr/bin/perl -I " perl5lib)))
2771 (patch-shebang "mb2md" (list (string-append perl "/bin")))
2772 (chmod "mb2md" #o555))
2774 (native-inputs `(("gzip" ,gzip)))
2775 (inputs `(("perl" ,perl)
2776 ("perl-timedate" ,perl-timedate)))
2777 (home-page "http://batleth.sapienti-sat.org/projects/mb2md/")
2778 (synopsis "Mbox to maildir converter")
2780 "Mb2md is a Perl script that takes one or more mbox format files and
2781 converts them to maildir format directories.")
2782 (license license:public-domain)))
2784 (define-public mblaze
2792 (url "https://github.com/leahneukirchen/mblaze")
2793 (commit (string-append "v" version))))
2794 (file-name (git-file-name name version))
2796 (base32 "1bir977vnqs76g8jgv1yivqw0wk2kn56l3l5r4w2ipix3fir138y"))))
2797 (build-system gnu-build-system)
2801 `(#:tests? #f ; XXX: Upstream tests appear to be broken
2802 #:make-flags (list (string-append "CC=" ,(cc-for-target))
2804 (string-append "DESTDIR=" %output))
2806 (modify-phases %standard-phases
2807 (delete 'configure))))
2808 (home-page "https://github.com/leahneukirchen/mblaze")
2809 (synopsis "Unix utilities to deal with Maildir")
2811 "The mblaze message system is a set of Unix utilities for processing and
2812 interacting with mail messages which are stored in maildir folders.
2814 Its design is roughly inspired by MH, the RAND Message Handling System, but it
2815 is a complete implementation from scratch.
2817 mblaze is a classic command line MUA and has no features for receiving or
2818 transferring messages; you can operate on messages in a local maildir spool,
2819 or fetch your messages using fdm(1), getmail(1), offlineimap(1), or similar
2820 utilities, and send it using dma(8), msmtp(1), sendmail(8), as provided by
2821 OpenSMTPD, Postfix, or similar.
2823 mblaze operates directly on maildir folders and doesn't use its own caches or
2824 databases. There is no setup needed for many uses. All utilities have been
2825 written with performance in mind. Enumeration of all messages in a maildir is
2826 avoided unless necessary, and then optimized to limit syscalls. Parsing
2827 message metadata is optimized to limit I/O requests. Initial operations on a
2828 large maildir may feel slow, but as soon as they are in the file system cache,
2829 everything is blazingly fast. The utilities are written to be memory
2830 efficient (i.e. not wasteful), but whole messages are assumed to fit into RAM
2831 easily (one at a time).")
2832 (license (list license:public-domain
2833 license:expat)))) ; mystrverscmp.c and mymemmem
2842 (uri (string-append "https://marlam.de/mpop/releases/"
2843 "mpop-" version ".tar.xz"))
2845 (base32 "1hbx69d6ivbvjajrcp54fdb3g1ms4ydj0ybf3bfhlravqrk88jdk"))))
2846 (build-system gnu-build-system)
2848 `(("gnutls" ,gnutls)))
2850 `(("pkg-config" ,pkg-config)))
2851 (home-page "https://marlam.de/mpop/")
2852 (synopsis "POP3 mail client")
2853 (description "mpop is a small and fast POP3 client suitable as a
2854 fetchmail replacement.
2856 mpop supports multiple accounts, header based mail filtering, delivery
2857 to mbox files, maildir folders or an @acronym{MDA, Mail Delivery Agent},
2858 TLS/SSL, several authentication methods, @acronym{IDN, Internationalized Domain
2859 Names} and SOCKS proxies.")
2860 (license license:gpl3+)))
2862 (define-public mhonarc
2869 (uri (string-append "mirror://cpan/authors/id/E/EH/EHOOD/MHonArc-"
2873 "0ll3v93yji334zqp6xfzfxc0127pmjcznmai1l5q6dzawrs2igzq"))))
2874 (build-system perl-build-system)
2875 (home-page "https://www.mhonarc.org/")
2876 (synopsis "Create HTML archives of mail/news messages")
2878 "MHonArc is a Perl mail-to-HTML converter. MHonArc
2879 provides HTML mail archiving with index, mail thread linking,
2880 etc; plus other capabilities including support for MIME and
2881 powerful user customization features.")
2882 (license license:gpl2+)))
2884 (define-public sendmail
2892 "ftp://ftp.sendmail.org/pub/sendmail/sendmail."
2896 "0fdl9ndmspqspdlmghzxlaqk56j3yajk52d7jxcg21b7sxglpy94"))))
2897 (build-system gnu-build-system)
2900 (modify-phases %standard-phases
2901 (add-before 'build 'replace-/bin/sh
2905 (list "smrsh/smrsh.c" "sendmail/conf.c" "contrib/mailprio"
2906 "contrib/mmuegel" "devtools/bin/configure.sh")
2907 (find-files "." ".*\\.m4")
2908 (find-files "." ".*\\.cf"))
2909 (("/bin/sh") (which "sh")))
2911 (substitute* "devtools/bin/Build"
2912 (("SHELL=/bin/sh") (string-append "SHELL=" (which "sh"))))
2914 (add-before 'build 'replace-/usr
2917 '("devtools/OS/Linux"
2918 "cf/ostype/mklinux.m4"
2919 "cf/ostype/linux.m4")
2920 (("/usr/sbin") "/sbin"))))
2924 ;; Render harmless any attempts to chown or chgrp
2925 (substitute* "devtools/bin/install.sh"
2926 (("owner=\\$2") "owner=''")
2927 (("group=\\$2") "group=''"))
2929 (with-output-to-file "devtools/Site/site.config.m4"
2932 define(`confEBINDIR', `/sbin')
2933 define(`confSBINDIR', `/sbin')
2934 define(`confMBINDIR', `/sbin')
2935 define(`confUBINDIR', `/bin')
2936 define(`confLINKS', `')
2937 define(`confCC', `gcc')
2938 define(`confOPTIMIZE', `-g -O2')
2939 define(`confLIBS', `-lresolv')
2940 define(`confINSTALL', `~a/devtools/bin/install.sh')
2941 define(`confDEPEND_TYPE', `CC-M')
2942 define(`confINST_DEP', `')
2947 (invoke "sh" "Build")
2948 (with-directory-excursion "cf/cf"
2949 (copy-file "generic-linux.mc" "sendmail.mc")
2950 (invoke "sh" "Build" "sendmail.cf"))
2952 (add-before 'install 'pre-install
2954 (let ((out (assoc-ref %outputs "out")))
2955 (mkdir-p (string-append out "/bin"))
2956 (mkdir-p (string-append out "/sbin"))
2957 (mkdir-p (string-append out "/etc/mail"))
2958 (setenv "DESTDIR" out)
2959 (with-directory-excursion "cf/cf"
2960 (invoke "sh" "Build" "install-cf"))
2962 (add-after 'install 'post-install
2964 ;; Make symbolic links manually, because build script uses
2965 ;; absolute paths for them and ignores DESTDIR.
2968 (symlink "../sbin/sendmail" (string-append %output "/bin/" name)))
2969 '("hoststat" "newaliases" "mailq" "purgestat")))))
2970 ;; There is no make check. There are some post installation tests, but those
2971 ;; require root privileges
2976 (home-page "http://sendmail.org")
2978 "Highly configurable Mail Transfer Agent (MTA)")
2980 "Sendmail is a mail transfer agent (MTA) originally developed by Eric
2981 Allman. It is highly configurable and supports many delivery methods and many
2982 transfer protocols.")
2983 (license (license:non-copyleft "file://LICENSE"
2984 "See LICENSE in the distribution."))))
2986 (define-public sieve-connect
2988 (name "sieve-connect")
2993 (uri (string-append "https://people.spodhuis.org/phil.pennock/software/"
2994 "sieve-connect-" version ".tar.bz2"))
2996 (base32 "00vnyzr67yr2ilnprbd388gfnwmrmbdx1jsig9d0n5q902jqn62a"))))
2997 (build-system gnu-build-system)
3000 (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
3001 #:tests? #f ; no test suite
3003 (modify-phases %standard-phases
3004 (delete 'configure) ; no configure script
3005 (add-before 'install 'create-output-directories
3006 (lambda* (#:key outputs #:allow-other-keys)
3007 (let ((out (assoc-ref outputs "out")))
3008 (for-each (lambda (subdirectory)
3009 (mkdir-p (string-append out "/" subdirectory)))
3013 (add-after 'install 'wrap-program
3014 (lambda* (#:key inputs outputs #:allow-other-keys)
3015 (let ((out (assoc-ref outputs "out"))
3016 (path (getenv "PERL5LIB")))
3017 (wrap-script (string-append out "/bin/sieve-connect")
3018 #:guile (search-input-file inputs "bin/guile")
3019 `("PERL5LIB" ":" = (,path)))
3022 `(("guile" ,guile-3.0) ; for wrap-script
3024 ("perl-authen-sasl" ,perl-authen-sasl)
3025 ("perl-io-socket-inet6" ,perl-io-socket-inet6)
3026 ("perl-io-socket-ssl" ,perl-io-socket-ssl)
3027 ("perl-net-dns" ,perl-net-dns)
3028 ("perl-socket6" ,perl-socket6)
3029 ("perl-term-readkey" ,perl-term-readkey)
3030 ("perl-term-readline" ,perl-term-readline-gnu)))
3032 "https://people.spodhuis.org/phil.pennock/software/#sieve-connect")
3033 (synopsis "ManageSieve client for managing Sieve e-mail filters")
3035 "Sieve-connect lets you view, upload, edit, delete, and otherwise manage
3036 Sieve scripts on any mail server that speaks the @dfn{ManageSieve} protocol,
3037 as specified in RFC 5804.
3039 @dfn{Sieve} (RFC 5228) is a specialised language for e-mail filtering. Sieve
3040 scripts are stored on the server and run whenever mail arrives. They can
3041 automatically sort new messages into folders, silently reject them, send an
3042 automated response, and more.
3044 @command{sieve-connect} is designed to be both a tool which can be invoked
3045 from scripts as well as a decent interactive client. It supports TLS for
3046 connection privacy, as well as authentication with SASL or GSSAPI client
3047 certificates. It should be a drop-in replacement for @command{sieveshell}
3048 from the Cyrus IMAP project.")
3049 (license license:bsd-3)))
3051 (define-public opensmtpd
3058 (uri (string-append "https://www.opensmtpd.org/archives/"
3059 "opensmtpd-" version ".tar.gz"))
3061 (base32 "05sd7bmq29ibnqbl2z53hiyprfxzf0qydfdaixs68rz55wqhbgsi"))))
3062 (build-system gnu-build-system)
3066 ("libevent" ,libevent)
3067 ("libressl" ,libressl) ; recommended, and supports e.g. ECDSA
3068 ("linux-pam" ,linux-pam)
3072 ("groff" ,groff))) ; for man pages
3075 (list "--localstatedir=/var"
3076 ;; This is the default only if it exists at build time—it doesn't.
3077 "--with-path-socket=/var/run"
3078 "--with-path-CAfile=/etc/ssl/certs/ca-certificates.crt"
3079 "--with-user-smtpd=smtpd"
3080 "--with-user-queue=smtpq" "--with-group-queue=smtpq"
3084 (modify-phases %standard-phases
3085 ;; See: https://github.com/OpenSMTPD/OpenSMTPD/issues/1069.
3086 (add-after 'unpack 'fix-smtpctl-encrypt-bug
3088 (substitute* "usr.sbin/smtpd/smtpctl.c"
3089 (("\"encrypt\", \"--\",")
3092 ;; Fix some incorrectly hard-coded external tool file names.
3093 (add-after 'unpack 'patch-FHS-file-names
3095 (substitute* "usr.sbin/smtpd/smtpctl.c"
3096 ;; ‘gzcat’ is auto-detected at compile time, but ‘cat’ isn't.
3097 (("/bin/cat") (which "cat")))
3098 (substitute* "usr.sbin/smtpd/mda_unpriv.c"
3099 (("/bin/sh") (which "sh")))
3101 ;; OpenSMTPD provides a single smtpctl utility to control both the
3102 ;; daemon and the local submission subsystem. To accomodate systems
3103 ;; that require historical interfaces such as sendmail, newaliases or
3104 ;; makemap, smtpctl operates in compatibility mode if called with the
3106 (add-after 'install 'install-compability-links
3107 (lambda* (#:key outputs #:allow-other-keys)
3108 (let* ((out (assoc-ref outputs "out"))
3109 (sbin (string-append out "/sbin/")))
3110 (for-each (lambda (command)
3111 (symlink "smtpctl" (string-append sbin command)))
3112 (list "mailq" "makemap" "newaliases"
3113 "send-mail" "sendmail")))
3115 (synopsis "Lightweight SMTP daemon")
3117 "OpenSMTPD is an implementation of server-side @acronym{SMTP, Simple Mail
3118 Transfer Protocol}, with some additional standard extensions. It allows
3119 ordinary machines to exchange e-mails with other systems speaking the SMTP
3120 protocol, or to deliver them to local users.
3122 In order to simplify the use of SMTP, OpenSMTPD implements a smaller set of
3123 functionality than those available in other SMTP daemons. The objective is to
3124 provide enough features to satisfy typical usage at the risk of unsuitability
3125 to esoteric or niche requirements.")
3126 (home-page "https://www.opensmtpd.org")
3127 (license (list license:bsd-2 license:bsd-3 license:bsd-4
3128 (license:non-copyleft "file://COPYING")
3129 license:public-domain license:isc license:openssl))))
3131 (define-public opensmtpd-extras
3133 (name "opensmtpd-extras")
3137 (uri (string-append "https://www.opensmtpd.org/archives/"
3138 "opensmtpd-extras-" version ".tar.gz"))
3141 "1b1mx71bvmv92lbm08wr2p60g3qhikvv3n15zsr6dcwbk9aqahzq"))))
3142 (build-system gnu-build-system)
3144 `(("pkg-config" ,pkg-config)))
3146 `(("libressl" ,libressl)
3147 ("libevent" ,libevent)
3149 ("opensmtpd" ,opensmtpd)
3150 ("postgresql" ,postgresql)
3151 ("python" ,python-2)
3152 ("sqlite" ,sqlite)))
3155 (list "--sysconfdir=/etc"
3156 "--localstatedir=/var"
3159 "--with-queue-python"
3164 "--with-table-mysql"
3165 "--with-table-postgres"
3166 ;; "--with-table-redis" ; TODO: package hiredis
3167 "--with-table-socketmap"
3168 "--with-table-passwd"
3169 "--with-table-python"
3170 "--with-table-sqlite"
3173 "--with-scheduler-ram"
3174 "--with-scheduler-stub"
3175 "--with-scheduler-python"
3177 "--with-user-smtpd=smtpd"
3179 ;; We have to configure it like this because the default checks for
3180 ;; for example Python in /usr/{,local/}bin and fails otherwise.
3181 (string-append "--with-python="
3182 (assoc-ref %build-inputs "python")))))
3183 (home-page "https://www.opensmtpd.org")
3184 (synopsis "Extra tables, filters, and various other addons for OpenSMTPD")
3186 "This package provides extra tables, filters, and various other addons
3187 for OpenSMTPD to extend its functionality.")
3188 (license (list license:bsd-2 license:bsd-3 ; openbsd-compat
3189 license:isc)))) ; everything else
3191 (define-public libopensmtpd
3192 ;; Private source dependency of opensmtpd-filter-dkimsign (by the same
3193 ;; author), until any project actually uses it in its compiled form.
3195 (name "libopensmtpd")
3200 (uri (list (string-append "https://imperialat.at/releases/"
3201 "libopensmtpd-" version ".tar.gz")
3202 (string-append "https://distfiles.sigtrap.nl/"
3203 "libopensmtpd-" version ".tar.gz")))
3205 (base32 "04x610mvwba7m0n9h0wbnsw58rb4khq44fm4blkgjqvh3bhxbmnd"))))
3206 (build-system gnu-build-system)
3209 (list "-f" "Makefile.gnu"
3210 (string-append "CC=" ,(cc-for-target))
3211 (string-append "LOCALBASE=" (assoc-ref %outputs "out")))
3212 #:tests? #f ; no test suite
3214 (modify-phases %standard-phases
3215 (add-after 'unpack 'inherit-ownership
3217 (substitute* "Makefile.gnu"
3218 (("-o \\$\\{...OWN\\} -g \\$\\{...GRP\\}") ""))))
3219 (delete 'configure)))) ; no configure script
3221 `(("mandoc" ,mandoc))) ; silently installs empty man page without
3223 `(("libevent" ,libevent)))
3224 (home-page "https://imperialat.at/dev/libopensmtpd/")
3225 (synopsis "OpenSMTPd filter C API")
3227 "The @code{osmtpd} API is an event-based C programming interface for
3228 writing OpenSMTPd filters.")
3229 (license license:expat)))
3231 (define-public opensmtpd-filter-dkimsign
3233 (name "opensmtpd-filter-dkimsign")
3238 (uri (list (string-append "https://imperialat.at/releases/"
3239 "filter-dkimsign-" version ".tar.gz")
3240 (string-append "https://distfiles.sigtrap.nl/"
3241 "filter-dkimsign-" version ".tar.gz")))
3243 (base32 "0jwp47ixibnz8rghn193bk2hxh1j1zfrnidml18j7d7cylxfrd55"))))
3244 (build-system gnu-build-system)
3247 (list "-f" "Makefile.gnu"
3248 (string-append "CC=" ,(cc-for-target))
3249 "HAVE_ED25519=yep-but-is-openssl-only"
3250 (string-append "LOCALBASE=" (assoc-ref %outputs "out")))
3251 #:tests? #f ; no test suite
3253 (modify-phases %standard-phases
3254 (add-after 'unpack 'patch-Makefile.gnu
3256 (substitute* "Makefile.gnu"
3257 (("pkg-config") ,(pkg-config-for-target))
3258 (("-o \\$\\{...OWN\\} -g \\$\\{...GRP\\}") ""))))
3259 (delete 'configure)))) ; no configure script
3261 `(("mandoc" ,mandoc))) ; silently installs empty man page without
3263 `(("libevent" ,libevent)
3264 ("libopensmtpd" ,libopensmtpd)
3265 ;; XXX Our OpenSMTPd package uses libressl, but this package currently
3266 ;; supports HAVE_ED25519 only with openssl. Switch back when possible.
3267 ("openssl" ,openssl)))
3268 (home-page "http://imperialat.at/dev/filter-dkimsign/")
3269 (synopsis "OpenSMTPd filter for signing mail with DKIM")
3271 "The @command{filter-dkimsign} OpenSMTPd filter signs outgoing e-mail
3272 messages with @acronym{DKIM, DomainKeys Identified Mail} (RFC 4871).")
3273 (license license:expat)))
3275 (define-public opensmtpd-filter-rspamd
3277 (name "opensmtpd-filter-rspamd")
3282 (url "https://github.com/poolpOrg/filter-rspamd")
3283 (commit (string-append "v" version))))
3285 (base32 "1qhrw20q9y44ffgx5k14nvqc9dh47ihywgzza84g0zv9xgif7hd5"))
3286 (file-name (git-file-name name version))))
3287 (build-system go-build-system)
3289 `(#:import-path "github.com/poolpOrg/filter-rspamd"
3291 (modify-phases %standard-phases
3292 (add-before 'build 'set-bootstrap-variables
3293 (lambda* (#:key outputs inputs #:allow-other-keys)
3294 ;; Tell the build system where to install binaries
3295 (let* ((out (assoc-ref outputs "out"))
3296 (libexec (string-append out "/libexec/opensmtpd")))
3297 (setenv "GOBIN" libexec)))))))
3299 `(("opensmtpd" ,opensmtpd)))
3300 (home-page "https://github.com/poolpOrg/filter-rspamd")
3301 (synopsis "OpenSMTPd filter to request an Rspamd analysis")
3303 "The @command{filter-rspamd} OpenSMTPd filter implements the
3304 Rspamd protocol and allows OpenSMTPd to request an Rspamd analysis of
3305 an SMTP transaction before a message is committed to queue.")
3306 (license license:isc)))
3308 (define-public mailman
3315 (uri (pypi-uri "mailman" version))
3317 (base32 "0a5ckbf8hc3y28b7p5psp0d4bxk601jlr5pd3hhh545xd8d9f0dg"))))
3318 (build-system python-build-system)
3320 `(("gunicorn" ,gunicorn)
3321 ("python-aiosmtpd" ,python-aiosmtpd)
3322 ("python-alembic" ,python-alembic)
3323 ("python-atpublic" ,python-atpublic)
3324 ("python-authheaders" ,python-authheaders)
3325 ("python-authres" ,python-authres)
3326 ("python-click" ,python-click)
3327 ("python-dateutil" ,python-dateutil)
3328 ("python-dnspython" ,python-dnspython)
3329 ("python-falcon" ,python-falcon)
3330 ("python-flufl-bounce" ,python-flufl-bounce)
3331 ("python-flufl-i18n" ,python-flufl-i18n)
3332 ("python-flufl-lock" ,python-flufl-lock)
3333 ("python-importlib-resources" ,python-importlib-resources)
3334 ("python-lazr-config" ,python-lazr-config)
3335 ("python-passlib" ,python-passlib)
3336 ("python-requests" ,python-requests)
3337 ("python-sqlalchemy" ,python-sqlalchemy)
3338 ("python-zope-component" ,python-zope-component)
3339 ("python-zope-configuration" ,python-zope-configuration)
3340 ("python-zope-event" ,python-zope-event)
3341 ("python-zope-interface" ,python-zope-interface)))
3343 `(("python-nose" ,python-nose)))
3344 (home-page "https://www.list.org")
3345 (synopsis "Mailing list manager")
3347 "GNU Mailman is software for managing email discussion and mailing
3348 lists. Both users and administrators generally perform their actions in a
3349 web interface, although email and command-line interfaces are also provided.
3350 The system features built-in archiving, automatic bounce processing, content
3351 filtering, digest delivery, and more.")
3352 (license license:gpl3+)))
3354 (define-public python-mailmanclient
3356 (name "python-mailmanclient")
3361 (uri (pypi-uri "mailmanclient" version))
3364 "0pjgzpvhdb6ql8asb20xr8d01m646zpghmcp9fmscks0n1k4di4g"))))
3365 (build-system python-build-system)
3367 `(#:tests? #f)) ; Requires mailman running
3369 `(("python-requests" ,python-requests)))
3371 ; `(("mailman" ,mailman)
3372 ; ("python-falcon" ,python-falcon)
3373 ; ("python-pytest" ,python-pytest)
3374 ; ("python-pytest-services" ,python-pytest-services)))
3375 (home-page "https://www.list.org/")
3376 (synopsis "Python bindings for the Mailman 3 REST API")
3378 "The mailmanclient library provides official Python bindings for
3379 the GNU Mailman 3 REST API.")
3380 (properties `((python2-variant . ,(delay python2-mailmanclient))))
3381 (license license:lgpl3+)))
3383 ;; This is the last version which supports Python-2.
3384 (define-public python2-mailmanclient
3385 (let ((base (package-with-python2
3386 (strip-python2-variant python-mailmanclient))))
3393 (uri (pypi-uri "mailmanclient" version))
3396 "0fdfs5g3pf30v2i7w18pdkv9xnfxmfcv66mzv56dck0a1igq07m3"))))
3398 `(("python2-six" ,python2-six)
3399 ("python2-httplib2" ,python2-httplib2))))))
3401 (define-public mlmmj
3408 (uri (string-append "http://mlmmj.org/releases/mlmmj-"
3409 version ".tar.bz2"))
3412 "0hpj10qad821ci11si8xc2qnmkzfn90y13s43fm4fca38f0qjp8w"))))
3413 (build-system gnu-build-system)
3415 `(("perl" ,perl))) ; For "contrib/web/"
3417 `(("pkg-config" ,pkg-config)))
3420 ;; mlmmj-receive-strip is a replacement for mlmmj-receive
3421 ;; It opens the files control/mimedeny and control/mimestrip to get a list
3422 ;; of mimetypes for parts of multipart/mime messages that should be denied
3423 ;; or stripped. The parts then get stripped directly when the mail is
3424 ;; received. mlmmj-receive-strip also appends an extra header
3425 ;; X-ThisMailContainsUnwantedMimeParts: Y when the mail contains unwanted
3427 (list "--enable-receive-strip")
3429 (modify-phases %standard-phases
3430 (add-before 'install 'install-contrib
3431 (lambda* (#:key outputs #:allow-other-keys)
3432 (let* ((out (assoc-ref outputs "out"))
3433 (share (string-append out "/share/mlmmj"))
3434 (contrib (string-append share "/contrib/web"))
3435 (texts (string-append share "/listtexts")))
3436 (copy-recursively "contrib/web/" contrib)
3437 (copy-recursively "listtexts" texts)
3438 (rename-file texts (string-append share "/texts"))
3440 (home-page "http://mlmmj.org")
3441 (synopsis "Mailing list managing made joyful")
3443 "Mlmmj is a simple and slim mailing list manager (MLM) inspired by ezmlm.
3444 It works with many different Mail Transport Agents (MTAs) and is simple for a
3445 system administrator to install, configure and integrate with other software.
3446 As it uses very few resources, and requires no daemons, it is ideal for
3447 installation on systems where resources are limited. Its features include:
3449 @item Archive, Custom headers / footer,
3450 @item Fully automated bounce handling (similar to ezmlm),
3451 @item Complete requeueing functionality, Moderation functionality, Subject prefix,
3452 @item Subscribers only posting, Regular expression access control,
3453 @item Functionality to retrieve old posts, Web interface, Digests,
3454 @item No-mail subscription, VERP support,
3455 @item Delivery Status Notification (RFC1891) support,
3456 @item Rich and customisable texts for automated operations.
3458 (license license:expat)))
3460 (define-public python-django-mailman3
3462 (name "python-django-mailman3")
3467 (uri (pypi-uri "django-mailman3" version))
3470 "1yrm7wpjy34xai72vn2vkhc9131cdrbqy08rrabf36kynj5vcdvy"))))
3471 (build-system python-build-system)
3474 (modify-phases %standard-phases
3477 (setenv "DJANGO_SETTINGS_MODULE"
3478 "django_mailman3.tests.settings_test")
3479 (invoke "django-admin" "test"
3480 "--pythonpath=."))))))
3482 `(("python-django" ,python-django)
3483 ("python-django-allauth" ,python-django-allauth)
3484 ("python-django-gravatar2" ,python-django-gravatar2)
3485 ("python-mailmanclient" ,python-mailmanclient)
3486 ("python-pytz" ,python-pytz)))
3488 `(("python-mock" ,python-mock)))
3489 (home-page "https://gitlab.com/mailman/django-mailman3")
3490 (synopsis "Django library to help interaction with Mailman")
3492 "This package contains libraries and templates for Django-based interfaces
3493 interacting with Mailman.")
3494 (license license:gpl3+)))
3496 (define-public python-mailman-hyperkitty
3498 (name "python-mailman-hyperkitty")
3503 (uri (pypi-uri "mailman-hyperkitty" version))
3506 "1lfqa9admhvdv71f528jmz2wl0i5cv77v6l64px2pm4zqr9ckkjx"))
3510 ;; see: https://gitlab.com/mailman/mailman-hyperkitty/issues/17
3511 ;; fixes test_archive_message_unserializable
3513 (uri "https://salsa.debian.org/mailman-team/mailman-hyperkitty/raw/debian/1.1.0-9/debian/patches/0002-Skip-the-test_archive_message_unserializable.patch")
3516 "0p1fwm46c4bl81lvsg3kjhn2r1lwgkpgxamb3xyqn7h9qdrw10hw")))))))
3517 (build-system python-build-system)
3519 `(("python-requests" ,python-requests)
3520 ("python-zope-interface" ,python-zope-interface)))
3522 `(("mailman" ,mailman)))
3524 `(("python-mock" ,python-mock)
3525 ("python-nose" ,python-nose)
3526 ("python-nose2" ,python-nose2)))
3527 (home-page "https://gitlab.com/mailman/mailman-hyperkitty/")
3528 (synopsis "Mailman archiver plugin for HyperKitty")
3530 "Mailman3 allows emails sent to its mailing lists to be archived by any
3531 software provided that there is a plugin (loadable by Mailman3) designed to
3532 communicate with it properly. This module contains a Mailman3 archiver plugin
3533 which sends emails to HyperKitty, the official Mailman3 web archiver.")
3534 (license license:gpl3+)))
3536 (define-public python-hyperkitty
3538 (name "python-hyperkitty")
3543 (uri (pypi-uri "HyperKitty" version))
3546 "0p85r9q6mn5as5b39xp9hkkipnk0156acx540n2ygk3qb3jd4a5n"))))
3547 (build-system python-build-system)
3550 (modify-phases %standard-phases
3553 (invoke "example_project/manage.py" "test"
3554 "--settings=hyperkitty.tests.settings_test"))))))
3556 `(("python-dateutil" ,python-dateutil)
3557 ("python-django" ,python-django-2.2)
3558 ("python-django-compressor" ,python-django-compressor)
3559 ("python-django-extensions" ,python-django-extensions)
3560 ("python-django-gravatar2" ,python-django-gravatar2)
3561 ("python-django-haystack" ,python-django-haystack)
3562 ("python-django-mailman3" ,python-django-mailman3)
3563 ("python-django-q" ,python-django-q)
3564 ("python-djangorestframework" ,python-djangorestframework)
3565 ("python-flufl-lock" ,python-flufl-lock)
3566 ("python-mailmanclient" ,python-mailmanclient)
3567 ("python-networkx" ,python-networkx)
3568 ("python-pytz" ,python-pytz)
3569 ("python-robot-detection" ,python-robot-detection)))
3571 `(("python-beautifulsoup4" ,python-beautifulsoup4)
3572 ("python-elasticsearch" ,python-elasticsearch)
3573 ("python-isort" ,python-isort)
3574 ("python-mock" ,python-mock)
3575 ("python-whoosh" ,python-whoosh)))
3576 (home-page "https://gitlab.com/mailman/hyperkitty")
3577 (synopsis "Web interface to access GNU Mailman v3 archives")
3579 "The hyperkitty Django app provides a web user interface to access GNU
3580 Mailman3 archives, and manage it. This interface uses django, and requires
3581 some configuration.")
3582 (license license:gpl3))) ; Some files are gpl2+
3584 (define-public postorius
3591 (uri (pypi-uri "postorius" version))
3594 "08jn23gblbkfl09qlykbpsmp39mmach3sl69h1j5cd5kkx839rwa"))))
3595 (build-system python-build-system)
3598 (modify-phases %standard-phases
3600 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
3601 (add-installed-pythonpath inputs outputs)
3603 (invoke "python" "example_project/manage.py" "test"
3604 "--settings=test_settings" "postorius")
3606 #:tests? #f)) ; Tests try to run a mailman instance to test against.
3608 `(("python-django" ,python-django)
3609 ("python-django-mailman3" ,python-django-mailman3)
3610 ("python-mailmanclient" ,python-mailmanclient)
3611 ("python-readme-renderer" ,python-readme-renderer)))
3613 `(("python-beautifulsoup4" ,python-beautifulsoup4)
3614 ("python-isort" ,python-isort)
3615 ("python-mock" ,python-mock)
3616 ("python-vcrpy" ,python-vcrpy)))
3617 (home-page "https://gitlab.com/mailman/postorius")
3618 (synopsis "Web user interface for GNU Mailman")
3620 "Postorius is a Django app which provides a web user interface
3621 to access GNU Mailman.")
3622 (license (list license:gpl3+ license:lgpl3+))))
3624 (define-public blists
3631 (uri (string-append "http://download.openwall.net/pub/projects/"
3632 "blists/blists-" version ".tar.gz"))
3635 "1xll5wn7py3bbncbwrj172f56nz75c9gwfsa80rwd96ss9gfmp3c"))))
3636 (build-system gnu-build-system)
3638 `(#:tests? #f ; No tests
3640 (modify-phases %standard-phases
3643 (lambda* (#:key outputs #:allow-other-keys)
3644 (let* ((out (assoc-ref outputs "out"))
3645 (bin (string-append out "/bin")))
3646 (install-file "bindex" bin)
3647 (install-file "bit" bin)
3649 (home-page "http://www.openwall.com/blists/")
3650 (synopsis "Web interface to mailing list archives")
3652 "Blists is a web interface to mailing list archives that works off
3653 indexed mbox files. There are two programs: @code{bindex} and @code{bit}.
3654 @code{bindex} generates or updates the index file (incremental updates
3655 are supported). @code{bit} is a CGI/SSI program that generates web pages
3656 on the fly. Both programs are written in C and are very fast.")
3657 (license license:expat)))
3659 (define-public swaks
3662 (version "20201014.0")
3667 (url "https://github.com/jetmore/swaks")
3668 (commit (string-append "v" version))))
3669 (file-name (git-file-name name version))
3671 (base32 "131i2b1yxhnbqkfk4kky40pfanqw2c5lcgbnjhfqp5cvpawpk2ai"))))
3672 (build-system perl-build-system)
3674 `(("perl-io-socket-inet6" ,perl-io-socket-inet6)
3675 ("perl-net-dns" ,perl-net-dns)
3676 ("perl-net-ssleay" ,perl-net-ssleay)
3677 ("perl-socket6" ,perl-socket6))) ; used by perl-io-socket-inet6
3679 `(#:tests? #f ; no tests
3681 (modify-phases %standard-phases
3682 (add-after 'unpack 'set-build_version
3684 (substitute* "swaks"
3685 (("\"DEVRELEASE\"") (format #f "\"~a\"" ,version)))
3690 (invoke "pod2man" "doc/base.pod" "swaks.1")))
3692 (lambda* (#:key outputs #:allow-other-keys)
3693 (let ((out (assoc-ref outputs "out")))
3694 (install-file "swaks" (string-append out "/bin"))
3695 (install-file "swaks.1" (string-append out "/share/man/man1")))
3697 (add-after 'install 'wrap-program
3698 (lambda* (#:key outputs #:allow-other-keys)
3699 (wrap-program (string-append (assoc-ref outputs "out")
3701 `("PERL5LIB" ":" = (,(getenv "PERL5LIB"))))
3703 (home-page "https://jetmore.org/john/code/swaks/")
3704 (synopsis "Featureful SMTP test tool")
3705 (description "Swaks is a flexible, scriptable, transaction-oriented SMTP
3706 test tool. It handles SMTP features and extensions such as TLS,
3707 authentication, and pipelining; multiple versions of the SMTP protocol
3708 including SMTP, ESMTP, and LMTP; and multiple transport methods including
3709 unix-domain sockets, internet-domain sockets, and pipes to spawned processes.
3710 Options can be specified in environment variables, configuration files, and
3711 the command line allowing maximum configurability and ease of use for
3712 operators and scripters.")
3713 (license license:gpl2+)))
3715 (define-public alpine
3722 ;; There are two versions: the plain continuation of Alpine without extra
3723 ;; patches and the version which adds extra fixes. Every distro uses
3724 ;; the patched version, and so do we to not break expectations.
3725 ;; http://alpine.freeiz.com/alpine/readme/README.patches
3727 (url "http://repo.or.cz/alpine.git")
3728 (commit (string-append "v" version))))
3729 (file-name (git-file-name name version))
3731 (base32 "0ibwss04j4qbhpd3jcw3d4xjf8jnmb9fi3sz58a99xw3awkfjabd"))
3732 (modules '((guix build utils)))
3735 ;; Remove pre-built binaries scattered across the source repository.
3736 (for-each delete-file (find-files "." "\\.(dll|exe)"))
3738 (build-system gnu-build-system)
3741 (list (string-append "CC=" ,(cc-for-target)))
3742 #:configure-flags (list (string-append "--with-ssl-include-dir="
3743 (assoc-ref %build-inputs "openssl")
3745 (string-append "--with-ssl-dir="
3746 (assoc-ref %build-inputs "openssl"))
3747 (string-append "--with-ssl-certs-dir="
3749 (string-append "--with-ssl-lib-dir="
3750 (assoc-ref %build-inputs "openssl")
3752 (string-append "--with-interactive-spellcheck="
3753 (assoc-ref %build-inputs "aspell")
3755 "--with-date-stamp=Thu 1 Jan 01:00:01 CET 1970")
3757 (modify-phases %standard-phases
3758 (add-after 'unpack 'assume-shadow-passwords
3759 ;; Alpine's configure script confuses ‘shadow password support’ with
3760 ;; ‘/etc/shadow exists in the build environment’. It does not.
3762 (substitute* "configure"
3763 (("test -f /etc/shadow") "true"))
3765 (add-after 'unpack 'make-reproducible
3767 ;; This removes time-dependent code to make alpine reproducible.
3768 (substitute* "pico/blddate.c"
3769 (("%02d-%s-%d") "1970-01-01"))
3772 `(("ncurses" ,ncurses)
3773 ("openssl" ,openssl)
3775 ("openldap" ,openldap)
3776 ("cyrus-sasl" ,cyrus-sasl)
3777 ("mit-krb5" ,mit-krb5)
3780 ("linux-pam" ,linux-pam)))
3781 (home-page "https://repo.or.cz/alpine.git")
3782 (synopsis "Alternatively Licensed Program for Internet News and Email")
3784 "Alpine is a text-based mail and news client. Alpine includes several
3785 tools and applications:
3787 @item alpine, the Alpine mailer
3788 @item pico, the standalone text editor, GNU nano's predecessor
3789 @item pilot, the standalone file system navigator
3791 (license license:asl2.0)))
3793 (define-public balsa
3800 (uri (string-append "https://pawsa.fedorapeople.org/balsa/"
3801 "balsa-" version ".tar.xz"))
3803 (base32 "1m0x3rk7cp7slr47rmg4y91rbxgs652v706lyxj600m5r5v4bl6l"))))
3804 (build-system gnu-build-system)
3807 '(;; Balsa tries to install additional MIME icons
3808 ;; under gtk+ directory.
3809 "--enable-extra-mimeicons=no"
3810 "--with-gtksourceview"
3812 "--with-spell-checker=gtkspell"
3818 `(("cyrus-sasl" ,cyrus-sasl)
3819 ("enchant" ,enchant)
3820 ("gdk-pixbuf" ,gdk-pixbuf)
3825 ("gtksourceview" ,gtksourceview)
3826 ("gtkspell3" ,gtkspell3)
3827 ("libassuan" ,libassuan) ; in gpgme.pc Requires
3828 ("libcanberra" ,libcanberra)
3829 ("libesmtp" ,libesmtp)
3830 ("libical" ,libical)
3831 ("libnotify" ,libnotify)
3832 ("libsecret" ,libsecret)
3833 ("openldap" ,openldap)
3835 ("webkitgtk" ,webkitgtk)))
3837 `(("compface" ,compface)
3838 ("glib" ,glib "bin")
3839 ("intltool" ,intltool)
3840 ("pkg-config" ,pkg-config)
3841 ("yelp-tools" ,yelp-tools)))
3842 (home-page "https://pawsa.fedorapeople.org/balsa")
3843 (synopsis "E-mail client for GNOME")
3844 (description "Balsa is a highly configurable and robust mail client for
3845 the GNOME desktop. It supports both POP3 and IMAP servers as well as the
3846 mbox, maildir and mh local mailbox formats. Balsa also supports SMTP and/or
3847 the use of a local MTA such as Sendmail.")
3848 (license license:gpl3+)))
3857 (uri (pypi-uri "afew" version))
3860 "0wpfqbqjlfb9z0hafvdhkm7qw56cr9kfy6n8vb0q42dwlghpz1ff"))))
3861 (build-system python-build-system)
3863 `(("notmuch" ,notmuch)
3864 ("python-chardet" ,python-chardet)
3865 ("python-dkimpy" ,python-dkimpy)
3866 ("python-notmuch" ,python-notmuch)))
3868 `(("python-freezegun" ,python-freezegun)
3869 ("python-setuptools-scm" ,python-setuptools-scm)))
3870 (home-page "https://github.com/afewmail/afew")
3871 (synopsis "Initial tagging script for notmuch mail")
3872 (description "afew is an initial tagging script for notmuch mail. It
3873 provides automatic tagging each time new mail is registered with notmuch. It
3874 can add tags based on email headers or Maildir folders and can handle spam and
3876 (license license:isc)))
3885 (uri (string-append "http://pan.rebelbase.com/download/releases/"
3886 version "/source/" name "-" version ".tar.bz2"))
3888 (base32 "17agd27sn4a7nahvkpg0w39kv74njgdrrygs74bbvpaj8rk2hb55"))))
3890 `(#:configure-flags '("--with-gtk3" "--with-gtkspell" "--with-gnutls"
3891 "--enable-libnotify" "--enable-manual"
3894 (modify-phases %standard-phases
3895 (add-before 'configure 'patch-gpg2
3896 (lambda* (#:key inputs #:allow-other-keys)
3897 (substitute* "pan/usenet-utils/gpg.cc"
3898 (("\"gpg2\"") (string-append "\""
3899 (assoc-ref inputs "gnupg")
3903 `(("gmime" ,gmime-2.6)
3907 ("gtkspell3" ,gtkspell3)
3908 ("libnotify" ,libnotify)
3909 ("libsecret" ,libsecret)
3910 ("libxml2" ,libxml2)
3913 `(("gettext-minimal" ,gettext-minimal)
3914 ("itstool" ,itstool)
3915 ("pkg-config" ,pkg-config)))
3916 (build-system gnu-build-system)
3917 (home-page "http://pan.rebelbase.com/")
3918 (synopsis "Pan newsreader")
3919 (description "@code{pan} is a Usenet newsreader that's good at both text
3920 and binaries. It supports offline reading, scoring and killfiles, yEnc, NZB,
3921 PGP handling, multiple servers, and secure connections.")
3922 ;; License of the docs: fdl-1.1; Others: gpl2.
3923 (license (list license:fdl1.1+ license:gpl2))))
3925 (define-public imapfilter
3933 (url "https://github.com/lefcha/imapfilter")
3934 (commit (string-append "v" version))))
3935 (file-name (git-file-name name version))
3937 (base32 "0a7f85r3axwclzw1s79zl2l8222nj2gklvvq33w9qv0dz5n71dcx"))))
3938 (build-system gnu-build-system)
3942 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
3943 (string-append "CC=" ,(cc-for-target)))
3945 (modify-phases %standard-phases
3946 (delete 'configure)))) ; no configure script
3950 ("openssl" ,openssl)))
3951 (home-page "https://github.com/lefcha/imapfilter")
3952 (synopsis "IMAP mail filtering utility")
3953 (description "IMAPFilter is a mail filtering utility. It connects
3954 to remote mail servers using IMAP, sends searching queries to the server and
3955 processes mailboxes based on the results. It can be used to delete, copy,
3956 move, flag, etc. messages residing in mailboxes at the same or different mail
3957 servers. The 4rev1 and 4 versions of IMAP are supported.")
3958 (license license:expat)))
3960 (define-public urlscan
3967 (uri (pypi-uri "urlscan" version))
3969 (base32 "09lxi7dhn49fpb3ij4cgrhj3qqqqs9rcxbjb7p9smw5wblrqpzga"))))
3970 (build-system python-build-system)
3972 `(("python-urwid" ,python-urwid)))
3973 (home-page "https://github.com/firecat53/urlscan")
3974 (synopsis "View/select the URLs in an email message or file")
3976 "Urlscan is a small program that is designed to integrate with the
3977 Mutt mail reader to allow you to easily launch a Web browser for URLs
3978 contained in email messages. It parses an email message or file and scans it
3979 for URLs and email addresses. It then displays the URLs and their context
3980 within the message, and allows you to choose one or more URLs to send to your
3981 Web browser. Alternatively, it send a list of all URLs to standard output.
3982 It is a replacement for the @command{urlview} program.")
3983 (license license:gpl2)))
3993 (url "https://github.com/verdammelt/tnef")
3996 (base32 "104g48mcm00bgiyzas2vf86331w7bnw7h3bc11ib4lp7rz6zqfck"))
3997 (file-name (git-file-name name version))))
3998 (build-system gnu-build-system)
4000 `(("autoconf" ,autoconf)
4001 ("automake" ,automake)))
4002 (arguments `(#:parallel-tests? #f)) ;tests are side-effect'y
4003 (home-page "https://github.com/verdammelt/tnef")
4004 (synopsis "Unpack @code{application/ms-tnef} attachments")
4006 "TNEF is a tar-like program that unpacks MIME attachments of type
4007 @code{application/ms-tnef}.")
4008 (license license:gpl2+)))
4011 (let ((commit "9f070bd90adc67064cd8aff4e40f303d5957ef4a")
4015 (version (git-version "0.0.1" revision commit))
4019 (url "https://git.elephly.net/software/mumi.git")
4021 (file-name (git-file-name name version))
4024 "1ym1j3nzy8qhd1ydadccbgm0nckkmnq3vnz9qh9x8rasx7zg1ldp"))))
4025 (build-system gnu-build-system)
4027 `(#:modules ((guix build gnu-build-system)
4028 ((guix build guile-build-system)
4029 #:select (target-guile-effective-version))
4031 #:imported-modules ((guix build guile-build-system)
4032 ,@%gnu-build-system-modules)
4034 #:configure-flags '("--localstatedir=/var")
4037 (modify-phases %standard-phases
4038 (add-after 'install 'wrap-executable
4039 (lambda* (#:key outputs #:allow-other-keys)
4040 (let* ((out (assoc-ref outputs "out"))
4041 (bin (string-append out "/bin"))
4042 (version (target-guile-effective-version))
4043 (scm (string-append out "/share/guile/site/" version))
4044 (go (string-append out "/lib/guile/" version
4046 (wrap-program (string-append bin "/mumi")
4047 `("GUILE_LOAD_PATH" ":" prefix
4048 (,scm ,(getenv "GUILE_LOAD_PATH")))
4049 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
4050 (,go ,(getenv "GUILE_LOAD_COMPILED_PATH"))))
4053 `(("guile-email" ,guile-email-latest)
4054 ("guile-fibers" ,guile-fibers)
4055 ("guile-gcrypt" ,guile-gcrypt)
4056 ("guile-json" ,guile-json-3)
4057 ("guile-redis" ,guile-redis)
4058 ("guile-syntax-highlight" ,guile-syntax-highlight)
4059 ("guile-webutils" ,guile-webutils)
4060 ("guile-xapian" ,guile-xapian)
4061 ("guile" ,guile-3.0)
4062 ("mailutils" ,mailutils)))
4064 `(("autoconf" ,autoconf)
4065 ("automake" ,automake)
4066 ("pkg-config" ,pkg-config)))
4067 (home-page "https://git.elephly.net/software/mumi.git")
4068 (synopsis "Debbugs web interface")
4069 (description "Mumi is a Debbugs web interface.")
4070 (license license:agpl3+))))
4072 (define-public ytnef
4079 (url "https://github.com/Yeraze/ytnef")
4080 (commit (string-append "v" version))))
4081 (file-name (git-file-name name version))
4084 "07h48s5qf08503pp9kafqbwipdqghiif22ghki7z8j67gyp04l6l"))
4085 (patches (search-patches "ytnef-CVE-2021-3403.patch"
4086 "ytnef-CVE-2021-3404.patch"))))
4087 (build-system gnu-build-system)
4089 `(("autoconf" ,autoconf)
4090 ("automake" ,automake)
4091 ("libtool" ,libtool)))
4092 (home-page "https://github.com/Yeraze/ytnef/")
4093 (synopsis "TNEF stream reader for winmail.dat files")
4094 (description "This package provides a TNEF stream reader library and
4095 related tools to process winmail.dat files.")
4096 (license license:gpl2+)))
4099 ;; No official release.
4100 (let ((commit "f7286b49bb5fce25c898c143712fe34ad4d7864e")
4104 (version (git-version "0.1.0" revision commit))
4109 (url "https://git.kernel.org/pub/scm/linux/kernel/git/dborkman/l2md.git")
4111 (file-name (git-file-name name version))
4113 (base32 "0hxz8i70v1xgv30zjclfvmjqszn073c7i8nwmswi2lr6vd7cklvp"))))
4114 (build-system gnu-build-system)
4116 `(("libgit2" ,libgit2)))
4119 (modify-phases %standard-phases
4120 (delete 'configure) ;no configure scripts
4121 (delete 'check) ;no tests
4122 (add-before 'install 'mkdir
4123 (lambda* (#:key outputs #:allow-other-keys)
4124 (let ((l2md (string-append (assoc-ref outputs "out") "/bin")))
4127 (list ,(string-append "CC=" (cc-for-target))
4128 (string-append "PREFIX=" %output "/bin"))))
4130 "https://git.kernel.org/pub/scm/linux/kernel/git/dborkman/l2md.git")
4131 (synopsis "Import public-inbox archives via Git")
4133 "The @command{l2md} command line tool imports public-inbox archives via
4134 Git and exports them in maildir format or to an MDA through a pipe.")
4135 (license license:gpl2))))
4137 (define-public public-inbox
4139 (name "public-inbox")
4142 (origin (method git-fetch)
4144 (url "https://public-inbox.org")
4145 (commit (string-append "v" version))))
4148 "0mlwnp5knr7rk9kv8grlh342wsq2193m22zs83cjn9p7x9r2x5f9"))
4149 (file-name (git-file-name name version))))
4150 (build-system perl-build-system)
4153 (modify-phases %standard-phases
4154 (add-before 'configure 'qualify-paths
4156 ;; Use absolute paths for 'xapian-compact'.
4157 (let ((xapian-compact (which "xapian-compact")))
4158 (substitute* "script/public-inbox-compact"
4159 (("xapian-compact") xapian-compact)))
4161 (add-before 'check 'pre-check
4163 (substitute* "t/spawn.t"
4164 (("\\['env'\\]") (string-append "['" (which "env") "']")))
4165 (substitute* "t/ds-leak.t"
4166 (("/bin/sh") (which "sh")))
4167 (invoke "./certs/create-certs.perl")
4168 ;; XXX: This test fails due to zombie process is not reaped by
4170 (substitute* "t/httpd-unix.t"
4171 (("^SKIP: \\{") "SKIP: { skip('Guix');"))
4173 (add-after 'install 'wrap-programs
4174 (lambda* (#:key inputs outputs #:allow-other-keys)
4175 (let ((out (assoc-ref outputs "out")))
4179 ;; Let those scripts find their perl modules.
4180 `("PERL5LIB" ":" prefix
4181 (,(string-append out "/lib/perl5/site_perl")
4182 ,(getenv "PERL5LIB")))
4183 ;; 'git' is invoked in various files of the PublicInbox
4186 (,(dirname (search-input-file inputs "/bin/git"))))))
4187 (find-files (string-append out "/bin"))))
4190 `(("xapian" ,xapian)
4193 ("openssl" ,openssl)))
4196 ("perl-dbd-sqlite" ,perl-dbd-sqlite)
4197 ("perl-dbi" ,perl-dbi)
4198 ("perl-email-address-xs" ,perl-email-address-xs)
4199 ("perl-email-mime-contenttype" ,perl-email-mime-contenttype)
4200 ("perl-email-mime" ,perl-email-mime)
4201 ("perl-email-simple" ,perl-email-simple)
4202 ("perl-net-server" ,perl-net-server)
4203 ("perl-plack-middleware-deflater" ,perl-plack-middleware-deflater)
4204 ("perl-plack-middleware-reverseproxy" ,perl-plack-middleware-reverseproxy)
4205 ("perl-plack" ,perl-plack)
4206 ("perl-search-xapian" ,perl-search-xapian)
4207 ("perl-timedate" ,perl-timedate)
4208 ("perl-uri-escape" ,perl-uri-escape)
4209 ("perl-inline-c" ,perl-inline-c)
4210 ("perl-parse-recdescent" ,perl-parse-recdescent)
4211 ("perl-linux-inotify2" ,perl-linux-inotify2)
4212 ;; FIXME: Perl modules are unable to find the config file for highlight
4213 ;; https://issues.guix.gnu.org/48033#4
4214 ;; ("highlight" ,highlight)
4217 ("perl-ipc-run" ,perl-ipc-run)
4218 ("perl-xml-feed" ,perl-xml-feed)))
4219 (home-page "https://public-inbox.org/README.html")
4220 (synopsis "Archive mailing lists in Git repositories")
4222 "public-inbox implements the sharing of an email inbox via Git to
4223 complement or replace traditional mailing lists. Readers may read via NNTP,
4224 IMAP, Atom feeds or HTML archives.")
4225 (license license:agpl3+)))
4227 (define-public sylpheed
4233 (uri (string-append "https://sylpheed.sraoss.jp/sylpheed/v3.7/"
4234 name "-" version ".tar.xz"))
4237 "0j9y5vdzch251s264diw9clrn88dn20bqqkwfmis9l7m8vmwasqd"))))
4238 (build-system gnu-build-system)
4240 `(("pkg-config" ,pkg-config)))
4242 `(("bogofilter" ,bogofilter)
4243 ("compface" ,compface)
4246 ("gtk+-2.0" ,gtk+-2)
4247 ("gtkspell" ,gtkspell3)
4249 ("openldap" ,openldap)
4250 ("openssl" ,openssl)))
4251 (home-page "https://sylpheed.sraoss.jp/en/")
4252 (synopsis "Lightweight GTK+ email client")
4254 "Sylpheed is a simple, lightweight but featureful, and easy-to-use e-mail
4255 client. Sylpheed provides intuitive user-interface. Sylpheed is also
4256 designed for keyboard-oriented operation.")
4257 (license license:gpl2+)))
4259 (define-public python-authres
4261 (name "python-authres")
4266 (uri (pypi-uri "authres" version))
4269 "1dr5zpqnb54h4f5ax8334l1dcp8j9083d7v4vdi1xqkwmnavklck"))))
4270 (build-system python-build-system)
4273 (modify-phases %standard-phases
4275 ;; Run doctests as described in the README.
4277 (invoke "python" "-m" "authres" "-v"))))))
4278 (home-page "https://launchpad.net/authentication-results-python")
4279 (synopsis "Authentication-Results email header creator and parser")
4281 "This Python module can be used to generate and parse RFC 5451/7001/7601
4282 @code{Authentication-Results} email headers. It supports extensions such as:
4284 @item RFC 5617 DKIM/ADSP
4285 @item RFC 6008 DKIM signature identification (@code{header.b})
4286 @item RFC 6212 @acronym{VBR, Vouch By Reference}
4287 @item RFC 6577 @acronym{SPF, Sender Policy Framework}
4288 @item RFC 7281 @code{Authentication-Results} registration for S/MIME
4289 @item RFC 7293 The @code{Require-Recipient-Valid-Since} header field
4290 @item RFC 7489 @acronym{DMARC, Domain-based Message Authentication Reporting
4292 @item @acronym{ARC, Authenticated Received Chain}
4293 (draft-ietf-dmarc-arc-protocol-08)
4295 (license license:asl2.0)))
4297 (define-public python-dkimpy
4299 (name "python-dkimpy")
4304 (uri (pypi-uri "dkimpy" version))
4306 (base32 "088iz5cqjqh4c7141d94pvn13bh25aizqlrifwv6fs5g16zj094s"))))
4307 (build-system python-build-system)
4310 (modify-phases %standard-phases
4311 (add-after 'patch-source-shebangs 'patch-more-source
4312 (lambda* (#:key inputs #:allow-other-keys)
4313 (let ((openssl (assoc-ref inputs "openssl")))
4314 (substitute* "dkim/dknewkey.py"
4315 (("/usr/bin/openssl") (string-append openssl "/bin/openssl"))))
4319 (invoke "python" "test.py"))))))
4321 `(("python-dnspython" ,python-dnspython)))
4323 `(("python-authres" ,python-authres)
4324 ("python-pynacl" ,python-pynacl)))
4326 `(("openssl" ,openssl)))
4327 (home-page "https://launchpad.net/dkimpy")
4328 (synopsis "DKIM (DomainKeys Identified Mail)")
4329 (description "Python module that implements @dfn{DKIM} (DomainKeys
4330 Identified Mail) email signing and verification (RFC6376). It also provides
4331 helper scripts for command line signing and verification. It supports DKIM
4332 signing/verifying of ed25519-sha256 signatures (RFC 8463). It also supports
4333 the RFC 8617 Authenticated Received Chain (ARC) protocol.")
4334 (license license:bsd-3)))
4336 (define-public python-authheaders
4338 (name "python-authheaders")
4343 (uri (pypi-uri "authheaders" version))
4346 "14k6i72k5f8dyvps8vc0aq0cczc8lvqpgjfjzsy6qqychjvjcmwk"))))
4347 (build-system python-build-system)
4349 `(("python-authres" ,python-authres)
4350 ("python-dkimpy" ,python-dkimpy)
4351 ("python-dnspython" ,python-dnspython)
4352 ("python-publicsuffix2" ,python-publicsuffix2)))
4353 (home-page "https://github.com/ValiMail/authentication-headers")
4354 (synopsis "Library wrapping email authentication header verification and generation")
4356 "This is a Python library for the generation of email authentication
4357 headers. The library can perform DKIM, SPF, and DMARC validation, and the
4358 results are packaged into the Authentication-Results header. The library can
4359 DKIM and ARC sign messages and output the corresponding signature headers.")
4360 ;; The package's metadata claims it were MIT licensed, but the source file
4361 ;; headers disagree. MPL-2 for the public suffix list.
4362 (license (list license:zpl2.1 license:zlib license:mpl2.0))))
4364 (define-public python-aiosmtpd
4366 (name "python-aiosmtpd")
4372 (url "https://github.com/aio-libs/aiosmtpd")
4375 (base32 "0083d6nf75xv8nq1il6jabz36v6c452svy4p402csxwwih5pw6sk"))
4376 (file-name (git-file-name name version))))
4377 (build-system python-build-system)
4380 (modify-phases %standard-phases
4381 (add-after 'unpack 'delete-failing-tests
4383 ;; This test uses an expired certificate.
4384 (delete-file "aiosmtpd/tests/test_smtps.py")
4388 (invoke "python" "-m" "nose2" "-v"))))))
4390 `(("python-flufl-testing" ,python-flufl-testing)
4391 ("python-nose2" ,python-nose2)))
4393 `(("python-atpublic" ,python-atpublic)))
4394 (home-page "https://aiosmtpd.readthedocs.io/")
4395 (synopsis "Asyncio based SMTP server")
4397 "This project is a reimplementation of the Python stdlib @code{smtpd.py}
4399 (license (list license:asl2.0
4400 license:lgpl3)))) ; only for setup_helpers.py
4402 (define-public python-imaplib2
4404 (name "python-imaplib2")
4409 (uri (pypi-uri "imaplib2" version))
4412 "0nqyb274hq30agg1c0zkb5ijmcirgg35sp4dp4n292l665dlijwn"))))
4413 (build-system python-build-system)
4414 (home-page "https://github.com/jazzband/imaplib2/")
4415 (synopsis "Threaded Python IMAP4 client")
4416 (description "This package provides a threaded Python IMAP4 client, based
4417 on RFC 3501 and original @code{imaplib} module.")
4418 (license license:expat)))
4420 (define-public rspamd
4428 (url "https://github.com/rspamd/rspamd")
4431 (base32 "0fw6nbfc3xqapzq5nydakwgpw6cz6vb3qby2aqlr06lzf87d3hic"))
4432 (file-name (git-file-name name version))))
4433 (build-system cmake-build-system)
4435 '(#:configure-flags '("-DENABLE_LUAJIT=ON")))
4437 `(("openssl" ,openssl)
4447 ("libsodium" ,libsodium)))
4449 `(("pkg-config" ,pkg-config)))
4450 (synopsis "Spam filtering system")
4451 (description "Rspamd is an advanced spam filtering system that
4452 allows evaluation of messages by a number of rules including regular
4453 expressions, statistical analysis and custom services such as URL
4454 black lists. Each message is analysed by Rspamd and given a spam
4456 (home-page "https://www.rspamd.com/")
4457 (license license:asl2.0)))
4459 (define-public undbx
4465 (uri (string-append "mirror://sourceforge/undbx/undbx-"
4469 "0ncs1dzhrn9nlaxpyap2ipf61fc7k9bkkqacp3w6bngfj2c0p6yj"))))
4470 (build-system gnu-build-system)
4471 (home-page "https://undbx.sourceforge.io/")
4472 (synopsis "Extract email messages from Outlook Express .dbx files")
4473 (description "This package provides a tool to extract, recover and
4474 undelete email messages from Outlook Express .dbx files.")
4475 (license license:gpl3+)))
4477 (define-public libpst
4484 (uri (string-append "https://www.five-ten-sg.com/libpst/packages/"
4485 "libpst-" version ".tar.gz"))
4488 "0hhbbb8ddsgjhv9y1xd8s9ixlhdnjmhw12v06jwx4j6vpgp1na9x"))))
4489 (build-system gnu-build-system)
4496 `(("pkg-config" ,pkg-config)))
4497 (home-page "https://www.five-ten-sg.com/libpst/")
4499 (description "The Libpst utilities include @code{readpst} which can
4500 convert email messages to both mbox and MH mailbox formats, @code{pst2ldif}
4501 which can convert the contacts to @code{.ldif} format for import into LDAP
4502 databases, and other tools to process Outlook email archives.")
4503 (license license:gpl2+)))
4505 (define-public crm114
4508 (version "20100106")
4512 (uri (string-append "http://crm114.sourceforge.net/tarballs/crm114-"
4513 version "-BlameMichelson.src.tar.gz"))
4516 "0awcjc5j2mclkkpbjyijj9mv8xjz3haljvaj0fyc4fm4xir68qpv"))))
4517 (build-system gnu-build-system)
4519 `(#:modules ((guix build gnu-build-system)
4520 ((guix build emacs-build-system) #:prefix emacs:)
4523 #:imported-modules (,@%gnu-build-system-modules
4524 (guix build emacs-build-system)
4525 (guix build emacs-utils))
4526 #:make-flags (list (string-append "prefix=" %output)
4527 "LDFLAGS=") ; disable static linking
4528 ;; Test suite is not fully automated. It requires a human to read the
4529 ;; results and determine if the tests have passed.
4532 (modify-phases %standard-phases
4534 (add-before 'build 'fix-build
4536 ;; Inline functions can only be used from the same compilation
4537 ;; unit. This causes the build to fail.
4538 (substitute* "crm_svm_matrix.c"
4539 (("^inline ") ""))))
4540 (add-before 'install 'pre-install
4541 (lambda* (#:key outputs #:allow-other-keys)
4542 (let ((out (assoc-ref outputs "out")))
4543 ;; Install maillib.crm library.
4544 (install-file "maillib.crm" (string-append out "/share/crm"))
4545 ;; Set absolute store paths.
4546 (substitute* "mailreaver.crm"
4547 (("insert maillib.crm")
4548 (string-append "insert " out "/share/crm/maillib.crm"))
4549 (("\\\\/bin\\\\/ls")
4550 (string-replace-substring (which "ls") "/" "\\/"))
4551 ((":\\*:trainer_invoke_command:")
4552 (string-append out "/bin/mailtrainer.crm")))
4553 ;; Install mail related crm scripts.
4554 (for-each (lambda (file)
4555 (install-file file (string-append out "/bin")))
4556 (list "mailfilter.crm" "mailreaver.crm" "mailtrainer.crm")))))
4557 (add-after 'install 'install-emacs-mode
4558 (assoc-ref emacs:%standard-phases 'install))
4559 ;; Run phases from the emacs build system.
4560 (add-after 'install-emacs-mode 'make-autoloads
4561 (assoc-ref emacs:%standard-phases 'make-autoloads))
4562 (add-after 'make-autoloads 'enable-autoloads-compilation
4563 (assoc-ref emacs:%standard-phases 'enable-autoloads-compilation))
4564 (add-after 'enable-autoloads-compilation 'emacs-build
4565 (assoc-ref emacs:%standard-phases 'build))
4566 (add-after 'emacs-build 'validate-compiled-autoloads
4567 (assoc-ref emacs:%standard-phases 'validate-compiled-autoloads)))))
4571 `(("emacs" ,emacs-minimal)))
4572 (home-page "http://crm114.sourceforge.net/")
4573 (synopsis "Controllable regex mutilator")
4574 (description "CRM114 is a system to examine incoming e-mail, system log
4575 streams, data files or other data streams, and to sort, filter, or alter the
4576 incoming files or data streams according to the user's wildest desires.
4577 Criteria for categorization of data can be via a host of methods, including
4578 regexes, approximate regexes, a Hidden Markov Model, Orthogonal Sparse
4579 Bigrams, WINNOW, Correllation, KNN/Hyperspace, or Bit Entropy (or by other
4580 means--it's all programmable).")
4581 (license license:gpl3)))