gnu: orc: Update home page.
[jackhill/guix/guix.git] / gnu / packages / guile.scm
CommitLineData
233e7676 1;;; GNU Guix --- Functional package management for GNU
a614ce38 2;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
b515822d 3;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
c5793e7e 4;;; Copyright © 2015, 2017 Christopher Allan Webber <cwebber@dustycloud.org>
44a2bdf8 5;;; Copyright © 2016 Alex Sassmannshausen <alex@pompo.co>
71311e4e 6;;; Copyright © 2016, 2017 Ricardo Wurmus <rekado@elephly.net>
76e6e663 7;;; Copyright © 2016 Erik Edrosa <erik.edrosa@gmail.com>
4176eb19 8;;; Copyright © 2016 Eraim Flashner <efraim@flashner.co.il>
bd9af610 9;;; Copyright © 2016 Alex Kost <alezost@gmail.com>
8a666bc5 10;;; Copyright © 2016 Adonay "adfeno" Felipe Nogueira <https://libreplanet.org/wiki/User:Adfeno> <adfeno@openmailbox.org>
3b5783fc 11;;; Copyright © 2016 Amirouche <amirouche@hypermove.net>
c5793e7e 12;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
aaf1bdc3 13;;; Copyright © 2017 Andy Wingo <wingo@igalia.com>
1722d680 14;;;
233e7676 15;;; This file is part of GNU Guix.
1722d680 16;;;
233e7676 17;;; GNU Guix is free software; you can redistribute it and/or modify it
1722d680
LC
18;;; under the terms of the GNU General Public License as published by
19;;; the Free Software Foundation; either version 3 of the License, or (at
20;;; your option) any later version.
21;;;
233e7676 22;;; GNU Guix is distributed in the hope that it will be useful, but
1722d680
LC
23;;; WITHOUT ANY WARRANTY; without even the implied warranty of
24;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25;;; GNU General Public License for more details.
26;;;
27;;; You should have received a copy of the GNU General Public License
233e7676 28;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
1722d680 29
1ffa7090 30(define-module (gnu packages guile)
71e0f217 31 #:use-module ((guix licenses) #:prefix license:)
59a43334 32 #:use-module (gnu packages)
472fc855 33 #:use-module (gnu packages aspell)
9c782445 34 #:use-module (gnu packages bash)
1ffa7090
LC
35 #:use-module (gnu packages bdw-gc)
36 #:use-module (gnu packages gawk)
37 #:use-module (gnu packages gperf)
38 #:use-module (gnu packages libffi)
39 #:use-module (gnu packages autotools)
f906d30c 40 #:use-module (gnu packages flex)
1ffa7090 41 #:use-module (gnu packages libunistring)
7119cca8 42 #:use-module (gnu packages linux)
1ffa7090
LC
43 #:use-module (gnu packages m4)
44 #:use-module (gnu packages multiprecision)
45 #:use-module (gnu packages pkg-config)
46 #:use-module (gnu packages readline)
ef02e1e9 47 #:use-module (gnu packages ncurses)
87d836b2 48 #:use-module (gnu packages ed)
ce0614dd 49 #:use-module (gnu packages base)
f906d30c 50 #:use-module (gnu packages texinfo)
01497dfe 51 #:use-module (gnu packages man)
f906d30c 52 #:use-module (gnu packages gettext)
b416aadf 53 #:use-module (gnu packages databases)
9d373377 54 #:use-module (gnu packages python)
5649c8cd
DT
55 #:use-module (gnu packages gl)
56 #:use-module (gnu packages sdl)
57 #:use-module (gnu packages maths)
58 #:use-module (gnu packages image)
bd233722 59 #:use-module (gnu packages version-control)
bd9af610
AK
60 #:use-module (gnu packages xdisorg)
61 #:use-module (gnu packages xorg)
71311e4e 62 #:use-module (gnu packages zip)
1722d680 63 #:use-module (guix packages)
87f5d366 64 #:use-module (guix download)
6bc24063 65 #:use-module (guix git-download)
32795fcf 66 #:use-module (guix build-system gnu)
6bc24063 67 #:use-module (guix build-system trivial)
32795fcf
LC
68 #:use-module (guix utils)
69 #:use-module (ice-9 match))
1722d680
LC
70
71;;; Commentary:
72;;;
c44899a2 73;;; GNU Guile, and modules and extensions.
1722d680
LC
74;;;
75;;; Code:
76
c44899a2
LC
77(define-public guile-1.8
78 (package
79 (name "guile")
80 (version "1.8.8")
81 (source (origin
87f5d366 82 (method url-fetch)
0db342a5 83 (uri (string-append "mirror://gnu/guile/guile-" version
c44899a2
LC
84 ".tar.gz"))
85 (sha256
86 (base32
01eafd38 87 "0l200a0v7h8bh0cwz6v7hc13ds39cgqsmfrks55b1rbj5vniyiy3"))
fc1adab1 88 (patches (search-patches "guile-1.8-cpp-4.5.patch"))))
c44899a2
LC
89 (build-system gnu-build-system)
90 (arguments '(#:configure-flags '("--disable-error-on-warning")
c44899a2
LC
91
92 ;; Insert a phase before `configure' to patch things up.
93 #:phases (alist-cons-before
94 'configure
2f4fbe1c 95 'patch-stuff
c44899a2
LC
96 (lambda* (#:key outputs #:allow-other-keys)
97 ;; Add a call to `lt_dladdsearchdir' so that
98 ;; `libguile-readline.so' & co. are in the
99 ;; loader's search path.
100 (substitute* "libguile/dynl.c"
2f4fbe1c
LC
101 (("lt_dlinit.*$" match)
102 (format #f
103 " ~a~% lt_dladdsearchdir(\"~a/lib\");~%"
104 match
105 (assoc-ref outputs "out"))))
106
107 ;; The usual /bin/sh...
108 (substitute* "ice-9/popen.scm"
109 (("/bin/sh") (which "sh"))))
c44899a2 110 %standard-phases)))
01eafd38 111 (inputs `(("gawk" ,gawk)
c44899a2
LC
112 ("readline" ,readline)))
113
114 ;; Since `guile-1.8.pc' has "Libs: ... -lgmp -lltdl", these must be
115 ;; propagated.
116 (propagated-inputs `(("gmp" ,gmp)
be11b102 117 ("libltdl" ,libltdl)))
c44899a2
LC
118
119 ;; When cross-compiling, a native version of Guile itself is needed.
120 (self-native-input? #t)
121
9be8d7c8
LC
122 (native-search-paths
123 (list (search-path-specification
124 (variable "GUILE_LOAD_PATH")
af070955 125 (files '("share/guile/site")))))
9be8d7c8 126
f50d2669 127 (synopsis "Scheme implementation intended especially for extensions")
c44899a2 128 (description
a22dc0c4
LC
129 "Guile is the GNU Ubiquitous Intelligent Language for Extensions, the
130official extension language of the GNU system. It is an implementation of
131the Scheme language which can be easily embedded in other applications to
132provide a convenient means of extending the functionality of the application
133without requiring the source code to be rewritten.")
c44899a2 134 (home-page "http://www.gnu.org/software/guile/")
71e0f217 135 (license license:lgpl2.0+)))
c44899a2
LC
136
137(define-public guile-2.0
138 (package
139 (name "guile")
7f9c8970 140 (version "2.0.12")
c62a31ca 141 (replacement guile-2.0.13) ;CVE-2016-8606 and CVE-2016-8605
c44899a2 142 (source (origin
87f5d366 143 (method url-fetch)
0db342a5 144 (uri (string-append "mirror://gnu/guile/guile-" version
c44899a2
LC
145 ".tar.xz"))
146 (sha256
147 (base32
923d9caa 148 "1sdpjq0jf1h65w29q0zprj4x6kdp5jskkvbnlwphy9lvdxrqg0fy"))))
c44899a2
LC
149 (build-system gnu-build-system)
150 (native-inputs `(("pkgconfig" ,pkg-config)))
151 (inputs `(("libffi" ,libffi)
9c782445 152 ("readline" ,readline)
88da729f
JN
153 ,@(libiconv-if-needed)
154 ,@(if (target-mingw?) '() `(("bash" ,bash)))))
c44899a2
LC
155 (propagated-inputs
156 `( ;; These ones aren't normally needed here, but since `libguile-2.0.la'
157 ;; reads `-lltdl -lunistring', adding them here will add the needed
158 ;; `-L' flags. As for why the `.la' file lacks the `-L' flags, see
159 ;; <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/18903>.
160 ("libunistring" ,libunistring)
be11b102
LC
161
162 ;; Depend on LIBLTDL, not LIBTOOL. That way, we avoid some the extra
163 ;; dependencies that LIBTOOL has, which is helpful during bootstrap.
164 ("libltdl" ,libltdl)
c44899a2
LC
165
166 ;; The headers and/or `guile-2.0.pc' refer to these packages, so they
167 ;; must be propagated.
bda1bc6c 168 ("bdw-gc" ,libgc)
c44899a2
LC
169 ("gmp" ,gmp)))
170
171 (self-native-input? #t)
172
9bf62d9b
LC
173 (outputs '("out" "debug"))
174
8ffaa93b 175 (arguments
b5e0c870
LC
176 `(#:configure-flags '("--disable-static") ;saves 3MiB
177 #:phases (alist-cons-before
8ffaa93b
LC
178 'configure 'pre-configure
179 (lambda* (#:key inputs #:allow-other-keys)
58b4e8e8 180 ;; Tell (ice-9 popen) the file name of Bash.
8ffaa93b
LC
181 (let ((bash (assoc-ref inputs "bash")))
182 (substitute* "module/ice-9/popen.scm"
88da729f
JN
183 ;; If bash is #f allow fallback for user to provide
184 ;; "bash" in PATH. This happens when cross-building to
185 ;; MinGW for which we do not have Bash yet.
8ffaa93b 186 (("/bin/sh")
88da729f
JN
187 ,@(if (target-mingw?)
188 '((if bash
189 (string-append bash "/bin/bash")
190 "bash"))
191 '((string-append bash "/bin/bash")))))))
db619089 192 %standard-phases)))
8ffaa93b 193
9be8d7c8
LC
194 (native-search-paths
195 (list (search-path-specification
196 (variable "GUILE_LOAD_PATH")
af070955 197 (files '("share/guile/site/2.0")))
9be8d7c8
LC
198 (search-path-specification
199 (variable "GUILE_LOAD_COMPILED_PATH")
ca408580 200 (files '("lib/guile/2.0/site-ccache"
05f1e956 201 "share/guile/site/2.0")))))
9be8d7c8 202
f50d2669 203 (synopsis "Scheme implementation intended especially for extensions")
c44899a2 204 (description
a22dc0c4
LC
205 "Guile is the GNU Ubiquitous Intelligent Language for Extensions, the
206official extension language of the GNU system. It is an implementation of
207the Scheme language which can be easily embedded in other applications to
208provide a convenient means of extending the functionality of the application
209without requiring the source code to be rewritten.")
c44899a2 210 (home-page "http://www.gnu.org/software/guile/")
71e0f217 211 (license license:lgpl3+)))
c44899a2 212
fa29b199
LC
213(define-public guile-2.0/fixed
214 ;; A package of Guile 2.0 that's rarely changed. It is the one used
215 ;; in the `base' module, and thus changing it entails a full rebuild.
c62a31ca
LC
216 (package
217 (inherit guile-2.0)
218 (properties '((hidden? . #t))) ;people should install 'guile-2.0'
219 (replacement #f)))
220
221(define guile-2.0.13
222 (package
223 (inherit guile-2.0)
224 (version "2.0.13")
225 (source (origin
226 (method url-fetch)
227 (uri (string-append "mirror://gnu/guile/guile-" version
228 ".tar.xz"))
229 (sha256
230 (base32
8134dc1f
LC
231 "12yqkr974y91ylgw6jnmci2v90i90s7h9vxa4zk0sai8vjnz4i1p"))
232 (patches (search-patches "guile-repl-server-test.patch"))))))
fa29b199 233
f6396d86 234(define-public guile-2.2
f906d30c 235 (package (inherit guile-2.0)
f6396d86 236 (name "guile")
80a72572 237 (version "2.2.0")
c62a31ca 238 (replacement #f)
4eae7980
LC
239 (source (origin
240 (method url-fetch)
80a72572
AW
241 (uri (string-append "mirror://gnu/guile/guile-" version
242 ".tar.lz"))
4eae7980
LC
243 (sha256
244 (base32
80a72572 245 "083vp6754dp4d5pvcy4bqvxq60cayf92v5slf5cgij8bnvixgyvr"))
d9f0788a
LC
246 (modules '((guix build utils)))
247
248 ;; Remove the pre-built object files. Instead, build everything
249 ;; from source, at the expense of significantly longer build
250 ;; times (almost 3 hours on a 4-core Intel i5).
251 (snippet '(for-each delete-file
252 (find-files "prebuilt" "\\.go$")))))
4fbd0f4f 253 (properties '((timeout . 72000) ;20 hours
f6396d86 254 (max-silent-time . 10800))) ;3 hours (needed on ARM)
dd90ed89
DT
255 (native-search-paths
256 (list (search-path-specification
257 (variable "GUILE_LOAD_PATH")
258 (files '("share/guile/site/2.2")))
259 (search-path-specification
260 (variable "GUILE_LOAD_COMPILED_PATH")
31769b9f 261 (files '("lib/guile/2.2/site-ccache"
dd90ed89 262 "share/guile/site/2.2")))))))
4eae7980 263
5cd074ea
LC
264(define-public guile-next
265 (deprecated-package "guile-next" guile-2.2))
266
8f4acad7
LC
267(define (guile-variant-package-name prefix)
268 (lambda (name)
269 "Return NAME with PREFIX instead of \"guile-\", when applicable."
270 (if (string-prefix? "guile-" name)
271 (string-append prefix "-"
272 (string-drop name
273 (string-length "guile-")))
274 name)))
947a5d47
LC
275
276(define package-for-guile-2.2
277 ;; A procedure that rewrites the dependency tree of the given package to use
f6396d86
LC
278 ;; GUILE-2.2 instead of GUILE-2.0.
279 (package-input-rewriting `((,guile-2.0 . ,guile-2.2))
8f4acad7
LC
280 (guile-variant-package-name "guile2.2")))
281
282(define package-for-guile-2.0
283 ;; Likewise, but the other way around. :-)
284 (package-input-rewriting `((,guile-2.2 . ,guile-2.0))
285 (guile-variant-package-name "guile2.0")))
947a5d47 286
4eae7980 287(define-public guile-for-guile-emacs
f6396d86 288 (package (inherit guile-2.2)
4eae7980
LC
289 (name "guile-for-guile-emacs")
290 (version "20150510.d8d9a8d")
f906d30c
CAW
291 (source (origin
292 (method git-fetch)
293 (uri (git-reference
4eae7980
LC
294 (url "git://git.hcoop.net/git/bpt/guile.git")
295 (commit "d8d9a8da05ec876acba81a559798eb5eeceb5a17")))
f906d30c
CAW
296 (sha256
297 (base32
4eae7980 298 "00sprsshy16y8pxjy126hr2adqcvvzzz96hjyjwgg8swva1qh6b0"))))
f906d30c
CAW
299 (arguments
300 (substitute-keyword-arguments `(;; Tests aren't passing for now.
301 ;; Obviously we should re-enable this!
302 #:tests? #f
f6396d86 303 ,@(package-arguments guile-2.2))
f906d30c
CAW
304 ((#:phases phases)
305 `(modify-phases ,phases
306 (add-after 'unpack 'autogen
307 (lambda _
308 (zero? (system* "sh" "autogen.sh"))))
309 (add-before 'autogen 'patch-/bin/sh
310 (lambda _
311 (substitute* "build-aux/git-version-gen"
312 (("#!/bin/sh") (string-append "#!" (which "sh"))))
313 #t))))))
314 (native-inputs
315 `(("autoconf" ,autoconf)
316 ("automake" ,automake)
317 ("libtool" ,libtool)
318 ("flex" ,flex)
319 ("texinfo" ,texinfo)
b94a6ca0 320 ("gettext" ,gettext-minimal)
f6396d86 321 ,@(package-native-inputs guile-2.2)))
daeb61f7
RW
322 ;; Same as in guile-2.0
323 (native-search-paths
324 (list (search-path-specification
325 (variable "GUILE_LOAD_PATH")
326 (files '("share/guile/site/2.0")))
327 (search-path-specification
328 (variable "GUILE_LOAD_COMPILED_PATH")
31769b9f 329 (files '("lib/guile/2.0/site-ccache"
daeb61f7 330 "share/guile/site/2.0")))))))
be3feafe 331
71311e4e
RW
332;; There has not been any release yet.
333(define-public guildhall
334 (let ((commit "2fe2cc539f4b811bbcd69e58738db03eb5a2b778")
335 (revision "1"))
336 (package
337 (name "guildhall")
338 (version (string-append "0-" revision "." (string-take commit 9)))
339 (source (origin
340 (method git-fetch)
341 (uri (git-reference
342 (url "https://github.com/ijp/guildhall.git")
343 (commit commit)))
344 (file-name (string-append name "-" version "-checkout"))
345 (sha256
346 (base32
347 "115bym7bg66h3gs399yb2vkzc2ygriaqsn4zbrg8f054mgy8wzn1"))))
348 (build-system gnu-build-system)
349 (arguments
350 `(#:phases
351 (modify-phases %standard-phases
352 ;; Tests fail without this fix because they try to load the bash
353 ;; executable as a Scheme file. See bug report at
354 ;; https://github.com/ijp/guildhall/issues/22
355 (add-after 'unpack 'fix-bug-22
356 (lambda _
357 (substitute* "Makefile.am"
358 (("TESTS_ENVIRONMENT=.*")
359 "AM_TESTS_ENVIRONMENT=srcdir=$(abs_top_srcdir)/tests/
360TEST_EXTENSIONS = .scm
361SCM_LOG_COMPILER= $(top_builddir)/env $(GUILE)
362AM_SCM_LOG_FLAGS = --no-auto-compile -s")
363 ;; FIXME: one of the database tests fails for unknown
364 ;; reasons. It does not fail when run outside of Guix.
365 (("tests/database.scm") ""))
366 #t))
367 (add-before 'configure 'autogen
368 (lambda _
369 (zero? (system* "sh" "autogen.sh")))))))
370 (inputs
371 `(("guile" ,guile-2.0)))
372 (native-inputs
373 `(("zip" ,zip) ; for tests
374 ("autoconf" ,autoconf)
375 ("automake" ,automake)
376 ("texinfo" ,texinfo)))
377 (synopsis "Package manager for Guile")
378 (description
379 "Guildhall is a package manager written for Guile Scheme. A guild is
380an association of independent craftspeople. A guildhall is where they meet.
381This Guildhall aims to make a virtual space for Guile wizards and journeyfolk
382to share code.
383
384On a practical level, Guildhall lets you share Scheme modules and programs
385over the internet, and install code that has been shared by others. Guildhall
386can handle dependencies, so when a program requires several libraries, and
387each of those has further dependencies, all of the prerequisites for the
388program can be installed in one go.")
389 (home-page "https://github.com/ijp/guildhall")
390 (license license:gpl3+))))
391
c44899a2
LC
392\f
393;;;
394;;; Extensions.
395;;;
396
7119cca8
ML
397(define-public artanis
398 (package
399 (name "artanis")
c84ceace 400 (version "0.1.2")
7119cca8
ML
401 (source (origin
402 (method url-fetch)
403 (uri (string-append "ftp://alpha.gnu.org/gnu/artanis/artanis-"
404 version ".tar.gz"))
405 (sha256
406 (base32
8a666bc5
AFN
407 "19m3ak12cqk8js9d2mdg11kh4fjsq8frfpd10qw75h0zpr5cywpp"))
408 (patches (search-patches "artanis-fix-Makefile.in.patch"))))
7119cca8
ML
409 (build-system gnu-build-system)
410 ;; TODO: Add guile-dbi and guile-dbd optional dependencies.
411 (inputs `(("guile" ,guile-2.0)))
412 (native-inputs `(("bash" ,bash) ;for the `source' builtin
413 ("pkgconfig" ,pkg-config)
414 ("util-linux" ,util-linux))) ;for the `script' command
415 (arguments
416 '(#:make-flags
417 ;; TODO: The documentation must be built with the `docs' target.
418 (let* ((out (assoc-ref %outputs "out"))
419 (dir (string-append out "/share/guile/site/2.0")))
420 ;; Don't use (%site-dir) for site paths.
421 (list (string-append "MOD_PATH=" dir)
8a666bc5 422 (string-append "MOD_COMPILED_PATH=" dir)))
7119cca8
ML
423 #:test-target "test"
424 #:phases
425 (modify-phases %standard-phases
426 (add-before
427 'install 'substitute-root-dir
428 (lambda* (#:key outputs #:allow-other-keys)
429 (let ((out (assoc-ref outputs "out")))
430 (substitute* "Makefile" ;ignore the execution of bash.bashrc
431 ((" /etc/bash.bashrc") " /dev/null"))
432 (substitute* "Makefile" ;set the root of config files to OUT
433 ((" /etc") (string-append " " out "/etc")))
434 (mkdir-p (string-append out "/bin")) ;for the `art' executable
435 #t))))))
436 (synopsis "Web application framework written in Guile")
437 (description "GNU Artanis is a web application framework written in Guile
438Scheme. A web application framework (WAF) is a software framework that is
439designed to support the development of dynamic websites, web applications, web
440services and web resources. The framework aims to alleviate the overhead
441associated with common activities performed in web development. Artanis
442provides several tools for web development: database access, templating
443frameworks, session management, URL-remapping for RESTful, page caching, and
444more.")
445 (home-page "https://www.gnu.org/software/artanis/")
71e0f217 446 (license (list license:gpl3+ license:lgpl3+)))) ;dual license
7119cca8 447
d6d9f1f7 448(define-public guile-reader
1722d680 449 (package
d6d9f1f7 450 (name "guile-reader")
77aa0887 451 (version "0.6.2")
d6d9f1f7
LC
452 (source (origin
453 (method url-fetch)
454 (uri (string-append "mirror://savannah/guile-reader/guile-reader-"
455 version ".tar.gz"))
456 (sha256
457 (base32
77aa0887 458 "0592s2s8ampqmqwilc4fvcild6rb9gy79di6vxv5kcdmv23abkgx"))))
d6d9f1f7
LC
459 (build-system gnu-build-system)
460 (native-inputs `(("pkgconfig" ,pkg-config)
461 ("gperf" ,gperf)))
bdf1022d 462 (inputs `(("guile" ,guile-2.2)))
d6d9f1f7
LC
463 (synopsis "Framework for building readers for GNU Guile")
464 (description
465 "Guile-Reader is a simple framework for building readers for GNU Guile.
1722d680
LC
466
467The idea is to make it easy to build procedures that extend Guile’s read
35b9e423 468procedure. Readers supporting various syntax variants can easily be written,
1722d680 469possibly by re-using existing “token readers” of a standard Scheme
35b9e423 470readers. For example, it is used to implement Skribilo’s R5RS-derived
1722d680
LC
471document syntax.
472
473Guile-Reader’s approach is similar to Common Lisp’s “read table”, but
474hopefully more powerful and flexible (for instance, one may instantiate as
475many readers as needed).")
d6d9f1f7 476 (home-page "http://www.nongnu.org/guile-reader/")
71e0f217 477 (license license:gpl3+)))
1722d680 478
bdf1022d
LC
479(define-public guile2.0-reader
480 (package-for-guile-2.0 guile-reader))
517fce63 481(define-public guile2.2-reader
bdf1022d 482 (deprecated-package "guile2.2-reader" guile-reader))
517fce63 483
ef02e1e9
LC
484(define-public guile-ncurses
485 (package
486 (name "guile-ncurses")
d81850d4 487 (version "2.1")
ef02e1e9
LC
488 (source (origin
489 (method url-fetch)
490 (uri (string-append "mirror://gnu/guile-ncurses/guile-ncurses-"
491 version ".tar.gz"))
492 (sha256
493 (base32
d81850d4 494 "1h7rnq4g7xlxxybcb3vjq6nscm9zhlmfaxb7258c8ax7him4azg6"))))
ef02e1e9
LC
495 (build-system gnu-build-system)
496 (inputs `(("ncurses" ,ncurses)
497 ("guile" ,guile-2.0)))
0881b616 498 (native-inputs `(("pkg-config" ,pkg-config)))
ef02e1e9 499 (arguments
2c6b7c7d 500 '(#:configure-flags (list "--with-ncursesw" ; Unicode support
0881b616 501 "--with-gnu-filesystem-hierarchy")
fa37f21b
EF
502 #:phases
503 (modify-phases %standard-phases
8c4e99cc 504 (add-before 'build 'fix-libguile-ncurses-file-name
fa37f21b 505 (lambda* (#:key outputs #:allow-other-keys)
8c4e99cc
JD
506 (and (zero? (system* "make" "install"
507 "-C" "src/ncurses"
508 "-j" (number->string
509 (parallel-job-count))))
510 (let* ((out (assoc-ref outputs "out"))
511 (dir "src/ncurses")
512 (files (find-files dir ".scm")))
513 (substitute* files
514 (("\"libguile-ncurses\"")
515 (format #f "\"~a/lib/guile/2.0/libguile-ncurses\""
516 out)))
517 #t)))))))
d81850d4 518 (home-page "https://www.gnu.org/software/guile-ncurses/")
f50d2669 519 (synopsis "Guile bindings to ncurses")
ef02e1e9 520 (description
12bcf94a 521 "guile-ncurses provides Guile language bindings for the ncurses
79c311b8 522library.")
71e0f217 523 (license license:lgpl3+)))
ef02e1e9 524
87d836b2
LC
525(define-public mcron
526 (package
527 (name "mcron")
d12c626c 528 (version "1.0.8")
87d836b2
LC
529 (source (origin
530 (method url-fetch)
531 (uri (string-append "mirror://gnu/mcron/mcron-"
532 version ".tar.gz"))
533 (sha256
534 (base32
d12c626c 535 "0zparwgf01jgl1x53ik71ghabldq6zz18ha4dscps1i0qrzgap1b"))
fc1adab1 536 (patches (search-patches "mcron-install.patch"))))
87d836b2 537 (build-system gnu-build-system)
b6c18d6a
LC
538 (native-inputs `(("pkg-config" ,pkg-config)))
539 (inputs `(("ed" ,ed) ("which" ,which) ("guile" ,guile-2.0)))
87d836b2 540 (home-page "http://www.gnu.org/software/mcron/")
f50d2669 541 (synopsis "Run jobs at scheduled times")
87d836b2 542 (description
79c311b8 543 "GNU Mcron is a complete replacement for Vixie cron. It is used to run
a22dc0c4 544tasks on a schedule, such as every hour or every Monday. Mcron is written in
79c311b8
LC
545Guile, so its configuration can be written in Scheme; the original cron
546format is also supported.")
71e0f217 547 (license license:gpl3+)))
87d836b2 548
01497dfe
LC
549(define-public mcron2
550 ;; This is mthl's mcron development branch, not yet merged in mcron.
551 (let ((commit "31baff1a5187d8ddc89324cbe42dbeffc309c962"))
552 (package
553 (inherit mcron)
554 (name "mcron2")
555 (version (string-append (package-version mcron) "-0."
556 (string-take commit 7)))
557 (source (origin
558 (method git-fetch)
559 (uri (git-reference
560 (url "https://notabug.org/mthl/mcron/")
561 (commit commit)))
562 (sha256
563 (base32
564 "1h5wxy997hxi718hpx419c23q09939kbxrjbbq54lv0cgw1bb63z"))
565 (file-name (string-append name "-" version "-checkout"))))
566 (native-inputs
567 `(("autoconf" ,autoconf)
568 ("automake" ,automake)
569 ("pkg-config" ,pkg-config)
570 ("texinfo" ,texinfo)
571 ("help2man" ,help2man)))
572 (arguments
573 `(#:modules ((ice-9 match) (ice-9 ftw)
574 ,@%gnu-build-system-modules)
575
576 #:phases (modify-phases %standard-phases
577 (add-after 'unpack 'bootstrap
578 (lambda _
579 (zero? (system* "autoreconf" "-vfi"))))
580 (add-after 'install 'wrap-mcron
581 (lambda* (#:key outputs #:allow-other-keys)
582 ;; Wrap the 'mcron' command to refer to the right
583 ;; modules.
584 (let* ((out (assoc-ref outputs "out"))
585 (bin (string-append out "/bin"))
586 (site (string-append
587 out "/share/guile/site")))
588 (match (scandir site)
589 (("." ".." version)
590 (let ((modules (string-append site "/" version)))
591 (wrap-program (string-append bin "/mcron")
592 `("GUILE_LOAD_PATH" ":" prefix
593 (,modules))
594 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
595 (,modules)))
596 #t))))))))))))
597
814b18e5
AS
598(define-public guile-ics
599 (package
600 (name "guile-ics")
601 (version "0.1.1")
602 (source (origin
603 (method git-fetch)
604 (uri (git-reference
605 (url "https://github.com/artyom-poptsov/guile-ics")
606 (commit "v0.1.1")))
607 (file-name (string-append name "-" version "-checkout"))
608 (sha256
609 (base32
610 "1pvg6j48inpbq47hq00yh5hhl2qd2srvrx5yjl7w7ky1jsjadp86"))))
611 (build-system gnu-build-system)
612 (arguments
613 '(#:phases (modify-phases %standard-phases
614 (add-before 'configure 'autoreconf
615 (lambda _
616 ;; Repository comes with a broken symlink
617 (delete-file "README")
618 (symlink "README.org" "README")
619 (zero? (system* "autoreconf" "-fi")))))))
620 (native-inputs
621 `(("autoconf" ,(autoconf-wrapper))
622 ("automake" ,automake)
623 ("texinfo" ,texinfo)
624 ;; Gettext brings 'AC_LIB_LINKFLAGS_FROM_LIBS'.
625 ("gettext" ,gettext-minimal)
626 ("pkg-config" ,pkg-config)))
627 (inputs `(("guile" ,guile-2.0) ("which" ,which)))
628 (propagated-inputs `(("guile-lib" ,guile-lib)))
629 (home-page "https://github.com/artyom-poptsov/guile-ics")
630 (synopsis "Guile parser library for the iCalendar format")
631 (description
632 "Guile-ICS is an iCalendar (RFC5545) format parser library written in
633pure Scheme. The library can be used to read and write iCalendar data.
634
635The library is shipped with documentation in Info format and usage examples.")
71e0f217 636 (license license:gpl3+)))
814b18e5 637
3e9066fc
LC
638(define-public guile-lib
639 (package
640 (name "guile-lib")
af126875 641 (version "0.2.5")
3e9066fc 642 (source (origin
af126875
MC
643 (method url-fetch)
644 (uri (string-append "mirror://savannah/guile-lib/guile-lib-"
645 version ".tar.gz"))
646 (sha256
647 (base32
648 "1qbk485djgxqrbfjvk4b7w7y4x9xygf2qb8dqnl7885kajasx8qg"))))
3e9066fc
LC
649 (build-system gnu-build-system)
650 (arguments
af126875
MC
651 '(#:make-flags
652 '("GUILE_AUTO_COMPILE=0") ;to prevent guild errors
653 #:phases
654 (modify-phases %standard-phases
655 (add-before 'configure 'patch-module-dir
656 (lambda _
657 (substitute* "src/Makefile.in"
658 (("^moddir = ([[:graph:]]+)")
659 "moddir = $(datadir)/guile/site/@GUILE_EFFECTIVE_VERSION@\n")
660 (("^godir = ([[:graph:]]+)")
661 "godir = \
bf62b8ff 662$(libdir)/guile/@GUILE_EFFECTIVE_VERSION@/site-ccache\n"))
af126875 663 #t)))))
bf62b8ff 664 (native-inputs `(("pkg-config" ,pkg-config)))
3e9066fc
LC
665 (inputs `(("guile" ,guile-2.0)))
666 (home-page "http://www.nongnu.org/guile-lib/")
667 (synopsis "Collection of useful Guile Scheme modules")
668 (description
35b9e423 669 "Guile-Lib is intended as an accumulation place for pure-scheme Guile
3e9066fc
LC
670modules, allowing for people to cooperate integrating their generic Guile
671modules into a coherent library. Think \"a down-scaled, limited-scope CPAN
672for Guile\".")
673
674 ;; The whole is under GPLv3+, but some modules are under laxer
675 ;; distribution terms such as LGPL and public domain. See `COPYING' for
676 ;; details.
71e0f217 677 (license license:gpl3+)))
3e9066fc 678
12773de3
LC
679(define-public guile2.2-lib
680 (package-for-guile-2.2 guile-lib))
681
6050a1fb
CR
682(define-public guile-json
683 (package
684 (name "guile-json")
1f4f2360 685 (version "0.6.0")
6050a1fb 686 (source (origin
ffc72ec6
LC
687 (method url-fetch)
688 (uri (string-append "mirror://savannah/guile-json/guile-json-"
689 version ".tar.gz"))
690 (sha256
691 (base32
1f4f2360 692 "1qmjg7lbgciw95fkdzvlp9f68vv17kdjky42ywfzd4ffzwww0lgc"))
ffc72ec6
LC
693 (modules '((guix build utils)))
694 (snippet
695 ;; Make sure everything goes under .../site/X.Y, like Guile's
696 ;; search paths expects.
697 '(begin
698 (substitute* "configure"
699 (("ac_subst_vars='")
700 "ac_subst_vars='GUILE_EFFECTIVE_VERSION\n"))
701 (substitute* '("Makefile.in" "json/Makefile.in")
702 (("moddir =.*/share/guile/site" all)
703 (string-append all "/@GUILE_EFFECTIVE_VERSION@")))))))
6050a1fb 704 (build-system gnu-build-system)
db5584dd 705 (native-inputs `(("guile" ,guile-2.0)))
6050a1fb
CR
706 (home-page "http://savannah.nongnu.org/projects/guile-json/")
707 (synopsis "JSON module for Guile")
708 (description
0f31d4f0
LC
709 "Guile-JSON supports parsing and building JSON documents according to the
710specification. These are the main features:
711
712@itemize
713@item Strictly complies to @uref{http://json.org, specification}.
714@item Build JSON documents programmatically via macros.
715@item Unicode support for strings.
716@item Allows JSON pretty printing.
717@end itemize\n")
71e0f217 718 (license license:lgpl3+)))
6050a1fb 719
947a5d47
LC
720(define-public guile2.2-json
721 (package-for-guile-2.2 guile-json))
722
6bc24063
CAW
723(define-public guile-minikanren
724 (package
725 (name "guile-minikanren")
726 (version "20150424.e844d85")
727 (source (origin
728 (method git-fetch)
729 (uri (git-reference
730 (url "https://github.com/ijp/minikanren.git")
731 (commit "e844d85512f8c055d3f96143ee506007389a25e3")))
821f4dc2 732 (file-name (string-append name "-" version "-checkout"))
6bc24063
CAW
733 (sha256
734 (base32
735 "0r50jlpzi940jlmxyy3ddqqwmj5r12gb4bcv0ssini9v8km13xz6"))))
736 (build-system trivial-build-system)
737 (arguments
4b74a29d 738 `(#:modules ((guix build utils))
6bc24063
CAW
739 #:builder
740 (begin
741 (use-modules (guix build utils)
4b74a29d
LC
742 (ice-9 match)
743 (ice-9 popen)
744 (ice-9 rdelim))
745
6bc24063 746 (let* ((out (assoc-ref %outputs "out"))
4b74a29d
LC
747 (guile (assoc-ref %build-inputs "guile"))
748 (effective (read-line
749 (open-pipe* OPEN_READ
750 (string-append guile "/bin/guile")
751 "-c" "(display (effective-version))")))
752 (module-dir (string-append out "/share/guile/site/"
753 effective))
6bc24063 754 (source (assoc-ref %build-inputs "source"))
f3d8cd79 755 (doc (string-append out "/share/doc/guile-minikanren"))
6bc24063
CAW
756 (scm-files '("minikanren.scm"
757 "minikanren/mkextraforms.scm"
758 "minikanren/mkprelude.scm"
759 "minikanren/mk.scm"))
760 (guild (string-append (assoc-ref %build-inputs "guile")
761 "/bin/guild")))
762 ;; Make installation directories.
763 (mkdir-p (string-append module-dir "/minikanren"))
764 (mkdir-p doc)
765
766 ;; Compile .scm files and install.
767 (chdir source)
768 (setenv "GUILE_AUTO_COMPILE" "0")
769 (for-each (lambda (file)
770 (let* ((dest-file (string-append module-dir "/"
76e6e663 771 file))
6bc24063
CAW
772 (go-file (match (string-split file #\.)
773 ((base _)
774 (string-append module-dir "/"
775 base ".go")))))
776 ;; Install source module.
777 (copy-file file dest-file)
778 ;; Install compiled module.
779 (unless (zero? (system* guild "compile"
780 "-L" source
781 "-o" go-file
782 file))
783 (error (format #f "Failed to compile ~s to ~s!"
784 file go-file)))))
785 scm-files)
786
787 ;; Also copy over the README.
96c46210 788 (install-file "README.org" doc)
6bc24063
CAW
789 #t))))
790 (inputs
791 `(("guile" ,guile-2.0)))
792 (home-page "https://github.com/ijp/minikanren")
e881752c 793 (synopsis "MiniKanren declarative logic system, packaged for Guile")
6bc24063
CAW
794 (description
795 "MiniKanren is a relational programming extension to the Scheme
796programming Language, written as a smaller version of Kanren suitable for
797pedagogical purposes. It is featured in the book, The Reasoned Schemer,
798written by Dan Friedman, William Byrd, and Oleg Kiselyov.
799
e881752c 800This is Ian Price's r6rs packaged version of miniKanren, which deviates
6bc24063
CAW
801slightly from miniKanren mainline.
802
803See http://minikanren.org/ for more on miniKanren generally.")
71e0f217 804 (license license:expat)))
6bc24063 805
947a5d47
LC
806(define-public guile2.2-minikanren
807 (package-for-guile-2.2 guile-minikanren))
808
32e14fc1
CAW
809(define-public guile-irregex
810 (package
811 (name "guile-irregex")
fb73f07a 812 (version "0.9.6")
32e14fc1
CAW
813 (source (origin
814 (method url-fetch)
815 (uri (string-append
816 "http://synthcode.com/scheme/irregex/irregex-"
d03f9446 817 version ".tar.gz"))
32e14fc1
CAW
818 (sha256
819 (base32
fb73f07a 820 "1ia3m7dp3lcxa048q0gqbiwwsyvn99baw6xkhb4bhhzn4k7bwyqq"))))
32e14fc1
CAW
821 (build-system gnu-build-system)
822 (arguments
823 `(#:modules ((guix build utils)
824 (ice-9 match)
fe447664
LC
825 (ice-9 rdelim)
826 (ice-9 popen)
32e14fc1
CAW
827 (guix build gnu-build-system))
828 #:phases
829 (modify-phases %standard-phases
32e14fc1
CAW
830 (delete 'configure)
831 (delete 'build)
832 (delete 'check)
833 (replace 'install
834 (lambda* (#:key inputs outputs #:allow-other-keys)
fe447664
LC
835 (let* ((out (assoc-ref outputs "out"))
836 (effective (read-line
837 (open-pipe* OPEN_READ
838 "guile" "-c"
839 "(display (effective-version))")))
840 (module-dir (string-append out "/share/guile/site/"
841 effective))
842 (source (assoc-ref inputs "source"))
843 (doc (string-append out "/share/doc/guile-irregex/"))
844 (guild (string-append (assoc-ref %build-inputs "guile")
845 "/bin/guild")))
846 ;; Make installation directories.
847 (mkdir-p (string-append module-dir "/rx/source"))
848 (mkdir-p doc)
849
850 ;; Compile .scm files and install.
851 (setenv "GUILE_AUTO_COMPILE" "0")
852
853 (for-each (lambda (copy-info)
854 (match copy-info
855 ((src-file dest-file-basis)
856 (let* ((dest-file (string-append
32e14fc1 857 module-dir dest-file-basis
fe447664
LC
858 ".scm"))
859 (go-file (string-append
860 module-dir dest-file-basis
861 ".go")))
862 ;; Install source module.
863 (copy-file src-file
864 dest-file)
865 ;; Install compiled module.
866 (unless (zero? (system* guild "compile"
867 "-L" (getcwd)
868 "-o" go-file
869 src-file))
870 (error (format #f "Failed to compile ~s to ~s!"
871 src-file dest-file)))))))
872 '(("irregex-guile.scm" "/rx/irregex")
873 ("irregex.scm" "/rx/source/irregex")
874 ;; Not really reachable via guile's packaging system,
875 ;; but nice to have around
876 ("irregex-utils.scm" "/rx/source/irregex-utils")))
877
878 ;; Also copy over the README.
879 (install-file "irregex.html" doc)
880 #t))))))
32e14fc1
CAW
881 (inputs
882 `(("guile" ,guile-2.0)))
883 (home-page "http://synthcode.com/scheme/irregex")
884 (synopsis "S-expression based regular expressions")
885 (description
886 "Irregex is an s-expression based alternative to your classic
887string-based regular expressions. It implements SRFI 115 and is deeply
888inspired by the SCSH regular expression system.")
71e0f217 889 (license license:bsd-3)))
93e7199b 890
947a5d47
LC
891(define-public guile2.2-irregex
892 (package-for-guile-2.2 guile-irregex))
893
93e7199b
CAW
894;; There are two guile-gdbm packages, one using the FFI and one with
895;; direct C bindings, hence the verbose name.
896
897(define-public guile-gdbm-ffi
898 (package
899 (name "guile-gdbm-ffi")
900 (version "20120209.fa1d5b6")
901 (source (origin
902 (method git-fetch)
903 (uri (git-reference
904 (url "https://github.com/ijp/guile-gdbm.git")
905 (commit "fa1d5b6231d0e4d096687b378c025f2148c5f246")))
821f4dc2 906 (file-name (string-append name "-" version "-checkout"))
93e7199b
CAW
907 (sha256
908 (base32
909 "1j8wrsw7v9w6qkl47xz0rdikg50v16nn6kbs3lgzcymjzpa7babj"))))
910 (build-system trivial-build-system)
911 (arguments
912 `(#:modules
913 ((guix build utils))
914 #:builder
915 (begin
916 (use-modules (guix build utils)
a5bd6a5e
CAW
917 (ice-9 rdelim)
918 (ice-9 popen))
919
920 ;; Avoid warnings we can safely ignore
921 (setenv "GUILE_AUTO_COMPILE" "0")
93e7199b
CAW
922
923 (let* ((out (assoc-ref %outputs "out"))
a5bd6a5e
CAW
924 (effective-version
925 (read-line
926 (open-pipe* OPEN_READ
927 (string-append
928 (assoc-ref %build-inputs "guile")
929 "/bin/guile")
930 "-c" "(display (effective-version))")))
931 (module-dir (string-append out "/share/guile/site/"
932 effective-version))
93e7199b
CAW
933 (source (assoc-ref %build-inputs "source"))
934 (doc (string-append out "/share/doc"))
935 (guild (string-append (assoc-ref %build-inputs "guile")
936 "/bin/guild"))
937 (gdbm.scm-dest
938 (string-append module-dir "/gdbm.scm"))
939 (gdbm.go-dest
a5bd6a5e
CAW
940 (string-append module-dir "/gdbm.go"))
941 (compile-file
942 (lambda (in-file out-file)
943 (system* guild "compile" "-o" out-file in-file))))
93e7199b
CAW
944 ;; Make installation directories.
945 (mkdir-p module-dir)
946 (mkdir-p doc)
947
948 ;; Switch directory for compiling and installing
949 (chdir source)
950
951 ;; copy the source
952 (copy-file "gdbm.scm" gdbm.scm-dest)
953
954 ;; Patch the FFI
955 (substitute* gdbm.scm-dest
956 (("\\(dynamic-link \"libgdbm\"\\)")
957 (format #f "(dynamic-link \"~a/lib/libgdbm.so\")"
958 (assoc-ref %build-inputs "gdbm"))))
959
960 ;; compile to the destination
a5bd6a5e 961 (compile-file gdbm.scm-dest gdbm.go-dest)))))
93e7199b
CAW
962 (inputs
963 `(("guile" ,guile-2.0)))
964 (propagated-inputs
965 `(("gdbm" ,gdbm)))
966 (home-page "https://github.com/ijp/guile-gdbm")
967 (synopsis "Guile bindings to the GDBM library via Guile's FFI")
968 (description
969 "Guile bindings to the GDBM key-value storage system, using
970Guile's foreign function interface.")
71e0f217 971 (license license:gpl3+)))
93e7199b 972
2737bcff
CAW
973(define-public guile2.2-gdbm-ffi
974 (package-for-guile-2.2 guile-gdbm-ffi))
975
e8ac1f8f
LC
976(define-public guile-sqlite3
977 (let ((commit "607721fe1174a299e45d457acacf94eefb964071"))
978 (package
979 (name "guile-sqlite3")
980 (version (string-append "0.0-0." (string-take commit 7)))
981
ae21519f
LC
982 ;; XXX: This used to be available read-only at
983 ;; <https://www.gitorious.org/guile-sqlite3/guile-sqlite3.git/> but it
984 ;; eventually disappeared, so we have our own copy here.
985 (home-page "https://notabug.org/civodul/guile-sqlite3.git")
e8ac1f8f
LC
986 (source (origin
987 (method git-fetch)
988 (uri (git-reference
989 (url home-page)
990 (commit commit)))
991 (sha256
992 (base32
993 "09gaffhh5rawz5kdmqx2ahvj1ngvxddp469r18bmjz3sz8p0slj2"))
994 (file-name (string-append name "-" version "-checkout"))
995 (modules '((guix build utils)))
996 (snippet
997 ;; Upgrade 'Makefile.am' to the current way of doing things.
998 '(substitute* "Makefile.am"
999 (("TESTS_ENVIRONMENT")
1000 "TEST_LOG_COMPILER")))))
1001
1002 (build-system gnu-build-system)
1003 (native-inputs
1004 `(("autoconf" ,autoconf)
1005 ("automake" ,automake)
1006 ("pkg-config" ,pkg-config)))
1007 (inputs
1008 `(("guile" ,guile-2.0)
1009 ("sqlite" ,sqlite)))
1010 (arguments
1011 '(#:phases (modify-phases %standard-phases
1012 (add-before 'configure 'autoreconf
1013 (lambda _
1014 (zero? (system* "autoreconf" "-vfi"))))
1015 (add-before 'build 'set-sqlite3-file-name
1016 (lambda* (#:key inputs #:allow-other-keys)
1017 (substitute* "sqlite3.scm"
1018 (("\"libsqlite3\"")
1019 (string-append "\"" (assoc-ref inputs "sqlite")
1020 "/lib/libsqlite3\"")))
1021 #t)))))
1022 (synopsis "Access SQLite databases from Guile")
1023 (description
1024 "This package provides Guile bindings to the SQLite database system.")
71e0f217 1025 (license license:gpl3+))))
e8ac1f8f 1026
27f5e13e
DT
1027(define-public haunt
1028 (package
1029 (name "haunt")
9b1a497e 1030 (version "0.2.1")
27f5e13e
DT
1031 (source (origin
1032 (method url-fetch)
4960beaa 1033 (uri (string-append "https://files.dthompson.us/haunt/haunt-"
27f5e13e
DT
1034 version ".tar.gz"))
1035 (sha256
1036 (base32
9b1a497e 1037 "1fpaf1vm6s7j13fs35barjh5yajcc2rc3pi8r7278wpgp4i2vs3w"))))
27f5e13e 1038 (build-system gnu-build-system)
4ecbf6d2
LC
1039 (arguments
1040 `(#:modules ((ice-9 match) (ice-9 ftw)
1041 ,@%gnu-build-system-modules)
1e406301 1042 #:tests? #f ; test suite is non-deterministic :(
4ecbf6d2
LC
1043 #:phases (modify-phases %standard-phases
1044 (add-after 'install 'wrap-haunt
1045 (lambda* (#:key outputs #:allow-other-keys)
1046 ;; Wrap the 'haunt' command to refer to the right
1047 ;; modules.
1048 (let* ((out (assoc-ref outputs "out"))
1049 (bin (string-append out "/bin"))
1050 (site (string-append
1051 out "/share/guile/site")))
1052 (match (scandir site)
1053 (("." ".." version)
1054 (let ((modules (string-append site "/" version)))
1055 (wrap-program (string-append bin "/haunt")
1056 `("GUILE_LOAD_PATH" ":" prefix
1057 (,modules))
1058 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
1059 (,modules)))
1060 #t)))))))))
4960beaa
DT
1061 (native-inputs
1062 `(("pkg-config" ,pkg-config)
1063 ("texinfo" ,texinfo)))
27f5e13e 1064 (inputs
bd19f65a 1065 `(("guile" ,guile-2.2)))
4960beaa 1066 (propagated-inputs
bdf1022d 1067 `(("guile-reader" ,guile-reader)
7c86c031 1068 ("guile-commonmark" ,guile-commonmark)))
27f5e13e
DT
1069 (synopsis "Functional static site generator")
1070 (description "Haunt is a static site generator written in Guile
1071Scheme. Haunt features a functional build system and an extensible
1072interface for reading articles in any format.")
1073 (home-page "http://haunt.dthompson.us")
71e0f217 1074 (license license:gpl3+)))
27f5e13e 1075
bd19f65a
LC
1076(define-public guile2.0-haunt
1077 (package-for-guile-2.0
1078 (package (inherit haunt) (name "guile2.0-haunt"))))
64f34aef 1079(define-public guile2.2-haunt
bd19f65a 1080 (deprecated-package "guile2.2-haunt" haunt))
64f34aef 1081
44a2bdf8
AS
1082(define-public guile-config
1083 (package
1084 (name "guile-config")
3c98acb7 1085 (version "0.1.1")
44a2bdf8
AS
1086 (source (origin
1087 (method url-fetch)
1088 (uri (string-append
1089 "http://alex.pompo.co/software/" name "-" version
1090 ".tar.gz"))
1091 (sha256
1092 (base32
3c98acb7 1093 "1b719bn192f9wg24rr0zx8jpmygsvyhfi35iy778pb5p392snrn8"))))
44a2bdf8
AS
1094 (build-system gnu-build-system)
1095 (inputs
1096 `(("guile" ,guile-2.0)))
1097 (synopsis "Guile application configuration parsing library")
1098 (description
1099 "Guile Config is a library providing a declarative approach to
1100application configuration specification. The library provides clean
1101configuration declaration forms, and processors that take care of:
1102configuration file creation; configuration file parsing; command-line
1103parameter parsing using getopt-long; basic GNU command-line parameter
1104generation (--help, --usage, --version); automatic output generation for the
1105above command-line parameters.")
1106 (home-page "https://github.com/a-sassmannshausen/guile-config")
71e0f217 1107 (license license:agpl3+)))
44a2bdf8 1108
36548111
DT
1109(define-public guile-redis
1110 (package
1111 (name "guile-redis")
1112 (version "0.1.0")
1113 (source (origin
1114 (method url-fetch)
1115 (uri (string-append "mirror://savannah/guile-redis/guile-redis-"
1116 version ".tar.gz"))
1117 (sha256
1118 (base32
1119 "0vx6if6b4r3kwx64vzbs6vpc0cpcr85x11w9vkzq27gw8n7isv56"))
1120 (modules '((guix build utils)))
1121 (snippet
ea833d30 1122 ;; Make sure everything goes under .../site/X.Y, like Guile's
36548111 1123 ;; search paths expects.
ea833d30
RW
1124 '(begin
1125 (substitute* "configure"
1126 (("ac_subst_vars='")
1127 "ac_subst_vars='GUILE_EFFECTIVE_VERSION\n"))
1128 (substitute* '("Makefile.in"
1129 "redis/Makefile.in"
1130 "redis/commands/Makefile.in")
1131 (("moddir =.*/share/guile/site" all)
1132 (string-append all "/@GUILE_EFFECTIVE_VERSION@")))))))
36548111
DT
1133 (build-system gnu-build-system)
1134 (native-inputs
1135 `(("guile" ,guile-2.0)))
1136 (home-page "http://savannah.nongnu.org/projects/guile-redis/")
1137 (synopsis "Redis client library for Guile")
1138 (description "Guile-redis provides a Scheme interface to the Redis
1139key-value cache and store.")
71e0f217 1140 (license license:lgpl3+)))
36548111 1141
85313be8
RW
1142(define-public guile2.2-redis
1143 (package-for-guile-2.2 guile-redis))
1144
9d373377
CAW
1145(define-public guile-wisp
1146 (package
1147 (name "guile-wisp")
1148 (version "0.9.0")
1149 (source (origin
1150 (method url-fetch)
1151 (uri (string-append "https://bitbucket.org/ArneBab/"
1152 "wisp/downloads/wisp-"
1153 version ".tar.gz"))
1154 (sha256
1155 (base32
1156 "0y5fxacalkgbv9s71h58vdvm2h2ln3rk024dd0vszwcf953as5fq"))))
1157 (build-system gnu-build-system)
1158 (arguments
1159 `(#:modules ((system base compile)
1160 ,@%gnu-build-system-modules)
1161 #:phases
1162 (modify-phases %standard-phases
1163 (add-before
1164 'configure 'substitute-before-config
1165
1166 (lambda* (#:key inputs #:allow-other-keys)
1167 (let ((bash (assoc-ref inputs "bash")))
1168 ;; configure checks for guile-2.0, but ours is just named "guile" :)
1169 (substitute* "configure"
1170 (("guile-2.0") "guile"))
1171 ;; Puts together some test files with /bin/bash hardcoded
1172 (substitute* "Makefile.in"
1173 (("/bin/bash")
1174 (string-append bash "/bin/bash") ))
1175 #t)))
1176
1177 ;; auto compilation breaks, but if we set HOME to /tmp,
1178 ;; that works ok
1179 (add-before
1180 'check 'auto-compile-hacky-workaround
1181 (lambda _
1182 (setenv "HOME" "/tmp")
1183 #t))
1184 (replace
1185 'install
1186 (lambda* (#:key outputs inputs #:allow-other-keys)
1187 (let* ((out (assoc-ref outputs "out"))
1188 (module-dir (string-append out "/share/guile/site/2.0"))
1189 (language-dir
1190 (string-append module-dir "/language/wisp"))
1191 (guild (string-append (assoc-ref inputs "guile")
1192 "/bin/guild")))
1193 ;; Make installation directories.
1194 (mkdir-p module-dir)
1195 (mkdir-p language-dir)
1196
1197 ;; copy the source
1198 (copy-file "wisp-scheme.scm"
1199 (string-append module-dir "/wisp-scheme.scm"))
1200 (copy-file "language/wisp/spec.scm"
1201 (string-append language-dir "/spec.scm"))
1202
1203 ;; compile to the destination
1204 (compile-file "wisp-scheme.scm"
1205 #:output-file (string-append
1206 module-dir "/wisp-scheme.go"))
1207 (compile-file "language/wisp/spec.scm"
1208 #:output-file (string-append
1209 language-dir "/spec.go"))
1210 #t))))))
1211 (home-page "http://draketo.de/english/wisp")
1212 (inputs
1213 `(("guile" ,guile-2.0)
1214 ("python" ,python)))
a124bbd2
SB
1215 (synopsis "Whitespace to lisp syntax for Guile")
1216 (description "Wisp is a syntax for Guile which provides a Python-like
9d373377
CAW
1217whitespace-significant language. It may be easier on the eyes for some
1218users and in some situations.")
71e0f217 1219 (license license:gpl3+)))
9d373377 1220
5649c8cd
DT
1221(define-public guile-sly
1222 (package
1223 (name "guile-sly")
1224 (version "0.1")
1225 (source (origin
1226 (method url-fetch)
8d5e7ad2 1227 (uri (string-append "https://files.dthompson.us/sly/sly-"
5649c8cd
DT
1228 version ".tar.gz"))
1229 (sha256
1230 (base32
1231 "1svzlbz2vripmyq2kjh0rig16bsrnbkwbsm558pjln9l65mcl4qq"))))
1232 (build-system gnu-build-system)
1233 (arguments
1234 '(#:configure-flags
1235 (list (string-append "--with-libfreeimage-prefix="
1236 (assoc-ref %build-inputs "freeimage"))
1237 (string-append "--with-libgslcblas-prefix="
1238 (assoc-ref %build-inputs "gsl")))))
1239 (native-inputs
1240 `(("pkg-config" ,pkg-config)))
1241 (propagated-inputs
1242 `(("guile" ,guile-2.0)
1243 ("guile-sdl" ,guile-sdl)
1244 ("guile-opengl" ,guile-opengl)))
1245 (inputs
1246 `(("gsl" ,gsl)
1247 ("freeimage" ,freeimage)
1248 ("mesa" ,mesa)))
1249 (synopsis "2D/3D game engine for GNU Guile")
1250 (description "Sly is a 2D/3D game engine written in Guile Scheme. Sly
1251features a functional reactive programming interface and live coding
1252capabilities.")
1253 (home-page "http://dthompson.us/pages/software/sly.html")
71e0f217 1254 (license license:gpl3+)))
5649c8cd 1255
dec1e2b3
AB
1256(define-public g-wrap
1257 (package
1258 (name "g-wrap")
1259 (version "1.9.15")
1260 (source (origin
1261 (method url-fetch)
1262 (uri (string-append "mirror://savannah/g-wrap/g-wrap-"
1263 version ".tar.gz"))
1264 (sha256
1265 (base32
1266 "0ak0bha37dfpj9kmyw1r8fj8nva639aw5xr66wr5gd3l1rqf5xhg"))))
1267 (build-system gnu-build-system)
1268 (native-inputs
1269 `(("pkg-config" ,pkg-config)))
1270 (propagated-inputs
1271 `(("guile" ,guile-2.0)
1272 ("guile-lib" ,guile-lib)))
1273 (inputs
1274 `(("libffi" ,libffi)))
9e8599a3
PH
1275 (arguments
1276 `(#:phases
1277 (modify-phases %standard-phases
1278 (add-before 'configure 'pre-configure
1279 (lambda* (#:key outputs #:allow-other-keys)
1280 (let ((out (assoc-ref outputs "out")))
1281 (substitute* (find-files "." "^Makefile.in$")
1282 (("guilemoduledir =.*guile/site" all)
1283 (string-append all "/2.0")))
1284 #t))))))
dec1e2b3
AB
1285 (synopsis "Generate C bindings for Guile")
1286 (description "G-Wrap is a tool and Guile library for generating function
1287wrappers for inter-language calls. It currently only supports generating Guile
1288wrappers for C functions. Given a definition of the types and prototypes for
1289a given C interface, G-Wrap will automatically generate the C code that
1290provides access to that interface and its types from the Scheme level.")
1291 (home-page "http://www.nongnu.org/g-wrap/index.html")
71e0f217 1292 (license license:lgpl2.1+)))
dec1e2b3 1293
01497dfe
LC
1294(define-public guile-dbi
1295 (package
1296 (name "guile-dbi")
1297 (version "2.1.6")
1298 (source (origin
1299 (method url-fetch)
1300 (uri (string-append
1301 "http://download.gna.org/guile-dbi/guile-dbi-"
1302 version ".tar.gz"))
1303 (sha256
1304 (base32
1305 "116njrprhgrsv1qm904sp3b02rq01fx639r433d657gyhw3x159n"))))
1306 (build-system gnu-build-system)
1307 (arguments
1308 '(#:configure-flags
1309 (list (string-append
1310 "--with-guile-site-dir=" %output "/share/guile/site/2.0"))
1311 #:phases
1312 (modify-phases %standard-phases
1313 (add-after 'install 'patch-extension-path
1314 (lambda* (#:key outputs #:allow-other-keys)
1315 (let* ((out (assoc-ref outputs "out"))
1316 (dbi.scm (string-append
1317 out "/share/guile/site/2.0/dbi/dbi.scm"))
1318 (ext (string-append out "/lib/libguile-dbi")))
1319 (substitute* dbi.scm (("libguile-dbi") ext))
1320 #t))))))
1321 (propagated-inputs
1322 `(("guile" ,guile-2.0)))
1323 (synopsis "Guile database abstraction layer")
1324 (home-page "http://home.gna.org/guile-dbi/guile-dbi.html")
1325 (description
1326 "guile-dbi is a library for Guile that provides a convenient interface to
1327SQL databases. Database programming with guile-dbi is generic in that the same
1328programming interface is presented regardless of which database system is used.
1329It currently supports MySQL, Postgres and SQLite3.")
71e0f217 1330 (license license:gpl2+)))
01497dfe
LC
1331
1332(define-public guile-dbd-sqlite3
1333 (package
1334 (name "guile-dbd-sqlite3")
1335 (version "2.1.6")
1336 (source (origin
1337 (method url-fetch)
1338 (uri (string-append
1339 "http://download.gna.org/guile-dbi/guile-dbd-sqlite3-"
1340 version ".tar.gz"))
1341 (sha256
1342 (base32
1343 "0rg71jchxd2y8x496s8zmfmikr5g8zxi8zv2ar3f7a23pph92iw2"))))
1344 (build-system gnu-build-system)
1345 (native-inputs
1346 `(("pkg-config" ,pkg-config)))
1347 (inputs
1348 `(("sqlite" ,sqlite)
1349 ("zlib" ,(@ (gnu packages compression) zlib))))
1350 (propagated-inputs
1351 `(("guile-dbi" ,guile-dbi)))
1352 (synopsis "Guile DBI driver for SQLite")
1353 (home-page "https://github.com/jkalbhenn/guile-dbd-sqlite3")
1354 (description
1355 "guile-dbi is a library for Guile that provides a convenient interface to
1356SQL databases. This package implements the interface for SQLite.")
71e0f217 1357 (license license:gpl2+)))
01497dfe 1358
bd9af610
AK
1359(define-public guile-xosd
1360 (package
1361 (name "guile-xosd")
4b2b7135 1362 (version "0.2.1")
bd9af610
AK
1363 (source (origin
1364 (method url-fetch)
1365 (uri (string-append "https://github.com/alezost/" name
1366 "/releases/download/v" version
1367 "/" name "-" version ".tar.gz"))
1368 (sha256
1369 (base32
4b2b7135 1370 "1ri5065c16kmgrf2pysn2ymxjqi5302lhpb07wkl1jr75ym8fn8p"))))
bd9af610
AK
1371 (build-system gnu-build-system)
1372 (native-inputs
1373 `(("pkg-config" ,pkg-config)))
1374 (inputs
1375 `(("guile" ,guile-2.0)
1376 ("libx11" ,libx11)
1377 ("libxext" ,libxext)
1378 ("libxinerama" ,libxinerama)
1379 ("xosd" ,xosd)))
1380 (home-page "https://github.com/alezost/guile-xosd")
1381 (synopsis "XOSD bindings for Guile")
1382 (description
1383 "Guile-XOSD provides Guile bindings for @code{libxosd},
1384@uref{http://sourceforge.net/projects/libxosd/, the X On Screen Display
1385library}.")
71e0f217 1386 (license license:gpl3+)))
bd9af610 1387
07f7cc03
AK
1388(define-public guile-daemon
1389 (package
1390 (name "guile-daemon")
876d8f29 1391 (version "0.1.1")
07f7cc03
AK
1392 (source (origin
1393 (method url-fetch)
1394 (uri (string-append "https://github.com/alezost/" name
1395 "/releases/download/v" version
1396 "/" name "-" version ".tar.gz"))
1397 (sha256
1398 (base32
876d8f29 1399 "0wsq9l6a4sijq4i1r3kcddfaznsak2jc5k59gzkhs5il5d2kn5yi"))))
07f7cc03
AK
1400 (build-system gnu-build-system)
1401 (native-inputs
1402 `(("pkg-config" ,pkg-config)))
1403 (inputs
1404 `(("guile" ,guile-2.0)))
1405 (home-page "https://github.com/alezost/guile-daemon")
1406 (synopsis "Evaluate code in a running Guile process")
1407 (description
1408 "Guile-Daemon is a small Guile program that loads your initial
1409configuration file, and then reads and evaluates Guile expressions that
1410you send to a FIFO file.")
71e0f217 1411 (license license:gpl3+)))
07f7cc03 1412
e28e74a5
EE
1413(define-public guile-commonmark
1414 (package
1415 (name "guile-commonmark")
1416 (version "0.1")
1417 (source (origin
1418 (method url-fetch)
1419 (uri (string-append "https://github.com/OrangeShark/" name
1420 "/releases/download/v" version
1421 "/" name "-" version ".tar.gz"))
1422 (sha256
1423 (base32
757ce0f9
LC
1424 "12cb5fqvvgc87f5xp0ih5az305wnjia89l5jba83d0r2p8bfy0b0"))
1425 (modules '((guix build utils)))
1426 (snippet
1427 ;; Use the real effective version of Guile in directory names
1428 ;; instead of a hard-coded "/2.0".
1429 '(begin
1430 (substitute* "configure"
1431 (("ac_subst_vars='")
1432 "ac_subst_vars='GUILE_EFFECTIVE_VERSION\n"))
1433 (substitute* "Makefile.in"
1434 (("/site/2.0")
1435 "/site/@GUILE_EFFECTIVE_VERSION@"))))))
e28e74a5
EE
1436 (build-system gnu-build-system)
1437 (inputs
7c86c031 1438 `(("guile" ,guile-2.2)))
e28e74a5
EE
1439 (synopsis "CommonMark parser for Guile")
1440 (description
1441 "guile-commonmark is a library for parsing CommonMark, a fully specified
1442variant of Markdown. The library is written in Guile Scheme and is designed
1443to transform a CommonMark document to SXML. guile-commonmark tries to closely
1444follow the @uref{http://commonmark.org/, CommonMark spec}, the main difference
1445is no support for parsing block and inline level HTML.")
1446 (home-page "https://github.com/OrangeShark/guile-commonmark")
71e0f217 1447 (license license:lgpl3+)))
e28e74a5 1448
7c86c031
LC
1449(define-public guile2.0-commonmark
1450 (package-for-guile-2.0 guile-commonmark))
947a5d47 1451(define-public guile2.2-commonmark
7c86c031 1452 (deprecated-package "guile2.2-commonmark" guile-commonmark))
947a5d47 1453
3b5783fc
AB
1454(define-public guile-bytestructures
1455 (package
1456 (name "guile-bytestructures")
1457 (version "20160726.53127f6")
1458 (source (origin
1459 (method git-fetch)
1460 (uri (git-reference
1461 (url "https://github.com/TaylanUB/scheme-bytestructures")
1462 (commit "53127f608caf64b34fa41c389b2743b546fbe9da")))
1463 (file-name (string-append name "-" version "-checkout"))
1464 (sha256
1465 (base32
1466 "0l4nx1vp9fkrgrgwjiycj7nx6wfjfd39rqamv4pmq7issi8mrywq"))))
1467 (build-system trivial-build-system)
1468 (arguments
1469 `(#:modules ((guix build utils))
1470 #:builder
1471 (begin
1472 (use-modules (guix build utils)
1473 (ice-9 match)
1474 (ice-9 popen)
1475 (ice-9 rdelim))
1476 (let* ((out (assoc-ref %outputs "out"))
1477 (guile (assoc-ref %build-inputs "guile"))
1478 (effective (read-line
1479 (open-pipe* OPEN_READ
1480 (string-append guile "/bin/guile")
1481 "-c" "(display (effective-version))")))
1482 (module-dir (string-append out "/share/guile/site/"
1483 effective))
1484 (source (assoc-ref %build-inputs "source"))
1485 (doc (string-append out "/share/doc/scheme-bytestructures"))
1486 (scm-files (filter (lambda (path)
1487 (not (string-prefix? "bytestructures/r7" path)))
1488 (with-directory-excursion source
1489 (find-files "bytestructures" "\\.scm$"))))
1490 (guild (string-append (assoc-ref %build-inputs "guile")
1491 "/bin/guild")))
1492 ;; Make installation directories.
1493 (mkdir-p doc)
1494
1495 ;; Compile .scm files and install.
1496 (chdir source)
1497 (setenv "GUILE_AUTO_COMPILE" "0")
1498 (for-each (lambda (file)
1499 (let* ((dest-file (string-append module-dir "/"
1500 file))
1501 (go-file (string-append module-dir "/"
1502 (substring file 0
1503 (string-rindex file #\.))
1504 ".go")))
1505 ;; Install source module.
1506 (mkdir-p (dirname dest-file))
1507 (copy-file file dest-file)
1508
1509 ;; Install compiled module.
1510 (mkdir-p (dirname go-file))
1511 (unless (zero? (system* guild "compile"
1512 "-L" source
1513 "-o" go-file
1514 file))
1515 (error (format #f "Failed to compile ~s to ~s!"
1516 file go-file)))))
1517 scm-files)
1518
1519 ;; Also copy over the README.
1520 (install-file "README.md" doc)
1521 #t))))
1522 (inputs
1523 `(("guile" ,guile-2.0)))
1524 (home-page "https://github.com/TaylanUB/scheme-bytestructures")
1525 (synopsis "Structured access to bytevector contents for Guile")
1526 (description
1527 "Guile bytestructures offers a system imitating the type system
1528of the C programming language, to be used on bytevectors. C's type
1529system works on raw memory, and Guile works on bytevectors which are
1530an abstraction over raw memory. It's also more powerful than the C
1531type system, elevating types to first-class status.")
71e0f217 1532 (license license:gpl3+)))
3b5783fc 1533
472fc855
LC
1534(define-public guile-aspell
1535 (package
1536 (name "guile-aspell")
1537 (version "0.3")
1538 (source (origin
1539 (method url-fetch)
1540 (uri (string-append
1541 "http://lonelycactus.com/tarball/guile_aspell-"
1542 version ".tar.gz"))
1543 (sha256
1544 (base32
1545 "1wknn57x2qcsbn7zw6sbn1ma6fjsg8cvpnf78ak47s8jw6k6j75n"))))
1546 (build-system gnu-build-system)
1547 (arguments
1548 '(#:configure-flags (list (string-append "--with-guilesitedir="
1549 (assoc-ref %outputs "out")
1550 "/share/guile/site/2.0"))
1551 #:phases (modify-phases %standard-phases
1552 (add-before 'build 'set-libaspell-file-name
1553 (lambda* (#:key inputs #:allow-other-keys)
1554 (let ((aspell (assoc-ref inputs "aspell")))
1555 (substitute* "aspell/aspell.scm"
1556 (("\"libaspell\\.so\"")
1557 (string-append "\"" aspell
1558 "/lib/libaspell\"")))
1559 #t))))))
1560 (native-inputs `(("pkg-config" ,pkg-config)))
1561 (inputs `(("guile" ,guile-2.0)
1562 ("aspell" ,aspell)))
1563 (home-page "https://github.com/spk121/guile-aspell")
1564 (synopsis "Spell-checking from Guile")
1565 (description
1566 "guile-aspell is a Guile Scheme library for comparing a string against a
1567dictionary and suggesting spelling corrections.")
71e0f217 1568 (license license:gpl3+)))
472fc855 1569
a614ce38
LC
1570(define-public guile-bash
1571 ;; This project is currently retired. It was initially announced here:
1572 ;; <https://lists.gnu.org/archive/html/guile-user/2015-02/msg00003.html>.
1573 (let ((commit "1eabc563ca5692b3e08d84f1f0e6fd2283284469")
1574 (revision "0"))
1575 (package
1576 (name "guile-bash")
1577 (version (string-append "0.1.6-" revision "." (string-take commit 7)))
1578 (home-page
1579 "https://anonscm.debian.org/cgit/users/kaction-guest/retired/dev.guile-bash.git")
1580 (source (origin
1581 (method git-fetch)
1582 (uri (git-reference
1583 (commit commit)
1584 (url home-page)))
1585 (sha256
1586 (base32
1587 "097vny990wp2qpjij6a5a5gwc6fxzg5wk56inhy18iki5v6pif1p"))
1588 (file-name (string-append name "-" version "-checkout"))))
1589 (build-system gnu-build-system)
1590 (arguments
1591 '(#:phases (modify-phases %standard-phases
1592 (add-after 'unpack 'bootstrap
1593 (lambda _
1594 (zero? (system* "sh" "bootstrap")))))
1595
1596 #:configure-flags
1597 ;; Add -I to match 'bash.pc' of Bash 4.4.
1598 (list (string-append "CPPFLAGS=-I"
1599 (assoc-ref %build-inputs "bash:include")
1600 "/include/bash/include")
1601
1602 ;; The '.a' file is useless.
1603 "--disable-static"
1604
1605 ;; Install 'lib/bash' as Bash 4.4 expects.
1606 (string-append "--libdir=" (assoc-ref %outputs "out")
1607 "/lib/bash"))))
1608 (native-inputs `(("pkg-config" ,pkg-config)
1609 ("autoconf" ,(autoconf-wrapper))
1610 ("automake" ,automake)
1611 ("libtool" ,libtool)
1612 ;; Gettext brings 'AC_LIB_LINKFLAGS_FROM_LIBS'.
1613 ("gettext" ,gettext-minimal)))
1614 (inputs `(("guile" ,guile-2.0)
1615 ("bash:include" ,bash "include")))
1616 (synopsis "Extend Bash using Guile")
1617 (description
1618 "Guile-Bash provides a shared library and set of Guile modules,
1619allowing you to extend Bash in Scheme. Scheme interfaces allow you to access
1620the following aspects of Bash:
1621
1622@itemize
1623@item aliases;
1624@item setting and getting Bash variables;
1625@item creating dynamic variables;
1626@item creating Bash functions with a Scheme implementation;
1627@item reader macro for output capturing;
1628@item reader macro for evaluating raw Bash commands.
1629@end itemize
1630
1631To enable it, run:
1632
1633@example
1634enable -f ~/.guix-profile/lib/bash/libguile-bash.so scm
1635@end example
1636
1637and then run @command{scm example.scm}.")
71e0f217 1638 (license license:gpl3+))))
a614ce38 1639
c5793e7e
CAW
1640(define-public guile-8sync
1641 (package
1642 (name "guile-8sync")
525acb6e 1643 (version "0.4.2")
c5793e7e
CAW
1644 (source (origin
1645 (method url-fetch)
1646 (uri (string-append "mirror://gnu/8sync/8sync-" version
1647 ".tar.gz"))
1648 (sha256
1649 (base32
525acb6e 1650 "031wm13srak3wsnll7j2mbbi29g1pcm4swdb71ds9yn567pn20qw"))))
c5793e7e
CAW
1651 (build-system gnu-build-system)
1652 (native-inputs `(("autoconf" ,autoconf)
1653 ("automake" ,automake)
f6396d86 1654 ("guile" ,guile-2.2)
c5793e7e
CAW
1655 ("pkg-config" ,pkg-config)
1656 ("texinfo" ,texinfo)))
1657 (arguments
1658 `(#:phases (modify-phases %standard-phases
1659 (add-before 'configure 'setenv
1660 (lambda _
1661 ;; quiet warnings
ab4a1731
CAW
1662 (setenv "GUILE_AUTO_COMPILE" "0")
1663 #t)))))
c5793e7e
CAW
1664 (home-page "https://gnu.org/s/8sync/")
1665 (synopsis "Asynchronous actor model library for Guile")
1666 (description
1667 "GNU 8sync (pronounced \"eight-sync\") is an asynchronous programming
1668library for GNU Guile based on the actor model.
1669
f6396d86 1670Note that 8sync is only available for Guile 2.2.")
71e0f217 1671 (license license:lgpl3+)))
c5793e7e 1672
aaf1bdc3
CAW
1673(define-public guile-fibers
1674 (package
1675 (name "guile-fibers")
1676 (version "1.0.0")
1677 (source (origin
1678 (method url-fetch)
1679 (uri (string-append "https://wingolog.org/pub/fibers/fibers-"
1680 version ".tar.gz"))
1681 (sha256
1682 (base32
1683 "0vjkg72ghgdgphzbjz9ig8al8271rq8974viknb2r1rg4lz92ld0"))))
1684 (build-system gnu-build-system)
1685 (native-inputs
1686 `(("texinfo" ,texinfo)
1687 ("pkg-config" ,pkg-config)))
1688 (inputs
f6396d86 1689 `(("guile" ,guile-2.2)))
aaf1bdc3
CAW
1690 (synopsis "Lightweight concurrency facility for Guile")
1691 (description
1692 "Fibers is a Guile library that implements a a lightweight concurrency
1693facility, inspired by systems like Concurrent ML, Go, and Erlang. A fiber is
1694like a \"goroutine\" from the Go language: a lightweight thread-like
1695abstraction. Systems built with Fibers can scale up to millions of concurrent
1696fibers, tens of thousands of concurrent socket connections, and many parallel
1697cores. The Fibers library also provides Concurrent ML-like channels for
1698communication between fibers.
1699
1700Note that Fibers makes use of some Guile 2.1/2.2-specific features and
1701is not available for Guile 2.0.")
1702 (home-page "https://github.com/wingo/fibers")
1703 (license license:lgpl3+)))
1704
bd233722
LC
1705(define-public guile-git
1706 (let ((revision "0")
1707 (commit "969514aa7224217bc3c1a4c5312a9469ac5f13d5"))
1708 (package
1709 (name "guile-git")
1710 (version (string-append "0.0-" revision "." (string-take commit 7)))
1711 (home-page "https://gitlab.com/amirouche/guile-git")
1712 (source (origin
1713 (method git-fetch)
1714 (uri (git-reference (url home-page) (commit commit)))
1715 (sha256
1716 (base32
1717 "079l8y6pjkmahb4k6dfqh3hk34pg540rrl29aixyvv86w9bdfjil"))
1718 (file-name (git-file-name name version))))
1719 (build-system gnu-build-system)
1720 (arguments
1721 '(#:phases (modify-phases %standard-phases
1722 (add-after 'unpack 'bootstrap
1723 (lambda _
1724 (zero? (system* "autoreconf" "-vfi")))))
1725
1726 ;; Test suite is not parallel-safe: the tests open same-named repos.
1727 #:parallel-tests? #f))
1728 (native-inputs
1729 `(("autoconf" ,autoconf)
1730 ("automake" ,automake)
1731 ("pkg-config" ,pkg-config)))
1732 (inputs
1733 `(("guile" ,guile-2.0)
1734 ("libgit2" ,libgit2)))
1735 (propagated-inputs
1736 `(("guile-bytestructures" ,guile-bytestructures)))
1737 (synopsis "Guile bindings for libgit2")
1738 (description
1739 "This package provides Guile bindings to libgit2, a library to
1740manipulate repositories of the Git version control system.")
1741 (license license:gpl3+))))
1742
1722d680 1743;;; guile.scm ends here