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