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