gnu: artanis: Update to 0.3.1.
[jackhill/guix/guix.git] / gnu / packages / mail.scm
CommitLineData
a661e420 1;;; GNU Guix --- Functional package management for GNU
3f3c0ab4 2;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018 Ludovic Courtès <ludo@gnu.org>
ee2b2d2f 3;;; Copyright © 2014, 2015, 2017 Mark H Weaver <mhw@netris.org>
29a7c98a 4;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net>
98e9e22f 5;;; Copyright © 2014 Sou Bunnbu <iyzsong@gmail.com>
f58f767b 6;;; Copyright © 2014 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>
73c0e477 11;;; Copyright © 2015, 2016, 2017, 2018 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>
4a78fd46 18;;; Copyright © 2016, 2017, 2018 Nils Gillmann <ng0@n0.is>
24262239 19;;; Copyright © 2016 Clément Lassieur <clement@lassieur.org>
d72f59a4 20;;; Copyright © 2016, 2017, 2018 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>
864f3f1d 25;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
e9201659 26;;; Copyright © 2017, 2018 Rene Saavedra <pacoon@protonmail.com>
e5fdc334 27;;; Copyright © 2018 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>
a661e420
LC
30;;;
31;;; This file is part of GNU Guix.
32;;;
33;;; GNU Guix is free software; you can redistribute it and/or modify it
34;;; under the terms of the GNU General Public License as published by
35;;; the Free Software Foundation; either version 3 of the License, or (at
36;;; your option) any later version.
37;;;
38;;; GNU Guix is distributed in the hope that it will be useful, but
39;;; WITHOUT ANY WARRANTY; without even the implied warranty of
40;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
41;;; GNU General Public License for more details.
42;;;
43;;; You should have received a copy of the GNU General Public License
44;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
45
1fdd3ee2 46(define-module (gnu packages mail)
59a43334 47 #:use-module (gnu packages)
b0eb2af2 48 #:use-module (gnu packages aspell)
d983a14f 49 #:use-module (gnu packages autotools)
e8435c4d 50 #:use-module (gnu packages backup)
938078a3 51 #:use-module (gnu packages base)
ee886454 52 #:use-module (gnu packages bash)
f8ae32a2 53 #:use-module (gnu packages bison)
fc9a93cb 54 #:use-module (gnu packages calendar)
ac257f12 55 #:use-module (gnu packages check)
938078a3 56 #:use-module (gnu packages compression)
944a5cdd 57 #:use-module (gnu packages crypto)
f58f767b 58 #:use-module (gnu packages curl)
4fd6bf53 59 #:use-module (gnu packages cyrus-sasl)
81ce19f4 60 #:use-module (gnu packages databases)
255d1bbe 61 #:use-module (gnu packages dbm)
d983a14f 62 #:use-module (gnu packages dejagnu)
8a3741e6 63 #:use-module (gnu packages django)
8b53366c 64 #:use-module (gnu packages dns)
938078a3 65 #:use-module (gnu packages docbook)
7a6213cb 66 #:use-module (gnu packages documentation)
d2938d59 67 #:use-module (gnu packages emacs)
e8435c4d 68 #:use-module (gnu packages enchant)
938078a3 69 #:use-module (gnu packages gdb)
aa20b004 70 #:use-module (gnu packages gettext)
938078a3 71 #:use-module (gnu packages ghostscript)
d2938d59 72 #:use-module (gnu packages glib)
e8435c4d 73 #:use-module (gnu packages gnome)
524e1df6 74 #:use-module (gnu packages gnupg)
152ffe7c 75 #:use-module (gnu packages groff)
d6e941bc 76 #:use-module (gnu packages gsasl)
e8435c4d 77 #:use-module (gnu packages gtk)
1ffa7090 78 #:use-module (gnu packages guile)
0791437f 79 #:use-module (gnu packages guile-xyz)
f8ae32a2 80 #:use-module (gnu packages flex)
b0eb2af2 81 #:use-module (gnu packages kerberos)
e8435c4d 82 #:use-module (gnu packages libcanberra)
8b53366c 83 #:use-module (gnu packages libevent)
d6e941bc 84 #:use-module (gnu packages libidn)
d983a14f 85 #:use-module (gnu packages linux)
152ffe7c 86 #:use-module (gnu packages lua)
d983a14f 87 #:use-module (gnu packages m4)
938078a3 88 #:use-module (gnu packages man)
1ffa7090 89 #:use-module (gnu packages ncurses)
938078a3 90 #:use-module (gnu packages networking)
b0eb2af2 91 #:use-module (gnu packages openldap)
c315d370 92 #:use-module (gnu packages onc-rpc)
66cc3ab2 93 #:use-module (gnu packages pcre)
13f04f48 94 #:use-module (gnu packages perl)
938078a3 95 #:use-module (gnu packages pkg-config)
3919a31a 96 #:use-module (gnu packages python)
1b2f753d 97 #:use-module (gnu packages python-web)
44d10b1f 98 #:use-module (gnu packages python-xyz)
1ffa7090 99 #:use-module (gnu packages readline)
938078a3 100 #:use-module (gnu packages ruby)
d2938d59 101 #:use-module (gnu packages search)
224b1c83 102 #:use-module (gnu packages serialization)
1bd3f849 103 #:use-module (gnu packages samba)
6cf27c89 104 #:use-module (gnu packages screen)
cd0322a3 105 #:use-module (gnu packages sqlite)
b0eb2af2 106 #:use-module (gnu packages tcl)
938078a3 107 #:use-module (gnu packages texinfo)
33dc54b0 108 #:use-module (gnu packages time)
a7fd7b68 109 #:use-module (gnu packages tls)
938078a3 110 #:use-module (gnu packages w3m)
be0c5733 111 #:use-module (gnu packages web)
7c16151a 112 #:use-module (gnu packages webkit)
e8435c4d 113 #:use-module (gnu packages xorg)
938078a3 114 #:use-module (gnu packages xml)
d983a14f 115 #:use-module ((guix licenses)
74c903ed
RW
116 #:select (fdl1.1+
117 agpl3+
118 gpl2 gpl2+ gpl3 gpl3+ lgpl2.1 lgpl2.1+ lgpl3+
24262239 119 non-copyleft (expat . license:expat) bsd-3
8b53366c 120 public-domain bsd-4 isc (openssl . license:openssl)
2f3108ad 121 bsd-2 x11-style agpl3 asl2.0 perl-license))
a661e420
LC
122 #:use-module (guix packages)
123 #:use-module (guix download)
f8ae32a2 124 #:use-module (guix git-download)
29a7c98a 125 #:use-module (guix utils)
681a6588 126 #:use-module (guix build-system gnu)
e3a47031 127 #:use-module (guix build-system guile)
ebda902f 128 #:use-module (guix build-system perl)
24262239
CL
129 #:use-module (guix build-system python)
130 #:use-module (guix build-system trivial))
a661e420
LC
131
132(define-public mailutils
133 (package
134 (name "mailutils")
20a3df0f 135 (version "3.5")
a661e420
LC
136 (source (origin
137 (method url-fetch)
138 (uri (string-append "mirror://gnu/mailutils/mailutils-"
20a3df0f 139 version ".tar.xz"))
a661e420
LC
140 (sha256
141 (base32
20a3df0f 142 "1wx275w38fwni2abc8g7g3irbk332vr34byxd72zqfdiznsqgims"))))
a661e420
LC
143 (build-system gnu-build-system)
144 (arguments
de75f0b1
EF
145 '(#:phases
146 (modify-phases %standard-phases
baa6790b 147 (add-before 'check 'prepare-test-suite
de75f0b1
EF
148 (lambda _
149 ;; Use the right file name for `cat'.
150 (substitute* "testsuite/lib/mailutils.exp"
151 (("/bin/cat")
152 (which "cat")))
14253017 153
de75f0b1
EF
154 ;; Tests try to invoke 'maidag' such that it looks up the
155 ;; 'root' user, which does not exist in the build
156 ;; environment.
157 (substitute* "maidag/tests/testsuite"
158 (("root <") "nobody <")
159 (("spool/root") "spool/nobody")
160 (("root@localhost") "nobody@localhost"))
14253017 161
de75f0b1
EF
162 ;; The 'pipeact.at' tests generate a shell script; make
163 ;; sure it uses the right shell.
164 (substitute* '("sieve/tests/testsuite"
165 "mh/tests/testsuite")
166 (("#! /bin/sh")
167 (string-append "#!" (which "sh"))))
14253017 168
de75f0b1
EF
169 (substitute* "mh/tests/testsuite"
170 (("moreproc: /bin/cat")
171 (string-append "moreproc: " (which "cat"))))
14253017 172
de75f0b1
EF
173 ;; XXX: The comsatd tests rely on being able to open
174 ;; /dev/tty, but that gives ENODEV in the build
175 ;; environment. Thus, ignore test failures here.
176 (substitute* "comsat/tests/Makefile.in"
177 (("\\$\\(SHELL\\) \\$\\(TESTSUITE\\)" all)
178 (string-append "-" all)))
14253017 179
baa6790b
LC
180 ;; 'frm' tests expect write access to $HOME.
181 (setenv "HOME" (getcwd))
182
183 ;; Avoid the message "I'm going to create the standard MH path
184 ;; for you", which would lead to one test failure (when diffing
185 ;; stdout of 'fmtcheck'.)
186 (call-with-output-file ".mh_profile"
187 (lambda (port)
188 (format port "Path: ~a/Mail-for-tests~%"
189 (getcwd))))
190
de75f0b1
EF
191 #t)))
192 ;; TODO: Add `--with-sql'.
ac3b4b12
LC
193 #:configure-flags (list "--sysconfdir=/etc"
194
195 ;; Add "/2.2" to the installation directory.
196 (string-append "--with-guile-site-dir="
197 (assoc-ref %outputs "out")
198 "/share/guile/site/2.2"))
199
a661e420 200 #:parallel-tests? #f))
3f3c0ab4 201 (native-inputs
20a3df0f 202 `(("perl" ,perl))) ;for 'gylwrap'
a661e420
LC
203 (inputs
204 `(("dejagnu" ,dejagnu)
205 ("m4" ,m4)
206 ("texinfo" ,texinfo)
20a3df0f 207 ("guile" ,guile-2.2)
1f889cac 208 ("gsasl" ,gsasl)
a661e420
LC
209 ("gnutls" ,gnutls)
210 ("ncurses" ,ncurses)
abe5d2dc 211 ("readline" ,readline)
a661e420 212 ("linux-pam" ,linux-pam)
3246cc91 213 ("libltdl" ,libltdl)
01eafd38 214 ("gdbm" ,gdbm)))
6fd52309 215 (home-page "https://mailutils.org")
f50d2669 216 (synopsis "Utilities and library for reading and serving mail")
a661e420 217 (description
79c311b8
LC
218 "GNU Mailutils is a collection of programs for managing, viewing and
219processing electronic mail. It contains both utilities and server daemons
220and all operate in a protocol-agnostic way. The underlying libraries are
221also available, simplifying the addition of mail capabilities to new
222software.")
a661e420
LC
223 (license
224 ;; Libraries are under LGPLv3+, and programs under GPLv3+.
225 (list gpl3+ lgpl3+))))
d983a14f
AE
226
227(define-public fetchmail
228 (package
229 (name "fetchmail")
230 (version "6.3.26")
231 (source (origin
232 (method url-fetch)
233 (uri (string-append "mirror://sourceforge/fetchmail/branch_6.3/fetchmail-"
234 version ".tar.xz"))
235 (sha256
236 (base32
237 "0l78ayvi9dm8hd190gl139cs2xqsrf7r9ncilslw20mgvd6cbd3r"))))
238 (build-system gnu-build-system)
239 (inputs
240 `(("openssl" ,openssl)))
241 (arguments
242 `(#:configure-flags (list (string-append "--with-ssl="
243 (assoc-ref %build-inputs "openssl")))))
07af3e5e 244 (home-page "http://www.fetchmail.info/")
ae2189a9 245 (synopsis "Remote-mail retrieval and forwarding utility")
d983a14f
AE
246 (description
247 "Fetchmail is a full-featured, robust, well-documented remote-mail
248retrieval and forwarding utility intended to be used over on-demand
249TCP/IP links (such as SLIP or PPP connections). It supports every
250remote-mail protocol now in use on the Internet: POP2, POP3, RPOP, APOP,
251KPOP, all flavors of IMAP, ETRN, and ODMR. It can even support IPv6
252and IPSEC.
253
254Fetchmail retrieves mail from remote mail servers and forwards it via SMTP,
255so it can then be read by normal mail user agents such as mutt, elm
256or BSD Mail. It allows all your system MTA's filtering, forwarding, and
257aliasing facilities to work just as they would on normal mail.")
258 (license gpl2+))) ; most files are actually public domain or x11
13f04f48
AE
259
260(define-public mutt
261 (package
262 (name "mutt")
15285938 263 (version "1.11.0")
13f04f48
AE
264 (source (origin
265 (method url-fetch)
7736bae9
LF
266 (uri (string-append "https://bitbucket.org/mutt/mutt/downloads/"
267 "mutt-" version ".tar.gz"))
13f04f48
AE
268 (sha256
269 (base32
15285938 270 "1qqhkhlzvjj0iih8vm0wfagv4fzqqy1wnsb4sqsfv7w06ccjdjcj"))
fc1adab1 271 (patches (search-patches "mutt-store-references.patch"))))
13f04f48
AE
272 (build-system gnu-build-system)
273 (inputs
4fd6bf53 274 `(("cyrus-sasl" ,cyrus-sasl)
b0bb0136 275 ("gdbm" ,gdbm)
524e1df6 276 ("gpgme" ,gpgme)
4fd6bf53 277 ("ncurses" ,ncurses)
13f04f48
AE
278 ("openssl" ,openssl)
279 ("perl" ,perl)))
280 (arguments
281 `(#:configure-flags '("--enable-smtp"
282 "--enable-imap"
283 "--enable-pop"
524e1df6 284 "--enable-gpgme"
b0bb0136 285 "--enable-hcache" ; for header caching
0323fe80 286 "--enable-sidebar"
13f04f48 287 "--with-ssl"
4fd6bf53 288 "--with-sasl"
13f04f48
AE
289 ;; so that mutt does not check whether the path
290 ;; exists, which it does not in the chroot
291 "--with-mailpath=/var/mail")))
292 (home-page "http://www.mutt.org/")
293 (synopsis "Mail client")
294 (description
295 "Mutt is a small but very powerful text-based mail client for Unix
296operating systems.")
297 (license gpl2+)))
681a6588 298
7596ddf3 299(define-public neomutt
300 (package
7596ddf3 301 (name "neomutt")
46add561 302 (version "20180716")
7596ddf3 303 (source
304 (origin
305 (method url-fetch)
306 (uri (string-append "https://github.com/" name "/" name
307 "/archive/" name "-" version ".tar.gz"))
7596ddf3 308 (sha256
309 (base32
46add561 310 "0072in2d6znwqq461shsaxlf40r4zr7w3j9848qvm4xlh1lq52dx"))))
32fc1ec3 311 (build-system gnu-build-system)
7596ddf3 312 (inputs
313 `(("cyrus-sasl" ,cyrus-sasl)
314 ("gdbm" ,gdbm)
315 ("gpgme" ,gpgme)
316 ("ncurses" ,ncurses)
317 ("gnutls" ,gnutls)
318 ("openssl" ,openssl) ;For smime
319 ("perl" ,perl)
5c95465e 320 ("kyotocabinet" ,kyotocabinet)
7596ddf3 321 ("libxslt" ,libxslt)
322 ("libidn" ,libidn)
323 ("libxml2" ,libxml2)
5c95465e 324 ("lmdb" ,lmdb)
7596ddf3 325 ("notmuch" ,notmuch)))
326 (native-inputs
54a402dd 327 `(("automake" ,automake)
aa20b004 328 ("gettext-minimal" ,gettext-minimal)
54a402dd 329 ("pkg-config" ,pkg-config)
330 ("docbook-xsl" ,docbook-xsl)
f58764d8 331 ("docbook-xml" ,docbook-xml-4.2)
54a402dd 332 ("w3m" ,w3m)
333 ("tcl" ,tcl)))
7596ddf3 334 (arguments
54a402dd 335 `(#:tests? #f
336 #:configure-flags
337 (list "--gpgme"
7596ddf3 338
339 ;; database, implies header caching
54a402dd 340 "--disable-tokyocabinet"
341 "--disable-qdbm"
342 "--disable-bdb"
343 "--lmdb"
344 "--kyotocabinet"
345
346 "--gdbm"
347
348 "--gnutls"
349 "--disable-ssl"
350 "--sasl"
351 (string-append "--with-sasl="
352 (assoc-ref %build-inputs "cyrus-sasl"))
7596ddf3 353
7596ddf3 354
54a402dd 355 "--smime"
356 "--notmuch"
357 "--idn"
7596ddf3 358
359 ;; If we do not set this, neomutt wants to check
360 ;; whether the path exists, which it does not
361 ;; in the chroot. The workaround is this.
362 "--with-mailpath=/var/mail"
363
54a402dd 364 "--with-ui=ncurses"
365 (string-append "--with-ncurses="
366 (assoc-ref %build-inputs "ncurses"))
367 (string-append "--prefix="
368 (assoc-ref %outputs "out"))
369 "--debug")
7596ddf3 370 #:phases
371 (modify-phases %standard-phases
54a402dd 372 ;; TODO: autosetup is meant to be included in the source,
373 ;; but we should package autosetup and use our own version of it.
54a402dd 374 (add-before 'configure 'fix-sasl-test
7596ddf3 375 (lambda _
54a402dd 376 ;; Upstream suggestion to fix the failing sasl autosetup test.
377 (substitute* "auto.def"
378 (("cc-with \\[list -cflags -I\\$prefix/include -libs")
379 "cc-with [list -includes stddef.h -cflags -I$prefix/include -libs"))
380 #t))
381 (replace 'configure
382 (lambda* (#:key outputs inputs configure-flags #:allow-other-keys)
383 (let* ((out (assoc-ref outputs "out"))
384 (flags `(,@configure-flags))
385 (bash (which "bash")))
386 (setenv "SHELL" bash)
387 (setenv "CONFIG_SHELL" bash)
388 (apply invoke bash
389 (string-append (getcwd) "/configure")
390 flags)))))))
7596ddf3 391 (home-page "https://www.neomutt.org/")
392 (synopsis "Command-line mail reader based on Mutt")
393 (description
394 "NeoMutt is a command-line mail reader which is based on mutt.
32fc1ec3 395It adds a large amount of new and improved features to mutt.")
396 (license gpl2+)))
7596ddf3 397
681a6588
MW
398(define-public gmime
399 (package
400 (name "gmime")
8e020519 401 (version "3.2.0")
681a6588
MW
402 (source (origin
403 (method url-fetch)
75630043 404 (uri (string-append "mirror://gnome/sources/gmime/"
29a7c98a 405 (version-major+minor version)
681a6588
MW
406 "/gmime-" version ".tar.xz"))
407 (sha256
408 (base32
8e020519 409 "1q6palbpf6lh6bvy9ly26q5apl5k0z0r4mvl6zzqh90rz4rn1v3m"))))
681a6588
MW
410 (build-system gnu-build-system)
411 (native-inputs
412 `(("pkg-config" ,pkg-config)
413 ("gnupg" ,gnupg))) ; for tests only
414 (inputs `(("glib" ,glib)
415 ("gpgme" ,gpgme)
416 ("zlib" ,zlib)))
417 (arguments
418 `(#:phases
cc955356
EF
419 (modify-phases %standard-phases
420 (add-after
421 'unpack 'patch-paths-in-tests
422 (lambda _
423 ;; The test programs run several programs using 'system' with
ae83dcf6 424 ;; hard-coded paths. Here we patch them all.
425 ;; We use ISO-8859-1 here because test-iconv.c contains
cc955356
EF
426 ;; raw byte sequences in several different encodings.
427 (with-fluids ((%default-port-encoding #f))
428 (substitute* (find-files "tests" "\\.c$")
429 (("(system *\\(\")(/[^ ]*)" all pre prog-path)
430 (let* ((base (basename prog-path))
ae83dcf6 431 (prog (which base)))
cc955356 432 (string-append pre
8e020519
MB
433 (or prog (error "not found: " base)))))))
434 #t)))))
681a6588
MW
435 (home-page "http://spruce.sourceforge.net/gmime/")
436 (synopsis "MIME message parser and creator library")
437 (description
438 "GMime provides a core library and set of utilities which may be used for
439the creation and parsing of messages using the Multipurpose Internet Mail
440Extension (MIME).")
441 (license (list lgpl2.1+ gpl2+ gpl3+))))
442
8e020519
MB
443;; Some packages are not ready for GMime 3 yet.
444(define-public gmime-2.6
445 (package
446 (inherit gmime)
447 (version "2.6.23")
448 (source (origin
449 (method url-fetch)
450 (uri (string-append "mirror://gnome/sources/gmime/"
451 (version-major+minor version)
452 "/gmime-" version ".tar.xz"))
453 (sha256
454 (base32
455 "0slzlzcr3h8jikpz5a5amqd0csqh2m40gdk910ws2hnaf5m6hjbi"))))))
456
a7e59c50
LC
457(define-public bogofilter
458 (package
459 (name "bogofilter")
460 (version "1.2.4")
461 (source (origin
462 (method url-fetch)
463 (uri (string-append "mirror://sourceforge/bogofilter/bogofilter-"
464 version "/bogofilter-"
465 version ".tar.bz2"))
466 (sha256
467 (base32
468 "1d56n2m9inm8gnzm88aa27xl2a7sp7aff3484vmflpqkinjqf0p1"))))
469 (build-system gnu-build-system)
470 (arguments
c55fa42b
EF
471 '(#:phases
472 (modify-phases %standard-phases
473 (add-before 'check 'pre-check
474 (lambda _
475 (substitute* "src/tests/t.frame"
476 (("GREP=/bin/grep")
477 (string-append "GREP=" (which "grep") "\n")))
478 #t)))))
a7e59c50
LC
479 (native-inputs `(("flex" ,flex)))
480 (inputs `(("bdb" ,bdb)))
481 (home-page "http://bogofilter.sourceforge.net/")
482 (synopsis "Mail classifier based on a Bayesian filter")
483 (description
484 "Bogofilter is a mail filter that classifies mail as spam or ham
485 (non-spam) by a statistical analysis of the message's header and
486content (body). The program is able to learn from the user's classifications
487and corrections. It is based on a Bayesian filter.")
488 (license gpl2)))
489
3919a31a
EB
490(define-public offlineimap
491 (package
492 (name "offlineimap")
081915c1 493 (version "7.2.2")
3919a31a 494 (source (origin
bc7c9f77
MB
495 (method git-fetch)
496 (uri (git-reference
497 (url "https://github.com/OfflineIMAP/offlineimap")
498 (commit (string-append "v" version))))
499 (file-name (git-file-name name version))
3919a31a
EB
500 (sha256
501 (base32
081915c1 502 "11nj7y9fa7v6vcxk3wr8smfgm3mxxnmq3l8q69rrjxlfzcv7dl8m"))))
3919a31a 503 (build-system python-build-system)
7a6213cb 504 (native-inputs
4b0e6367 505 `(("asciidoc" ,asciidoc)))
a4ea25d3
EF
506 (inputs `(("python2-pysqlite" ,python2-pysqlite)
507 ("python2-six" ,python2-six)))
3919a31a
EB
508 (arguments
509 ;; The setup.py script expects python-2.
510 `(#:python ,python-2
511 ;; Tests require a modifiable IMAP account.
42aa73b3
EF
512 #:tests? #f
513 #:phases
514 (modify-phases %standard-phases
7a6213cb
MB
515 (add-after 'build 'build-documentation
516 (lambda _
517 (substitute* "docs/Makefile"
518 ;; Prevent xmllint and xsltproc from downloading a DTD file.
519 (("a2x -v") "a2x --no-xmllint --xsltproc-opts=--nonet -v"))
7232c3f5 520 (invoke "make" "-C" "docs" "man")))
7a6213cb
MB
521 (add-after 'install 'install-documentation
522 (lambda* (#:key outputs #:allow-other-keys)
523 (let* ((out (assoc-ref outputs "out"))
524 (man (string-append out "/share/man")))
525 (install-file "docs/offlineimap.1" (string-append man "/man1"))
526 (install-file "docs/offlineimapui.7" (string-append man "/man7"))
527 #t)))
528 (add-after 'install-documentation 'wrap-binary
529 (lambda* (#:key outputs #:allow-other-keys)
42aa73b3
EF
530 (let* ((out (assoc-ref outputs "out"))
531 (bin (string-append out "/bin/offlineimap")))
532 (wrap-program bin
533 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH"))))
534 #t))))))
684633e2 535 (home-page "https://www.offlineimap.org")
31e98ca6 536 (synopsis "Sync emails between two repositories")
3919a31a
EB
537 (description
538 "OfflineImap synchronizes emails between two repositories, so that you
539can read the same mailbox from multiple computers. It supports IMAP as REMOTE
540repository and Maildir/IMAP as LOCAL repository.")
7886e23b 541 (license gpl2+)))
3919a31a 542
3e9750c3
TD
543(define-public emacs-mew
544 (package
545 (name "emacs-mew")
546 (version "6.7")
547 (source (origin
548 (method url-fetch)
8502ff7a 549 (uri (string-append "https://mew.org/Release/mew-"
3e9750c3
TD
550 version ".tar.gz"))
551 (sha256
552 (base32
553 "03fzky2kz73vgx4cbps2psbbnrgqgkk5q7jwfldisymkzr9iz03y"))))
554 (native-inputs
555 `(("emacs" ,emacs)))
556 (propagated-inputs
557 `(("ruby-sqlite3" ,ruby-sqlite3) ; optional for the database of messages
558 ("ruby" ,ruby))) ; to set GEM_PATH so ruby-sqlite3 is found at runtime
559 (build-system gnu-build-system)
560 (arguments
561 (let ((elisp-dir "/share/emacs/site-lisp/guix.d/mew")
562 (icon-dir "/share/mew"))
563 `(#:modules ((guix build gnu-build-system)
564 (guix build utils)
565 (guix build emacs-utils))
566 #:imported-modules (,@%gnu-build-system-modules
567 (guix build emacs-utils))
568 #:configure-flags
569 (list (string-append "--with-elispdir=" %output ,elisp-dir)
570 (string-append "--with-etcdir=" %output ,icon-dir))
571 #:phases
572 (modify-phases %standard-phases
573 (add-after 'configure 'patch-mew-icon-directory
574 (lambda* (#:key outputs #:allow-other-keys)
575 (emacs-substitute-sexps "mew-key.el"
576 ("(def.* mew-icon-directory"
577 `(progn
578 (add-to-list 'image-load-path 'mew-icon-directory)
579 ,(string-append (assoc-ref outputs "out") ,icon-dir))))
580 #t))
581 (add-after 'install 'generate-autoloads
582 (lambda* (#:key outputs #:allow-other-keys)
583 (emacs-generate-autoloads
584 "mew" (string-append (assoc-ref outputs "out") ,elisp-dir))
585 #t)))
586 #:tests? #f)))
8502ff7a 587 (home-page "https://mew.org")
3e9750c3
TD
588 (synopsis "Emacs e-mail client")
589 (description "Mew (Messaging in the Emacs World) is a user interface
590for text messages, multimedia messages (MIME), news articles and
591security functionality including PGP, S/MIME, SSH, and SSL.")
592 (license bsd-3)))
593
d2938d59
EB
594(define-public mu
595 (package
596 (name "mu")
e5fdc334 597 (version "1.0")
d2938d59
EB
598 (source (origin
599 (method url-fetch)
e7b9da24 600 (uri (string-append "https://github.com/djcb/mu/releases/"
e5fdc334
PL
601 "download/v" version "/mu-"
602 version ".tar.xz"))
d2938d59
EB
603 (sha256
604 (base32
e5fdc334 605 "04x5azl19gszw2h7argq666gf9xs4hy9q7w9cbqxvy08n56xqsln"))))
d2938d59
EB
606 (build-system gnu-build-system)
607 (native-inputs
608 `(("pkg-config" ,pkg-config)
9fd571a2 609 ("glib" ,glib "bin") ; for gtester
63298f14 610 ("emacs" ,emacs-minimal)
efe2a283 611 ("tzdata" ,tzdata-for-tests))) ;for mu/test/test-mu-query.c
d2938d59
EB
612 ;; TODO: Add webkit and gtk to build the mug GUI.
613 (inputs
614 `(("xapian" ,xapian)
d59ec129 615 ("guile" ,guile-2.2)
d2938d59 616 ("glib" ,glib)
8e020519 617 ("gmime" ,gmime-2.6)))
d2938d59 618 (arguments
704f2196
AK
619 `(#:modules ((guix build gnu-build-system)
620 (guix build utils)
621 (guix build emacs-utils))
622 #:imported-modules (,@%gnu-build-system-modules
623 (guix build emacs-utils))
624 #:phases
99404fff 625 (modify-phases %standard-phases
e62e975b 626 (add-after 'unpack 'patch-configure
789bda83
AK
627 ;; By default, elisp code goes to "share/emacs/site-lisp/mu4e",
628 ;; so our Emacs package can't find it. Setting "--with-lispdir"
629 ;; configure flag doesn't help because "mu4e" will be added to
630 ;; the lispdir anyway, so we have to modify "configure.ac".
631 (lambda _
e62e975b 632 (substitute* "configure"
d59ec129
RW
633 (("^ +lispdir=\"\\$\\{lispdir\\}/mu4e/\".*") "")
634 ;; Use latest Guile
635 (("guile-2.0") "guile-2.2"))
636 (substitute* '("guile/Makefile.in"
637 "guile/mu/Makefile.in")
638 (("share/guile/site/2.0/") "share/guile/site/2.2/"))
789bda83 639 #t))
3481c714
MC
640 (add-after 'patch-configure 'fix-date-tests
641 ;; Loosen test tolerances to prevent failures caused by daylight
642 ;; saving time (DST). See: https://github.com/djcb/mu/issues/1214.
643 (lambda _
644 (substitute* "lib/parser/test-utils.cc"
645 (("\\* 60 \\* 60, 1 },")
646 "* 60 * 60, 3600 + 1 },"))
647 #t))
c9dc4577
RW
648 (add-before 'install 'fix-ffi
649 (lambda* (#:key outputs #:allow-other-keys)
650 (substitute* "guile/mu.scm"
651 (("\"libguile-mu\"")
652 (format #f "\"~a/lib/libguile-mu\""
653 (assoc-ref outputs "out"))))
654 #t))
99404fff
AK
655 (add-before 'check 'check-tz-setup
656 (lambda* (#:key inputs #:allow-other-keys)
657 ;; For mu/test/test-mu-query.c
658 (setenv "TZDIR"
659 (string-append (assoc-ref inputs "tzdata")
660 "/share/zoneinfo"))
704f2196
AK
661 #t))
662 (add-after 'install 'install-emacs-autoloads
663 (lambda* (#:key outputs #:allow-other-keys)
664 (emacs-generate-autoloads
665 "mu4e"
666 (string-append (assoc-ref outputs "out")
667 "/share/emacs/site-lisp"))
99404fff 668 #t)))))
d2938d59
EB
669 (home-page "http://www.djcbsoftware.nl/code/mu/")
670 (synopsis "Quickly find emails")
671 (description
672 "Mu is a tool for dealing with e-mail messages stored in the
673Maildir-format. Mu's purpose in life is to help you to quickly find the
674messages you need; in addition, it allows you to view messages, extract
675attachments, create new maildirs, and so on.")
676 (license gpl3+)))
677
a2cb16b0
TS
678(define-public alot
679 (package
680 (name "alot")
3f81ca32 681 (version "0.5.1")
a2cb16b0
TS
682 (source (origin
683 (method url-fetch)
1b94f182
TS
684 ;; package author intends on distributing via github rather
685 ;; than pypi:
686 ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331
a2cb16b0
TS
687 (uri (string-append "https://github.com/pazz/alot/archive/"
688 version ".tar.gz"))
689 (file-name (string-append "alot-" version ".tar.gz"))
690 (sha256
691 (base32
3f81ca32 692 "0wax30hjzmkqfml7hig1dqw1v1y63yc0cgbzl96x58b9h2ggqx3a"))))
a2cb16b0
TS
693 (build-system python-build-system)
694 (arguments
3f81ca32 695 `(;; python 3 is currently unsupported, more info:
fe3b8862 696 ;; https://github.com/pazz/alot/blob/master/docs/source/faq.rst
a2cb16b0 697 #:python ,python-2))
3f81ca32
TS
698 (native-inputs
699 `(("python2-mock" ,python2-mock)))
a2cb16b0
TS
700 (inputs
701 `(("python2-magic" ,python2-magic)
702 ("python2-configobj" ,python2-configobj)
703 ("python2-twisted" ,python2-twisted)
704 ("python2-urwid" ,python2-urwid)
705 ("python2-urwidtrees" ,python2-urwidtrees)
706 ("python2-pygpgme" ,python2-pygpgme)
707 ("python2-notmuch" ,python2-notmuch)))
708 (home-page "https://github.com/pazz/alot")
cfcfc6ab 709 (synopsis "Command-line MUA using @code{notmuch}")
a2cb16b0 710 (description
cfcfc6ab 711 "Alot is an experimental terminal mail user agent (@dfn{MUA}) based on
a2cb16b0
TS
712@code{notmuch} mail. It is written in Python using the @code{urwid} toolkit.")
713 (license gpl3+)))
714
0350a8bb
HG
715(define-public notifymuch
716 (let
717 ((commit "9d4aaf54599282ce80643b38195ff501120807f0")
718 (revision "1"))
719 (package
720 (name "notifymuch")
721 (version (string-append "0.1-" revision "." (string-take commit 7)))
722 (source
723 (origin
724 (method git-fetch)
725 (uri (git-reference
726 (url "https://github.com/kspi/notifymuch.git")
727 (commit commit)))
728 (sha256
729 (base32
730 "1lssr7iv43mp5v6nzrfbqlfzx8jcc7m636wlfyhhnd8ydd39n6k4"))
731 (file-name (string-append name "-" version "-checkout"))))
732 (build-system python-build-system)
733 (inputs
734 `(("python-notmuch" ,python-notmuch)
735 ("python-pygobject" ,python-pygobject)
736 ("gobject-introspection" ,gobject-introspection)
737 ("libnotify" ,libnotify)
738 ("gtk+" ,gtk+)))
739 (arguments
740 `(#:phases
741 (modify-phases %standard-phases
742 (add-after 'install 'wrap-binary
743 (lambda* (#:key outputs #:allow-other-keys)
744 (let* ((out (assoc-ref outputs "out"))
745 (bin (string-append out "/bin/notifymuch")))
746 (wrap-program bin
747 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH")))
748 `("GI_TYPELIB_PATH" ":" prefix
749 (,(getenv "GI_TYPELIB_PATH")
750 ,(string-append out "/lib/girepository-1.0")))))
751 #t)))))
752 (home-page "https://github.com/kspi/notifymuch")
753 (synopsis "Displays notifications for changes in the notmuch email database")
754 (description "notifymuch displays desktop notifications for messages in
755the notmuch database. The notifications are sent using libnotify to a
756notification daemon. The query to find messages to send a notification about
757is configurable, and a notification for the same message will not be send
758within a configurable period (defaults to 48 hours). To use notifymuch, run
759@command{notifymuch} after new mail is indexed, this can be automated by
760invoking @command{notifymuch} from the post-new hook.")
761 (license gpl3))))
762
1bd3f849
DT
763(define-public notmuch
764 (package
765 (name "notmuch")
a908ffd1 766 (version "0.28")
1bd3f849
DT
767 (source (origin
768 (method url-fetch)
866fade9 769 (uri (string-append "https://notmuchmail.org/releases/notmuch-"
1bd3f849
DT
770 version ".tar.gz"))
771 (sha256
772 (base32
a908ffd1 773 "0dqarmjc8544m2w7bqrqmvsfy55fw82707z3lz9cql8nr777bjmc"))))
1bd3f849
DT
774 (build-system gnu-build-system)
775 (arguments
d738f134
AI
776 `(#:modules ((guix build gnu-build-system)
777 ((guix build emacs-build-system) #:prefix emacs:)
778 (guix build utils))
779 #:imported-modules (,@%gnu-build-system-modules
780 (guix build emacs-build-system)
781 (guix build emacs-utils))
782 #:make-flags (list "V=1") ; Verbose test output.
eb537f57 783 #:phases (modify-phases %standard-phases
6cf27c89
MB
784 (add-after 'unpack 'patch-notmuch-lib.el
785 (lambda _
786 (substitute* "emacs/notmuch-lib.el"
787 (("/bin/sh") (which "sh")))
788 #t))
eb537f57
DT
789 (replace 'configure
790 (lambda* (#:key outputs #:allow-other-keys)
791 (setenv "CC" "gcc")
792 (setenv "CONFIG_SHELL" (which "sh"))
ee886454 793
d738f134
AI
794 (let* ((out (assoc-ref outputs "out"))
795 (elisp
796 (string-append out "/share/emacs/site-lisp/guix.d/"
797 ,name "-" ,version)))
82d2dfa0
TGR
798 (invoke "./configure"
799 (string-append "--prefix=" out)
800 (string-append "--emacslispdir=" elisp)
801 (string-append "--emacsetcdir=" elisp)))))
6cf27c89
MB
802 (add-before 'check 'prepare-test-environment
803 (lambda _
804 (setenv "TEST_CC" "gcc")
805 ;; Patch various inline shell invocations.
806 (substitute* (find-files "test" "\\.sh$")
807 (("/bin/sh") (which "sh")))
d738f134
AI
808 #t))
809 (add-after 'install 'make-autoloads
810 (assoc-ref emacs:%standard-phases 'make-autoloads)))))
1bd3f849 811 (native-inputs
2c5b91dc 812 `(("bash-completion" ,bash-completion)
6cf27c89 813 ("emacs" ,emacs-no-x) ; Minimal lacks libxml, needed for some tests.
2c5b91dc 814 ("pkg-config" ,pkg-config)
ee886454 815 ("python" ,python-2)
eb537f57 816 ("python-docutils" ,python2-docutils)
6cf27c89
MB
817 ("python-sphinx" ,python2-sphinx)
818
819 ;; The following are required for tests only.
820 ("which" ,which)
821 ("dtach" ,dtach)
822 ("gnupg" ,gnupg)
823 ("man" ,man-db)
824 ("perl" ,perl)))
1bd3f849 825 (inputs
2c5b91dc 826 `(("glib" ,glib)
1bd3f849
DT
827 ("gmime" ,gmime)
828 ("talloc" ,talloc)
829 ("xapian" ,xapian)
830 ("zlib" ,zlib)))
540d6cc7 831 (home-page "https://notmuchmail.org/")
1bd3f849
DT
832 (synopsis "Thread-based email index, search, and tagging")
833 (description
834 "Notmuch is a command-line based program for indexing, searching, read-
835ing, and tagging large collections of email messages.")
836 (license gpl3+)))
837
8a75c589 838(define-public notmuch-addrlookup-c
a5d6b0a3
TS
839 ;; This commit includes a compatibility fix for notmuch-0.25, and is not
840 ;; currently part of any release. Please update this package when
841 ;; notmuch-addrlookup-c-9 is released.
842 (let ((commit "88f156d04990a71c6ad6fc2757b537b44e3c4d00")
843 (revision "1")) ;Guix package revision
844 (package
845 (name "notmuch-addrlookup-c")
846 (version (string-append "8-" revision "."
847 (string-take commit 7)))
848 (source (origin
849 (method git-fetch)
850 (uri (git-reference
851 (url "https://github.com/aperezdc/notmuch-addrlookup-c.git")
852 (commit commit)))
853 (file-name (string-append name "-" version "-checkout"))
854 (sha256
855 (base32
856 "0v0wzs7qzy4n1hbql8s10qrwgalcxdzbxf8pj6cii1pv2jwmkxbm"))))
857 (build-system gnu-build-system)
858 (arguments
859 '(#:tests? #f ; no tests
860 #:make-flags (list "CC=gcc"
861 (string-append "PREFIX="
862 (assoc-ref %outputs "out")))
863 #:phases (modify-phases %standard-phases
864 (delete 'configure)
865 ;; Remove vim code completion config, it's not needed to
866 ;; build (or be patched).
867 (add-before 'patch-source-shebangs 'delete-ycm-file
868 (lambda _ (delete-file ".ycm_extra_conf.py")))
869 (replace 'install
870 (lambda* (#:key outputs #:allow-other-keys)
871 (let ((bin (string-append
872 (assoc-ref outputs "out") "/bin")))
873 (install-file "notmuch-addrlookup" bin)))))))
874 (native-inputs
875 `(("pkg-config" ,pkg-config)))
876 (inputs
877 `(("glib" ,glib)
878 ("notmuch" ,notmuch)))
879 (home-page "https://github.com/aperezdc/notmuch-addrlookup-c")
880 (synopsis "Address lookup tool for Notmuch")
881 (description "This is an address lookup tool using a Notmuch database,
8a75c589 882useful for email address completion.")
a5d6b0a3 883 (license license:expat))))
8a75c589 884
4b6909bc
TS
885(define-public python-notmuch
886 (package
887 (name "python-notmuch")
540d6cc7 888 (version (package-version notmuch))
4b6909bc
TS
889 ;; Notmuch python bindings are now unavailable on pypi. The
890 ;; bindings are distributed via the notmuch release tarball.
891 (source (package-source notmuch))
892 (build-system python-build-system)
893 (inputs `(("notmuch" ,notmuch)))
894 (arguments
895 `(#:tests? #f ; no "test" target
896 #:phases
897 (modify-phases %standard-phases
898 ;; This python package lives in a subdirectory of the notmuch source
899 ;; tree, so chdir into it before building.
900 (add-after 'unpack 'enter-python-dir
901 (lambda _ (chdir "bindings/python") #t))
902 ;; Make sure the correct notmuch shared library gets loaded.
903 (add-before 'build 'set-libnotmuch-file-name
904 (lambda* (#:key inputs #:allow-other-keys)
905 (let ((notmuch (assoc-ref inputs "notmuch")))
906 (substitute* "notmuch/globals.py"
907 (("libnotmuch\\.so\\.")
908 (string-append notmuch "/lib/libnotmuch.so.")))
909 #t))))))
540d6cc7 910 (home-page (package-home-page notmuch))
4b6909bc
TS
911 (synopsis "Python bindings of the Notmuch mail indexing library")
912 (description
913 "This package provides Python bindings to use the Notmuch mail indexing
914and search library.")
915 (license gpl3+)))
916
1c74da21 917(define-public python2-notmuch
caa6fc89 918 (package-with-python2 python-notmuch))
1c74da21 919
98e9e22f
SB
920(define-public getmail
921 (package
922 (name "getmail")
36e8cfa1 923 (version "5.6")
98e9e22f
SB
924 (source
925 (origin
926 (method url-fetch)
927 (uri (string-append "http://pyropus.ca/software/getmail/old-versions/"
928 name "-" version ".tar.gz"))
929 (sha256
930 (base32
36e8cfa1 931 "16nmvj80szr6yvcxxgmxn2lxqpjqqj4xg5a0b66zhvck6j42q3a6"))))
98e9e22f
SB
932 (build-system python-build-system)
933 (arguments
934 `(#:tests? #f ; no tests
935 #:python ,python-2))
936 (home-page "http://pyropus.ca/software/getmail/")
937 (synopsis "Mail retriever")
938 (description
939 "A flexible, extensible mail retrieval system with support for
940POP3, IMAP4, SSL variants of both, maildirs, mboxrd files, external MDAs,
941arbitrary message filtering, single-user and domain-mailboxes, and many other
942useful features.")
943
944 ;; License is specified in file '__init__.py'.
945 (license gpl2)))
946
f58f767b
JL
947(define-public libetpan
948 (package
949 (name "libetpan")
8f2253af 950 (version "1.9.2")
f58f767b 951 (source (origin
aae96f8f
TGR
952 (method git-fetch)
953 (uri (git-reference
954 (url "https://github.com/dinhviethoa/libetpan.git")
955 (commit version)))
956 (file-name (git-file-name name version))
f58f767b 957 (sha256
8f2253af 958 (base32 "13jiy2ddxbp9f2mk1mip9sk8h97bva5m0pnq2mlvh5xhifs6gza4"))))
f58f767b 959 (build-system gnu-build-system)
464f5447 960 (native-inputs `(("autoconf" ,autoconf-wrapper)
f58f767b 961 ("automake" ,automake)
3246cc91 962 ("libtool" ,libtool)
f58f767b
JL
963 ("pkg-config" ,pkg-config)))
964 (propagated-inputs
965 ;; 'libetpan-config --libs' returns '-lssl -lcrypto -lsasl2', so these
966 ;; libraries need to be propagated.
967 `(("cyrus-sasl" ,cyrus-sasl)
968 ("openssl" ,openssl)))
969 (inputs
970 `(("curl" ,curl)
c1748912
EF
971 ("expat" ,expat)
972 ("zlib" ,zlib)))
f58f767b 973 (arguments
602460ea
EF
974 '(#:phases
975 (modify-phases %standard-phases
976 (add-after 'unpack 'autogen
977 (lambda _
978 (setenv "NOCONFIGURE" "true")
df22b95c 979 (invoke "sh" "autogen.sh"))))
f58f767b
JL
980 #:configure-flags
981 '("--disable-static" "--disable-db")))
81fb037f 982 (home-page "https://www.etpan.org/libetpan.html")
f58f767b
JL
983 (synopsis "Portable middleware for email access")
984 (description
985 "The purpose of this mail library is to provide a portable, efficient
986framework for different kinds of mail access: IMAP, SMTP, POP and NNTP. It
987provides an API for C language. It's the low-level API used by MailCore and
988MailCore 2.")
a979eea9 989 (license bsd-3)))
f58f767b 990
ee6e780b
DM
991(define-public compface
992 (package
993 (name "compface")
994 (version "1.5.2")
995 (source (origin
996 (method url-fetch)
997 (uri (string-append "https://ftp.heanet.ie/mirrors/"
998 "ftp.xemacs.org/aux/"
999 name "-" version ".tar.gz"))
1000 (sha256
1001 (base32
1002 "09b89wg63hg502hsz592cd2h87wdprb1dq1k1y07n89hym2q56d6"))))
1003 (build-system gnu-build-system)
1004 (arguments
1005 `(#:tests? #f))
1006 (synopsis "Portrait image compressor")
1007 (description "This packages takes your 48x48x1 portrait image and
1008compresses it.")
1009 (home-page "http://www.cs.indiana.edu/pub/faces/")
1010 (license (x11-style "file://README"))))
1011
e8435c4d
JL
1012(define-public claws-mail
1013 (package
1014 (name "claws-mail")
23ae876b 1015 (version "3.17.3")
e8435c4d
JL
1016 (source (origin
1017 (method url-fetch)
1018 (uri (string-append
ca6f5ab8 1019 "https://www.claws-mail.org/releases/claws-mail-" version
6ea4b094 1020 ".tar.xz"))
e8435c4d 1021 (sha256
ec92806a 1022 (base32
23ae876b 1023 "1wnj6c9cbmhphs2l6wfvndkk2g08rmxw0sl2c8k1k008dxd1ykjh"))))
e8435c4d
JL
1024 (build-system gnu-build-system)
1025 (native-inputs `(("pkg-config" ,pkg-config)))
1026 (inputs `(("bogofilter" ,bogofilter)
1027 ("curl" ,curl)
1028 ("dbus-glib" ,dbus-glib)
e8435c4d
JL
1029 ("enchant" ,enchant)
1030 ("expat" ,expat)
1031 ("ghostscript" ,ghostscript)
1032 ("hicolor-icon-theme" ,hicolor-icon-theme)
1033 ("gnupg" ,gnupg)
1034 ("gnutls" ,gnutls)
1035 ("gpgme" ,gpgme)
1036 ("gtk" ,gtk+-2)
1037 ("libarchive" ,libarchive)
1038 ("libcanberra" ,libcanberra)
1039 ("libetpan" ,libetpan)
fc9a93cb 1040 ("libical" ,libical)
e8435c4d
JL
1041 ("libnotify" ,libnotify)
1042 ("libsm" ,libsm)
1043 ("libxml2" ,libxml2)
1044 ("perl" ,perl)
f6292baf
EB
1045 ("python-2" ,python-2)
1046 ("mime-info" ,shared-mime-info)))
e8435c4d
JL
1047 (arguments
1048 '(#:configure-flags
f6292baf 1049 '("--enable-gnutls" "--enable-pgpmime-plugin" "--enable-enchant")
ff4192ff
DM
1050 #:make-flags
1051 ;; Disable updating icon cache since it's done by the profile hook.
1052 ;; Conflict with other packages in the profile would be inevitable
1053 ;; otherwise.
1054 '("gtk_update_icon_cache=true")
f6292baf
EB
1055 #:phases (modify-phases %standard-phases
1056 (add-before 'build 'patch-mime
1057 (lambda* (#:key inputs #:allow-other-keys)
1058 (substitute* "src/procmime.c"
1059 (("/usr/share/mime/globs")
1060 (string-append (assoc-ref inputs "mime-info")
1061 "/share/mime/globs"))))))))
e8435c4d
JL
1062 (synopsis "GTK-based Email client")
1063 (description
1064 "Claws-Mail is an email client (and news reader) based on GTK+. The
1065appearance and interface are designed to be familiar to new users coming from
1066other popular email clients, as well as experienced users. Almost all commands
1067are accessible with the keyboard. Plus, Claws-Mail is extensible via addons
1068which can add many functionalities to the base client.")
ba5c926c 1069 (home-page "https://www.claws-mail.org/")
e8435c4d
JL
1070 (license gpl3+))) ; most files are actually public domain or x11
1071
d6e941bc
1072(define-public msmtp
1073 (package
1074 (name "msmtp")
1460e77a 1075 (version "1.8.1")
d6e941bc
1076 (source
1077 (origin
1078 (method url-fetch)
1a80f1a9 1079 (uri (string-append "https://marlam.de/msmtp/releases/"
d23d1ddf
LF
1080 "/msmtp-" version ".tar.xz"))
1081 (sha256
1082 (base32
1460e77a 1083 "1nm4vizrnrrnknc4mc8nr7grz9q76m1vraa0hsl5rfm34gnsg8ph"))))
d6e941bc
1084 (build-system gnu-build-system)
1085 (inputs
91b3a6d4 1086 `(("libsecret" ,libsecret)
d6e941bc
1087 ("gnutls" ,gnutls)
1088 ("zlib" ,zlib)
1089 ("gsasl" ,gsasl)))
1090 (native-inputs
1091 `(("pkg-config" ,pkg-config)))
1a80f1a9 1092 (home-page "https://marlam.de/msmtp/")
d6e941bc
1093 (arguments
1094 `(#:configure-flags (list "--with-libgsasl"
1095 "--with-libidn"
823e2ed4
LF
1096 "--with-tls=gnutls")
1097 #:phases
1098 (modify-phases %standard-phases
1099 (add-after 'install 'install-msmtpq
1100 (lambda* (#:key outputs #:allow-other-keys)
1101 (let* ((out (assoc-ref outputs "out"))
1102 (bin (string-append out "/bin"))
1103 (doc (string-append out "/share/doc/msmtp"))
1104 (msmtpq (string-append "scripts/msmtpq")))
1105 (install-file (string-append msmtpq "/msmtpq") bin)
1106 (install-file (string-append msmtpq "/msmtp-queue") bin)
1107 (install-file (string-append msmtpq "/README.msmtpq") doc)
1108 #t))))))
d6e941bc
1109 (synopsis
1110 "Simple and easy to use SMTP client with decent sendmail compatibility")
1111 (description
1112 "msmtp is an SMTP client. In the default mode, it transmits a mail to
1113an SMTP server (for example at a free mail provider) which takes care of further
1114delivery.")
1115 (license gpl3+)))
1116
66cc3ab2
TUBK
1117(define-public exim
1118 (package
1119 (name "exim")
354c493f 1120 (version "4.90.1")
66cc3ab2
TUBK
1121 (source
1122 (origin
1123 (method url-fetch)
354c493f 1124 (uri (list (string-append "https://ftp.exim.org/pub/exim/exim4/exim-"
fc6fdc05 1125 version ".tar.bz2")
354c493f 1126 (string-append "https://ftp.exim.org/pub/exim/exim4/old/exim-"
fc6fdc05 1127 version ".tar.bz2")))
66cc3ab2 1128 (sha256
513f8ab4 1129 (base32
354c493f 1130 "1w6blvvrd87c649j8xpag034md2w1ib0db9c4ijqbzc5dh2i1xfq"))))
66cc3ab2
TUBK
1131 (build-system gnu-build-system)
1132 (inputs
1133 `(("bdb" ,bdb)
1134 ("gnutls" ,gnutls)
1135 ("gzip" ,gzip)
1136 ("bzip2" ,bzip2)
1137 ("xz" ,xz)
66cc3ab2 1138 ("perl" ,perl)
c315d370 1139 ("libnsl" ,libnsl)
66cc3ab2
TUBK
1140 ("libxt" ,libxt)
1141 ("libxaw" ,libxaw)))
1142 (native-inputs
42773138
EF
1143 `(("pcre" ,pcre "bin")
1144 ("perl" ,perl)))
66cc3ab2
TUBK
1145 (arguments
1146 '(#:phases
dc1d3cde
KK
1147 (modify-phases %standard-phases
1148 (replace 'configure
1149 ;; We'd use #:make-flags but the top-level Makefile calls others
1150 ;; recursively, so just set all variables this way.
1151 (lambda* (#:key outputs inputs #:allow-other-keys)
1152 (substitute* '("Makefile" "OS/Makefile-Default")
1153 (("(RM_COMMAND=).*" all var)
1154 (string-append var "rm\n")))
1155 (copy-file "src/EDITME" "Local/Makefile")
1156 (copy-file "exim_monitor/EDITME" "Local/eximon.conf")
1157 (let ((out (assoc-ref outputs "out"))
1158 (gzip (assoc-ref inputs "gzip"))
1159 (bzip2 (assoc-ref inputs "bzip2"))
1160 (xz (assoc-ref inputs "xz")))
1161 (substitute* '("Local/Makefile")
1162 (("(BIN_DIRECTORY=).*" all var)
1163 (string-append var out "/bin\n"))
1164 (("(CONFIGURE_FILE=).*" all var)
1165 (string-append var out "/etc/exim.conf\n"))
1166 (("(EXIM_USER=).*" all var)
1167 (string-append var "nobody\n"))
1168 (("(FIXED_NEVER_USERS=).*" all var)
1169 (string-append var "\n")) ;XXX no root in build environment
1170 (("(COMPRESS_COMMAND=).*" all var)
1171 (string-append var gzip "/bin/gzip\n"))
1172 (("(ZCAT_COMMAND=).*" all var)
1173 (string-append var gzip "/bin/zcat\n")))
1174 ;; This file has hardcoded names for tools despite the zcat
1175 ;; configuration above.
1176 (substitute* '("src/exigrep.src")
1177 (("'zcat'") (string-append "'" gzip "/bin/zcat'"))
1178 (("'bzcat'") (string-append "'" bzip2 "/bin/bzcat'"))
1179 (("'xzcat'") (string-append "'" xz "/bin/xzcat'"))
1180 (("'lzma'") (string-append "'" xz "/bin/lzma'"))))
1181 #t))
1182 (add-before 'build 'fix-sh-paths
1183 (lambda* (#:key inputs #:allow-other-keys)
1184 (substitute* '("scripts/lookups-Makefile" "scripts/reversion")
1185 (("SHELL=/bin/sh") "SHELL=sh"))
1186 (substitute* '("scripts/Configure-config.h")
1187 (("\\| /bin/sh") "| sh"))
1188 (let ((bash (assoc-ref inputs "bash")))
1189 (substitute* '("scripts/Configure-eximon")
1190 (("#!/bin/sh") (string-append "#!" bash "/bin/sh"))))
1191 #t)))
66cc3ab2
TUBK
1192 #:make-flags '("INSTALL_ARG=-no_chown")
1193 ;; No 'check' target.
1194 #:tests? #f))
85a9ffcb 1195 (home-page "https://www.exim.org/")
66cc3ab2
TUBK
1196 (synopsis
1197 "Message Transfer Agent (MTA) developed at the University of Cambridge")
1198 (description
1199 "Exim is a message transfer agent (MTA) developed at the University of
1200Cambridge for use on Unix systems connected to the Internet. In style it is
1201similar to Smail 3, but its facilities are more general. There is a great
1202deal of flexibility in the way mail can be routed, and there are extensive
1203facilities for checking incoming mail.")
1204 (license gpl2+)))
1205
7d2b784b
MW
1206(define-public dovecot
1207 (package
1208 (name "dovecot")
bc6062ae 1209 (version "2.3.4")
7d2b784b
MW
1210 (source
1211 (origin
1212 (method url-fetch)
c8608faf 1213 (uri (string-append "https://www.dovecot.org/releases/"
7d2b784b
MW
1214 (version-major+minor version) "/"
1215 name "-" version ".tar.gz"))
4d6ce834 1216 (sha256 (base32
bc6062ae 1217 "01ggzf7b3jpl89mjiqr7xbpbs181g2gjf6wzg70qaqfzz3ppc6yr"))))
7d2b784b
MW
1218 (build-system gnu-build-system)
1219 (native-inputs
1220 `(("pkg-config" ,pkg-config)))
1221 (inputs
1222 `(("openssl" ,openssl)
1223 ("zlib" ,zlib)
1224 ("bzip2" ,bzip2)
fd5c70f8
AW
1225 ("sqlite" ,sqlite)
1226 ("linux-pam" ,linux-pam)))
7d2b784b
MW
1227 (arguments
1228 `(#:configure-flags '("--sysconfdir=/etc"
1229 "--localstatedir=/var")
1230 #:phases (modify-phases %standard-phases
1231 (add-before
1232 'configure 'pre-configure
1233 (lambda _
15ff38f1 1234 ;; Simple hack to avoid installing in /etc.
7d2b784b
MW
1235 (substitute* '("doc/Makefile.in"
1236 "doc/example-config/Makefile.in")
1237 (("pkgsysconfdir = .*")
1238 "pkgsysconfdir = /tmp/etc"))
072f1e22
EF
1239 #t))
1240 (add-after
15ff38f1 1241 'unpack 'patch-other-file-names
072f1e22
EF
1242 (lambda _
1243 (substitute*
15ff38f1
TGR
1244 "src/lib-program-client/test-program-client-local.c"
1245 (("(/bin/| )cat") (which "cat"))
072f1e22 1246 (("/bin/echo") (which "echo"))
15ff38f1
TGR
1247 (("/bin/false") (which "false"))
1248 (("/bin/sh") (which "bash"))
1249 (("head") (which "head"))
1250 (("sleep") (which "sleep")))
7d2b784b 1251 #t)))))
c8608faf 1252 (home-page "https://www.dovecot.org")
7d2b784b
MW
1253 (synopsis "Secure POP3/IMAP server")
1254 (description
1255 "Dovecot is a mail server whose major goals are security and reliability.
1256It supports mbox/Maildir and its own dbox/mdbox formats.")
1257 ;; Most source files are covered by either lgpl2.1 or expat. The SHA code
1258 ;; is covered by a variant of BSD-3, and UnicodeData.txt is covered by the
1259 ;; Unicode, Inc. License Agreement for Data Files and Software.
1260 (license (list lgpl2.1 license:expat (non-copyleft "file://COPYING")))))
1261
944a5cdd 1262(define-public dovecot-trees
cf47a8a5 1263 (package
1264 (name "dovecot-trees")
1265 (version "2.1.0")
1266 (source
1267 (origin
1268 (method url-fetch)
1269 (uri (string-append "https://0xacab.org/riseuplabs/trees/repository/"
1270 "archive.tar.gz?ref=v" version))
1271 (file-name (string-append name "-" version ".tar.gz"))
1272 (sha256
1273 (base32
0e66f4a1
TGR
1274 "0rkk10b1bsjz979sc864vpgcdchy7yxwmyv4ik50lar1h6awdnrf"))
1275 (patches
1276 (search-patches "dovecot-trees-support-dovecot-2.3.patch"))))
cf47a8a5 1277 (build-system gnu-build-system)
1278 (native-inputs
1279 `(("automake" ,automake)
1280 ("autoconf" ,autoconf)
1281 ("libtool" ,libtool)
1282 ("dovecot" ,dovecot)
1283 ("pkg-config" ,pkg-config)))
1284 (inputs
1285 `(("libsodium" ,libsodium)))
1286 (arguments
1287 `(#:tests? #f ;No tests exist.
1288 #:configure-flags (list (string-append "--with-dovecot="
1289 (assoc-ref %build-inputs "dovecot")
1290 "/lib/dovecot"))
1291 #:phases
1292 (modify-phases %standard-phases
d10092b8 1293 (add-after 'unpack 'autogen
cf47a8a5 1294 (lambda _
1a1f778e 1295 (invoke "sh" "autogen.sh"))))))
cf47a8a5 1296 (home-page "https://0xacab.org/riseuplabs/trees")
1297 (synopsis "NaCL-based Dovecot email storage encryption plugin")
1298 (description
1299 "Technology for Resting Email Encrypted Storage (TREES) is a NaCL-based
944a5cdd 1300Dovecot encryption plugin. This plugin adds individually encrypted mail
1301storage to the Dovecot IMAP server. It is inspired by Posteo's scrambler
1302which uses OpenSSL and RSA keypairs. TREES works in a similar way, but uses
1303the Sodium crypto library (based on NaCL).
1304
1305How it works:
1306@enumerate
1307@item On IMAP log in, the user's cleartext password is passed to the plugin.
1308@item The plugin creates an argon2 digest from the password.
1309@item This password digest is used as a symmetric secret to decrypt a libsodium secretbox.
1310@item Inside the secretbox is stored a Curve25519 private key.
1311@item The Curve25519 private key is used to decrypt each individual message,
1312using lidsodium sealed boxes.
1313@item New mail is encrypted as it arrives using the Curve25519 public key.
1314@end enumerate\n")
cf47a8a5 1315 (license agpl3)))
944a5cdd 1316
a4651f64 1317(define-public dovecot-libsodium-plugin
1318 (let ((commit "044de73c01c35385df0105f6b387bec5d5317ce7")
1319 (revision "1"))
1320 (package
1321 (name "dovecot-libsodium-plugin")
1322 (version (string-append "0.0.0-" revision "." (string-take commit 7)))
1323 (source
1324 (origin
1325 (method git-fetch)
1326 (uri (git-reference
1327 (url "https://github.com/LuckyFellow/dovecot-libsodium-plugin")
1328 (commit commit)))
1329 (file-name (string-append name "-" version "-checkout"))
1330 (sha256
1331 (base32
1332 "13h07l7xy713zchnj2p9fhvq7fdl4zy1ai94li3ygkqjjj8hrgas"))))
1333 (build-system gnu-build-system)
1334 (native-inputs
1335 `(("automake" ,automake)
1336 ("autoconf" ,autoconf)
1337 ("libtool" ,libtool)
1338 ("dovecot" ,dovecot)
1339 ("pkg-config" ,pkg-config)))
1340 (inputs
1341 `(("libsodium" ,libsodium)))
1342 (arguments
1343 `(#:tests? #f ;No tests exist.
1344 #:configure-flags (list (string-append "--with-dovecot="
1345 (assoc-ref %build-inputs "dovecot")
1346 "/lib/dovecot"))
1347 #:phases
1348 (modify-phases %standard-phases
d10092b8 1349 (add-after 'unpack 'autogen
a4651f64 1350 (lambda _
bc884ed8 1351 (invoke "sh" "autogen.sh"))))))
a4651f64 1352 (home-page "https://github.com/LuckyFellow/dovecot-libsodium-plugin")
1353 (synopsis "Libsodium password hashing schemes plugin for Dovecot")
1354 (description
1355 "@code{dovecot-libsodium-plugin} provides libsodium password
1356hashing schemes plugin for @code{Dovecot}.")
1357 (license gpl3+))))
1358
81ce19f4
1359(define-public isync
1360 (package
1361 (name "isync")
49490231 1362 (version "1.3.0")
81ce19f4
1363 (source
1364 (origin
1365 (method url-fetch)
1366 (uri (string-append "mirror://sourceforge/isync/isync/"
1367 version "/isync-" version ".tar.gz"))
1368 (sha256 (base32
49490231 1369 "173wd7x8y5sp94slzwlnb7zhgs32r57zl9xspl2rf4g3fqwmhpwd"))))
81ce19f4 1370 (build-system gnu-build-system)
49490231
LF
1371 (native-inputs
1372 `(("perl" ,perl)))
81ce19f4
1373 (inputs
1374 `(("bdb" ,bdb)
a052d5ab 1375 ("cyrus-sasl" ,cyrus-sasl)
a66fb3a1
TGR
1376 ("openssl" ,openssl)
1377 ("zlib" ,zlib)))
81ce19f4
1378 (home-page "http://isync.sourceforge.net/")
1379 (synopsis "Mailbox synchronization program")
1380 (description
f6cd8586 1381 "isync/mbsync is a command-line tool for two-way synchronization of
81ce19f4
1382mailboxes. Currently Maildir and IMAP are supported types.")
1383 (license gpl2+)))
1384
26b8de19
EB
1385(define-public perl-email-abstract
1386 (package
1387 (name "perl-email-abstract")
1388 (version "3.008")
1389 (source
1390 (origin
1391 (method url-fetch)
1392 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1393 "Email-Abstract-" version ".tar.gz"))
1394 (sha256
1395 (base32
1396 "0h42rhvp769wb421cpbbg6v6xjp8iv86mvz70pqgfgf4nsn6jwgw"))))
1397 (build-system perl-build-system)
1398 (propagated-inputs
1399 `(("perl-email-simple" ,perl-email-simple)
a2190ccc 1400 ("perl-module-pluggable" ,perl-module-pluggable)
26b8de19 1401 ("perl-mro-compat" ,perl-mro-compat)))
9aba9b12 1402 (home-page "https://metacpan.org/release/Email-Abstract")
26b8de19
EB
1403 (synopsis "Interface to mail representations")
1404 (description "Email::Abstract provides module writers with the ability to
1405write simple, representation-independent mail handling code.")
2f3108ad 1406 (license perl-license)))
26b8de19 1407
ebda902f
EB
1408(define-public perl-email-address
1409 (package
1410 (name "perl-email-address")
c8213ffc 1411 (version "1.909")
ebda902f
EB
1412 (source
1413 (origin
1414 (method url-fetch)
1415 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1416 "Email-Address-" version ".tar.gz"))
1417 (sha256
1418 (base32
c8213ffc 1419 "0l7x6sl06j9ffgfz5f9vgms2b5axd4cgp5fj03ivb3kia4km6b3g"))))
ebda902f 1420 (build-system perl-build-system)
9aba9b12 1421 (home-page "https://metacpan.org/release/Email-Address")
ebda902f
EB
1422 (synopsis "Email address parsing and creation")
1423 (description "Email::Address implements a regex-based RFC 2822 parser that
1424locates email addresses in strings and returns a list of Email::Address
1425objects found. Alternatively you may construct objects manually.")
2f3108ad 1426 (license perl-license)))
ebda902f 1427
aa86a3be
EB
1428(define-public perl-email-date-format
1429 (package
1430 (name "perl-email-date-format")
1431 (version "1.005")
1432 (source
1433 (origin
1434 (method url-fetch)
1435 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1436 "Email-Date-Format-" version ".tar.gz"))
1437 (sha256
1438 (base32
1439 "012ivfwpnbl3wr50f9c6f4azhdlxnm31pdn72528g79v61z6372p"))))
1440 (build-system perl-build-system)
9aba9b12 1441 (home-page "https://metacpan.org/release/Email-Date-Format")
aa86a3be
EB
1442 (synopsis "Produce RFC 2822 date strings")
1443 (description "Email::Date::Format provides a means for generating an RFC
14442822 compliant datetime string.")
2f3108ad 1445 (license perl-license)))
aa86a3be 1446
08bf7095
EB
1447(define-public perl-email-messageid
1448 (package
1449 (name "perl-email-messageid")
1fb37ef0 1450 (version "1.406")
08bf7095
EB
1451 (source
1452 (origin
1453 (method url-fetch)
1454 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1455 "Email-MessageID-" version ".tar.gz"))
1456 (sha256
1457 (base32
1fb37ef0 1458 "1f22sdnfq169qw1l0lg7y74pmiam7j9v95bggjnf3q4mygdmshpc"))))
08bf7095 1459 (build-system perl-build-system)
9aba9b12 1460 (home-page "https://metacpan.org/release/Email-MessageID")
08bf7095
EB
1461 (synopsis "Generate world unique message-ids")
1462 (description "Email::MessageID generates recommended message-ids to
1463identify a message uniquely.")
2f3108ad 1464 (license perl-license)))
08bf7095 1465
0a4c49f6
EB
1466(define-public perl-email-mime
1467 (package
1468 (name "perl-email-mime")
4f50fd75 1469 (version "1.946")
0a4c49f6
EB
1470 (source
1471 (origin
1472 (method url-fetch)
1473 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1474 "Email-MIME-" version ".tar.gz"))
1475 (sha256
1476 (base32
4f50fd75 1477 "0z1k3i0lzp2k421gc8f3wq0jbqflkbw2xqd2k7n7pmv56417kvk8"))))
0a4c49f6
EB
1478 (build-system perl-build-system)
1479 (propagated-inputs
1480 `(("perl-email-address" ,perl-email-address)
1481 ("perl-email-messageid" ,perl-email-messageid)
1482 ("perl-email-mime-contenttype" ,perl-email-mime-contenttype)
1483 ("perl-email-mime-encodings" ,perl-email-mime-encodings)
1484 ("perl-email-simple" ,perl-email-simple)
4f50fd75
TGR
1485 ("perl-mime-types" ,perl-mime-types)
1486 ("perl-module-runtime" ,perl-module-runtime)))
9aba9b12 1487 (home-page "https://metacpan.org/release/Email-MIME")
0a4c49f6
EB
1488 (synopsis "MIME message handling")
1489 (description "Email::MIME is an extension of the Email::Simple module, to
1490handle MIME encoded messages. It takes a message as a string, splits it up
1491into its constituent parts, and allows you access to various parts of the
1492message. Headers are decoded from MIME encoding.")
2f3108ad 1493 (license perl-license)))
0a4c49f6 1494
55025bb5
EB
1495(define-public perl-email-mime-contenttype
1496 (package
1497 (name "perl-email-mime-contenttype")
9b5fc20c 1498 (version "1.022")
55025bb5
EB
1499 (source
1500 (origin
1501 (method url-fetch)
1502 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1503 "Email-MIME-ContentType-" version ".tar.gz"))
1504 (sha256
1505 (base32
9b5fc20c 1506 "042kxhs3bp1ab9z0mbr1wy21ld4lxd6v2a2mmrashqnsn2075fws"))))
55025bb5
EB
1507 (build-system perl-build-system)
1508 (native-inputs
1509 `(("perl-capture-tiny" ,perl-capture-tiny)))
9aba9b12 1510 (home-page "https://metacpan.org/release/Email-MIME-ContentType")
55025bb5
EB
1511 (synopsis "Parse MIME Content-Type headers")
1512 (description "Email::MIME::ContentType parses a MIME Content-Type
1513header.")
2f3108ad 1514 (license perl-license)))
55025bb5 1515
02e29936
EB
1516(define-public perl-email-mime-encodings
1517 (package
1518 (name "perl-email-mime-encodings")
1519 (version "1.315")
1520 (source
1521 (origin
1522 (method url-fetch)
1523 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1524 "Email-MIME-Encodings-" version ".tar.gz"))
1525 (sha256
1526 (base32
1527 "0p5b8g9gh35m8fqrpx60g4bp98rvwd02n5b0vm9wh7mk0xah8wac"))))
1528 (build-system perl-build-system)
1529 (native-inputs
1530 `(("perl-capture-tiny" ,perl-capture-tiny)))
9aba9b12 1531 (home-page "https://metacpan.org/release/Email-MIME-Encodings")
02e29936
EB
1532 (synopsis "Unified interface to MIME encoding and decoding")
1533 (description "This module wraps MIME::Base64 and MIME::QuotedPrint.")
2f3108ad 1534 (license perl-license)))
02e29936 1535
a24c5420
EB
1536(define-public perl-email-sender
1537 (package
1538 (name "perl-email-sender")
801eb746 1539 (version "1.300031")
a24c5420
EB
1540 (source
1541 (origin
1542 (method url-fetch)
1543 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1544 "Email-Sender-" version ".tar.gz"))
1545 (sha256
1546 (base32
801eb746 1547 "052g0slw3h2lzn93j71fi47nfawww2aph4jhr3c860ji70lkf4n4"))))
a24c5420
EB
1548 (build-system perl-build-system)
1549 (native-inputs
1550 `(("perl-capture-tiny" ,perl-capture-tiny)))
1551 (propagated-inputs
1552 `(("perl-email-abstract" ,perl-email-abstract)
1553 ("perl-email-address" ,perl-email-address)
1554 ("perl-email-simple" ,perl-email-simple)
1555 ("perl-list-moreutils" ,perl-list-moreutils)
1556 ("perl-module-runtime" ,perl-module-runtime)
1557 ("perl-moo" ,perl-moo)
1558 ("perl-moox-types-mooselike" ,perl-moox-types-mooselike)
1559 ("perl-sub-exporter" ,perl-sub-exporter)
1560 ("perl-throwable" ,perl-throwable)
1561 ("perl-try-tiny" ,perl-try-tiny)))
9aba9b12 1562 (home-page "https://metacpan.org/release/Email-Sender")
a24c5420
EB
1563 (synopsis "Perl library for sending email")
1564 (description "Email::Sender replaces the old and sometimes problematic
1565Email::Send library.")
2f3108ad 1566 (license perl-license)))
a24c5420 1567
151ef3ed
EB
1568(define-public perl-email-simple
1569 (package
1570 (name "perl-email-simple")
3a2f1d93 1571 (version "2.216")
151ef3ed
EB
1572 (source
1573 (origin
1574 (method url-fetch)
1575 (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/"
1576 "Email-Simple-" version ".tar.gz"))
1577 (sha256
1578 (base32
3a2f1d93 1579 "1m4brbjvalyp5kjqslqv4155dzwg977shxin208i7lc8236n6pyq"))))
151ef3ed
EB
1580 (build-system perl-build-system)
1581 (propagated-inputs
1582 `(("perl-email-date-format" ,perl-email-date-format)))
9aba9b12 1583 (home-page "https://metacpan.org/release/Email-Simple")
151ef3ed
EB
1584 (synopsis "Parsing of RFC 2822 messages")
1585 (description "Email::Simple provides simple parsing of RFC 2822 message
1586format and headers.")
2f3108ad 1587 (license perl-license)))
151ef3ed 1588
f5dceecb
AW
1589(define-public libesmtp
1590 (package
1591 (name "libesmtp")
1592 (version "1.0.6")
1593 (source
1594 (origin
1595 (method url-fetch)
049e02ea
LF
1596 (uri (list (string-append "https://pkgs.fedoraproject.org/repo/pkgs/"
1597 "libesmtp/libesmtp-" version ".tar.bz2/"
1598 "bf3915e627fd8f35524a8fdfeed979c8/libesmtp-"
1599 version ".tar.bz2")
1600 ;; XXX This site is offline, so we fetch Fedora's cached copy
1601 ;; of the source tarball.
1602 (string-append "http://www.stafford.uklinux.net/libesmtp/libesmtp-"
1603 version ".tar.bz2")))
f5dceecb
AW
1604 (sha256
1605 (base32
1606 "02zbniyz7qys1jmx3ghx21kxmns1wc3hmv80gp7ag7yra9f1m9nh"))))
1607 (build-system gnu-build-system)
1608 (propagated-inputs
1609 `(("openssl" ,openssl)))
1610 (home-page "http://www.stafford.uklinux.net/libesmtp/")
1611 (synopsis "Library for sending mail via remote hosts using SMTP")
1612 (description "libESMTP is an SMTP client which manages posting (or
1613submission of) electronic mail via a preconfigured Mail Transport Agent (MTA).
1614It may be used as part of a Mail User Agent (MUA) or other program that must
1615be able to post electronic mail where mail functionality may not be that
1616program's primary purpose.")
1617 (license (list lgpl2.1+ gpl2+))))
1618
f8ae32a2
AW
1619(define-public esmtp
1620 (package
1621 (name "esmtp")
1622 (version "1.2")
1623 (source
1624 (origin
1625 (method git-fetch)
1626 (uri (git-reference
1627 (url "https://github.com/andywingo/esmtp.git")
1628 (commit "01bf9fc")))
1629 (sha256
1630 (base32
1631 "1ay282rrl92h0m0m8z5zzjnwiiagi7c78aq2qvhia5mw7prwfyw2"))
1632 (file-name (string-append name "-" version "-checkout"))))
1633 (arguments
1634 `(#:phases (modify-phases %standard-phases
73c0e477
EF
1635 (replace 'bootstrap
1636 (lambda _ (invoke "autoreconf" "-vfi"))))))
f8ae32a2
AW
1637 (build-system gnu-build-system)
1638 (native-inputs
1639 `(("bison" ,bison)
1640 ("flex" ,flex)
1641 ("autoconf" ,autoconf)
1642 ("automake" ,automake)
1643 ("libtool" ,libtool)))
1644 (inputs
718c5dd6 1645 `(("libesmtp" ,libesmtp)))
3b3b60d0 1646 (home-page "https://sourceforge.net/projects/esmtp/")
f8ae32a2
AW
1647 (synopsis "Relay-only mail transfer agent (MTA)")
1648 (description "Esmtp is a simple relay-only mail transfer agent built using
1649libESMTP. It sends e-mail via a remote SMTP server using credentials from the
1650user's @file{$HOME/.esmtprc} configuration file; see the @command{esmtprc} man
1651page for more on configuration. This package also provides minimal
1652compatibility shims for the @command{sendmail}, @command{mailq}, and
1653@command{newaliases} commands.")
1654 (license gpl2+)))
1655
34dd26af
CAW
1656(define-public fdm
1657 (package
1658 (name "fdm")
1659 (version "1.9")
1660 (source (origin
1661 (method url-fetch)
1662 (uri (string-append "https://github.com/nicm/fdm/releases/download/"
1663 version "/fdm-"
1664 version ".tar.gz"))
1665 (file-name (string-append name "-" version ".tar.gz"))
1666 (sha256
1667 (base32 "054rscijahiza5f9qha79rg3siji3bk5mk10f8c2vqx7m4w6qh8n"))))
1668 (build-system gnu-build-system)
1669 (inputs
1670 `(("tdb" ,tdb)
1671 ("openssl" ,openssl)
1672 ("zlib" ,zlib)))
1673 (home-page "https://github.com/nicm/fdm")
1674 (synopsis "Mail Retrieval Agent (MRA) and Mail Delivery Agent (MDA)")
1675 (description "fdm is a program designed to fetch mail from POP3
1676or IMAP servers, or receive local mail from stdin, and
1677deliver it in various ways.")
1678 (license
1679 ;; Why point to a source file? Well, all the individual files have a
1680 ;; copy of this license in their headers, but there's no seprate file
1681 ;; with that information.
16966d5b 1682 (non-copyleft "https://github.com/nicm/fdm/blob/master/command.c"))))
34dd26af 1683
e90819c4
LG
1684
1685(define-public procmail
1686 (package
1687 (name "procmail")
1688 (version "3.22")
1689 (source
1690 (origin
1691 (method url-fetch)
1692 (uri (string-append
1693 "ftp://ftp.fu-berlin.de/pub/unix/mail/procmail/procmail-"
1694 version
1695 ".tar.gz"))
1696 (sha256
1697 (base32
1698 "05z1c803n5cppkcq99vkyd5myff904lf9sdgynfqngfk9nrpaz08"))
1699 ;; The following patch fixes an ambiguous definition of
1700 ;; getline() in formail.c. The patch is provided by Debian as
1701 ;; patch 24.
1d982d78 1702 (patches (search-patches "procmail-ambiguous-getline-debian.patch"
c297e965
LF
1703 "procmail-CVE-2014-3618.patch"
1704 "procmail-CVE-2017-16844.patch"))))
e90819c4
LG
1705 (arguments
1706 `(#:phases (modify-phases %standard-phases
1707 (replace 'configure
1708 (lambda _
1709 (substitute* "Makefile"
1710 (("/bin/sh")
1711 (which "sh"))
1712 (("/usr")
1713 (assoc-ref %outputs "out"))
1714 (("/bin/rm")
1715 (which "rm")))
1716 #t)))
1717 #:tests? #f)) ;; There are no tests indicating a successful
1718 ;; build. Some tests of basic locking mechanisms provided by the
8f65585b 1719 ;; file system are performed during 'make install'. However, these
e90819c4
LG
1720 ;; are performed before the actual build process.
1721 (build-system gnu-build-system)
05aa576b 1722 (inputs `(("exim" ,exim)))
e90819c4
LG
1723 (home-page "http://www.procmail.org/")
1724 (synopsis "Versatile mail delivery agent (MDA)")
1725 (description "Procmail is a mail delivery agent (MDA) featuring support
1726for a variety of mailbox formats such as mbox, mh and maildir. Incoming mail
1727can be sorted into separate files/directories and arbitrary commands can be
1728executed on mail arrival. Procmail is considered stable, but is no longer
1729maintained.")
1730 (license gpl2+))) ;; procmail allows to choose the
1731 ;; nonfree Artistic License 1.0
1732 ;; as alternative to the GPL2+.
1733 ;; This option is not listed here.
e90819c4 1734
61c30e9d
LF
1735(define-public khard
1736 (package
1737 (name "khard")
224b1c83 1738 (version "0.12.2")
61c30e9d
LF
1739 (source (origin
1740 (method url-fetch)
1741 (uri (pypi-uri name version))
1742 (sha256
1743 (base32
224b1c83 1744 "01y52qmab4cw9wmx87aahnxbyaxrxw8j2wx06mpcqsfvgk8d54wi"))))
61c30e9d
LF
1745 (build-system python-build-system)
1746 (arguments
a57495e2 1747 `(#:phases
61c30e9d 1748 (modify-phases %standard-phases
61c30e9d
LF
1749 (add-after 'install 'install-doc
1750 (lambda* (#:key outputs #:allow-other-keys)
1751 (let* ((out (assoc-ref outputs "out"))
1752 (doc (string-append out "/share/doc/khard")))
e9eafae2
MB
1753 (copy-recursively "misc/khard" doc)
1754 #t))))
224b1c83
EF
1755 ;; Tests are currently only runnable without preexisting data on
1756 ;; the development branch:
1757 ;; https://github.com/scheibler/khard/issues/176
e9eafae2 1758 #:tests? #f))
61c30e9d 1759 (propagated-inputs
224b1c83
EF
1760 `(("python-atomicwrites" ,python-atomicwrites)
1761 ("python-configobj" ,python-configobj)
a57495e2 1762 ("python-pyyaml" ,python-pyyaml)
224b1c83
EF
1763 ("python-ruamel.yaml" ,python-ruamel.yaml)
1764 ("python-unidecode" ,python-unidecode)
1765 ("python-vobject" ,python-vobject)))
61c30e9d
LF
1766 (synopsis "Console address book using CardDAV")
1767 (description "Khard is an address book for the console. It creates, reads,
1768modifies and removes CardDAV address book entries at your local machine. For
1769synchronizing with a remote address book, @command{vdirsyncer} is recommended.
1770Khard can also be used from within the email client @command{mutt}.")
1771 (home-page "https://github.com/scheibler/khard")
1772 (license gpl3+)))
be0c5733
DM
1773
1774(define-public perl-mail-spf
1775 (package
1776 (name "perl-mail-spf")
1777 (version "v2.9.0")
1778 (source
1779 (origin
1780 (method url-fetch)
1781 (uri (string-append
1782 "mirror://cpan/authors/id/J/JM/JMEHNLE/mail-spf/Mail-SPF-"
1783 version
1784 ".tar.gz"))
1785 (sha256
1786 (base32
1787 "0qk1rfgfm5drj4iyniiabrasrpqv570vzhgz66lwgb67y4amkjv1"))))
1788 (build-system perl-build-system)
1789 (native-inputs
1790 `(("perl-module-build" ,perl-module-build)
1791 ("perl-net-dns-resolver-programmable"
1792 ,perl-net-dns-resolver-programmable)))
1793 (arguments
1794 `(#:phases (modify-phases %standard-phases
1795 (add-before 'configure 'modify-Build.PL
1796 (lambda* (#:key outputs #:allow-other-keys)
1797 (substitute* "Build.PL"
1798 (("'/usr/sbin'") (string-append "'"
1799 (assoc-ref outputs "out")
1800 "/sbin'")))
1801 #t)))))
1802 (inputs
1803 `(("perl-error" ,perl-error)
1804 ("perl-net-dns" ,perl-net-dns)
1805 ("perl-netaddr-ip" ,perl-netaddr-ip)
1806 ("perl-uri" ,perl-uri)))
1807 (home-page
9aba9b12 1808 "https://metacpan.org/release/Mail-SPF")
be0c5733
DM
1809 (synopsis
1810 "Perl implementation of Sender Policy Framework")
1811 (description "Mail::SPF is the Sender Policy Framework implemented
1812in Perl.")
1813 (license bsd-3)))
24262239
CL
1814
1815(define-public mb2md
1816 (package
1817 (name "mb2md")
1818 (version "3.20")
1819 (source (origin
1820 (method url-fetch)
1821 (uri (string-append
1822 "http://batleth.sapienti-sat.org/projects/mb2md/mb2md-"
1823 version ".pl.gz"))
1824 (sha256
1825 (base32
1826 "0bvkky3c90738h3skd2f1b2yy5xzhl25cbh9w2dy97rs86ssjidg"))))
1827 (build-system trivial-build-system)
1828 (arguments
1829 '(#:modules ((guix build utils))
1830 #:builder
1831 (begin
1832 (use-modules (guix build utils))
1833 (let* ((source (assoc-ref %build-inputs "source"))
1834 (out (assoc-ref %outputs "out"))
1835 (bin (string-append out "/bin"))
1836 (perl (assoc-ref %build-inputs "perl"))
1837 (gzip (assoc-ref %build-inputs "gzip"))
1838 (perl-timedate (assoc-ref %build-inputs "perl-timedate"))
1839 (perl5lib (string-append perl-timedate "/lib/perl5/site_perl")))
1840 (mkdir-p bin)
1841 (with-directory-excursion bin
1842 (copy-file source "mb2md.gz")
e3cfef22 1843 (invoke (string-append gzip "/bin/gzip") "-d" "mb2md.gz")
24262239
CL
1844 (substitute* "mb2md"
1845 (("#!/usr/bin/perl")
1846 (string-append "#!/usr/bin/perl -I " perl5lib)))
1847 (patch-shebang "mb2md" (list (string-append perl "/bin")))
1848 (chmod "mb2md" #o555))
1849 #t))))
c695fb76 1850 (native-inputs `(("gzip" ,gzip)))
24262239
CL
1851 (inputs `(("perl" ,perl)
1852 ("perl-timedate" ,perl-timedate)))
1853 (home-page "http://batleth.sapienti-sat.org/projects/mb2md/")
1854 (synopsis "Mbox to maildir converter")
1855 (description
1856 "Mb2md is a Perl script that takes one or more mbox format files and
1857converts them to maildir format directories.")
1858 (license public-domain)))
e0d7b421
AI
1859
1860(define-public mpop
1861 (package
1862 (name "mpop")
3e84ce51 1863 (version "1.4.0")
e0d7b421
AI
1864 (source
1865 (origin
1866 (method url-fetch)
1497b95c
TGR
1867 (uri (string-append "https://marlam.de/mpop/releases/"
1868 name "-" version ".tar.xz"))
e0d7b421
AI
1869 (sha256
1870 (base32
3e84ce51 1871 "14xsvpm5bc1wycisq882gqrnamnyi1q4rlk6anlw8ihzvwgm4h2j"))))
e0d7b421
AI
1872 (build-system gnu-build-system)
1873 (inputs
1874 `(("gnutls" ,gnutls)
1875 ("libidn" ,libidn)))
1876 (native-inputs
1877 `(("pkg-config" ,pkg-config)))
1497b95c 1878 (home-page "https://marlam.de/mpop/")
e0d7b421
AI
1879 (synopsis "POP3 mail client")
1880 (description "mpop is a small and fast POP3 client suitable as a
1881fetchmail replacement.
1882
1883mpop supports multiple accounts, header based mail filtering, delivery
1884to mbox files, maildir folders or a Mail Delivery Agent (MDA),
1885TLS/SSL, several authentication methods, Internationalized Domain
1886Names (IDN) and SOCKS proxies.")
1887 (license gpl3+)))
74c0282c 1888
1889(define-public mhonarc
1890 (package
1891 (name "mhonarc")
1892 (version "2.6.19")
1893 (source
1894 (origin
1895 (method url-fetch)
1896 (uri (string-append "mirror://cpan/authors/id/E/EH/EHOOD/MHonArc-"
1897 version ".tar.gz"))
1898 (sha256
1899 (base32
1900 "0ll3v93yji334zqp6xfzfxc0127pmjcznmai1l5q6dzawrs2igzq"))))
1901 (build-system perl-build-system)
1902 (home-page "https://www.mhonarc.org/")
1903 (synopsis "Create HTML archives of mail/news messages")
1904 (description
1905 "MHonArc is a Perl mail-to-HTML converter. MHonArc
1906provides HTML mail archiving with index, mail thread linking,
1907etc; plus other capabilities including support for MIME and
1908powerful user customization features.")
1909 (license gpl2+)))
5d87088c
JD
1910
1911
1912(define-public sendmail
1913 (package
1914 (name "sendmail")
1915 (version "8.15.2")
1916 (source
1917 (origin
1918 (method url-fetch)
1919 (uri (string-append
1920 "ftp://ftp.sendmail.org/pub/sendmail/sendmail."
1921 version ".tar.gz"))
1922 (sha256
1923 (base32
1924 "0fdl9ndmspqspdlmghzxlaqk56j3yajk52d7jxcg21b7sxglpy94"))))
1925 (build-system gnu-build-system)
1926 (arguments
1927 `(#:phases
1928 (modify-phases %standard-phases
1929 (add-before 'build 'replace-/bin/sh
1930 (lambda _
1931 (substitute*
1932 (append
1933 (list "smrsh/smrsh.c" "sendmail/conf.c" "contrib/mailprio"
1934 "contrib/mmuegel" "devtools/bin/configure.sh")
1935 (find-files "." ".*\\.m4")
1936 (find-files "." ".*\\.cf"))
19527952 1937 (("/bin/sh") (which "sh")))
5d87088c
JD
1938
1939 (substitute* "devtools/bin/Build"
19527952 1940 (("SHELL=/bin/sh") (string-append "SHELL=" (which "sh"))))
5d87088c
JD
1941 #t))
1942 (replace 'configure
1943 (lambda _
1944
1945 ;; Render harmless any attempts to chown or chgrp
1946 (substitute* "devtools/bin/install.sh"
1947 (("owner=\\$2") "owner=''")
1948 (("group=\\$2") "group=''"))
1949
1950 (with-output-to-file "devtools/Site/site.config.m4"
1951 (lambda ()
1952 (format #t "
1953define(`confCC', `gcc')
1954define(`confOPTIMIZE', `-g -O2')
1955define(`confLIBS', `-lresolv')
1956define(`confINSTALL', `~a/devtools/bin/install.sh')
1957define(`confDEPEND_TYPE', `CC-M')
1958define(`confINST_DEP', `')
55492129
TGR
1959" (getcwd))))
1960 #t))
5d87088c
JD
1961 (replace 'build
1962 (lambda _
55492129
TGR
1963 (invoke "sh" "Build")
1964 (with-directory-excursion "cf/cf"
1965 (copy-file "generic-linux.mc" "sendmail.mc")
1966 (invoke "sh" "Build" "sendmail.cf"))
1967 #t))
5d87088c
JD
1968 (add-before 'install 'pre-install
1969 (lambda _
1970 (let ((out (assoc-ref %outputs "out")))
1971 (mkdir-p (string-append out "/usr/bin"))
1972 (mkdir-p (string-append out "/usr/sbin"))
1973 (mkdir-p (string-append out "/etc/mail"))
1974 (setenv "DESTDIR" out)
1975 (with-directory-excursion "cf/cf"
55492129
TGR
1976 (invoke "sh" "Build" "install-cf"))
1977 #t))))
5d87088c
JD
1978 ;; There is no make check. There are some post installation tests, but those
1979 ;; require root privileges
1980 #:tests? #f))
1981 (inputs
1982 `(("m4" ,m4)
1983 ("perl" ,perl)))
1984 (home-page "http://sendmail.org")
1985 (synopsis
1986 "Highly configurable Mail Transfer Agent (MTA)")
1987 (description
1988 "Sendmail is a mail transfer agent (MTA) originally developed by Eric
1989Allman. It is highly configurable and supports many delivery methods and many
1990transfer protocols.")
1991 (license (non-copyleft "file://LICENSE"
1992 "See LICENSE in the distribution."))))
1993
8b53366c 1994(define-public opensmtpd
1995 (package
1996 (name "opensmtpd")
2f2ce920 1997 (version "6.0.3p1")
8b53366c 1998 (source (origin
1999 (method url-fetch)
2000 (uri (string-append "https://www.opensmtpd.org/archives/"
2001 name "-" version ".tar.gz"))
2002 (sha256
2003 (base32
d6dd64af
AZ
2004 "10bsfsnlg9d9i6l2izdnxp05s3ri8fvwzqxvx1jmarc852382619"))
2005 ;; Fixed upstream: <github.com/OpenSMTPD/OpenSMTPD/pull/835>.
2006 (patches (search-patches "opensmtpd-fix-crash.patch"))))
8b53366c 2007 (build-system gnu-build-system)
2008 (inputs
2009 `(("bdb" ,bdb)
2010 ("libressl" ,libressl)
2011 ("libevent" ,libevent)
2012 ("libasr" ,libasr)
2013 ("linux-pam" ,linux-pam)
2014 ("zlib" ,zlib)))
2015 (native-inputs
d7da7604
SB
2016 `(("bison" ,bison)
2017 ("groff" ,groff)))
8b53366c 2018 (arguments
ae1e2133 2019 `(#:configure-flags
a1b517f9 2020 (list "--with-table-db" "--with-auth-pam" "--localstatedir=/var"
ae1e2133
SB
2021 "--with-user-smtpd=smtpd" "--with-user-queue=smtpq"
2022 "--with-group-queue=smtpq"
2f2ce920 2023 "--with-path-socket=/var/run" ; not default (./configure lies)
ae1e2133 2024 "--with-path-CAfile=/etc/ssl/certs/ca-certificates.crt")
8b53366c 2025 #:phases
2026 (modify-phases %standard-phases
19fed049
TGR
2027 ;; Fix some incorrectly hard-coded external tool file names.
2028 (add-after 'unpack 'patch-FHS-file-names
2029 (lambda* (#:key inputs #:allow-other-keys)
2030 (substitute* "smtpd/smtpctl.c"
2031 (("/bin/cat") (which "cat"))
2032 (("/bin/sh") (which "sh")))
2033 #t))
8b53366c 2034 ;; OpenSMTPD provides a single utility smtpctl to control the daemon and
2035 ;; the local submission subsystem. To accomodate systems that require
2036 ;; historical interfaces such as sendmail, newaliases or makemap, the
2037 ;; smtpctl utility can operate in compatibility mode if called with the
2038 ;; historical name.
a1eabab1
TGR
2039 (add-after 'install 'install-compability-links
2040 (lambda* (#:key outputs #:allow-other-keys)
2041 (let* ((out (assoc-ref outputs "out"))
8b53366c 2042 (sbin (string-append out "/sbin/")))
a1eabab1
TGR
2043 (for-each (lambda (command)
2044 (symlink "smtpctl" (string-append sbin command)))
8b53366c 2045 '("makemap" "sendmail" "send-mail"
2046 "newaliases" "mailq")))
2047 #t)))))
2048 (synopsis "Lightweight SMTP daemon")
2049 (description
2050 "OpenSMTPD is an implementation of the server-side SMTP protocol, with
2051some additional standard extensions. It allows ordinary machines to exchange
2052e-mails with other systems speaking the SMTP protocol.")
2053 (home-page "https://www.opensmtpd.org")
2054 (license (list bsd-2 bsd-3 bsd-4 (non-copyleft "file://COPYING")
19262a71 2055 public-domain isc license:openssl))))
152ffe7c 2056
2057(define-public opensmtpd-extras
2058 (package
2059 (name "opensmtpd-extras")
2060 (version "5.7.1")
2061 (source (origin
2062 (method url-fetch)
2063 (uri (string-append "https://www.opensmtpd.org/archives/"
2064 name "-" version ".tar.gz"))
2065 (sha256
2066 (base32
2067 "1kld4hxgz792s0cb2gl7m2n618ikzqkj88w5dhaxdrxg4x2c4vdm"))))
2068 (build-system gnu-build-system)
2069 (inputs
2070 `(("libressl" ,libressl)
2071 ("libevent" ,libevent)
2072 ("libasr" ,libasr)
2073 ("python-2" ,python-2)
2074 ("opensmtpd" ,opensmtpd)
2075 ("perl" ,perl)
2076 ("lua" ,lua)
2077 ("postgresql" ,postgresql)
2078 ("sqlite" ,sqlite)
2079 ("linux-pam" ,linux-pam)))
2080 (native-inputs
2081 `(("bison" ,bison)
2082 ("pkg-config" ,pkg-config)
2083 ("groff" ,groff)
2084 ("automake" ,automake)
2085 ("autoconf" ,autoconf)))
2086 (arguments
2087 `(;; We have to configure it like this because the default checks for for example
2088 ;; python in /usr/local/bin, /usr/bin and fails otherwise.
2089 #:configure-flags (list
2090 "--with-filter-clamav" "--with-filter-dkim-signer"
2091 "--with-filter-dnsbl" "--with-filter-lua"
2092 "--with-filter-monkey" "--with-filter-pause"
2093 "--with-filter-perl" "--with-filter-python"
2094 "--with-filter-regex" "--with-filter-spamassassin"
2095 "--with-filter-stub" "--with-filter-trace"
2096 "--with-filter-void"
2097
2098 "--with-queue-null" "--with-queue-python"
2099 "--with-queue-ram" "--with-queue-stub"
2100
2101 "--with-scheduler-python" "--with-scheduler-ram"
2102 "--with-scheduler-stub"
2103
2104 "--with-table-ldap" ; "--with-table-mysql"
2105 "--with-table-passwd" "--with-table-postgres"
2106 "--with-table-python" "--with-table-socketmap"
2107 "--with-table-sqlite" "--with-table-stub"
2108 ;;"--with-table-redis" ; TODO: package hiredis
2109
2110 "--with-user=smtpd" "--with-privsep-user=smtpd"
2111 "--localstatedir=/var" "--sysconfdir=/etc"
2112 "--with-lua-type=lua" ; can use lua or luajit
2113
2114 (string-append "--with-python="
2115 (assoc-ref %build-inputs "python-2"))
2116 (string-append "--with-lua="
2117 (assoc-ref %build-inputs "lua")))))
19262a71
LC
2118 (license (list bsd-2 bsd-3 bsd-4
2119 public-domain isc license:openssl))
152ffe7c 2120 (synopsis "Extra tables, filters, and various other addons for OpenSMTPD")
2121 (description
2122 "This package provides extra tables, filters, and various other addons
2123for OpenSMTPD to extend its functionality.")
2124 (home-page "https://www.opensmtpd.org")))
6d3dda4f 2125
2126(define-public python-mailmanclient
2127 (package
2128 (name "python-mailmanclient")
c115a1c8 2129 (version "3.1.1")
6d3dda4f 2130 (source
2131 (origin
2132 (method url-fetch)
2133 (uri (pypi-uri "mailmanclient" version))
2134 (sha256
2135 (base32
c115a1c8 2136 "0fdfs5g3pf30v2i7w18pdkv9xnfxmfcv66mzv56dck0a1igq07m3"))))
6d3dda4f 2137 (build-system python-build-system)
2138 (arguments
2139 `(#:tests? #f)) ; Requires mailman running
f22efa01 2140 (propagated-inputs
6d3dda4f 2141 `(("python-six" ,python-six)
2142 ("python-httplib2" ,python-httplib2)))
2143 (home-page "https://launchpad.net/mailman.client")
2144 (synopsis "Python bindings for the Mailman 3 REST API")
2145 (description
2146 "The mailmanclient library provides official Python bindings for
2147the GNU Mailman 3 REST API.")
6d3dda4f 2148 (license lgpl3+)))
2149
2150(define-public python2-mailmanclient
5c31f4aa 2151 (package-with-python2 python-mailmanclient))
3163a289 2152
2153(define-public mlmmj
2154 (package
2155 (name "mlmmj")
28b48c87 2156 (version "1.3.0")
3163a289 2157 (source
2158 (origin
2159 (method url-fetch)
2160 (uri (string-append "http://mlmmj.org/releases/mlmmj-"
2161 version ".tar.bz2"))
2162 (sha256
2163 (base32
28b48c87 2164 "0hpj10qad821ci11si8xc2qnmkzfn90y13s43fm4fca38f0qjp8w"))))
3163a289 2165 (build-system gnu-build-system)
2166 (inputs
2167 `(("perl" ,perl))) ; For "contrib/web/"
2168 (native-inputs
2169 `(("pkg-config" ,pkg-config)))
2170 (arguments
2171 `(#:configure-flags
2172 ;; mlmmj-receive-strip is a replacement for mlmmj-receive
2173 ;; It opens the files control/mimedeny and control/mimestrip to get a list
2174 ;; of mimetypes for parts of multipart/mime messages that should be denied
2175 ;; or stripped. The parts then get stripped directly when the mail is
2176 ;; received. mlmmj-receive-strip also appends an extra header
2177 ;; X-ThisMailContainsUnwantedMimeParts: Y when the mail contains unwanted
2178 ;; mime parts
2179 (list "--enable-receive-strip")
2180 #:phases
2181 (modify-phases %standard-phases
2182 (add-before 'install 'install-contrib
2183 (lambda* (#:key outputs #:allow-other-keys)
2184 (let* ((out (assoc-ref outputs "out"))
2185 (share (string-append out "/share/mlmmj"))
2186 (contrib (string-append share "/contrib/web"))
2187 (texts (string-append share "/listtexts")))
2188 (copy-recursively "contrib/web/" contrib)
2189 (copy-recursively "listtexts" texts)
2190 (rename-file texts (string-append share "/texts"))
2191 #t))))))
2192 (home-page "http://mlmmj.org")
2193 (synopsis "Mailing list managing made joyful")
2194 (description
2195 "Mlmmj is a simple and slim mailing list manager (MLM) inspired by ezmlm.
2196It works with many different Mail Transport Agents (MTAs) and is simple for a
d1e4ad1b 2197system administrator to install, configure and integrate with other software.
3163a289 2198As it uses very few resources, and requires no daemons, it is ideal for
2199installation on systems where resources are limited. Its features include:
2200@enumerate
2201@item Archive, Custom headers / footer,
2202@item Fully automated bounce handling (similar to ezmlm),
2203@item Complete requeueing functionality, Moderation functionality, Subject prefix,
2204@item Subscribers only posting, Regular expression access control,
2205@item Functionality to retrieve old posts, Web interface, Digests,
2206@item No-mail subscription, VERP support,
2207@item Delivery Status Notification (RFC1891) support,
2208@item Rich and customisable texts for automated operations.
2209@end enumerate\n")
2210 (license license:expat)))
3a263368 2211
ea3b9f7b 2212(define-public python2-django-mailman3
8a3741e6 2213 (package
ea3b9f7b 2214 (name "python2-django-mailman3")
bdf0c644 2215 (version "1.1.0")
8a3741e6 2216 (source
2217 (origin
2218 (method url-fetch)
2219 (uri (pypi-uri "django-mailman3" version))
2220 (sha256
2221 (base32
bdf0c644 2222 "1xjdkgfjwhgyrp5nxw65dcpcsr98ygj6856sp0bwkrmyxpd1xxk2"))))
8a3741e6 2223 (build-system python-build-system)
ea3b9f7b
CB
2224 (arguments
2225 `(#:phases
2226 (modify-phases %standard-phases
2227 (replace 'check
2228 (lambda _
dcfdaa15
TGR
2229 (invoke "django-admin"
2230 "test"
2231 "--settings=django_mailman3.tests.settings_test"
2232 "django_mailman3"))))
ea3b9f7b 2233 #:python ,python-2))
8a3741e6 2234 (inputs
ea3b9f7b 2235 `(("python2-django" ,python2-django)))
8a3741e6 2236 (propagated-inputs
ea3b9f7b
CB
2237 `(("python2-requests" ,python2-requests)
2238 ("python2-requests-oauthlib" ,python2-requests-oauthlib)
2239 ("python2-openid" ,python2-openid)
2240 ("python2-mailmanclient" ,python2-mailmanclient)
2241 ("python2-django-allauth" ,python2-django-allauth)
2242 ("python2-django-gravatar2" ,python2-django-gravatar2)
2243 ("python2-pytz" ,python2-pytz)))
8a3741e6 2244 (home-page "https://gitlab.com/mailman/django-mailman3")
2245 (synopsis "Django library for Mailman UIs")
2246 (description
2247 "Libraries and templates for Django-based interfaces
2248interacting with Mailman.")
2249 (license gpl3+)))
2250
d99a2add 2251(define-public postorius
2252 (package
2253 (name "postorius")
2254 (version "1.0.3")
2255 (source
2256 (origin
2257 (method url-fetch)
2258 (uri (pypi-uri "postorius" version "+post2.tar.gz"))
2259 (file-name (string-append name "-" version ".tar.gz"))
2260 (sha256
2261 (base32
2262 "1wymcpv2icjjy8h1ni52p6dr7wwxf71ivqgbqhzx4i82yqphcaq5"))))
2263 (build-system python-build-system)
2264 (arguments
2265 `(; One test dependency relies on Persona, which was shut down in
2266 ;; November 2016.
2267 #:tests? #f
2268 ;; The part of the frontend of Mailman is still python 2.7.
2269 #:python ,python-2))
2270 (inputs
2271 `(("python2-django" ,python2-django)
2272 ("python2-django-mailman3" ,python2-django-mailman3)
2273 ("python2-mailmanclient" ,python2-mailmanclient)))
2274 (home-page "https://gitlab.com/mailman/postorius")
2275 (synopsis "Web user interface for GNU Mailman")
2276 (description
2277 "Postorius is a Django app which provides a web user interface
2278to access GNU Mailman.")
2279 (license (list gpl3+ lgpl3+))))
2280
3a263368 2281(define-public blists
2282 (package
2283 (name "blists")
18b1589b 2284 (version "2.0")
3a263368 2285 (source
2286 (origin
2287 (method url-fetch)
2288 (uri (string-append "http://download.openwall.net/pub/projects/"
2289 "blists/blists-" version ".tar.gz"))
2290 (sha256
2291 (base32
18b1589b 2292 "1xll5wn7py3bbncbwrj172f56nz75c9gwfsa80rwd96ss9gfmp3c"))))
3a263368 2293 (build-system gnu-build-system)
2294 (arguments
2295 `(#:tests? #f ; No tests
2296 #:phases
2297 (modify-phases %standard-phases
2298 (delete 'configure)
2299 (replace 'install
2300 (lambda* (#:key outputs #:allow-other-keys)
2301 (let* ((out (assoc-ref outputs "out"))
2302 (bin (string-append out "/bin")))
2303 (install-file "bindex" bin)
2304 (install-file "bit" bin)
2305 #t))))))
2306 (home-page "http://www.openwall.com/blists/")
2307 (synopsis "Web interface to mailing list archives")
2308 (description
2309 "Blists is a web interface to mailing list archives that works off
2310indexed mbox files. There are two programs: @code{bindex} and @code{bit}.
2311@code{bindex} generates or updates the index file (incremental updates
2312are supported). @code{bit} is a CGI/SSI program that generates web pages
2313on the fly. Both programs are written in C and are very fast.")
2314 (license license:expat)))
ed428a58
AI
2315
2316(define-public swaks
2317 (package
2318 (name "swaks")
2319 (version "20170101.0")
2320 (source
2321 (origin
2322 (method url-fetch)
2323 (uri (string-append
d72f59a4 2324 "https://jetmore.org/john/code/swaks/files/swaks-"
ed428a58
AI
2325 version ".tar.gz"))
2326 (sha256
2327 (base32
2328 "0pli4mlhasnqqxmmxalwyg3x7n2vhcbgsnp2xgddamjavv82vrl4"))))
2329 (build-system perl-build-system)
2330 (inputs
2331 `(("perl-net-dns" ,perl-net-dns)
2332 ("perl-net-ssleay" ,perl-net-ssleay)))
2333 (arguments
2334 `(#:tests? #f ; No tests
2335 #:phases
2336 (modify-phases %standard-phases
2337 (delete 'configure)
2338 (replace 'build
2339 (lambda _
d72f59a4 2340 (invoke "pod2man" "doc/ref.pod" "swaks.1")))
ed428a58
AI
2341 (replace 'install
2342 (lambda* (#:key outputs #:allow-other-keys)
2343 (let ((out (assoc-ref outputs "out")))
2344 (install-file "swaks" (string-append out "/bin"))
2345 (install-file "swaks.1" (string-append out "/share/man/man1")))
2346 #t))
2347 (add-after 'install 'wrap-program
2348 (lambda* (#:key outputs #:allow-other-keys)
2349 (wrap-program (string-append (assoc-ref outputs "out")
2350 "/bin/swaks")
2351 `("PERL5LIB" ":" = (,(getenv "PERL5LIB"))))
2352 #t)))))
d72f59a4 2353 (home-page "https://jetmore.org/john/code/swaks/")
ed428a58
AI
2354 (synopsis "Featureful SMTP test tool")
2355 (description "Swaks is a flexible, scriptable, transaction-oriented SMTP
2356test tool. It handles SMTP features and extensions such as TLS,
2357authentication, and pipelining; multiple versions of the SMTP protocol
2358including SMTP, ESMTP, and LMTP; and multiple transport methods including
2359unix-domain sockets, internet-domain sockets, and pipes to spawned processes.
2360Options can be specified in environment variables, configuration files, and
2361the command line allowing maximum configurability and ease of use for
2362operators and scripters.")
2363 (license gpl2+)))
b0eb2af2 2364
2365(define-public alpine
2366 (package
2367 (name "alpine")
05a40469 2368 (version "2.21.9999")
b0eb2af2 2369 (source
2370 (origin
2371 (method url-fetch)
2372 ;; There are two versions: the plain continuation of Alpine without extra
2373 ;; patches and the version which adds extra fixes. Every distro uses
2374 ;; the patched version, and so do we to not break expectations.
32f9cc33 2375 ;; http://alpine.freeiz.com/alpine/readme/README.patches
78ba71b0 2376 (uri (string-append "http://repo.or.cz/alpine.git/snapshot/"
05a40469 2377 "d3e6f3932f2af9deca8eed09e30a55e9bd524362.tar.gz"))
78ba71b0 2378 (file-name (string-append name "-" version ".tar.gz"))
b0eb2af2 2379 (sha256
2380 (base32
05a40469 2381 "0w4qyybfdxi29r2z3giq0by6aa6v6nrgibh1xgv4d1vwwq4hw35w"))))
b0eb2af2 2382 (build-system gnu-build-system)
2383 (arguments
2384 `(#:make-flags (list "CC=gcc")
2385 #:configure-flags (list (string-append "--with-ssl-include-dir="
2386 (assoc-ref %build-inputs "openssl")
2387 "/include/openssl")
2388 (string-append "--with-ssl-dir="
2389 (assoc-ref %build-inputs "openssl"))
2390 (string-append "--with-ssl-certs-dir="
2391 "/etc/ssl/certs/")
2392 (string-append "--with-ssl-lib-dir="
2393 (assoc-ref %build-inputs "openssl")
2394 "/lib")
2395 (string-append "--with-interactive-spellcheck="
2396 (assoc-ref %build-inputs "aspell")
2397 "/bin/aspell"))
2398 #:phases
2399 (modify-phases %standard-phases
2400 (add-after 'unpack 'make-reproducible
2401 (lambda _
2402 ;; This removes time-dependent code to make alpine reproducible.
2403 (substitute* "pico/blddate.c"
2404 (("%02d-%s-%d") "1970-01-01"))
2405 (substitute* (list "alpine/Makefile.in"
2406 "web/src/alpined.d/Makefile.in")
2407 (("`date`") "1970-01-01"))
2408 #t)))))
2409 (inputs
2410 `(("ncurses" ,ncurses)
2411 ("openssl" ,openssl)
2412 ("gnutls" ,gnutls)
2413 ("openldap" ,openldap)
2414 ("cyrus-sasl" ,cyrus-sasl)
2415 ("mit-krb5" ,mit-krb5)
2416 ("aspell" ,aspell)
2417 ("tcl" ,tcl)
2418 ("linux-pam" ,linux-pam)))
78ba71b0 2419 (home-page "http://repo.or.cz/alpine.git")
b0eb2af2 2420 (synopsis "Alternatively Licensed Program for Internet News and Email")
2421 (description
2422 "Alpine is a text-based mail and news client. Alpine includes several
2423tools and applications:
2424@enumerate
2425@item alpine, the Alpine mailer
2426@item pico, the standalone text editor, GNU nano's predecessor
2427@item pilot, the standalone file system navigator
2428@end enumerate\n")
2429 (license asl2.0)))
7c16151a
RS
2430
2431(define-public balsa
2432 (package
2433 (name "balsa")
e9201659 2434 (version "2.5.6")
7c16151a
RS
2435 (source
2436 (origin
2437 (method url-fetch)
e9201659
R
2438 (uri (string-append "https://pawsa.fedorapeople.org/balsa/"
2439 name "-" version ".tar.bz2"))
7c16151a
RS
2440 (sha256
2441 (base32
e9201659 2442 "17k6wcsl8gki7cskr3hhmfj6n54rha8ca3b6fzd8blsl5shsankx"))))
7c16151a
RS
2443 (build-system gnu-build-system)
2444 (arguments
2445 `(#:configure-flags
2446 '(;; Balsa tries to install additional MIME icons
2447 ;; under gtk+ directory.
2448 "--enable-extra-mimeicons=no"
2449 "--with-gtksourceview"
2450 "--with-canberra"
2451 "--with-spell-checker=gtkspell"
2452 "--with-gpgme"
2453 "--with-sqlite"
2454 "--with-compface"
2455 "--with-ldap")))
2456 (inputs
2457 `(("cyrus-sasl" ,cyrus-sasl)
2458 ("enchant" ,enchant)
2459 ("gdk-pixbuf" ,gdk-pixbuf)
8e020519 2460 ("gmime" ,gmime-2.6)
7c16151a
RS
2461 ("gnutls" ,gnutls)
2462 ("gpgme" ,gpgme)
2463 ("gtk+" ,gtk+)
2464 ("gtksourceview" ,gtksourceview)
2465 ("gtkspell3" ,gtkspell3)
2466 ("libcanberra" ,libcanberra)
2467 ("libesmtp" ,libesmtp)
2468 ("libnotify" ,libnotify)
2469 ("openldap" ,openldap)
2470 ("sqlite" ,sqlite)
2471 ("webkitgtk" ,webkitgtk)))
2472 (native-inputs
2473 `(("compface" ,compface)
2474 ("glib" ,glib "bin")
2475 ("intltool" ,intltool)
2476 ("pkg-config" ,pkg-config)
2477 ("yelp-tools" ,yelp-tools)))
2478 (home-page "https://pawsa.fedorapeople.org/balsa")
2479 (synopsis "E-mail client for GNOME")
2480 (description "Balsa is a highly configurable and robust mail client for
2481the GNOME desktop. It supports both POP3 and IMAP servers as well as the
2482mbox, maildir and mh local mailbox formats. Balsa also supports SMTP and/or
b95d5f62 2483the use of a local MTA such as Sendmail.")
7c16151a 2484 (license gpl3+)))
1e52fd83
AI
2485
2486(define-public afew
2487 (package
2488 (name "afew")
2489 (version "1.2.0")
2490 (source
2491 (origin
2492 (method url-fetch)
2493 (uri (pypi-uri "afew" version))
2494 (sha256
2495 (base32
2496 "121w7bd53xyibllxxbfykjj76n81kn1vgjqd22izyh67y8qyyk5r"))))
2497 (build-system python-build-system)
2498 (inputs
2499 `(("python-chardet" ,python-chardet)
2500 ("python-notmuch" ,python-notmuch)))
2501 (native-inputs
2502 `(("python-setuptools-scm" ,python-setuptools-scm)))
2503 (home-page "https://github.com/afewmail/afew")
2504 (synopsis "Initial tagging script for notmuch mail")
2505 (description "afew is an initial tagging script for notmuch mail. It
2506provides automatic tagging each time new mail is registered with notmuch. It
2507can add tags based on email headers or Maildir folders and can handle spam and
2508killed threads.")
2509 (license isc)))
1679923a
DM
2510
2511(define-public pan
2512 (package
2513 (name "pan")
0eeade9b 2514 (version "0.145")
1679923a
DM
2515 (source
2516 (origin
2517 (method url-fetch)
2518 (uri (string-append "http://pan.rebelbase.com/download/releases/"
2519 version "/source/" name "-" version ".tar.bz2"))
2520 (sha256
2521 (base32
0eeade9b 2522 "1b4wamv33hprghcjk903bpvnd233yxyrm18qnh13alc8h1553nk8"))))
1679923a
DM
2523 (arguments
2524 `(#:configure-flags '("--with-gtk3" "--with-gtkspell" "--with-gnutls"
2525 "--enable-libnotify" "--enable-manual"
2526 "--enable-gkr")
2527 #:phases
2528 (modify-phases %standard-phases
2529 (add-before 'configure 'patch-gpg2
2530 (lambda* (#:key inputs #:allow-other-keys)
2531 (substitute* "pan/usenet-utils/gpg.cc"
2532 (("\"gpg2\"") (string-append "\""
2533 (assoc-ref inputs "gnupg")
2534 "/bin/gpg\"")))
2535 #t)))))
2536 (inputs
8e020519 2537 `(("gmime" ,gmime-2.6)
1679923a
DM
2538 ("gnupg" ,gnupg)
2539 ("gnutls" ,gnutls)
2540 ("gtk+" ,gtk+)
2541 ("gtkspell3" ,gtkspell3)
2542 ("libnotify" ,libnotify)
2543 ("libsecret" ,libsecret)
2544 ("libxml2" ,libxml2)
2545 ("zlib" ,zlib)))
2546 (native-inputs
2547 `(("gettext-minimal" ,gettext-minimal)
2548 ("itstool" ,itstool)
2549 ("pkg-config" ,pkg-config)))
2550 (build-system gnu-build-system)
2551 (home-page "http://pan.rebelbase.com/")
2552 (synopsis "Pan newsreader")
2553 (description "@code{pan} is a Usenet newsreader that's good at both text
2554and binaries. It supports offline reading, scoring and killfiles, yEnc, NZB,
2555PGP handling, multiple servers, and secure connections.")
2556 ;; License of the docs: fdl-1.1; Others: gpl2.
2557 (license (list fdl1.1+ gpl2))))
ae7c1c37
JL
2558
2559(define-public imapfilter
2560 (package
2561 (name "imapfilter")
88abd73e 2562 (version "2.6.12")
ae7c1c37
JL
2563 (source
2564 (origin
b1d30f46
TGR
2565 (method git-fetch)
2566 (uri (git-reference
2567 (url "https://github.com/lefcha/imapfilter.git")
2568 (commit (string-append "v" version))))
2569 (file-name (git-file-name name version))
ae7c1c37 2570 (sha256
88abd73e 2571 (base32 "0vzpc54fjf5vb5vx5w0fl20xvx1k9cg6a3hbl86mm8kwsqf3wrab"))))
ae7c1c37
JL
2572 (build-system gnu-build-system)
2573 (arguments
2574 `(#:tests? #f
2575 #:make-flags
2576 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
2577 "CC=gcc")
2578 #:phases
2579 (modify-phases %standard-phases
2580 (delete 'configure)
2581 (add-after 'unpack 'fix-include-path
2582 (lambda* (#:key inputs #:allow-other-keys)
2583 (let ((pcre (assoc-ref inputs "pcre")))
2584 (substitute* "src/Makefile"
2585 (("INCDIRS =")
2586 (string-append "INCDIRS ="
2587 "-I" pcre "/include")))
2588 #t))))))
2589 (native-inputs
2590 `(("lua" ,lua)
2591 ("pcre" ,pcre)
2592 ("openssl" ,openssl)))
2593 (home-page "https://github.com/lefcha/imapfilter")
2594 (synopsis "IMAP mail filtering utility")
2595 (description "IMAPFilter is a mail filtering utility. It connects
2596to remote mail servers using IMAP, sends searching queries to the server and
2597processes mailboxes based on the results. It can be used to delete, copy,
2598move, flag, etc. messages residing in mailboxes at the same or different mail
2599servers. The 4rev1 and 4 versions of IMAP are supported.")
2600 (license license:expat)))
dc8675af
EF
2601
2602(define-public urlscan
2603 (package
2604 (name "urlscan")
d7571ff5 2605 (version "0.9.1")
dc8675af
EF
2606 (source
2607 (origin
2608 (method url-fetch)
2609 (uri (pypi-uri "urlscan" version))
2610 (sha256
2611 (base32
d7571ff5 2612 "0vpdyrx51sg9a8kswa7ibbcgcpvc7r03aq8x4n4c7v2xg0v3c7wb"))))
dc8675af
EF
2613 (build-system python-build-system)
2614 (propagated-inputs
2615 `(("python-urwid" ,python-urwid)))
2616 (home-page "https://github.com/firecat53/urlscan")
2617 (synopsis "View/select the URLs in an email message or file")
2618 (description
2619 "Urlscan is a small program that is designed to integrate with the
2620@code{mutt} mailreader to allow you to easily launch a Web browser for URLs
2621contained in email messages. It parses an email message or file and scans it
2622for URLs and email addresses. It then displays the URLs and their context
2623within the message, and allows you to choose one or more URLs to send to your
2624Web browser. Alternatively, it send a list of all URLs to stdout. It is a
2625replacement for the @code{urlview} program.")
2626 (license gpl2)))
829785c1
EB
2627
2628(define-public tnef
2629 (package
2630 (name "tnef")
2631 (version "1.4.17")
2632 (source
2633 (origin
2634 (method git-fetch)
2635 (uri (git-reference
2636 (url "https://github.com/verdammelt/tnef.git")
2637 (commit version)))
2638 (sha256
2639 (base32
2640 "0cq2xh5wd74qn6k2nnw5rayxgqhjl3jbzf4zlc4babcwxrv32ldh"))
2641 (file-name (git-file-name name version))))
2642 (build-system gnu-build-system)
2643 (native-inputs
2644 `(("autoconf" ,autoconf)
2645 ("automake" ,automake)))
2646 (arguments `(#:parallel-tests? #f)) ;tests are side-effect'y
2647 (home-page "https://github.com/verdammelt/tnef")
2648 (synopsis "Unpack @code{application/ms-tnef} attachments")
2649 (description
2650 "TNEF is a tar-like program that unpacks MIME attachments of type
2651@code{application/ms-tnef}.")
2652 (license gpl2+)))
e3a47031
RW
2653
2654(define-public mumi
e874f34d
RW
2655 (let ((commit "bfd96ce76b4600ae232e6548b26c9365095fd174")
2656 (revision "2"))
e3a47031
RW
2657 (package
2658 (name "mumi")
2659 (version (git-version "0.0.0" revision commit))
2660 (source (origin
2661 (method git-fetch)
2662 (uri (git-reference
2663 (url "https://git.elephly.net/software/mumi.git")
2664 (commit commit)))
2665 (file-name (git-file-name name version))
2666 (sha256
2667 (base32
e874f34d 2668 "05miwfi1bh0v9x2gvn15bwkb3gn4xy53z506ysjzns2y497zkc5h"))))
e3a47031
RW
2669 (build-system gnu-build-system)
2670 (arguments
2671 `(#:phases
2672 (modify-phases %standard-phases
2673 (add-after 'install 'wrap-executable
2674 (lambda* (#:key outputs #:allow-other-keys)
2675 (let* ((out (assoc-ref outputs "out"))
2676 (bin (string-append out "/bin"))
2677 (scm (string-append out "/share/guile/site/2.2"))
2678 (go (string-append out "/lib/guile/2.2/site-ccache")))
2679 (wrap-program (string-append bin "/mumi")
2680 `("GUILE_LOAD_PATH" ":" prefix
2681 (,scm ,(getenv "GUILE_LOAD_PATH")))
2682 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
2683 (,go ,(getenv "GUILE_LOAD_COMPILED_PATH"))))
2684 #t))))))
2685 (inputs
2686 `(("guile-debbugs" ,guile-debbugs-next)
2687 ("guile-email" ,guile-email)
2688 ("guile-fibers" ,guile-fibers)
2689 ("guile-json" ,guile-json)
2690 ("guile-syntax-highlight" ,guile-syntax-highlight)
79ee97a1 2691 ("guile" ,guile-2.2)))
e3a47031
RW
2692 (native-inputs
2693 `(("autoconf" ,autoconf)
2694 ("automake" ,automake)
2695 ("pkg-config" ,pkg-config)))
2696 (home-page "https://git.elephly.net/software/mumi.git")
2697 (synopsis "Debbugs web interface")
2698 (description "Mumi is a Debbugs web interface.")
2699 (license agpl3+))))