1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2014, 2015, 2017 Mark H Weaver <mhw@netris.org>
4 ;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net>
5 ;;; Copyright © 2014 Sou Bunnbu <iyzsong@gmail.com>
6 ;;; Copyright © 2014 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 Eric Bavier <bavier@member.fsf.org>
10 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
11 ;;; Copyright © 2015, 2016, 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
12 ;;; Copyright © 2016 Christopher Allan Webber <cwebber@dustycloud.org>
13 ;;; Copyright © 2016 Al McElrath <hello@yrns.org>
14 ;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
15 ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org>
16 ;;; Copyright © 2016 Alex Kost <alezost@gmail.com>
17 ;;; Copyright © 2016, 2017 Troy Sankey <sankeytms@gmail.com>
18 ;;; Copyright © 2016, 2017, 2018 Nils Gillmann <ng0@n0.is>
19 ;;; Copyright © 2016 Clément Lassieur <clement@lassieur.org>
20 ;;; Copyright © 2016, 2017, 2018 Arun Isaac <arunisaac@systemreboot.net>
21 ;;; Copyright © 2016 John Darrington <jmd@gnu.org>
22 ;;; Copyright © 2016, 2018 Marius Bakke <mbakke@fastmail.com>
23 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
24 ;;; Copyright © 2017 Kyle Meyer <kyle@kyleam.com>
25 ;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
26 ;;; Copyright © 2017 Rene Saavedra <rennes@openmailbox.org>
27 ;;; Copyright © 2018 Pierre Langlois <pierre.langlois@gmx.com>
28 ;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
29 ;;; Copyright © 2018 Gábor Boskovits <boskovits@gmail.com>
31 ;;; This file is part of GNU Guix.
33 ;;; GNU Guix is free software; you can redistribute it and/or modify it
34 ;;; under the terms of the GNU General Public License as published by
35 ;;; the Free Software Foundation; either version 3 of the License, or (at
36 ;;; your option) any later version.
38 ;;; GNU Guix is distributed in the hope that it will be useful, but
39 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
40 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
41 ;;; GNU General Public License for more details.
43 ;;; You should have received a copy of the GNU General Public License
44 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
46 (define-module (gnu packages mail)
47 #:use-module (gnu packages)
48 #:use-module (gnu packages aspell)
49 #:use-module (gnu packages autotools)
50 #:use-module (gnu packages base)
51 #:use-module (gnu packages backup)
52 #:use-module (gnu packages bash)
53 #:use-module (gnu packages bison)
54 #:use-module (gnu packages calendar)
55 #:use-module (gnu packages check)
56 #:use-module (gnu packages crypto)
57 #:use-module (gnu packages curl)
58 #:use-module (gnu packages cyrus-sasl)
59 #:use-module (gnu packages databases)
60 #:use-module (gnu packages dejagnu)
61 #:use-module (gnu packages django)
62 #:use-module (gnu packages dns)
63 #:use-module (gnu packages documentation)
64 #:use-module (gnu packages emacs)
65 #:use-module (gnu packages enchant)
66 #:use-module (gnu packages ghostscript)
67 #:use-module (gnu packages gettext)
68 #:use-module (gnu packages glib)
69 #:use-module (gnu packages gnome)
70 #:use-module (gnu packages gnupg)
71 #:use-module (gnu packages groff)
72 #:use-module (gnu packages gsasl)
73 #:use-module (gnu packages gtk)
74 #:use-module (gnu packages guile)
75 #:use-module (gnu packages flex)
76 #:use-module (gnu packages kerberos)
77 #:use-module (gnu packages libcanberra)
78 #:use-module (gnu packages libevent)
79 #:use-module (gnu packages libidn)
80 #:use-module (gnu packages linux)
81 #:use-module (gnu packages lua)
82 #:use-module (gnu packages m4)
83 #:use-module (gnu packages ncurses)
84 #:use-module (gnu packages openldap)
85 #:use-module (gnu packages onc-rpc)
86 #:use-module (gnu packages pcre)
87 #:use-module (gnu packages perl)
88 #:use-module (gnu packages python)
89 #:use-module (gnu packages python-web)
90 #:use-module (gnu packages readline)
91 #:use-module (gnu packages search)
92 #:use-module (gnu packages texinfo)
93 #:use-module (gnu packages compression)
94 #:use-module (gnu packages glib)
95 #:use-module (gnu packages pkg-config)
96 #:use-module (gnu packages flex)
97 #:use-module (gnu packages gdb)
98 #:use-module (gnu packages man)
99 #:use-module (gnu packages ruby)
100 #:use-module (gnu packages samba)
101 #:use-module (gnu packages screen)
102 #:use-module (gnu packages tcl)
103 #:use-module (gnu packages time)
104 #:use-module (gnu packages tls)
105 #:use-module (gnu packages networking)
106 #:use-module (gnu packages web)
107 #:use-module (gnu packages webkit)
108 #:use-module (gnu packages w3m)
109 #:use-module (gnu packages xml)
110 #:use-module (gnu packages xorg)
111 #:use-module (gnu packages docbook)
112 #:use-module ((guix licenses)
113 #:select (fdl1.1+ gpl2 gpl2+ gpl3 gpl3+ lgpl2.1 lgpl2.1+ lgpl3+
114 non-copyleft (expat . license:expat) bsd-3
115 public-domain bsd-4 isc (openssl . license:openssl)
116 bsd-2 x11-style agpl3 asl2.0 perl-license))
117 #:use-module (guix packages)
118 #:use-module (guix download)
119 #:use-module (guix git-download)
120 #:use-module (guix utils)
121 #:use-module (guix build-system gnu)
122 #:use-module (guix build-system perl)
123 #:use-module (guix build-system python)
124 #:use-module (guix build-system trivial))
126 (define-public mailutils
132 (uri (string-append "mirror://gnu/mailutils/mailutils-"
136 "1dn71p85wlyisnwsb485sk3q5v393k3dizsa9fmimskdwjwgk3ch"))
138 (search-patches "mailutils-uninitialized-memory.patch"))
140 ;; For a rebuild of the Flex/Bison byproducts touched by the
143 (for-each delete-file
144 '("mh/mh_alias_lex.c"
145 "libmailutils/cfg/parser.c"))
147 (build-system gnu-build-system)
150 (modify-phases %standard-phases
151 (add-before 'check 'prepare-test-suite
153 ;; Use the right file name for `cat'.
154 (substitute* "testsuite/lib/mailutils.exp"
158 ;; Tests try to invoke 'maidag' such that it looks up the
159 ;; 'root' user, which does not exist in the build
161 (substitute* "maidag/tests/testsuite"
162 (("root <") "nobody <")
163 (("spool/root") "spool/nobody")
164 (("root@localhost") "nobody@localhost"))
166 ;; The 'pipeact.at' tests generate a shell script; make
167 ;; sure it uses the right shell.
168 (substitute* '("sieve/tests/testsuite"
169 "mh/tests/testsuite")
171 (string-append "#!" (which "sh"))))
173 (substitute* "mh/tests/testsuite"
174 (("moreproc: /bin/cat")
175 (string-append "moreproc: " (which "cat"))))
177 ;; XXX: The comsatd tests rely on being able to open
178 ;; /dev/tty, but that gives ENODEV in the build
179 ;; environment. Thus, ignore test failures here.
180 (substitute* "comsat/tests/Makefile.in"
181 (("\\$\\(SHELL\\) \\$\\(TESTSUITE\\)" all)
182 (string-append "-" all)))
184 ;; 'frm' tests expect write access to $HOME.
185 (setenv "HOME" (getcwd))
187 ;; Avoid the message "I'm going to create the standard MH path
188 ;; for you", which would lead to one test failure (when diffing
189 ;; stdout of 'fmtcheck'.)
190 (call-with-output-file ".mh_profile"
192 (format port "Path: ~a/Mail-for-tests~%"
196 ;; TODO: Add `--with-sql'.
197 #:configure-flags '("--sysconfdir=/etc")
198 #:parallel-tests? #f))
200 ;; Note: Bison and Flex needed due to
201 ;; 'mailutils-uninitialized-memory.patch'.
204 ("perl" ,perl))) ;for 'gylwrap'
206 `(("dejagnu" ,dejagnu)
212 ("readline" ,readline)
213 ("linux-pam" ,linux-pam)
216 (home-page "https://mailutils.org")
217 (synopsis "Utilities and library for reading and serving mail")
219 "GNU Mailutils is a collection of programs for managing, viewing and
220 processing electronic mail. It contains both utilities and server daemons
221 and all operate in a protocol-agnostic way. The underlying libraries are
222 also available, simplifying the addition of mail capabilities to new
225 ;; Libraries are under LGPLv3+, and programs under GPLv3+.
226 (list gpl3+ lgpl3+))))
228 (define-public fetchmail
234 (uri (string-append "mirror://sourceforge/fetchmail/branch_6.3/fetchmail-"
238 "0l78ayvi9dm8hd190gl139cs2xqsrf7r9ncilslw20mgvd6cbd3r"))))
239 (build-system gnu-build-system)
241 `(("openssl" ,openssl)))
243 `(#:configure-flags (list (string-append "--with-ssl="
244 (assoc-ref %build-inputs "openssl")))))
245 (home-page "http://www.fetchmail.info/")
246 (synopsis "Remote-mail retrieval and forwarding utility")
248 "Fetchmail is a full-featured, robust, well-documented remote-mail
249 retrieval and forwarding utility intended to be used over on-demand
250 TCP/IP links (such as SLIP or PPP connections). It supports every
251 remote-mail protocol now in use on the Internet: POP2, POP3, RPOP, APOP,
252 KPOP, all flavors of IMAP, ETRN, and ODMR. It can even support IPv6
255 Fetchmail retrieves mail from remote mail servers and forwards it via SMTP,
256 so it can then be read by normal mail user agents such as mutt, elm
257 or BSD Mail. It allows all your system MTA's filtering, forwarding, and
258 aliasing facilities to work just as they would on normal mail.")
259 (license gpl2+))) ; most files are actually public domain or x11
267 (uri (string-append "https://bitbucket.org/mutt/mutt/downloads/"
268 "mutt-" version ".tar.gz"))
271 "182lkbkpd3q3l1x6bvyds90ycp38gyyxhf35ry0d3hwf2n1khjkk"))
272 (patches (search-patches "mutt-store-references.patch"))))
273 (build-system gnu-build-system)
275 `(("cyrus-sasl" ,cyrus-sasl)
282 `(#:configure-flags '("--enable-smtp"
286 "--enable-hcache" ; for header caching
290 ;; so that mutt does not check whether the path
291 ;; exists, which it does not in the chroot
292 "--with-mailpath=/var/mail")))
293 (home-page "http://www.mutt.org/")
294 (synopsis "Mail client")
296 "Mutt is a small but very powerful text-based mail client for Unix
300 (define-public neomutt
307 (uri (string-append "https://github.com/" name "/" name
308 "/archive/" name "-" version ".tar.gz"))
311 "0072in2d6znwqq461shsaxlf40r4zr7w3j9848qvm4xlh1lq52dx"))))
312 (build-system gnu-build-system)
314 `(("cyrus-sasl" ,cyrus-sasl)
319 ("openssl" ,openssl) ;For smime
321 ("kyotocabinet" ,kyotocabinet)
326 ("notmuch" ,notmuch)))
328 `(("automake" ,automake)
329 ("gettext-minimal" ,gettext-minimal)
330 ("pkg-config" ,pkg-config)
331 ("docbook-xsl" ,docbook-xsl)
332 ("docbook-xml" ,docbook-xml-4.2)
340 ;; database, implies header caching
341 "--disable-tokyocabinet"
352 (string-append "--with-sasl="
353 (assoc-ref %build-inputs "cyrus-sasl"))
360 ;; If we do not set this, neomutt wants to check
361 ;; whether the path exists, which it does not
362 ;; in the chroot. The workaround is this.
363 "--with-mailpath=/var/mail"
366 (string-append "--with-ncurses="
367 (assoc-ref %build-inputs "ncurses"))
368 (string-append "--prefix="
369 (assoc-ref %outputs "out"))
372 (modify-phases %standard-phases
373 ;; TODO: autosetup is meant to be included in the source,
374 ;; but we should package autosetup and use our own version of it.
375 (add-before 'configure 'fix-sasl-test
377 ;; Upstream suggestion to fix the failing sasl autosetup test.
378 (substitute* "auto.def"
379 (("cc-with \\[list -cflags -I\\$prefix/include -libs")
380 "cc-with [list -includes stddef.h -cflags -I$prefix/include -libs"))
383 (lambda* (#:key outputs inputs configure-flags #:allow-other-keys)
384 (let* ((out (assoc-ref outputs "out"))
385 (flags `(,@configure-flags))
386 (bash (which "bash")))
387 (setenv "SHELL" bash)
388 (setenv "CONFIG_SHELL" bash)
390 (string-append (getcwd) "/configure")
392 (home-page "https://www.neomutt.org/")
393 (synopsis "Command-line mail reader based on Mutt")
395 "NeoMutt is a command-line mail reader which is based on mutt.
396 It adds a large amount of new and improved features to mutt.")
405 (uri (string-append "mirror://gnome/sources/gmime/"
406 (version-major+minor version)
407 "/gmime-" version ".tar.xz"))
410 "1q6palbpf6lh6bvy9ly26q5apl5k0z0r4mvl6zzqh90rz4rn1v3m"))))
411 (build-system gnu-build-system)
413 `(("pkg-config" ,pkg-config)
414 ("gnupg" ,gnupg))) ; for tests only
415 (inputs `(("glib" ,glib)
420 (modify-phases %standard-phases
422 'unpack 'patch-paths-in-tests
424 ;; The test programs run several programs using 'system' with
425 ;; hard-coded paths. Here we patch them all.
426 ;; We use ISO-8859-1 here because test-iconv.c contains
427 ;; raw byte sequences in several different encodings.
428 (with-fluids ((%default-port-encoding #f))
429 (substitute* (find-files "tests" "\\.c$")
430 (("(system *\\(\")(/[^ ]*)" all pre prog-path)
431 (let* ((base (basename prog-path))
434 (or prog (error "not found: " base)))))))
436 (home-page "http://spruce.sourceforge.net/gmime/")
437 (synopsis "MIME message parser and creator library")
439 "GMime provides a core library and set of utilities which may be used for
440 the creation and parsing of messages using the Multipurpose Internet Mail
442 (license (list lgpl2.1+ gpl2+ gpl3+))))
444 ;; Some packages are not ready for GMime 3 yet.
445 (define-public gmime-2.6
451 (uri (string-append "mirror://gnome/sources/gmime/"
452 (version-major+minor version)
453 "/gmime-" version ".tar.xz"))
456 "0slzlzcr3h8jikpz5a5amqd0csqh2m40gdk910ws2hnaf5m6hjbi"))))))
458 (define-public bogofilter
464 (uri (string-append "mirror://sourceforge/bogofilter/bogofilter-"
465 version "/bogofilter-"
469 "1d56n2m9inm8gnzm88aa27xl2a7sp7aff3484vmflpqkinjqf0p1"))))
470 (build-system gnu-build-system)
473 (modify-phases %standard-phases
474 (add-before 'check 'pre-check
476 (substitute* "src/tests/t.frame"
478 (string-append "GREP=" (which "grep") "\n")))
480 (native-inputs `(("flex" ,flex)))
481 (inputs `(("bdb" ,bdb)))
482 (home-page "http://bogofilter.sourceforge.net/")
483 (synopsis "Mail classifier based on a Bayesian filter")
485 "Bogofilter is a mail filter that classifies mail as spam or ham
486 (non-spam) by a statistical analysis of the message's header and
487 content (body). The program is able to learn from the user's classifications
488 and corrections. It is based on a Bayesian filter.")
491 (define-public offlineimap
497 (uri (string-append "https://github.com/OfflineIMAP/offlineimap/"
498 "archive/v" version ".tar.gz"))
499 (file-name (string-append name "-" version ".tar.gz"))
502 "1022xf2w1xax4vx4kzhlfbhaf0b72wkpvrcscvs4q8qk2ja68h8x"))))
503 (build-system python-build-system)
505 `(("asciidoc" ,asciidoc)))
506 (inputs `(("python2-pysqlite" ,python2-pysqlite)
507 ("python2-six" ,python2-six)))
509 ;; The setup.py script expects python-2.
511 ;; Tests require a modifiable IMAP account.
514 (modify-phases %standard-phases
515 (add-after 'build 'build-documentation
517 (substitute* "docs/Makefile"
518 ;; Prevent xmllint and xsltproc from downloading a DTD file.
519 (("a2x -v") "a2x --no-xmllint --xsltproc-opts=--nonet -v"))
520 (invoke "make" "-C" "docs" "man")))
521 (add-after 'install 'install-documentation
522 (lambda* (#:key outputs #:allow-other-keys)
523 (let* ((out (assoc-ref outputs "out"))
524 (man (string-append out "/share/man")))
525 (install-file "docs/offlineimap.1" (string-append man "/man1"))
526 (install-file "docs/offlineimapui.7" (string-append man "/man7"))
528 (add-after 'install-documentation 'wrap-binary
529 (lambda* (#:key outputs #:allow-other-keys)
530 (let* ((out (assoc-ref outputs "out"))
531 (bin (string-append out "/bin/offlineimap")))
533 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH"))))
535 (home-page "http://www.offlineimap.org")
536 (synopsis "Sync emails between two repositories")
538 "OfflineImap synchronizes emails between two repositories, so that you
539 can read the same mailbox from multiple computers. It supports IMAP as REMOTE
540 repository and Maildir/IMAP as LOCAL repository.")
543 (define-public emacs-mew
549 (uri (string-append "https://mew.org/Release/mew-"
553 "03fzky2kz73vgx4cbps2psbbnrgqgkk5q7jwfldisymkzr9iz03y"))))
557 `(("ruby-sqlite3" ,ruby-sqlite3) ; optional for the database of messages
558 ("ruby" ,ruby))) ; to set GEM_PATH so ruby-sqlite3 is found at runtime
559 (build-system gnu-build-system)
561 (let ((elisp-dir "/share/emacs/site-lisp/guix.d/mew")
562 (icon-dir "/share/mew"))
563 `(#:modules ((guix build gnu-build-system)
565 (guix build emacs-utils))
566 #:imported-modules (,@%gnu-build-system-modules
567 (guix build emacs-utils))
569 (list (string-append "--with-elispdir=" %output ,elisp-dir)
570 (string-append "--with-etcdir=" %output ,icon-dir))
572 (modify-phases %standard-phases
573 (add-after 'configure 'patch-mew-icon-directory
574 (lambda* (#:key outputs #:allow-other-keys)
575 (emacs-substitute-sexps "mew-key.el"
576 ("(def.* mew-icon-directory"
578 (add-to-list 'image-load-path 'mew-icon-directory)
579 ,(string-append (assoc-ref outputs "out") ,icon-dir))))
581 (add-after 'install 'generate-autoloads
582 (lambda* (#:key outputs #:allow-other-keys)
583 (emacs-generate-autoloads
584 "mew" (string-append (assoc-ref outputs "out") ,elisp-dir))
587 (home-page "https://mew.org")
588 (synopsis "Emacs e-mail client")
589 (description "Mew (Messaging in the Emacs World) is a user interface
590 for text messages, multimedia messages (MIME), news articles and
591 security functionality including PGP, S/MIME, SSH, and SSL.")
600 (uri (string-append "https://github.com/djcb/mu/releases/"
601 "download/v" version "/mu-"
605 "04x5azl19gszw2h7argq666gf9xs4hy9q7w9cbqxvy08n56xqsln"))))
606 (build-system gnu-build-system)
608 `(("pkg-config" ,pkg-config)
609 ("glib" ,glib "bin") ; for gtester
610 ("emacs" ,emacs-minimal)
611 ("tzdata" ,tzdata-for-tests))) ;for mu/test/test-mu-query.c
612 ;; TODO: Add webkit and gtk to build the mug GUI.
617 ("gmime" ,gmime-2.6)))
619 `(#:modules ((guix build gnu-build-system)
621 (guix build emacs-utils))
622 #:imported-modules (,@%gnu-build-system-modules
623 (guix build emacs-utils))
625 (modify-phases %standard-phases
626 (add-after 'unpack 'patch-configure
627 ;; By default, elisp code goes to "share/emacs/site-lisp/mu4e",
628 ;; so our Emacs package can't find it. Setting "--with-lispdir"
629 ;; configure flag doesn't help because "mu4e" will be added to
630 ;; the lispdir anyway, so we have to modify "configure.ac".
632 (substitute* "configure"
633 (("^ +lispdir=\"\\$\\{lispdir\\}/mu4e/\".*") "")
635 (("guile-2.0") "guile-2.2"))
636 (substitute* '("guile/Makefile.in"
637 "guile/mu/Makefile.in")
638 (("share/guile/site/2.0/") "share/guile/site/2.2/"))
640 (add-after 'patch-configure 'fix-date-tests
641 ;; Loosen test tolerances to prevent failures caused by daylight
642 ;; saving time (DST). See: https://github.com/djcb/mu/issues/1214.
644 (substitute* "lib/parser/test-utils.cc"
645 (("\\* 60 \\* 60, 1 },")
646 "* 60 * 60, 3600 + 1 },"))
648 (add-before 'install 'fix-ffi
649 (lambda* (#:key outputs #:allow-other-keys)
650 (substitute* "guile/mu.scm"
652 (format #f "\"~a/lib/libguile-mu\""
653 (assoc-ref outputs "out"))))
655 (add-before 'check 'check-tz-setup
656 (lambda* (#:key inputs #:allow-other-keys)
657 ;; For mu/test/test-mu-query.c
659 (string-append (assoc-ref inputs "tzdata")
662 (add-after 'install 'install-emacs-autoloads
663 (lambda* (#:key outputs #:allow-other-keys)
664 (emacs-generate-autoloads
666 (string-append (assoc-ref outputs "out")
667 "/share/emacs/site-lisp"))
669 (home-page "http://www.djcbsoftware.nl/code/mu/")
670 (synopsis "Quickly find emails")
672 "Mu is a tool for dealing with e-mail messages stored in the
673 Maildir-format. Mu's purpose in life is to help you to quickly find the
674 messages you need; in addition, it allows you to view messages, extract
675 attachments, create new maildirs, and so on.")
684 ;; package author intends on distributing via github rather
686 ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331
687 (uri (string-append "https://github.com/pazz/alot/archive/"
689 (file-name (string-append "alot-" version ".tar.gz"))
692 "0wax30hjzmkqfml7hig1dqw1v1y63yc0cgbzl96x58b9h2ggqx3a"))))
693 (build-system python-build-system)
695 `(;; python 3 is currently unsupported, more info:
696 ;; https://github.com/pazz/alot/blob/master/docs/source/faq.rst
699 `(("python2-mock" ,python2-mock)))
701 `(("python2-magic" ,python2-magic)
702 ("python2-configobj" ,python2-configobj)
703 ("python2-twisted" ,python2-twisted)
704 ("python2-urwid" ,python2-urwid)
705 ("python2-urwidtrees" ,python2-urwidtrees)
706 ("python2-pygpgme" ,python2-pygpgme)
707 ("python2-notmuch" ,python2-notmuch)))
708 (home-page "https://github.com/pazz/alot")
709 (synopsis "Command-line MUA using @code{notmuch}")
711 "Alot is an experimental terminal mail user agent (@dfn{MUA}) based on
712 @code{notmuch} mail. It is written in Python using the @code{urwid} toolkit.")
715 (define-public notifymuch
717 ((commit "9d4aaf54599282ce80643b38195ff501120807f0")
721 (version (string-append "0.1-" revision "." (string-take commit 7)))
726 (url "https://github.com/kspi/notifymuch.git")
730 "1lssr7iv43mp5v6nzrfbqlfzx8jcc7m636wlfyhhnd8ydd39n6k4"))
731 (file-name (string-append name "-" version "-checkout"))))
732 (build-system python-build-system)
734 `(("python-notmuch" ,python-notmuch)
735 ("python-pygobject" ,python-pygobject)
736 ("gobject-introspection" ,gobject-introspection)
737 ("libnotify" ,libnotify)
741 (modify-phases %standard-phases
742 (add-after 'install 'wrap-binary
743 (lambda* (#:key outputs #:allow-other-keys)
744 (let* ((out (assoc-ref outputs "out"))
745 (bin (string-append out "/bin/notifymuch")))
747 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH")))
748 `("GI_TYPELIB_PATH" ":" prefix
749 (,(getenv "GI_TYPELIB_PATH")
750 ,(string-append out "/lib/girepository-1.0")))))
752 (home-page "https://github.com/kspi/notifymuch")
753 (synopsis "Displays notifications for changes in the notmuch email database")
754 (description "notifymuch displays desktop notifications for messages in
755 the notmuch database. The notifications are sent using libnotify to a
756 notification daemon. The query to find messages to send a notification about
757 is configurable, and a notification for the same message will not be send
758 within a configurable period (defaults to 48 hours). To use notifymuch, run
759 @command{notifymuch} after new mail is indexed, this can be automated by
760 invoking @command{notifymuch} from the post-new hook.")
763 (define-public notmuch
769 (uri (string-append "https://notmuchmail.org/releases/notmuch-"
773 "0dqarmjc8544m2w7bqrqmvsfy55fw82707z3lz9cql8nr777bjmc"))))
774 (build-system gnu-build-system)
776 `(#:modules ((guix build gnu-build-system)
777 ((guix build emacs-build-system) #:prefix emacs:)
779 #:imported-modules (,@%gnu-build-system-modules
780 (guix build emacs-build-system)
781 (guix build emacs-utils))
782 #:make-flags (list "V=1") ; Verbose test output.
783 #:phases (modify-phases %standard-phases
784 (add-after 'unpack 'patch-notmuch-lib.el
786 (substitute* "emacs/notmuch-lib.el"
787 (("/bin/sh") (which "sh")))
790 (lambda* (#:key outputs #:allow-other-keys)
792 (setenv "CONFIG_SHELL" (which "sh"))
794 (let* ((out (assoc-ref outputs "out"))
796 (string-append out "/share/emacs/site-lisp/guix.d/"
797 ,name "-" ,version)))
798 (invoke "./configure"
799 (string-append "--prefix=" out)
800 (string-append "--emacslispdir=" elisp)
801 (string-append "--emacsetcdir=" elisp)))))
802 (add-before 'check 'prepare-test-environment
804 (setenv "TEST_CC" "gcc")
805 ;; Patch various inline shell invocations.
806 (substitute* (find-files "test" "\\.sh$")
807 (("/bin/sh") (which "sh")))
809 (add-after 'install 'make-autoloads
810 (assoc-ref emacs:%standard-phases 'make-autoloads)))))
812 `(("bash-completion" ,bash-completion)
813 ("emacs" ,emacs-no-x) ; Minimal lacks libxml, needed for some tests.
814 ("pkg-config" ,pkg-config)
816 ("python-docutils" ,python2-docutils)
817 ("python-sphinx" ,python2-sphinx)
819 ;; The following are required for tests only.
831 (home-page "https://notmuchmail.org/")
832 (synopsis "Thread-based email index, search, and tagging")
834 "Notmuch is a command-line based program for indexing, searching, read-
835 ing, and tagging large collections of email messages.")
838 (define-public notmuch-addrlookup-c
839 ;; This commit includes a compatibility fix for notmuch-0.25, and is not
840 ;; currently part of any release. Please update this package when
841 ;; notmuch-addrlookup-c-9 is released.
842 (let ((commit "88f156d04990a71c6ad6fc2757b537b44e3c4d00")
843 (revision "1")) ;Guix package revision
845 (name "notmuch-addrlookup-c")
846 (version (string-append "8-" revision "."
847 (string-take commit 7)))
851 (url "https://github.com/aperezdc/notmuch-addrlookup-c.git")
853 (file-name (string-append name "-" version "-checkout"))
856 "0v0wzs7qzy4n1hbql8s10qrwgalcxdzbxf8pj6cii1pv2jwmkxbm"))))
857 (build-system gnu-build-system)
859 '(#:tests? #f ; no tests
860 #:make-flags (list "CC=gcc"
861 (string-append "PREFIX="
862 (assoc-ref %outputs "out")))
863 #:phases (modify-phases %standard-phases
865 ;; Remove vim code completion config, it's not needed to
866 ;; build (or be patched).
867 (add-before 'patch-source-shebangs 'delete-ycm-file
868 (lambda _ (delete-file ".ycm_extra_conf.py")))
870 (lambda* (#:key outputs #:allow-other-keys)
871 (let ((bin (string-append
872 (assoc-ref outputs "out") "/bin")))
873 (install-file "notmuch-addrlookup" bin)))))))
875 `(("pkg-config" ,pkg-config)))
878 ("notmuch" ,notmuch)))
879 (home-page "https://github.com/aperezdc/notmuch-addrlookup-c")
880 (synopsis "Address lookup tool for Notmuch")
881 (description "This is an address lookup tool using a Notmuch database,
882 useful for email address completion.")
883 (license license:expat))))
885 (define-public python-notmuch
887 (name "python-notmuch")
888 (version (package-version notmuch))
889 ;; Notmuch python bindings are now unavailable on pypi. The
890 ;; bindings are distributed via the notmuch release tarball.
891 (source (package-source notmuch))
892 (build-system python-build-system)
893 (inputs `(("notmuch" ,notmuch)))
895 `(#:tests? #f ; no "test" target
897 (modify-phases %standard-phases
898 ;; This python package lives in a subdirectory of the notmuch source
899 ;; tree, so chdir into it before building.
900 (add-after 'unpack 'enter-python-dir
901 (lambda _ (chdir "bindings/python") #t))
902 ;; Make sure the correct notmuch shared library gets loaded.
903 (add-before 'build 'set-libnotmuch-file-name
904 (lambda* (#:key inputs #:allow-other-keys)
905 (let ((notmuch (assoc-ref inputs "notmuch")))
906 (substitute* "notmuch/globals.py"
907 (("libnotmuch\\.so\\.")
908 (string-append notmuch "/lib/libnotmuch.so.")))
910 (home-page (package-home-page notmuch))
911 (synopsis "Python bindings of the Notmuch mail indexing library")
913 "This package provides Python bindings to use the Notmuch mail indexing
914 and search library.")
917 (define-public python2-notmuch
918 (package-with-python2 python-notmuch))
920 (define-public getmail
927 (uri (string-append "http://pyropus.ca/software/getmail/old-versions/"
928 name "-" version ".tar.gz"))
931 "16nmvj80szr6yvcxxgmxn2lxqpjqqj4xg5a0b66zhvck6j42q3a6"))))
932 (build-system python-build-system)
934 `(#:tests? #f ; no tests
936 (home-page "http://pyropus.ca/software/getmail/")
937 (synopsis "Mail retriever")
939 "A flexible, extensible mail retrieval system with support for
940 POP3, IMAP4, SSL variants of both, maildirs, mboxrd files, external MDAs,
941 arbitrary message filtering, single-user and domain-mailboxes, and many other
944 ;; License is specified in file '__init__.py'.
947 (define-public libetpan
954 (url "https://github.com/dinhviethoa/libetpan.git")
956 (file-name (git-file-name name version))
958 (base32 "1628lb1qvxixl64ifvjjr839hmirpx532klhv2mr7m6gmn7nlci5"))))
959 (build-system gnu-build-system)
960 (native-inputs `(("autoconf" ,autoconf-wrapper)
961 ("automake" ,automake)
963 ("pkg-config" ,pkg-config)))
965 ;; 'libetpan-config --libs' returns '-lssl -lcrypto -lsasl2', so these
966 ;; libraries need to be propagated.
967 `(("cyrus-sasl" ,cyrus-sasl)
968 ("openssl" ,openssl)))
975 (modify-phases %standard-phases
976 (add-after 'unpack 'autogen
978 (setenv "NOCONFIGURE" "true")
979 (invoke "sh" "autogen.sh"))))
981 '("--disable-static" "--disable-db")))
982 (home-page "https://www.etpan.org/libetpan.html")
983 (synopsis "Portable middleware for email access")
985 "The purpose of this mail library is to provide a portable, efficient
986 framework for different kinds of mail access: IMAP, SMTP, POP and NNTP. It
987 provides an API for C language. It's the low-level API used by MailCore and
991 (define-public compface
997 (uri (string-append "https://ftp.heanet.ie/mirrors/"
998 "ftp.xemacs.org/aux/"
999 name "-" version ".tar.gz"))
1002 "09b89wg63hg502hsz592cd2h87wdprb1dq1k1y07n89hym2q56d6"))))
1003 (build-system gnu-build-system)
1006 (synopsis "Portrait image compressor")
1007 (description "This packages takes your 48x48x1 portrait image and
1009 (home-page "http://www.cs.indiana.edu/pub/faces/")
1010 (license (x11-style "file://README"))))
1012 (define-public claws-mail
1019 "https://www.claws-mail.org/releases/" name "-" version
1023 "1wknxbwyzm5xjh3cqmddcxmvp1rkp301qga5n5rgfi7vcd0myyvm"))))
1024 (build-system gnu-build-system)
1025 (native-inputs `(("pkg-config" ,pkg-config)))
1026 (inputs `(("bogofilter" ,bogofilter)
1028 ("dbus-glib" ,dbus-glib)
1029 ("enchant" ,enchant)
1031 ("ghostscript" ,ghostscript)
1032 ("hicolor-icon-theme" ,hicolor-icon-theme)
1037 ("libarchive" ,libarchive)
1038 ("libcanberra" ,libcanberra)
1039 ("libetpan" ,libetpan)
1040 ("libical" ,libical)
1041 ("libnotify" ,libnotify)
1043 ("libxml2" ,libxml2)
1045 ("python-2" ,python-2)
1046 ("mime-info" ,shared-mime-info)))
1049 '("--enable-gnutls" "--enable-pgpmime-plugin" "--enable-enchant")
1051 ;; Disable updating icon cache since it's done by the profile hook.
1052 ;; Conflict with other packages in the profile would be inevitable
1054 '("gtk_update_icon_cache=true")
1055 #:phases (modify-phases %standard-phases
1056 (add-before 'build 'patch-mime
1057 (lambda* (#:key inputs #:allow-other-keys)
1058 (substitute* "src/procmime.c"
1059 (("/usr/share/mime/globs")
1060 (string-append (assoc-ref inputs "mime-info")
1061 "/share/mime/globs"))))))))
1062 (synopsis "GTK-based Email client")
1064 "Claws-Mail is an email client (and news reader) based on GTK+. The
1065 appearance and interface are designed to be familiar to new users coming from
1066 other popular email clients, as well as experienced users. Almost all commands
1067 are accessible with the keyboard. Plus, Claws-Mail is extensible via addons
1068 which can add many functionalities to the base client.")
1069 (home-page "https://www.claws-mail.org/")
1070 (license gpl3+))) ; most files are actually public domain or x11
1072 (define-public msmtp
1079 (uri (string-append "https://marlam.de/msmtp/releases/"
1080 "/msmtp-" version ".tar.xz"))
1083 "1k9wwlapkxk9ql3xq05y6vwn6ziqk9b1v8lyhj1866qd02zhqwxx"))))
1084 (build-system gnu-build-system)
1086 `(("libsecret" ,libsecret)
1091 `(("pkg-config" ,pkg-config)))
1092 (home-page "https://marlam.de/msmtp/")
1094 `(#:configure-flags (list "--with-libgsasl"
1096 "--with-tls=gnutls")
1098 (modify-phases %standard-phases
1099 (add-after 'install 'install-msmtpq
1100 (lambda* (#:key outputs #:allow-other-keys)
1101 (let* ((out (assoc-ref outputs "out"))
1102 (bin (string-append out "/bin"))
1103 (doc (string-append out "/share/doc/msmtp"))
1104 (msmtpq (string-append "scripts/msmtpq")))
1105 (install-file (string-append msmtpq "/msmtpq") bin)
1106 (install-file (string-append msmtpq "/msmtp-queue") bin)
1107 (install-file (string-append msmtpq "/README.msmtpq") doc)
1110 "Simple and easy to use SMTP client with decent sendmail compatibility")
1112 "msmtp is an SMTP client. In the default mode, it transmits a mail to
1113 an SMTP server (for example at a free mail provider) which takes care of further
1124 (uri (list (string-append "https://ftp.exim.org/pub/exim/exim4/exim-"
1126 (string-append "https://ftp.exim.org/pub/exim/exim4/old/exim-"
1127 version ".tar.bz2")))
1130 "1w6blvvrd87c649j8xpag034md2w1ib0db9c4ijqbzc5dh2i1xfq"))))
1131 (build-system gnu-build-system)
1141 ("libxaw" ,libxaw)))
1143 `(("pcre" ,pcre "bin")
1147 (modify-phases %standard-phases
1149 ;; We'd use #:make-flags but the top-level Makefile calls others
1150 ;; recursively, so just set all variables this way.
1151 (lambda* (#:key outputs inputs #:allow-other-keys)
1152 (substitute* '("Makefile" "OS/Makefile-Default")
1153 (("(RM_COMMAND=).*" all var)
1154 (string-append var "rm\n")))
1155 (copy-file "src/EDITME" "Local/Makefile")
1156 (copy-file "exim_monitor/EDITME" "Local/eximon.conf")
1157 (let ((out (assoc-ref outputs "out"))
1158 (gzip (assoc-ref inputs "gzip"))
1159 (bzip2 (assoc-ref inputs "bzip2"))
1160 (xz (assoc-ref inputs "xz")))
1161 (substitute* '("Local/Makefile")
1162 (("(BIN_DIRECTORY=).*" all var)
1163 (string-append var out "/bin\n"))
1164 (("(CONFIGURE_FILE=).*" all var)
1165 (string-append var out "/etc/exim.conf\n"))
1166 (("(EXIM_USER=).*" all var)
1167 (string-append var "nobody\n"))
1168 (("(FIXED_NEVER_USERS=).*" all var)
1169 (string-append var "\n")) ;XXX no root in build environment
1170 (("(COMPRESS_COMMAND=).*" all var)
1171 (string-append var gzip "/bin/gzip\n"))
1172 (("(ZCAT_COMMAND=).*" all var)
1173 (string-append var gzip "/bin/zcat\n")))
1174 ;; This file has hardcoded names for tools despite the zcat
1175 ;; configuration above.
1176 (substitute* '("src/exigrep.src")
1177 (("'zcat'") (string-append "'" gzip "/bin/zcat'"))
1178 (("'bzcat'") (string-append "'" bzip2 "/bin/bzcat'"))
1179 (("'xzcat'") (string-append "'" xz "/bin/xzcat'"))
1180 (("'lzma'") (string-append "'" xz "/bin/lzma'"))))
1182 (add-before 'build 'fix-sh-paths
1183 (lambda* (#:key inputs #:allow-other-keys)
1184 (substitute* '("scripts/lookups-Makefile" "scripts/reversion")
1185 (("SHELL=/bin/sh") "SHELL=sh"))
1186 (substitute* '("scripts/Configure-config.h")
1187 (("\\| /bin/sh") "| sh"))
1188 (let ((bash (assoc-ref inputs "bash")))
1189 (substitute* '("scripts/Configure-eximon")
1190 (("#!/bin/sh") (string-append "#!" bash "/bin/sh"))))
1192 #:make-flags '("INSTALL_ARG=-no_chown")
1193 ;; No 'check' target.
1195 (home-page "https://www.exim.org/")
1197 "Message Transfer Agent (MTA) developed at the University of Cambridge")
1199 "Exim is a message transfer agent (MTA) developed at the University of
1200 Cambridge for use on Unix systems connected to the Internet. In style it is
1201 similar to Smail 3, but its facilities are more general. There is a great
1202 deal of flexibility in the way mail can be routed, and there are extensive
1203 facilities for checking incoming mail.")
1206 (define-public dovecot
1213 (uri (string-append "https://www.dovecot.org/releases/"
1214 (version-major+minor version) "/"
1215 name "-" version ".tar.gz"))
1217 "0d2ffbicgl3wswbnyjbw6qigz7r1aqzprpchbwp5cynw122i2raa"))))
1218 (build-system gnu-build-system)
1220 `(("pkg-config" ,pkg-config)))
1222 `(("openssl" ,openssl)
1226 ("linux-pam" ,linux-pam)))
1228 `(#:configure-flags '("--sysconfdir=/etc"
1229 "--localstatedir=/var")
1230 #:phases (modify-phases %standard-phases
1232 'configure 'pre-configure
1234 ;; Simple hack to avoid installing in /etc.
1235 (substitute* '("doc/Makefile.in"
1236 "doc/example-config/Makefile.in")
1237 (("pkgsysconfdir = .*")
1238 "pkgsysconfdir = /tmp/etc"))
1241 'unpack 'patch-other-file-names
1244 "src/lib-program-client/test-program-client-local.c"
1245 (("(/bin/| )cat") (which "cat"))
1246 (("/bin/echo") (which "echo"))
1247 (("/bin/false") (which "false"))
1248 (("/bin/sh") (which "bash"))
1249 (("head") (which "head"))
1250 (("sleep") (which "sleep")))
1252 (home-page "https://www.dovecot.org")
1253 (synopsis "Secure POP3/IMAP server")
1255 "Dovecot is a mail server whose major goals are security and reliability.
1256 It supports mbox/Maildir and its own dbox/mdbox formats.")
1257 ;; Most source files are covered by either lgpl2.1 or expat. The SHA code
1258 ;; is covered by a variant of BSD-3, and UnicodeData.txt is covered by the
1259 ;; Unicode, Inc. License Agreement for Data Files and Software.
1260 (license (list lgpl2.1 license:expat (non-copyleft "file://COPYING")))))
1262 (define-public dovecot-trees
1264 (name "dovecot-trees")
1269 (uri (string-append "https://0xacab.org/riseuplabs/trees/repository/"
1270 "archive.tar.gz?ref=v" version))
1271 (file-name (string-append name "-" version ".tar.gz"))
1274 "0rkk10b1bsjz979sc864vpgcdchy7yxwmyv4ik50lar1h6awdnrf"))
1276 (search-patches "dovecot-trees-support-dovecot-2.3.patch"))))
1277 (build-system gnu-build-system)
1279 `(("automake" ,automake)
1280 ("autoconf" ,autoconf)
1281 ("libtool" ,libtool)
1282 ("dovecot" ,dovecot)
1283 ("pkg-config" ,pkg-config)))
1285 `(("libsodium" ,libsodium)))
1287 `(#:tests? #f ;No tests exist.
1288 #:configure-flags (list (string-append "--with-dovecot="
1289 (assoc-ref %build-inputs "dovecot")
1292 (modify-phases %standard-phases
1293 (add-after 'unpack 'autogen
1295 (invoke "sh" "autogen.sh"))))))
1296 (home-page "https://0xacab.org/riseuplabs/trees")
1297 (synopsis "NaCL-based Dovecot email storage encryption plugin")
1299 "Technology for Resting Email Encrypted Storage (TREES) is a NaCL-based
1300 Dovecot encryption plugin. This plugin adds individually encrypted mail
1301 storage to the Dovecot IMAP server. It is inspired by Posteo's scrambler
1302 which uses OpenSSL and RSA keypairs. TREES works in a similar way, but uses
1303 the Sodium crypto library (based on NaCL).
1307 @item On IMAP log in, the user's cleartext password is passed to the plugin.
1308 @item The plugin creates an argon2 digest from the password.
1309 @item This password digest is used as a symmetric secret to decrypt a libsodium secretbox.
1310 @item Inside the secretbox is stored a Curve25519 private key.
1311 @item The Curve25519 private key is used to decrypt each individual message,
1312 using lidsodium sealed boxes.
1313 @item New mail is encrypted as it arrives using the Curve25519 public key.
1317 (define-public dovecot-libsodium-plugin
1318 (let ((commit "044de73c01c35385df0105f6b387bec5d5317ce7")
1321 (name "dovecot-libsodium-plugin")
1322 (version (string-append "0.0.0-" revision "." (string-take commit 7)))
1327 (url "https://github.com/LuckyFellow/dovecot-libsodium-plugin")
1329 (file-name (string-append name "-" version "-checkout"))
1332 "13h07l7xy713zchnj2p9fhvq7fdl4zy1ai94li3ygkqjjj8hrgas"))))
1333 (build-system gnu-build-system)
1335 `(("automake" ,automake)
1336 ("autoconf" ,autoconf)
1337 ("libtool" ,libtool)
1338 ("dovecot" ,dovecot)
1339 ("pkg-config" ,pkg-config)))
1341 `(("libsodium" ,libsodium)))
1343 `(#:tests? #f ;No tests exist.
1344 #:configure-flags (list (string-append "--with-dovecot="
1345 (assoc-ref %build-inputs "dovecot")
1348 (modify-phases %standard-phases
1349 (add-after 'unpack 'autogen
1351 (invoke "sh" "autogen.sh"))))))
1352 (home-page "https://github.com/LuckyFellow/dovecot-libsodium-plugin")
1353 (synopsis "Libsodium password hashing schemes plugin for Dovecot")
1355 "@code{dovecot-libsodium-plugin} provides libsodium password
1356 hashing schemes plugin for @code{Dovecot}.")
1359 (define-public isync
1366 (uri (string-append "mirror://sourceforge/isync/isync/"
1367 version "/isync-" version ".tar.gz"))
1369 "173wd7x8y5sp94slzwlnb7zhgs32r57zl9xspl2rf4g3fqwmhpwd"))))
1370 (build-system gnu-build-system)
1375 ("cyrus-sasl" ,cyrus-sasl)
1376 ("openssl" ,openssl)
1378 (home-page "http://isync.sourceforge.net/")
1379 (synopsis "Mailbox synchronization program")
1381 "isync/mbsync is a command-line tool for two-way synchronization of
1382 mailboxes. Currently Maildir and IMAP are supported types.")
1385 (define-public perl-email-abstract
1387 (name "perl-email-abstract")
1392 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1393 "Email-Abstract-" version ".tar.gz"))
1396 "0h42rhvp769wb421cpbbg6v6xjp8iv86mvz70pqgfgf4nsn6jwgw"))))
1397 (build-system perl-build-system)
1399 `(("perl-email-simple" ,perl-email-simple)
1400 ("perl-module-pluggable" ,perl-module-pluggable)
1401 ("perl-mro-compat" ,perl-mro-compat)))
1402 (home-page "https://metacpan.org/release/Email-Abstract")
1403 (synopsis "Interface to mail representations")
1404 (description "Email::Abstract provides module writers with the ability to
1405 write simple, representation-independent mail handling code.")
1406 (license perl-license)))
1408 (define-public perl-email-address
1410 (name "perl-email-address")
1415 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1416 "Email-Address-" version ".tar.gz"))
1419 "0l7x6sl06j9ffgfz5f9vgms2b5axd4cgp5fj03ivb3kia4km6b3g"))))
1420 (build-system perl-build-system)
1421 (home-page "https://metacpan.org/release/Email-Address")
1422 (synopsis "Email address parsing and creation")
1423 (description "Email::Address implements a regex-based RFC 2822 parser that
1424 locates email addresses in strings and returns a list of Email::Address
1425 objects found. Alternatively you may construct objects manually.")
1426 (license perl-license)))
1428 (define-public perl-email-date-format
1430 (name "perl-email-date-format")
1435 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1436 "Email-Date-Format-" version ".tar.gz"))
1439 "012ivfwpnbl3wr50f9c6f4azhdlxnm31pdn72528g79v61z6372p"))))
1440 (build-system perl-build-system)
1441 (home-page "https://metacpan.org/release/Email-Date-Format")
1442 (synopsis "Produce RFC 2822 date strings")
1443 (description "Email::Date::Format provides a means for generating an RFC
1444 2822 compliant datetime string.")
1445 (license perl-license)))
1447 (define-public perl-email-messageid
1449 (name "perl-email-messageid")
1454 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1455 "Email-MessageID-" version ".tar.gz"))
1458 "1f22sdnfq169qw1l0lg7y74pmiam7j9v95bggjnf3q4mygdmshpc"))))
1459 (build-system perl-build-system)
1460 (home-page "https://metacpan.org/release/Email-MessageID")
1461 (synopsis "Generate world unique message-ids")
1462 (description "Email::MessageID generates recommended message-ids to
1463 identify a message uniquely.")
1464 (license perl-license)))
1466 (define-public perl-email-mime
1468 (name "perl-email-mime")
1473 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1474 "Email-MIME-" version ".tar.gz"))
1477 "0z1k3i0lzp2k421gc8f3wq0jbqflkbw2xqd2k7n7pmv56417kvk8"))))
1478 (build-system perl-build-system)
1480 `(("perl-email-address" ,perl-email-address)
1481 ("perl-email-messageid" ,perl-email-messageid)
1482 ("perl-email-mime-contenttype" ,perl-email-mime-contenttype)
1483 ("perl-email-mime-encodings" ,perl-email-mime-encodings)
1484 ("perl-email-simple" ,perl-email-simple)
1485 ("perl-mime-types" ,perl-mime-types)
1486 ("perl-module-runtime" ,perl-module-runtime)))
1487 (home-page "https://metacpan.org/release/Email-MIME")
1488 (synopsis "MIME message handling")
1489 (description "Email::MIME is an extension of the Email::Simple module, to
1490 handle MIME encoded messages. It takes a message as a string, splits it up
1491 into its constituent parts, and allows you access to various parts of the
1492 message. Headers are decoded from MIME encoding.")
1493 (license perl-license)))
1495 (define-public perl-email-mime-contenttype
1497 (name "perl-email-mime-contenttype")
1502 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1503 "Email-MIME-ContentType-" version ".tar.gz"))
1506 "042kxhs3bp1ab9z0mbr1wy21ld4lxd6v2a2mmrashqnsn2075fws"))))
1507 (build-system perl-build-system)
1509 `(("perl-capture-tiny" ,perl-capture-tiny)))
1510 (home-page "https://metacpan.org/release/Email-MIME-ContentType")
1511 (synopsis "Parse MIME Content-Type headers")
1512 (description "Email::MIME::ContentType parses a MIME Content-Type
1514 (license perl-license)))
1516 (define-public perl-email-mime-encodings
1518 (name "perl-email-mime-encodings")
1523 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1524 "Email-MIME-Encodings-" version ".tar.gz"))
1527 "0p5b8g9gh35m8fqrpx60g4bp98rvwd02n5b0vm9wh7mk0xah8wac"))))
1528 (build-system perl-build-system)
1530 `(("perl-capture-tiny" ,perl-capture-tiny)))
1531 (home-page "https://metacpan.org/release/Email-MIME-Encodings")
1532 (synopsis "Unified interface to MIME encoding and decoding")
1533 (description "This module wraps MIME::Base64 and MIME::QuotedPrint.")
1534 (license perl-license)))
1536 (define-public perl-email-sender
1538 (name "perl-email-sender")
1539 (version "1.300031")
1543 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1544 "Email-Sender-" version ".tar.gz"))
1547 "052g0slw3h2lzn93j71fi47nfawww2aph4jhr3c860ji70lkf4n4"))))
1548 (build-system perl-build-system)
1550 `(("perl-capture-tiny" ,perl-capture-tiny)))
1552 `(("perl-email-abstract" ,perl-email-abstract)
1553 ("perl-email-address" ,perl-email-address)
1554 ("perl-email-simple" ,perl-email-simple)
1555 ("perl-list-moreutils" ,perl-list-moreutils)
1556 ("perl-module-runtime" ,perl-module-runtime)
1557 ("perl-moo" ,perl-moo)
1558 ("perl-moox-types-mooselike" ,perl-moox-types-mooselike)
1559 ("perl-sub-exporter" ,perl-sub-exporter)
1560 ("perl-throwable" ,perl-throwable)
1561 ("perl-try-tiny" ,perl-try-tiny)))
1562 (home-page "https://metacpan.org/release/Email-Sender")
1563 (synopsis "Perl library for sending email")
1564 (description "Email::Sender replaces the old and sometimes problematic
1565 Email::Send library.")
1566 (license perl-license)))
1568 (define-public perl-email-simple
1570 (name "perl-email-simple")
1575 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1576 "Email-Simple-" version ".tar.gz"))
1579 "1m4brbjvalyp5kjqslqv4155dzwg977shxin208i7lc8236n6pyq"))))
1580 (build-system perl-build-system)
1582 `(("perl-email-date-format" ,perl-email-date-format)))
1583 (home-page "https://metacpan.org/release/Email-Simple")
1584 (synopsis "Parsing of RFC 2822 messages")
1585 (description "Email::Simple provides simple parsing of RFC 2822 message
1586 format and headers.")
1587 (license perl-license)))
1589 (define-public libesmtp
1596 (uri (list (string-append "https://pkgs.fedoraproject.org/repo/pkgs/"
1597 "libesmtp/libesmtp-" version ".tar.bz2/"
1598 "bf3915e627fd8f35524a8fdfeed979c8/libesmtp-"
1600 ;; XXX This site is offline, so we fetch Fedora's cached copy
1601 ;; of the source tarball.
1602 (string-append "http://www.stafford.uklinux.net/libesmtp/libesmtp-"
1603 version ".tar.bz2")))
1606 "02zbniyz7qys1jmx3ghx21kxmns1wc3hmv80gp7ag7yra9f1m9nh"))))
1607 (build-system gnu-build-system)
1609 `(("openssl" ,openssl)))
1610 (home-page "http://www.stafford.uklinux.net/libesmtp/")
1611 (synopsis "Library for sending mail via remote hosts using SMTP")
1612 (description "libESMTP is an SMTP client which manages posting (or
1613 submission of) electronic mail via a preconfigured Mail Transport Agent (MTA).
1614 It may be used as part of a Mail User Agent (MUA) or other program that must
1615 be able to post electronic mail where mail functionality may not be that
1616 program's primary purpose.")
1617 (license (list lgpl2.1+ gpl2+))))
1619 (define-public esmtp
1627 (url "https://github.com/andywingo/esmtp.git")
1628 (commit "01bf9fc")))
1631 "1ay282rrl92h0m0m8z5zzjnwiiagi7c78aq2qvhia5mw7prwfyw2"))
1632 (file-name (string-append name "-" version "-checkout"))))
1634 `(#:phases (modify-phases %standard-phases
1636 (lambda _ (invoke "autoreconf" "-vfi"))))))
1637 (build-system gnu-build-system)
1641 ("autoconf" ,autoconf)
1642 ("automake" ,automake)
1643 ("libtool" ,libtool)))
1645 `(("libesmtp" ,libesmtp)))
1646 (home-page "https://sourceforge.net/projects/esmtp/")
1647 (synopsis "Relay-only mail transfer agent (MTA)")
1648 (description "Esmtp is a simple relay-only mail transfer agent built using
1649 libESMTP. It sends e-mail via a remote SMTP server using credentials from the
1650 user's @file{$HOME/.esmtprc} configuration file; see the @command{esmtprc} man
1651 page for more on configuration. This package also provides minimal
1652 compatibility shims for the @command{sendmail}, @command{mailq}, and
1653 @command{newaliases} commands.")
1662 (uri (string-append "https://github.com/nicm/fdm/releases/download/"
1665 (file-name (string-append name "-" version ".tar.gz"))
1667 (base32 "054rscijahiza5f9qha79rg3siji3bk5mk10f8c2vqx7m4w6qh8n"))))
1668 (build-system gnu-build-system)
1671 ("openssl" ,openssl)
1673 (home-page "https://github.com/nicm/fdm")
1674 (synopsis "Mail Retrieval Agent (MRA) and Mail Delivery Agent (MDA)")
1675 (description "fdm is a program designed to fetch mail from POP3
1676 or IMAP servers, or receive local mail from stdin, and
1677 deliver it in various ways.")
1679 ;; Why point to a source file? Well, all the individual files have a
1680 ;; copy of this license in their headers, but there's no seprate file
1681 ;; with that information.
1682 (non-copyleft "https://github.com/nicm/fdm/blob/master/command.c"))))
1685 (define-public procmail
1693 "ftp://ftp.fu-berlin.de/pub/unix/mail/procmail/procmail-"
1698 "05z1c803n5cppkcq99vkyd5myff904lf9sdgynfqngfk9nrpaz08"))
1699 ;; The following patch fixes an ambiguous definition of
1700 ;; getline() in formail.c. The patch is provided by Debian as
1702 (patches (search-patches "procmail-ambiguous-getline-debian.patch"
1703 "procmail-CVE-2014-3618.patch"
1704 "procmail-CVE-2017-16844.patch"))))
1706 `(#:phases (modify-phases %standard-phases
1709 (substitute* "Makefile"
1713 (assoc-ref %outputs "out"))
1717 #:tests? #f)) ;; There are no tests indicating a successful
1718 ;; build. Some tests of basic locking mechanisms provided by the
1719 ;; file system are performed during 'make install'. However, these
1720 ;; are performed before the actual build process.
1721 (build-system gnu-build-system)
1722 (inputs `(("exim" ,exim)))
1723 (home-page "http://www.procmail.org/")
1724 (synopsis "Versatile mail delivery agent (MDA)")
1725 (description "Procmail is a mail delivery agent (MDA) featuring support
1726 for a variety of mailbox formats such as mbox, mh and maildir. Incoming mail
1727 can be sorted into separate files/directories and arbitrary commands can be
1728 executed on mail arrival. Procmail is considered stable, but is no longer
1730 (license gpl2+))) ;; procmail allows to choose the
1731 ;; nonfree Artistic License 1.0
1732 ;; as alternative to the GPL2+.
1733 ;; This option is not listed here.
1735 (define-public khard
1741 (uri (pypi-uri name version))
1744 "1shhlq6ljbd8095hd82v4mw56rjcfxf1ymmgknbgh8gix02nsxw1"))))
1745 (build-system python-build-system)
1748 (modify-phases %standard-phases
1749 (add-after 'install 'install-doc
1750 (lambda* (#:key outputs #:allow-other-keys)
1751 (let* ((out (assoc-ref outputs "out"))
1752 (doc (string-append out "/share/doc/khard")))
1753 (copy-recursively "misc/khard" doc)
1755 ;; FIXME: check phase fails with
1756 ;; "Config file /tmp/.config/khard/khard.conf not available"
1759 `(("python-vobject" ,python-vobject)
1760 ("python-pyyaml" ,python-pyyaml)
1761 ("python-atomicwrites" ,python-atomicwrites)
1762 ("python-configobj" ,python-configobj)))
1763 (synopsis "Console address book using CardDAV")
1764 (description "Khard is an address book for the console. It creates, reads,
1765 modifies and removes CardDAV address book entries at your local machine. For
1766 synchronizing with a remote address book, @command{vdirsyncer} is recommended.
1767 Khard can also be used from within the email client @command{mutt}.")
1768 (home-page "https://github.com/scheibler/khard")
1771 (define-public perl-mail-spf
1773 (name "perl-mail-spf")
1779 "mirror://cpan/authors/id/J/JM/JMEHNLE/mail-spf/Mail-SPF-"
1784 "0qk1rfgfm5drj4iyniiabrasrpqv570vzhgz66lwgb67y4amkjv1"))))
1785 (build-system perl-build-system)
1787 `(("perl-module-build" ,perl-module-build)
1788 ("perl-net-dns-resolver-programmable"
1789 ,perl-net-dns-resolver-programmable)))
1791 `(#:phases (modify-phases %standard-phases
1792 (add-before 'configure 'modify-Build.PL
1793 (lambda* (#:key outputs #:allow-other-keys)
1794 (substitute* "Build.PL"
1795 (("'/usr/sbin'") (string-append "'"
1796 (assoc-ref outputs "out")
1800 `(("perl-error" ,perl-error)
1801 ("perl-net-dns" ,perl-net-dns)
1802 ("perl-netaddr-ip" ,perl-netaddr-ip)
1803 ("perl-uri" ,perl-uri)))
1805 "https://metacpan.org/release/Mail-SPF")
1807 "Perl implementation of Sender Policy Framework")
1808 (description "Mail::SPF is the Sender Policy Framework implemented
1812 (define-public mb2md
1819 "http://batleth.sapienti-sat.org/projects/mb2md/mb2md-"
1823 "0bvkky3c90738h3skd2f1b2yy5xzhl25cbh9w2dy97rs86ssjidg"))))
1824 (build-system trivial-build-system)
1826 '(#:modules ((guix build utils))
1829 (use-modules (guix build utils))
1830 (let* ((source (assoc-ref %build-inputs "source"))
1831 (out (assoc-ref %outputs "out"))
1832 (bin (string-append out "/bin"))
1833 (perl (assoc-ref %build-inputs "perl"))
1834 (gzip (assoc-ref %build-inputs "gzip"))
1835 (perl-timedate (assoc-ref %build-inputs "perl-timedate"))
1836 (perl5lib (string-append perl-timedate "/lib/perl5/site_perl")))
1838 (with-directory-excursion bin
1839 (copy-file source "mb2md.gz")
1840 (invoke (string-append gzip "/bin/gzip") "-d" "mb2md.gz")
1841 (substitute* "mb2md"
1842 (("#!/usr/bin/perl")
1843 (string-append "#!/usr/bin/perl -I " perl5lib)))
1844 (patch-shebang "mb2md" (list (string-append perl "/bin")))
1845 (chmod "mb2md" #o555))
1847 (native-inputs `(("gzip" ,gzip)))
1848 (inputs `(("perl" ,perl)
1849 ("perl-timedate" ,perl-timedate)))
1850 (home-page "http://batleth.sapienti-sat.org/projects/mb2md/")
1851 (synopsis "Mbox to maildir converter")
1853 "Mb2md is a Perl script that takes one or more mbox format files and
1854 converts them to maildir format directories.")
1855 (license public-domain)))
1864 (uri (string-append "https://marlam.de/mpop/releases/"
1865 name "-" version ".tar.xz"))
1868 "1skrda7lbks5h0v03ab8bhpg6ma1b63if8x9x3kb2fv70x2pkhqn"))))
1869 (build-system gnu-build-system)
1871 `(("gnutls" ,gnutls)
1872 ("libidn" ,libidn)))
1874 `(("pkg-config" ,pkg-config)))
1875 (home-page "https://marlam.de/mpop/")
1876 (synopsis "POP3 mail client")
1877 (description "mpop is a small and fast POP3 client suitable as a
1878 fetchmail replacement.
1880 mpop supports multiple accounts, header based mail filtering, delivery
1881 to mbox files, maildir folders or a Mail Delivery Agent (MDA),
1882 TLS/SSL, several authentication methods, Internationalized Domain
1883 Names (IDN) and SOCKS proxies.")
1886 (define-public mhonarc
1893 (uri (string-append "mirror://cpan/authors/id/E/EH/EHOOD/MHonArc-"
1897 "0ll3v93yji334zqp6xfzfxc0127pmjcznmai1l5q6dzawrs2igzq"))))
1898 (build-system perl-build-system)
1899 (home-page "https://www.mhonarc.org/")
1900 (synopsis "Create HTML archives of mail/news messages")
1902 "MHonArc is a Perl mail-to-HTML converter. MHonArc
1903 provides HTML mail archiving with index, mail thread linking,
1904 etc; plus other capabilities including support for MIME and
1905 powerful user customization features.")
1909 (define-public sendmail
1917 "ftp://ftp.sendmail.org/pub/sendmail/sendmail."
1921 "0fdl9ndmspqspdlmghzxlaqk56j3yajk52d7jxcg21b7sxglpy94"))))
1922 (build-system gnu-build-system)
1925 (modify-phases %standard-phases
1926 (add-before 'build 'replace-/bin/sh
1930 (list "smrsh/smrsh.c" "sendmail/conf.c" "contrib/mailprio"
1931 "contrib/mmuegel" "devtools/bin/configure.sh")
1932 (find-files "." ".*\\.m4")
1933 (find-files "." ".*\\.cf"))
1934 (("/bin/sh") (which "sh")))
1936 (substitute* "devtools/bin/Build"
1937 (("SHELL=/bin/sh") (string-append "SHELL=" (which "sh"))))
1942 ;; Render harmless any attempts to chown or chgrp
1943 (substitute* "devtools/bin/install.sh"
1944 (("owner=\\$2") "owner=''")
1945 (("group=\\$2") "group=''"))
1947 (with-output-to-file "devtools/Site/site.config.m4"
1950 define(`confCC', `gcc')
1951 define(`confOPTIMIZE', `-g -O2')
1952 define(`confLIBS', `-lresolv')
1953 define(`confINSTALL', `~a/devtools/bin/install.sh')
1954 define(`confDEPEND_TYPE', `CC-M')
1955 define(`confINST_DEP', `')
1960 (invoke "sh" "Build")
1961 (with-directory-excursion "cf/cf"
1962 (copy-file "generic-linux.mc" "sendmail.mc")
1963 (invoke "sh" "Build" "sendmail.cf"))
1965 (add-before 'install 'pre-install
1967 (let ((out (assoc-ref %outputs "out")))
1968 (mkdir-p (string-append out "/usr/bin"))
1969 (mkdir-p (string-append out "/usr/sbin"))
1970 (mkdir-p (string-append out "/etc/mail"))
1971 (setenv "DESTDIR" out)
1972 (with-directory-excursion "cf/cf"
1973 (invoke "sh" "Build" "install-cf"))
1975 ;; There is no make check. There are some post installation tests, but those
1976 ;; require root privileges
1981 (home-page "http://sendmail.org")
1983 "Highly configurable Mail Transfer Agent (MTA)")
1985 "Sendmail is a mail transfer agent (MTA) originally developed by Eric
1986 Allman. It is highly configurable and supports many delivery methods and many
1987 transfer protocols.")
1988 (license (non-copyleft "file://LICENSE"
1989 "See LICENSE in the distribution."))))
1991 (define-public opensmtpd
1997 (uri (string-append "https://www.opensmtpd.org/archives/"
1998 name "-" version ".tar.gz"))
2001 "10bsfsnlg9d9i6l2izdnxp05s3ri8fvwzqxvx1jmarc852382619"))
2002 ;; Fixed upstream: <github.com/OpenSMTPD/OpenSMTPD/pull/835>.
2003 (patches (search-patches "opensmtpd-fix-crash.patch"))))
2004 (build-system gnu-build-system)
2007 ("libressl" ,libressl)
2008 ("libevent" ,libevent)
2010 ("linux-pam" ,linux-pam)
2017 (list "--with-table-db" "--with-auth-pam" "--localstatedir=/var"
2018 "--with-user-smtpd=smtpd" "--with-user-queue=smtpq"
2019 "--with-group-queue=smtpq"
2020 "--with-path-socket=/var/run" ; not default (./configure lies)
2021 "--with-path-CAfile=/etc/ssl/certs/ca-certificates.crt")
2023 (modify-phases %standard-phases
2024 ;; Fix some incorrectly hard-coded external tool file names.
2025 (add-after 'unpack 'patch-FHS-file-names
2026 (lambda* (#:key inputs #:allow-other-keys)
2027 (substitute* "smtpd/smtpctl.c"
2028 (("/bin/cat") (which "cat"))
2029 (("/bin/sh") (which "sh")))
2031 ;; OpenSMTPD provides a single utility smtpctl to control the daemon and
2032 ;; the local submission subsystem. To accomodate systems that require
2033 ;; historical interfaces such as sendmail, newaliases or makemap, the
2034 ;; smtpctl utility can operate in compatibility mode if called with the
2036 (add-after 'install 'install-compability-links
2037 (lambda* (#:key outputs #:allow-other-keys)
2038 (let* ((out (assoc-ref outputs "out"))
2039 (sbin (string-append out "/sbin/")))
2040 (for-each (lambda (command)
2041 (symlink "smtpctl" (string-append sbin command)))
2042 '("makemap" "sendmail" "send-mail"
2043 "newaliases" "mailq")))
2045 (synopsis "Lightweight SMTP daemon")
2047 "OpenSMTPD is an implementation of the server-side SMTP protocol, with
2048 some additional standard extensions. It allows ordinary machines to exchange
2049 e-mails with other systems speaking the SMTP protocol.")
2050 (home-page "https://www.opensmtpd.org")
2051 (license (list bsd-2 bsd-3 bsd-4 (non-copyleft "file://COPYING")
2052 public-domain isc license:openssl))))
2054 (define-public opensmtpd-extras
2056 (name "opensmtpd-extras")
2060 (uri (string-append "https://www.opensmtpd.org/archives/"
2061 name "-" version ".tar.gz"))
2064 "1kld4hxgz792s0cb2gl7m2n618ikzqkj88w5dhaxdrxg4x2c4vdm"))))
2065 (build-system gnu-build-system)
2067 `(("libressl" ,libressl)
2068 ("libevent" ,libevent)
2070 ("python-2" ,python-2)
2071 ("opensmtpd" ,opensmtpd)
2074 ("postgresql" ,postgresql)
2076 ("linux-pam" ,linux-pam)))
2079 ("pkg-config" ,pkg-config)
2081 ("automake" ,automake)
2082 ("autoconf" ,autoconf)))
2084 `(;; We have to configure it like this because the default checks for for example
2085 ;; python in /usr/local/bin, /usr/bin and fails otherwise.
2086 #:configure-flags (list
2087 "--with-filter-clamav" "--with-filter-dkim-signer"
2088 "--with-filter-dnsbl" "--with-filter-lua"
2089 "--with-filter-monkey" "--with-filter-pause"
2090 "--with-filter-perl" "--with-filter-python"
2091 "--with-filter-regex" "--with-filter-spamassassin"
2092 "--with-filter-stub" "--with-filter-trace"
2093 "--with-filter-void"
2095 "--with-queue-null" "--with-queue-python"
2096 "--with-queue-ram" "--with-queue-stub"
2098 "--with-scheduler-python" "--with-scheduler-ram"
2099 "--with-scheduler-stub"
2101 "--with-table-ldap" ; "--with-table-mysql"
2102 "--with-table-passwd" "--with-table-postgres"
2103 "--with-table-python" "--with-table-socketmap"
2104 "--with-table-sqlite" "--with-table-stub"
2105 ;;"--with-table-redis" ; TODO: package hiredis
2107 "--with-user=smtpd" "--with-privsep-user=smtpd"
2108 "--localstatedir=/var" "--sysconfdir=/etc"
2109 "--with-lua-type=lua" ; can use lua or luajit
2111 (string-append "--with-python="
2112 (assoc-ref %build-inputs "python-2"))
2113 (string-append "--with-lua="
2114 (assoc-ref %build-inputs "lua")))))
2115 (license (list bsd-2 bsd-3 bsd-4
2116 public-domain isc license:openssl))
2117 (synopsis "Extra tables, filters, and various other addons for OpenSMTPD")
2119 "This package provides extra tables, filters, and various other addons
2120 for OpenSMTPD to extend its functionality.")
2121 (home-page "https://www.opensmtpd.org")))
2123 (define-public python-mailmanclient
2125 (name "python-mailmanclient")
2130 (uri (pypi-uri "mailmanclient" version))
2133 "0fdfs5g3pf30v2i7w18pdkv9xnfxmfcv66mzv56dck0a1igq07m3"))))
2134 (build-system python-build-system)
2136 `(#:tests? #f)) ; Requires mailman running
2138 `(("python-six" ,python-six)
2139 ("python-httplib2" ,python-httplib2)))
2140 (home-page "https://launchpad.net/mailman.client")
2141 (synopsis "Python bindings for the Mailman 3 REST API")
2143 "The mailmanclient library provides official Python bindings for
2144 the GNU Mailman 3 REST API.")
2147 (define-public python2-mailmanclient
2148 (package-with-python2 python-mailmanclient))
2150 (define-public mlmmj
2157 (uri (string-append "http://mlmmj.org/releases/mlmmj-"
2158 version ".tar.bz2"))
2161 "0hpj10qad821ci11si8xc2qnmkzfn90y13s43fm4fca38f0qjp8w"))))
2162 (build-system gnu-build-system)
2164 `(("perl" ,perl))) ; For "contrib/web/"
2166 `(("pkg-config" ,pkg-config)))
2169 ;; mlmmj-receive-strip is a replacement for mlmmj-receive
2170 ;; It opens the files control/mimedeny and control/mimestrip to get a list
2171 ;; of mimetypes for parts of multipart/mime messages that should be denied
2172 ;; or stripped. The parts then get stripped directly when the mail is
2173 ;; received. mlmmj-receive-strip also appends an extra header
2174 ;; X-ThisMailContainsUnwantedMimeParts: Y when the mail contains unwanted
2176 (list "--enable-receive-strip")
2178 (modify-phases %standard-phases
2179 (add-before 'install 'install-contrib
2180 (lambda* (#:key outputs #:allow-other-keys)
2181 (let* ((out (assoc-ref outputs "out"))
2182 (share (string-append out "/share/mlmmj"))
2183 (contrib (string-append share "/contrib/web"))
2184 (texts (string-append share "/listtexts")))
2185 (copy-recursively "contrib/web/" contrib)
2186 (copy-recursively "listtexts" texts)
2187 (rename-file texts (string-append share "/texts"))
2189 (home-page "http://mlmmj.org")
2190 (synopsis "Mailing list managing made joyful")
2192 "Mlmmj is a simple and slim mailing list manager (MLM) inspired by ezmlm.
2193 It works with many different Mail Transport Agents (MTAs) and is simple for a
2194 system administrator to install, configure and integrate with other software.
2195 As it uses very few resources, and requires no daemons, it is ideal for
2196 installation on systems where resources are limited. Its features include:
2198 @item Archive, Custom headers / footer,
2199 @item Fully automated bounce handling (similar to ezmlm),
2200 @item Complete requeueing functionality, Moderation functionality, Subject prefix,
2201 @item Subscribers only posting, Regular expression access control,
2202 @item Functionality to retrieve old posts, Web interface, Digests,
2203 @item No-mail subscription, VERP support,
2204 @item Delivery Status Notification (RFC1891) support,
2205 @item Rich and customisable texts for automated operations.
2207 (license license:expat)))
2209 (define-public python2-django-mailman3
2211 (name "python2-django-mailman3")
2216 (uri (pypi-uri "django-mailman3" version))
2219 "1xjdkgfjwhgyrp5nxw65dcpcsr98ygj6856sp0bwkrmyxpd1xxk2"))))
2220 (build-system python-build-system)
2223 (modify-phases %standard-phases
2226 (invoke "django-admin"
2228 "--settings=django_mailman3.tests.settings_test"
2229 "django_mailman3"))))
2230 #:python ,python-2))
2232 `(("python2-django" ,python2-django)))
2234 `(("python2-requests" ,python2-requests)
2235 ("python2-requests-oauthlib" ,python2-requests-oauthlib)
2236 ("python2-openid" ,python2-openid)
2237 ("python2-mailmanclient" ,python2-mailmanclient)
2238 ("python2-django-allauth" ,python2-django-allauth)
2239 ("python2-django-gravatar2" ,python2-django-gravatar2)
2240 ("python2-pytz" ,python2-pytz)))
2241 (home-page "https://gitlab.com/mailman/django-mailman3")
2242 (synopsis "Django library for Mailman UIs")
2244 "Libraries and templates for Django-based interfaces
2245 interacting with Mailman.")
2248 (define-public postorius
2255 (uri (pypi-uri "postorius" version "+post2.tar.gz"))
2256 (file-name (string-append name "-" version ".tar.gz"))
2259 "1wymcpv2icjjy8h1ni52p6dr7wwxf71ivqgbqhzx4i82yqphcaq5"))))
2260 (build-system python-build-system)
2262 `(; One test dependency relies on Persona, which was shut down in
2265 ;; The part of the frontend of Mailman is still python 2.7.
2266 #:python ,python-2))
2268 `(("python2-django" ,python2-django)
2269 ("python2-django-mailman3" ,python2-django-mailman3)
2270 ("python2-mailmanclient" ,python2-mailmanclient)))
2271 (home-page "https://gitlab.com/mailman/postorius")
2272 (synopsis "Web user interface for GNU Mailman")
2274 "Postorius is a Django app which provides a web user interface
2275 to access GNU Mailman.")
2276 (license (list gpl3+ lgpl3+))))
2278 (define-public blists
2285 (uri (string-append "http://download.openwall.net/pub/projects/"
2286 "blists/blists-" version ".tar.gz"))
2289 "1xll5wn7py3bbncbwrj172f56nz75c9gwfsa80rwd96ss9gfmp3c"))))
2290 (build-system gnu-build-system)
2292 `(#:tests? #f ; No tests
2294 (modify-phases %standard-phases
2297 (lambda* (#:key outputs #:allow-other-keys)
2298 (let* ((out (assoc-ref outputs "out"))
2299 (bin (string-append out "/bin")))
2300 (install-file "bindex" bin)
2301 (install-file "bit" bin)
2303 (home-page "http://www.openwall.com/blists/")
2304 (synopsis "Web interface to mailing list archives")
2306 "Blists is a web interface to mailing list archives that works off
2307 indexed mbox files. There are two programs: @code{bindex} and @code{bit}.
2308 @code{bindex} generates or updates the index file (incremental updates
2309 are supported). @code{bit} is a CGI/SSI program that generates web pages
2310 on the fly. Both programs are written in C and are very fast.")
2311 (license license:expat)))
2313 (define-public swaks
2316 (version "20170101.0")
2321 "https://jetmore.org/john/code/swaks/files/swaks-"
2325 "0pli4mlhasnqqxmmxalwyg3x7n2vhcbgsnp2xgddamjavv82vrl4"))))
2326 (build-system perl-build-system)
2328 `(("perl-net-dns" ,perl-net-dns)
2329 ("perl-net-ssleay" ,perl-net-ssleay)))
2331 `(#:tests? #f ; No tests
2333 (modify-phases %standard-phases
2337 (invoke "pod2man" "doc/ref.pod" "swaks.1")))
2339 (lambda* (#:key outputs #:allow-other-keys)
2340 (let ((out (assoc-ref outputs "out")))
2341 (install-file "swaks" (string-append out "/bin"))
2342 (install-file "swaks.1" (string-append out "/share/man/man1")))
2344 (add-after 'install 'wrap-program
2345 (lambda* (#:key outputs #:allow-other-keys)
2346 (wrap-program (string-append (assoc-ref outputs "out")
2348 `("PERL5LIB" ":" = (,(getenv "PERL5LIB"))))
2350 (home-page "https://jetmore.org/john/code/swaks/")
2351 (synopsis "Featureful SMTP test tool")
2352 (description "Swaks is a flexible, scriptable, transaction-oriented SMTP
2353 test tool. It handles SMTP features and extensions such as TLS,
2354 authentication, and pipelining; multiple versions of the SMTP protocol
2355 including SMTP, ESMTP, and LMTP; and multiple transport methods including
2356 unix-domain sockets, internet-domain sockets, and pipes to spawned processes.
2357 Options can be specified in environment variables, configuration files, and
2358 the command line allowing maximum configurability and ease of use for
2359 operators and scripters.")
2362 (define-public alpine
2365 (version "2.21.9999")
2369 ;; There are two versions: the plain continuation of Alpine without extra
2370 ;; patches and the version which adds extra fixes. Every distro uses
2371 ;; the patched version, and so do we to not break expectations.
2372 ;; http://alpine.freeiz.com/alpine/readme/README.patches
2373 (uri (string-append "http://repo.or.cz/alpine.git/snapshot/"
2374 "d3e6f3932f2af9deca8eed09e30a55e9bd524362.tar.gz"))
2375 (file-name (string-append name "-" version ".tar.gz"))
2378 "0w4qyybfdxi29r2z3giq0by6aa6v6nrgibh1xgv4d1vwwq4hw35w"))))
2379 (build-system gnu-build-system)
2381 `(#:make-flags (list "CC=gcc")
2382 #:configure-flags (list (string-append "--with-ssl-include-dir="
2383 (assoc-ref %build-inputs "openssl")
2385 (string-append "--with-ssl-dir="
2386 (assoc-ref %build-inputs "openssl"))
2387 (string-append "--with-ssl-certs-dir="
2389 (string-append "--with-ssl-lib-dir="
2390 (assoc-ref %build-inputs "openssl")
2392 (string-append "--with-interactive-spellcheck="
2393 (assoc-ref %build-inputs "aspell")
2396 (modify-phases %standard-phases
2397 (add-after 'unpack 'make-reproducible
2399 ;; This removes time-dependent code to make alpine reproducible.
2400 (substitute* "pico/blddate.c"
2401 (("%02d-%s-%d") "1970-01-01"))
2402 (substitute* (list "alpine/Makefile.in"
2403 "web/src/alpined.d/Makefile.in")
2404 (("`date`") "1970-01-01"))
2407 `(("ncurses" ,ncurses)
2408 ("openssl" ,openssl)
2410 ("openldap" ,openldap)
2411 ("cyrus-sasl" ,cyrus-sasl)
2412 ("mit-krb5" ,mit-krb5)
2415 ("linux-pam" ,linux-pam)))
2416 (home-page "http://repo.or.cz/alpine.git")
2417 (synopsis "Alternatively Licensed Program for Internet News and Email")
2419 "Alpine is a text-based mail and news client. Alpine includes several
2420 tools and applications:
2422 @item alpine, the Alpine mailer
2423 @item pico, the standalone text editor, GNU nano's predecessor
2424 @item pilot, the standalone file system navigator
2428 (define-public balsa
2435 (uri (string-append "https://pawsa.fedorapeople.org/balsa/balsa-"
2436 version ".tar.bz2"))
2439 "15jkwp3ylbwd8iha4dr37z1xb6mkk31ym90vv3h2a5xk2rmym5mq"))))
2440 (build-system gnu-build-system)
2443 '(;; Balsa tries to install additional MIME icons
2444 ;; under gtk+ directory.
2445 "--enable-extra-mimeicons=no"
2446 "--with-gtksourceview"
2448 "--with-spell-checker=gtkspell"
2454 `(("cyrus-sasl" ,cyrus-sasl)
2455 ("enchant" ,enchant)
2456 ("gdk-pixbuf" ,gdk-pixbuf)
2457 ("gmime" ,gmime-2.6)
2461 ("gtksourceview" ,gtksourceview)
2462 ("gtkspell3" ,gtkspell3)
2463 ("libcanberra" ,libcanberra)
2464 ("libesmtp" ,libesmtp)
2465 ("libnotify" ,libnotify)
2466 ("openldap" ,openldap)
2468 ("webkitgtk" ,webkitgtk)))
2470 `(("compface" ,compface)
2471 ("glib" ,glib "bin")
2472 ("intltool" ,intltool)
2473 ("pkg-config" ,pkg-config)
2474 ("yelp-tools" ,yelp-tools)))
2475 (home-page "https://pawsa.fedorapeople.org/balsa")
2476 (synopsis "E-mail client for GNOME")
2477 (description "Balsa is a highly configurable and robust mail client for
2478 the GNOME desktop. It supports both POP3 and IMAP servers as well as the
2479 mbox, maildir and mh local mailbox formats. Balsa also supports SMTP and/or
2480 the use of a local MTA such as Sendmail.")
2490 (uri (pypi-uri "afew" version))
2493 "121w7bd53xyibllxxbfykjj76n81kn1vgjqd22izyh67y8qyyk5r"))))
2494 (build-system python-build-system)
2496 `(("python-chardet" ,python-chardet)
2497 ("python-notmuch" ,python-notmuch)))
2499 `(("python-setuptools-scm" ,python-setuptools-scm)))
2500 (home-page "https://github.com/afewmail/afew")
2501 (synopsis "Initial tagging script for notmuch mail")
2502 (description "afew is an initial tagging script for notmuch mail. It
2503 provides automatic tagging each time new mail is registered with notmuch. It
2504 can add tags based on email headers or Maildir folders and can handle spam and
2515 (uri (string-append "http://pan.rebelbase.com/download/releases/"
2516 version "/source/" name "-" version ".tar.bz2"))
2519 "1b4wamv33hprghcjk903bpvnd233yxyrm18qnh13alc8h1553nk8"))))
2521 `(#:configure-flags '("--with-gtk3" "--with-gtkspell" "--with-gnutls"
2522 "--enable-libnotify" "--enable-manual"
2525 (modify-phases %standard-phases
2526 (add-before 'configure 'patch-gpg2
2527 (lambda* (#:key inputs #:allow-other-keys)
2528 (substitute* "pan/usenet-utils/gpg.cc"
2529 (("\"gpg2\"") (string-append "\""
2530 (assoc-ref inputs "gnupg")
2534 `(("gmime" ,gmime-2.6)
2538 ("gtkspell3" ,gtkspell3)
2539 ("libnotify" ,libnotify)
2540 ("libsecret" ,libsecret)
2541 ("libxml2" ,libxml2)
2544 `(("gettext-minimal" ,gettext-minimal)
2545 ("itstool" ,itstool)
2546 ("pkg-config" ,pkg-config)))
2547 (build-system gnu-build-system)
2548 (home-page "http://pan.rebelbase.com/")
2549 (synopsis "Pan newsreader")
2550 (description "@code{pan} is a Usenet newsreader that's good at both text
2551 and binaries. It supports offline reading, scoring and killfiles, yEnc, NZB,
2552 PGP handling, multiple servers, and secure connections.")
2553 ;; License of the docs: fdl-1.1; Others: gpl2.
2554 (license (list fdl1.1+ gpl2))))
2556 (define-public imapfilter
2564 (url "https://github.com/lefcha/imapfilter.git")
2565 (commit (string-append "v" version))))
2566 (file-name (git-file-name name version))
2568 (base32 "0vzpc54fjf5vb5vx5w0fl20xvx1k9cg6a3hbl86mm8kwsqf3wrab"))))
2569 (build-system gnu-build-system)
2573 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
2576 (modify-phases %standard-phases
2578 (add-after 'unpack 'fix-include-path
2579 (lambda* (#:key inputs #:allow-other-keys)
2580 (let ((pcre (assoc-ref inputs "pcre")))
2581 (substitute* "src/Makefile"
2583 (string-append "INCDIRS ="
2584 "-I" pcre "/include")))
2589 ("openssl" ,openssl)))
2590 (home-page "https://github.com/lefcha/imapfilter")
2591 (synopsis "IMAP mail filtering utility")
2592 (description "IMAPFilter is a mail filtering utility. It connects
2593 to remote mail servers using IMAP, sends searching queries to the server and
2594 processes mailboxes based on the results. It can be used to delete, copy,
2595 move, flag, etc. messages residing in mailboxes at the same or different mail
2596 servers. The 4rev1 and 4 versions of IMAP are supported.")
2597 (license license:expat)))
2599 (define-public urlscan
2606 (uri (pypi-uri "urlscan" version))
2609 "133f28bisr4xj0nihpwpil8dyadss62mp8qgqdyzd676hg9xjfyc"))))
2610 (build-system python-build-system)
2612 `(("python-urwid" ,python-urwid)))
2613 (home-page "https://github.com/firecat53/urlscan")
2614 (synopsis "View/select the URLs in an email message or file")
2616 "Urlscan is a small program that is designed to integrate with the
2617 @code{mutt} mailreader to allow you to easily launch a Web browser for URLs
2618 contained in email messages. It parses an email message or file and scans it
2619 for URLs and email addresses. It then displays the URLs and their context
2620 within the message, and allows you to choose one or more URLs to send to your
2621 Web browser. Alternatively, it send a list of all URLs to stdout. It is a
2622 replacement for the @code{urlview} program.")