aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/mail.scm
diff options
context:
space:
mode:
authorMark H Weaver <mhw@netris.org>2014-02-18 23:08:04 -0500
committerMark H Weaver <mhw@netris.org>2014-02-19 22:27:25 -0500
commit681a6588b20eeb665e5cc620a158726f68ea2fdd (patch)
tree07a6d44fe5ed3d20137e40a0a245caf55193b42f /gnu/packages/mail.scm
parent68640c3c09c6c9ddcaae8d50754f0876b273d42a (diff)
downloadguix-681a6588b20eeb665e5cc620a158726f68ea2fdd.tar
guix-681a6588b20eeb665e5cc620a158726f68ea2fdd.tar.gz
gnu: Add gmime.
* gnu/packages/mail.scm (gmime): New variable.
Diffstat (limited to 'gnu/packages/mail.scm')
-rw-r--r--gnu/packages/mail.scm54
1 files changed, 52 insertions, 2 deletions
diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index bdb3d52070..8d67629c6b 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -1,5 +1,6 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright © 2014 Mark H Weaver <mhw@netris.org>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -33,11 +34,15 @@
#:use-module (gnu packages perl)
#:use-module (gnu packages readline)
#:use-module (gnu packages texinfo)
+ #:use-module (gnu packages compression)
+ #:use-module (gnu packages glib)
+ #:use-module (gnu packages pkg-config)
#:use-module ((guix licenses)
- #:select (gpl2+ gpl3+ lgpl3+))
+ #:select (gpl2+ gpl3+ lgpl2.1+ lgpl3+))
#:use-module (guix packages)
#:use-module (guix download)
- #:use-module (guix build-system gnu))
+ #:use-module (guix build-system gnu)
+ #:use-module (srfi srfi-1))
(define-public mailutils
(package
@@ -162,3 +167,48 @@ aliasing facilities to work just as they would on normal mail.")
"Mutt is a small but very powerful text-based mail client for Unix
operating systems.")
(license gpl2+)))
+
+(define-public gmime
+ (package
+ (name "gmime")
+ (version "2.6.19")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://download.gnome.org/sources/gmime/"
+ (string-join (take (string-split version #\.)
+ 2)
+ ".")
+ "/gmime-" version ".tar.xz"))
+ (sha256
+ (base32
+ "0jm1fgbjgh496rsc0il2y46qd4bqq2ln9168p4zzh68mk4ml1yxg"))))
+ (build-system gnu-build-system)
+ (native-inputs
+ `(("pkg-config" ,pkg-config)
+ ("gnupg" ,gnupg))) ; for tests only
+ (inputs `(("glib" ,glib)
+ ("gpgme" ,gpgme)
+ ("zlib" ,zlib)))
+ (arguments
+ `(#:phases
+ (alist-cons-after
+ 'unpack 'patch-paths-in-tests
+ (lambda _
+ ;; The test programs run several programs using 'system'
+ ;; with hard-coded paths. Here we patch them all. We also
+ ;; change "gpg" to "gpg2".
+ (substitute* (find-files "tests" "\\.c$")
+ (("(system *\\(\")(/[^ ]*)" all pre prog-path)
+ (let* ((base (basename prog-path))
+ (prog (which (if (string=? base "gpg") "gpg2" base))))
+ (string-append pre (or prog (error "not found: " base)))))))
+ %standard-phases)))
+ (home-page "http://spruce.sourceforge.net/gmime/")
+ (synopsis "MIME message parser and creator library")
+ (description
+ "GMime provides a core library and set of utilities which may be used for
+the creation and parsing of messages using the Multipurpose Internet Mail
+Extension (MIME).")
+ (license (list lgpl2.1+ gpl2+ gpl3+))))
+
+;;; mail.scm ends here