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