Add syntax highlighting for Scheme files.
[software/mumi.git] / guix.scm
1 ;;; mumi - Mediocre, uh, mail interface
2 ;;; Copyright © 2016, 2017, 2018 Ricardo Wurmus <rekado@elephly.net>
3 ;;;
4 ;;; This file is part of mumi.
5 ;;;
6 ;;; mumi is free software; you can redistribute it and/or modify it
7 ;;; under the terms of the GNU General Public License as published by
8 ;;; the Free Software Foundation; either version 3 of the License, or
9 ;;; (at your option) any later version.
10 ;;;
11 ;;; mumi is distributed in the hope that it will be useful, but
12 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
13 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 ;;; General Public License for more details.
15 ;;;
16 ;;; You should have received a copy of the GNU General Public License
17 ;;; along with mumi. If not, see <http://www.gnu.org/licenses/>.
18
19 ;;; Run the following command to enter a development environment for
20 ;;; mumi:
21 ;;;
22 ;;; $ guix environment -l guix.scm
23
24 (use-modules ((guix licenses) #:prefix license:)
25 (guix packages)
26 (guix download)
27 (guix git-download)
28 (guix utils)
29 (guix build-system gnu)
30 (gnu packages)
31 (gnu packages autotools)
32 (gnu packages gettext)
33 (gnu packages guile)
34 (gnu packages gsasl)
35 (gnu packages mail)
36 (gnu packages pkg-config)
37 (gnu packages texinfo)
38 (srfi srfi-1))
39
40 (define-public mailutils-next
41 ;; This version of Mailutils supports Guile 2.2, unlike version <= 3.4.
42 (let ((commit "ce5b13e92b6e2f7af243654fe0673646f00dc3a6")
43 (revision "1"))
44 (package
45 (inherit mailutils)
46 (version (string-append (package-version mailutils)
47 "-" revision "." (string-take commit 7)))
48 (source (origin
49 (method git-fetch)
50 (uri (git-reference
51 (url "https://git.savannah.gnu.org/git/mailutils.git")
52 (commit commit)
53 (recursive? #t))) ;for Gnulib & co.
54 (sha256
55 (base32
56 "15vbj5by7qg8zmh3scr3k9pymls6ijk1s85y1skclsln172r9p33"))
57 (file-name (string-append "mailutils-" version "-checkout"))))
58 (outputs '("out" "debug"))
59 (inputs
60 `(("guile" ,guile-2.2)
61 ("gsasl" ,gsasl) ;for SMTP authentication
62 ,@(alist-delete "guile" (package-inputs mailutils))))
63 (native-inputs
64 `(("autoconf" ,autoconf-wrapper)
65 ("automake" ,automake)
66 ("libtool" ,libtool)
67 ("gettext" ,gnu-gettext)
68 ,@(package-native-inputs mailutils)))
69 (arguments
70 (substitute-keyword-arguments (package-arguments mailutils)
71 ((#:modules modules %gnu-build-system-modules)
72 `((srfi srfi-1) ,@modules))
73 ((#:configure-flags flags ''())
74 `(cons* "--disable-radius"
75
76 ;; Add "/2.2" to the installation directory.
77 (string-append "--with-guile-site-dir="
78 (assoc-ref %outputs "out")
79 "/share/guile/site/2.2")
80 ,flags))
81 ((#:phases phases)
82 `(modify-phases ,phases
83 (replace 'bootstrap
84 (lambda* (#:key inputs #:allow-other-keys)
85 (for-each patch-shebang
86 '("bootstrap" "gnulib/gnulib-tool"))
87 (substitute* "bootstrap.conf"
88 (("git submodule" all)
89 (string-append "#" all)))
90 (for-each make-file-writable (find-files "gnulib"))
91 (substitute* "configure.ac"
92 (("AM_GNU_RADIUS") ""))
93 (invoke "./bootstrap" "--no-git" "--skip-po"
94 (string-append "--gnulib-srcdir=gnulib"))
95 #t))
96 (delete 'prepare-test-suite)))
97 ((#:parallel-build? _ #f) ;due to parser.y
98 #f)
99 ((#:tests? _ #f) ;XXX
100 #f))))))
101
102 (define-public guile-debbugs-next
103 (let ((commit "3b3945fbfc30ed1ca146d641f509c85bfe72901a")
104 (revision "1"))
105 (package
106 (name "guile-debbugs")
107 (version (git-version "0.0.3" revision commit))
108 (source (origin
109 (method git-fetch)
110 (uri (git-reference
111 (url "https://git.savannah.gnu.org/git/guile-debbugs.git")
112 (commit commit)))
113 (file-name (git-file-name name version))
114 (sha256
115 (base32
116 "1g5j6192mp62yvir35607pnyvvjmjz09qv7zdq3y2dx8yj5khd2g"))))
117 (build-system gnu-build-system)
118 (native-inputs
119 `(("pkg-config" ,pkg-config)
120 ("autoconf" ,autoconf)
121 ("automake" ,automake)
122 ("texinfo" ,texinfo)))
123 (inputs
124 `(("guile" ,guile-2.2.4)))
125 (home-page "https://www.gnu.org/software/guile-debbugs")
126 (synopsis "Guile bindings for the Debbugs bug tracker")
127 (description "This package provides a Guile library to communicate with a
128 Debbugs bug tracker's SOAP service.")
129 (license license:gpl3+))))
130
131 (package
132 (name "mumi")
133 (version "0.0.0")
134 (source #f)
135 (build-system gnu-build-system)
136 (inputs
137 `(("guile-debbugs" ,guile-debbugs-next)
138 ("guile-syntax-highlight" ,guile-syntax-highlight)
139 ("mailutils" ,mailutils-next)
140 ("guile" ,guile-2.2.4)))
141 (native-inputs
142 `(("autoconf" ,autoconf)
143 ("automake" ,automake)
144 ("pkg-config" ,pkg-config)))
145 (synopsis "TODO")
146 (description "TODO")
147 (home-page "TODO")
148 (license license:gpl3+))