gnu: polkit-qt: Use https for home-page.
[jackhill/guix/guix.git] / gnu / packages / guile-xyz.scm
CommitLineData
0791437f
RW
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019 Ludovic Courtès <ludo@gnu.org>
3;;; Copyright © 2014, 2015, 2018 Mark H Weaver <mhw@netris.org>
4;;; Copyright © 2015, 2017 Christopher Allan Webber <cwebber@dustycloud.org>
5;;; Copyright © 2016 Alex Sassmannshausen <alex@pompo.co>
6;;; Copyright © 2016, 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
7;;; Copyright © 2016 Erik Edrosa <erik.edrosa@gmail.com>
f61f424d 8;;; Copyright © 2016, 2019 Eraim Flashner <efraim@flashner.co.il>
0791437f
RW
9;;; Copyright © 2016, 2017 Alex Kost <alezost@gmail.com>
10;;; Copyright © 2016, 2017 Adonay "adfeno" Felipe Nogueira <https://libreplanet.org/wiki/User:Adfeno> <adfeno@openmailbox.org>
11;;; Copyright © 2016 Amirouche <amirouche@hypermove.net>
bdf2dd79 12;;; Copyright © 2016, 2019 Jan Nieuwenhuizen <janneke@gnu.org>
0791437f
RW
13;;; Copyright © 2017 Andy Wingo <wingo@igalia.com>
14;;; Copyright © 2017 David Thompson <davet@gnu.org>
a3246602 15;;; Copyright © 2017, 2018, 2019 Mathieu Othacehe <m.othacehe@gmail.com>
0791437f 16;;; Copyright © 2017 Theodoros Foradis <theodoros@foradis.org>
47956fa0 17;;; Copyright © 2017 ng0 <ng0@n0.is>
0791437f
RW
18;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
19;;; Copyright © 2018 Maxim Cournoyer <maxim.cournoyer@gmail.com>
50771f5b 20;;; Copyright © 2018, 2019 Arun Isaac <arunisaac@systemreboot.net>
0791437f
RW
21;;; Copyright © 2018 Pierre-Antoine Rouby <pierre-antoine.rouby@inria.fr>
22;;; Copyright © 2018 Eric Bavier <bavier@member.fsf.org>
cd81199c 23;;; Copyright © 2019 swedebugia <swedebugia@riseup.net>
c99f32b9 24;;; Copyright © 2019 Amar Singh <nly@disroot.org>
0791437f
RW
25;;;
26;;; This file is part of GNU Guix.
27;;;
28;;; GNU Guix is free software; you can redistribute it and/or modify it
29;;; under the terms of the GNU General Public License as published by
30;;; the Free Software Foundation; either version 3 of the License, or (at
31;;; your option) any later version.
32;;;
33;;; GNU Guix is distributed in the hope that it will be useful, but
34;;; WITHOUT ANY WARRANTY; without even the implied warranty of
35;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
36;;; GNU General Public License for more details.
37;;;
38;;; You should have received a copy of the GNU General Public License
39;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
40
41(define-module (gnu packages guile-xyz)
42 #:use-module ((guix licenses) #:prefix license:)
43 #:use-module (gnu packages)
7ff157c1 44 #:use-module (gnu packages algebra)
0791437f
RW
45 #:use-module (gnu packages aspell)
46 #:use-module (gnu packages autotools)
47 #:use-module (gnu packages base)
48 #:use-module (gnu packages bash)
49 #:use-module (gnu packages compression)
406ef442 50 #:use-module (gnu packages databases)
0791437f 51 #:use-module (gnu packages disk)
15218d4e 52 #:use-module (gnu packages emacs)
5531782d 53 #:use-module (gnu packages emacs-xyz)
0791437f
RW
54 #:use-module (gnu packages gawk)
55 #:use-module (gnu packages gettext)
56 #:use-module (gnu packages gl)
bdf2dd79 57 #:use-module (gnu packages glib)
5531782d 58 #:use-module (gnu packages gnome)
e8c2da41 59 #:use-module (gnu packages gnupg)
0791437f 60 #:use-module (gnu packages gperf)
bdf2dd79 61 #:use-module (gnu packages gtk)
0791437f
RW
62 #:use-module (gnu packages guile)
63 #:use-module (gnu packages hurd)
64 #:use-module (gnu packages image)
d1a3a8e1 65 #:use-module (gnu packages imagemagick)
0791437f
RW
66 #:use-module (gnu packages libffi)
67 #:use-module (gnu packages libunistring)
68 #:use-module (gnu packages linux)
69 #:use-module (gnu packages man)
70 #:use-module (gnu packages maths)
71 #:use-module (gnu packages multiprecision)
72 #:use-module (gnu packages ncurses)
73 #:use-module (gnu packages networking)
f0de9544 74 #:use-module (gnu packages noweb)
e8c2da41 75 #:use-module (gnu packages password-utils)
406ef442 76 #:use-module (gnu packages perl)
0791437f
RW
77 #:use-module (gnu packages pkg-config)
78 #:use-module (gnu packages python)
79 #:use-module (gnu packages readline)
80 #:use-module (gnu packages sdl)
81 #:use-module (gnu packages slang)
82 #:use-module (gnu packages sqlite)
f0de9544 83 #:use-module (gnu packages tex)
0791437f
RW
84 #:use-module (gnu packages texinfo)
85 #:use-module (gnu packages tls)
86 #:use-module (gnu packages version-control)
bdf2dd79 87 #:use-module (gnu packages webkit)
0791437f
RW
88 #:use-module (gnu packages xdisorg)
89 #:use-module (gnu packages xorg)
90 #:use-module (guix packages)
91 #:use-module (guix download)
92 #:use-module (guix git-download)
dec4b3aa 93 #:use-module (guix hg-download)
0791437f
RW
94 #:use-module (guix build-system gnu)
95 #:use-module (guix build-system guile)
96 #:use-module (guix utils)
97 #:use-module (ice-9 match)
98 #:use-module ((srfi srfi-1) #:select (alist-delete)))
99
100(define-public artanis
cd81199c 101 (let ((release "0.3.1")
fd9a6d83 102 (revision 0))
0791437f
RW
103 (package
104 (name "artanis")
105 (version (if (zero? revision)
106 release
107 (string-append release "-"
108 (number->string revision))))
109 (source (origin
110 (method url-fetch)
111 (uri (string-append "mirror://gnu/artanis/artanis-"
112 release ".tar.gz"))
113 (file-name (string-append name "-" version ".tar.gz"))
114 (sha256
115 (base32
cd81199c 116 "0hqr5m3mb558bdhkc2sadmd9cbrhp3y525wx7cwirgy6i0zmay68"))
0791437f
RW
117 (modules '((guix build utils)))
118 (snippet
119 '(begin
cd81199c 120 ;; Unbundle guile-redis and guile-json
0791437f
RW
121 (delete-file-recursively "artanis/third-party/json.scm")
122 (delete-file-recursively "artanis/third-party/json")
cd81199c 123 (delete-file-recursively "artanis/third-party/redis.scm")
124 (delete-file-recursively "artanis/third-party/redis")
0791437f 125 (substitute* '("artanis/artanis.scm"
cd81199c 126 "artanis/lpc.scm"
0791437f
RW
127 "artanis/oht.scm")
128 (("(#:use-module \\()artanis third-party (json\\))" _
129 use-module json)
130 (string-append use-module json)))
cd81199c 131 (substitute* '("artanis/lpc.scm"
132 "artanis/session.scm")
133 (("(#:use-module \\()artanis third-party (redis\\))" _
134 use-module redis)
135 (string-append use-module redis)))
0791437f
RW
136 (substitute* "artanis/oht.scm"
137 (("([[:punct:][:space:]]+)(->json-string)([[:punct:][:space:]]+)"
138 _ pre json-string post)
139 (string-append pre
140 "scm" json-string
141 post)))
142 (substitute* "artanis/artanis.scm"
143 (("[[:punct:][:space:]]+->json-string[[:punct:][:space:]]+")
144 ""))
145 #t))))
146 (build-system gnu-build-system)
cd81199c 147 ;; FIXME the bundled csv contains one more exported procedure
148 ;; (sxml->csv-string) than guile-csv. The author is maintainer of both
149 ;; projects.
0791437f
RW
150 ;; TODO: Add guile-dbi and guile-dbd optional dependencies.
151 (inputs `(("guile" ,guile-2.2)
91f55717 152 ("guile-json" ,guile-json-1)
cd81199c 153 ("guile-redis" ,guile-redis)))
0791437f
RW
154 (native-inputs `(("bash" ,bash) ;for the `source' builtin
155 ("pkgconfig" ,pkg-config)
156 ("util-linux" ,util-linux))) ;for the `script' command
157 (arguments
158 '(#:make-flags
159 ;; TODO: The documentation must be built with the `docs' target.
160 (let* ((out (assoc-ref %outputs "out"))
161 (scm (string-append out "/share/guile/site/2.2"))
162 (go (string-append out "/lib/guile/2.2/site-ccache")))
163 ;; Don't use (%site-dir) for site paths.
164 (list (string-append "MOD_PATH=" scm)
165 (string-append "MOD_COMPILED_PATH=" go)))
166 #:test-target "test"
167 #:phases
168 (modify-phases %standard-phases
fd9a6d83
CB
169 (add-after 'unpack 'patch-site-dir
170 (lambda* (#:key outputs #:allow-other-keys)
171 (substitute* "artanis/commands/help.scm"
172 (("\\(%site-dir\\)")
173 (string-append "\""
174 (assoc-ref outputs "out")
175 "/share/guile/site/2.2\"")))))
0791437f
RW
176 (add-before 'install 'substitute-root-dir
177 (lambda* (#:key outputs #:allow-other-keys)
178 (let ((out (assoc-ref outputs "out")))
179 (substitute* "Makefile" ;ignore the execution of bash.bashrc
180 ((" /etc/bash.bashrc") " /dev/null"))
181 (substitute* "Makefile" ;set the root of config files to OUT
182 ((" /etc") (string-append " " out "/etc")))
183 (mkdir-p (string-append out "/bin")) ;for the `art' executable
184 #t)))
185 (add-after 'install 'wrap-art
fd9a6d83 186 (lambda* (#:key inputs outputs #:allow-other-keys)
0791437f
RW
187 (let* ((out (assoc-ref outputs "out"))
188 (bin (string-append out "/bin"))
189 (scm (string-append out "/share/guile/site/2.2"))
190 (go (string-append out "/lib/guile/2.2/site-ccache")))
191 (wrap-program (string-append bin "/art")
fd9a6d83
CB
192 `("GUILE_LOAD_PATH" ":" prefix
193 (,scm ,(getenv "GUILE_LOAD_PATH")))
194 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
195 (,go ,(getenv "GUILE_LOAD_COMPILED_PATH"))))
0791437f
RW
196 #t))))))
197 (synopsis "Web application framework written in Guile")
198 (description "GNU Artanis is a web application framework written in Guile
199Scheme. A web application framework (WAF) is a software framework that is
200designed to support the development of dynamic websites, web applications, web
201services and web resources. The framework aims to alleviate the overhead
202associated with common activities performed in web development. Artanis
203provides several tools for web development: database access, templating
204frameworks, session management, URL-remapping for RESTful, page caching, and
205more.")
206 (home-page "https://www.gnu.org/software/artanis/")
207 (license (list license:gpl3+ license:lgpl3+))))) ;dual license
208
209;; There has not been any release yet.
210(define-public guildhall
211 (let ((commit "2fe2cc539f4b811bbcd69e58738db03eb5a2b778")
212 (revision "1"))
213 (package
214 (name "guildhall")
215 (version (string-append "0-" revision "." (string-take commit 9)))
216 (source (origin
217 (method git-fetch)
218 (uri (git-reference
219 (url "https://github.com/ijp/guildhall.git")
220 (commit commit)))
221 (file-name (string-append name "-" version "-checkout"))
222 (sha256
223 (base32
224 "115bym7bg66h3gs399yb2vkzc2ygriaqsn4zbrg8f054mgy8wzn1"))))
225 (build-system gnu-build-system)
226 (arguments
227 `(#:phases
228 (modify-phases %standard-phases
229 ;; Tests fail without this fix because they try to load the bash
230 ;; executable as a Scheme file. See bug report at
231 ;; https://github.com/ijp/guildhall/issues/22
232 (add-after 'unpack 'fix-bug-22
233 (lambda _
234 (substitute* "Makefile.am"
235 (("TESTS_ENVIRONMENT=.*")
236 "AM_TESTS_ENVIRONMENT=srcdir=$(abs_top_srcdir)/tests/
237TEST_EXTENSIONS = .scm
238SCM_LOG_COMPILER= $(top_builddir)/env $(GUILE)
239AM_SCM_LOG_FLAGS = --no-auto-compile -s")
240 ;; FIXME: one of the database tests fails for unknown
241 ;; reasons. It does not fail when run outside of Guix.
242 (("tests/database.scm") ""))
243 #t)))))
244 (inputs
245 `(("guile" ,guile-2.0)))
246 (native-inputs
247 `(("zip" ,zip) ; for tests
248 ("autoconf" ,autoconf)
249 ("automake" ,automake)
250 ("texinfo" ,texinfo)))
251 (synopsis "Package manager for Guile")
252 (description
253 "Guildhall is a package manager written for Guile Scheme. A guild is
254an association of independent craftspeople. A guildhall is where they meet.
255This Guildhall aims to make a virtual space for Guile wizards and journeyfolk
256to share code.
257
258On a practical level, Guildhall lets you share Scheme modules and programs
259over the internet, and install code that has been shared by others. Guildhall
260can handle dependencies, so when a program requires several libraries, and
261each of those has further dependencies, all of the prerequisites for the
262program can be installed in one go.")
263 (home-page "https://github.com/ijp/guildhall")
264 (license license:gpl3+))))
265
266(define-public guile-aspell
267 (package
268 (name "guile-aspell")
269 (version "0.4")
270 (source (origin
271 (method url-fetch)
272 (uri (string-append
273 "http://lonelycactus.com/tarball/guile_aspell-"
274 version ".tar.gz"))
275 (sha256
276 (base32
277 "0vpk5xj9m9qc702z3khmkwhgpb949qbsyz8kw2qycda6qnxk0077"))))
278 (build-system gnu-build-system)
279 (arguments
280 '(#:phases (modify-phases %standard-phases
281 (add-before 'configure 'set-guilesitedir
282 (lambda _
283 (substitute* "Makefile.in"
284 (("^guilesitedir =.*$")
285 "guilesitedir = \
286$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
287 #t))
288 (add-before 'build 'set-libaspell-file-name
289 (lambda* (#:key inputs #:allow-other-keys)
290 (let ((aspell (assoc-ref inputs "aspell")))
291 (substitute* "aspell.scm"
292 (("\"libaspell\\.so\"")
293 (string-append "\"" aspell
294 "/lib/libaspell\"")))
295 #t))))))
296 (native-inputs `(("pkg-config" ,pkg-config)))
297 (inputs `(("guile" ,guile-2.2)
298 ("aspell" ,aspell)))
299 (home-page "https://github.com/spk121/guile-aspell")
300 (synopsis "Spell-checking from Guile")
301 (description
302 "guile-aspell is a Guile Scheme library for comparing a string against a
303dictionary and suggesting spelling corrections.")
304 (license license:gpl3+)))
305
306(define-public guile-bash
307 ;; This project is currently retired. It was initially announced here:
308 ;; <https://lists.gnu.org/archive/html/guile-user/2015-02/msg00003.html>.
309 (let ((commit "1eabc563ca5692b3e08d84f1f0e6fd2283284469")
310 (revision "0"))
311 (package
312 (name "guile-bash")
313 (version (string-append "0.1.6-" revision "." (string-take commit 7)))
314 (home-page
315 "https://anonscm.debian.org/cgit/users/kaction-guest/retired/dev.guile-bash.git")
316 (source (origin
317 (method git-fetch)
318 (uri (git-reference
319 (commit commit)
320 (url home-page)))
321 (sha256
322 (base32
323 "097vny990wp2qpjij6a5a5gwc6fxzg5wk56inhy18iki5v6pif1p"))
324 (file-name (string-append name "-" version "-checkout"))))
325 (build-system gnu-build-system)
326 (arguments
327 '(#:configure-flags
328 ;; Add -I to match 'bash.pc' of Bash 4.4.
329 (list (string-append "CPPFLAGS=-I"
330 (assoc-ref %build-inputs "bash:include")
331 "/include/bash/include")
332
333 ;; The '.a' file is useless.
334 "--disable-static"
335
336 ;; Install 'lib/bash' as Bash 4.4 expects.
337 (string-append "--libdir=" (assoc-ref %outputs "out")
338 "/lib/bash"))))
339 (native-inputs `(("pkg-config" ,pkg-config)
340 ("autoconf" ,autoconf-wrapper)
341 ("automake" ,automake)
342 ("libtool" ,libtool)
343 ;; Gettext brings 'AC_LIB_LINKFLAGS_FROM_LIBS'.
344 ("gettext" ,gettext-minimal)
345
346 ;; Bash with loadable module support, for the test
347 ;; suite.
348 ("bash-full" ,bash)))
349 (inputs `(("guile" ,guile-2.0)
350 ("bash:include" ,bash "include")))
351 (synopsis "Extend Bash using Guile")
352 (description
353 "Guile-Bash provides a shared library and set of Guile modules,
354allowing you to extend Bash in Scheme. Scheme interfaces allow you to access
355the following aspects of Bash:
356
357@itemize
358@item aliases;
359@item setting and getting Bash variables;
360@item creating dynamic variables;
361@item creating Bash functions with a Scheme implementation;
362@item reader macro for output capturing;
363@item reader macro for evaluating raw Bash commands.
364@end itemize
365
366To enable it, run:
367
368@example
369enable -f ~/.guix-profile/lib/bash/libguile-bash.so scm
370@end example
371
372and then run @command{scm example.scm}.")
373 (license license:gpl3+))))
374
375(define-public guile-8sync
376 (package
377 (name "guile-8sync")
378 (version "0.4.2")
379 (source (origin
380 (method url-fetch)
381 (uri (string-append "mirror://gnu/8sync/8sync-" version
382 ".tar.gz"))
383 (sha256
384 (base32
385 "031wm13srak3wsnll7j2mbbi29g1pcm4swdb71ds9yn567pn20qw"))))
386 (build-system gnu-build-system)
387 (native-inputs `(("autoconf" ,autoconf)
388 ("automake" ,automake)
389 ("guile" ,guile-2.2)
390 ("pkg-config" ,pkg-config)
391 ("texinfo" ,texinfo)))
392 (arguments
393 `(#:phases (modify-phases %standard-phases
394 (add-before 'configure 'setenv
395 (lambda _
396 ;; quiet warnings
397 (setenv "GUILE_AUTO_COMPILE" "0")
398 #t)))))
399 (home-page "https://gnu.org/s/8sync/")
400 (synopsis "Asynchronous actor model library for Guile")
401 (description
402 "GNU 8sync (pronounced \"eight-sync\") is an asynchronous programming
403library for GNU Guile based on the actor model.
404
405Note that 8sync is only available for Guile 2.2.")
406 (license license:lgpl3+)))
407
408(define-public guile-daemon
409 (package
410 (name "guile-daemon")
411 (version "0.1.2")
412 (source (origin
413 (method url-fetch)
414 (uri (string-append "https://github.com/alezost/" name
415 "/releases/download/v" version
416 "/" name "-" version ".tar.gz"))
417 (sha256
418 (base32
419 "0hh6gq6b6phpxm0b1dkxyzj3f4sxdf7dji63609lzypa5v1ad2gv"))))
420 (build-system gnu-build-system)
421 (native-inputs
422 `(("pkg-config" ,pkg-config)))
423 (inputs
424 `(("guile" ,guile-2.2)))
425 (home-page "https://github.com/alezost/guile-daemon")
426 (synopsis "Evaluate code in a running Guile process")
427 (description
428 "Guile-Daemon is a small Guile program that loads your initial
429configuration file, and then reads and evaluates Guile expressions that
430you send to a FIFO file.")
431 (license license:gpl3+)))
432
433(define-public guile-dsv
434 (package
435 (name "guile-dsv")
436 (version "0.2.1")
437 (source (origin
438 (method git-fetch)
439 (uri (git-reference
440 (url "https://github.com/artyom-poptsov/guile-dsv")
441 (commit "bdc5267d007478abc20ea96d7c459b7dd9560b3d")))
442 (file-name (string-append name "-" version "-checkout"))
443 (sha256
444 (base32
445 "1irw6mz8998nwyhzrw9g94jcz60b9zljgqfmipaz1ybn8579qjx0"))))
446 (build-system gnu-build-system)
447 (native-inputs
448 `(("autoconf" ,autoconf)
449 ("automake" ,automake)
450 ("pkg-config" ,pkg-config)
451 ("texinfo" ,texinfo)))
452 (inputs `(("guile" ,guile-2.2)))
453 (propagated-inputs `(("guile-lib" ,guile-lib)))
454 (arguments
455 '(#:phases (modify-phases %standard-phases
456 (add-before 'configure 'set-guilesitedir
457 (lambda _
458 (substitute* "Makefile.in"
459 (("^guilesitedir =.*$")
460 "guilesitedir = \
461$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
462 (substitute* "modules/Makefile.in"
463 (("^guilesitedir =.*$")
464 "guilesitedir = \
465$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
466 (substitute* "modules/dsv/Makefile.in"
467 (("^guilesitedir =.*$")
468 "guilesitedir = \
469$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
470 #t)))))
471 (home-page "https://github.com/artyom-poptsov/guile-dsv")
472 (synopsis "DSV module for Guile")
473 (description
474 "Guile-DSV is a GNU Guile module for working with the
475delimiter-separated values (DSV) data format. Guile-DSV supports the
476Unix-style DSV format and RFC 4180 format.")
477 (license license:gpl3+)))
478
479(define-public guile-fibers
480 (package
481 (name "guile-fibers")
482 (version "1.0.0")
483 (source (origin
484 (method url-fetch)
485 (uri (string-append "https://wingolog.org/pub/fibers/fibers-"
486 version ".tar.gz"))
487 (sha256
488 (base32
489 "0vjkg72ghgdgphzbjz9ig8al8271rq8974viknb2r1rg4lz92ld0"))))
490 (build-system gnu-build-system)
491 (arguments
492 '(#:phases (modify-phases %standard-phases
493 (add-after 'install 'mode-guile-objects
494 (lambda* (#:key outputs #:allow-other-keys)
495 ;; .go files are installed to "lib/guile/X.Y/cache".
496 ;; This phase moves them to "…/site-ccache".
497 (let* ((out (assoc-ref outputs "out"))
498 (lib (string-append out "/lib/guile"))
499 (old (car (find-files lib "^ccache$"
500 #:directories? #t)))
501 (new (string-append (dirname old)
502 "/site-ccache")))
503 (rename-file old new)
504 #t))))))
505 (native-inputs
506 `(("texinfo" ,texinfo)
507 ("pkg-config" ,pkg-config)))
508 (inputs
509 `(("guile" ,guile-2.2)))
510 (synopsis "Lightweight concurrency facility for Guile")
511 (description
512 "Fibers is a Guile library that implements a a lightweight concurrency
513facility, inspired by systems like Concurrent ML, Go, and Erlang. A fiber is
514like a \"goroutine\" from the Go language: a lightweight thread-like
515abstraction. Systems built with Fibers can scale up to millions of concurrent
516fibers, tens of thousands of concurrent socket connections, and many parallel
517cores. The Fibers library also provides Concurrent ML-like channels for
518communication between fibers.
519
520Note that Fibers makes use of some Guile 2.1/2.2-specific features and
521is not available for Guile 2.0.")
522 (home-page "https://github.com/wingo/fibers")
523 (license license:lgpl3+)))
524
525(define-public guile-syntax-highlight
526 (package
527 (name "guile-syntax-highlight")
528 (version "0.1")
529 (source (origin
530 (method url-fetch)
531 (uri (string-append "https://files.dthompson.us/"
532 "guile-syntax-highlight/"
533 "guile-syntax-highlight-"
534 version ".tar.gz"))
535 (sha256
536 (base32
537 "1p771kq15x83483m23bhah1sz6vkalg3drm7x279f4j1cxligkzi"))))
538 (build-system gnu-build-system)
539 (native-inputs
540 `(("pkg-config" ,pkg-config)))
541 (inputs
542 `(("guile" ,guile-2.2)))
543 (synopsis "General-purpose syntax highlighter for GNU Guile")
544 (description "Guile-syntax-highlight is a general-purpose syntax
545highlighting library for GNU Guile. It can parse code written in various
546programming languages into a simple s-expression that can be converted to
547HTML (via SXML) or any other format for rendering.")
548 (home-page "http://dthompson.us/projects/guile-syntax-highlight.html")
549 (license license:lgpl3+)))
550
551(define-public guile-sjson
552 (package
553 (name "guile-sjson")
554 (version "0.2.1")
555 (source (origin
556 (method url-fetch)
557 (uri (string-append "https://dustycloud.org/misc/sjson-" version
558 ".tar.gz"))
559 (sha256
560 (base32
561 "1mzmapln79vv10qxaggz9qwcdbag3jnrj19xx8bgkmxss8h03sv3"))))
562 (build-system gnu-build-system)
563 (native-inputs
564 `(("autoconf" ,autoconf)
565 ("automake" ,automake)
566 ("pkg-config" ,pkg-config)))
567 (inputs
568 `(("guile" ,guile-2.2)))
569 (home-page "https://gitlab.com/dustyweb/guile-sjson")
570 (synopsis "S-expression based json reader/writer for Guile")
571 (description "guile-sjson is a json reader/writer for Guile.
572It has a nice, simple s-expression based syntax.")
573 (license license:lgpl3+)))
574
61dafdc0
CB
575(define-public guile-squee
576 (let ((commit "a85902a92bf6f58a1d35fd974a01ade163deda8d")
577 (revision "0"))
578 (package
579 (name "guile-squee")
580 (version (string-append "0-" revision "." (string-take commit 7)))
581 (source (origin
582 (method git-fetch)
583 (uri (git-reference
584 (url "https://notabug.org/cwebber/guile-squee.git")
585 (commit commit)))
586 (file-name (git-file-name name version))
587 (sha256
588 (base32
589 "0p1lpsp4kx57j3ai1dkxilm4ziavzzx8wbbc42m3hpziq0a7qz5z"))))
590 (build-system guile-build-system)
591 (arguments
592 '(#:phases
593 (modify-phases %standard-phases
594 (add-after 'unpack 'patch
595 (lambda* (#:key inputs #:allow-other-keys)
596 (substitute* "squee.scm"
597 (("dynamic-link \"libpq\"")
598 (string-append
599 "dynamic-link \""
600 (assoc-ref inputs "postgresql") "/lib/libpq.so"
601 "\"")))
602 #t)))))
603 (inputs
604 `(("postgresql" ,postgresql)))
605 (native-inputs
606 `(("guile" ,guile-2.2)))
607 (home-page "https://notabug.org/cwebber/guile-squee")
608 (synopsis "Connect to PostgreSQL using Guile")
609 (description
610 "@code{squee} is a Guile library for connecting to PostgreSQL databases
611using Guile's foreign function interface.")
6fd72f70 612 (license license:lgpl3+))))
61dafdc0 613
0791437f
RW
614(define-public guile-colorized
615 (package
616 (name "guile-colorized")
617 (version "0.1")
1340ce28
TGR
618 (source
619 (origin
620 (method git-fetch)
621 (uri (git-reference
55f4282e 622 (url "https://gitlab.com/NalaGinrut/guile-colorized.git")
1340ce28
TGR
623 (commit (string-append "v" version))))
624 (file-name (git-file-name name version))
625 (sha256
626 (base32 "10mv8c63159r3qvwwdvsgnsvdg7nc2ghak85zapwqpv4ywrqp9zc"))))
0791437f
RW
627 (build-system guile-build-system)
628 (native-inputs
629 `(("guile" ,guile-2.2)))
55f4282e 630 (home-page "https://gitlab.com/NalaGinrut/guile-colorized")
0791437f
RW
631 (synopsis "Colorized REPL for Guile")
632 (description
633 "Guile-colorized provides you with a colorized REPL for GNU Guile.")
634 (license license:gpl3+)))
635
636(define-public guile-pfds
637 (package
638 (name "guile-pfds")
639 (version "0.3")
640 (home-page "https://github.com/ijp/pfds")
641 (source (origin
642 (method git-fetch)
643 (uri (git-reference
644 (url home-page)
645 (commit (string-append "v" version))))
646 (sha256
647 (base32
648 "19y33wg94pf0n98dkfqd1zbw93fgky4sawxsxl6s3vyqwl0yi5vh"))
649 (file-name (string-append name "-" version "-checkout"))))
650 (build-system guile-build-system)
651 (arguments
652 '(#:source-directory "src"
653 #:phases (modify-phases %standard-phases
654 (add-after 'unpack 'move-files-around
655 (lambda _
656 ;; Move files under a pfds/ directory to reflect the
657 ;; module hierarchy.
658 (mkdir-p "src/pfds")
659 (for-each (lambda (file)
660 (rename-file file
661 (string-append "src/pfds/"
662 file)))
663 '("bbtrees.sls"
664 "deques"
665 "deques.sls"
666 "dlists.sls"
667 "fingertrees.sls"
668 "hamts.sls"
669 "heaps.sls"
670 "private"
671 "psqs.sls"
672 "queues"
673 "queues.sls"
674 "sequences.sls"
675 "sets.sls"))
676
677 ;; In Guile <= 2.2.4, there's no way to tell 'guild
678 ;; compile' to accept the ".sls" extension. So...
679 (for-each (lambda (file)
680 (rename-file file
681 (string-append
682 (string-drop-right file 4)
683 ".scm")))
684 (find-files "." "\\.sls$"))
685 #t)))))
686 (native-inputs
687 `(("guile" ,guile-2.2)))
688 (synopsis "Purely functional data structures for Guile")
689 (description
690 "This package provides purely functional data structures written in R6RS
691Scheme and compiled for Guile. It has been tested with Racket, Guile 2,
692Vicare Scheme and IronScheme. Right now it contains:
693
694@itemize
695@item queues
696@item deques
697@item bbtrees
698@item sets
699@item dlists
700@item priority search queues (PSQs)
701@item finger trees
702@item sequences
703@item heaps
704@item hash array mapped tries (HAMTs).
705@end itemize\n")
706 (license license:bsd-3)))
707
708(define-public guile-aa-tree
709 (package
710 (name "guile-aa-tree")
711 (version "3.1.1")
712 (source (origin
713 (method url-fetch)
714 (uri (string-append "mirror://savannah/guile-aa-tree/guile-aa-tree-"
715 version ".tar.gz"))
716 (sha256
717 (base32
718 "0044c105r3q9vpl17pv3phl1b79kjm1llhkakqgiasixyav01blh"))))
719 (build-system guile-build-system)
720 (native-inputs `(("guile" ,guile-2.2)))
721 ;; https://savannah.nongnu.org/projects/guile-aa-tree
722 (home-page "https://qlfiles.net/guile-aa-tree/")
723 (synopsis "AA tree data structure for Guile")
724 (description
725 "This package provides an implementation of @dfn{AA trees}, a
726self-balancing binary tree data structure, for Guile. It ensure @math{O(log
727n)} worst case performance for core operations. The module provides
728non-mutating insert, delete, and search operations, with support for
729convenient nested tree operations.")
730 (license license:gpl3+)))
731
732(define-public guile-simple-zmq
733 (let ((commit "68bedb6679716214fb9d3472da57544526f7a618")
734 (revision "3"))
735 (package
736 (name "guile-simple-zmq")
737 (version (git-version "0.0.0" revision commit))
738 (source
739 (origin
740 (method git-fetch)
741 (uri (git-reference
742 (url "https://github.com/jerry40/guile-simple-zmq")
743 (commit commit)))
744 (sha256
745 (base32
746 "1ad3xg69qqviy1f6dnlw0ysmfdbmp1jq65rfqb8nfd8dsrq2syli"))
747 (file-name (git-file-name name version))))
748 (build-system guile-build-system)
749 (arguments
750 `(#:source-directory "src"
751 #:phases (modify-phases %standard-phases
752 (add-after 'unpack 'set-libzmq-file-name
753 (lambda* (#:key inputs #:allow-other-keys)
754 (substitute* "src/simple-zmq.scm"
755 (("\\(dynamic-link \"libzmq\"\\)")
756 (format #f "(dynamic-link \"~a/lib/libzmq.so\")"
757 (assoc-ref inputs "zeromq"))))
758 #t)))))
759 (native-inputs
760 `(("guile" ,guile-2.2)))
761 (inputs
762 `(("zeromq" ,zeromq)))
763 (home-page "https://github.com/jerry40/guile-simple-zmq")
764 (synopsis "Guile wrapper over ZeroMQ library")
765 (description
766 "This package provides a Guile programming interface to the ZeroMQ
767messaging library.")
768 (license license:gpl3+))))
769
770(define-public jupyter-guile-kernel
771 (let ((commit "a7db9245a886e104138474df46c3e88b95cff629")
772 (revision "1"))
773 (package
774 (name "jupyter-guile-kernel")
775 (version (git-version "0.0.0" revision commit))
776 (source
777 (origin
778 (method git-fetch)
779 (uri (git-reference
780 (url "https://github.com/jerry40/guile-kernel")
781 (commit commit)))
782 (sha256
783 (base32
784 "0aj04853bqm47ivfcmrgpb7w3wkis847kc7qrwsa5zcn9h38qh2f"))))
785 (build-system guile-build-system)
786 (arguments
787 '(#:phases (modify-phases %standard-phases
788 (add-after 'unpack 'set-openssl-file-name
789 (lambda* (#:key inputs #:allow-other-keys)
790 ;; Record the absolute file name of the 'openssl'
791 ;; command.
792 (substitute* "src/hmac.scm"
793 (("openssl")
794 (string-append (assoc-ref inputs "openssl")
795 "/bin/openssl")))
796 #t))
797
798 ;; XXX: The code uses 'include' to include its own source
799 ;; files, and "-L src" isn't enough in this case.
800 (add-before 'build 'chdir
801 (lambda _ (chdir "src") #t))
802 (add-after 'build 'chdir-back
803 (lambda _ (chdir "..") #t))
804
805 (add-after 'install 'install-kernel
806 (lambda* (#:key inputs outputs #:allow-other-keys)
807 (let* ((out (assoc-ref outputs "out"))
808 (json (assoc-ref inputs "guile-json"))
809 (zmq (assoc-ref inputs "guile-simple-zmq"))
810 (deps (list json zmq))
811 (dir (string-append
812 out "/share/jupyter/kernels/guile"))
813 (effective (target-guile-effective-version)))
814 ;; Install kernel.
815 (install-file "src/kernel.json" dir)
816
817 ;; Fix hard-coded file name in the kernel.
818 (substitute* (string-append dir "/kernel.json")
819 (("/home/.*/guile-jupyter-kernel.scm")
820 (string-append out "/share/guile/site/"
821 (target-guile-effective-version)
822 "/guile-jupyter-kernel.scm"))
823 (("\"guile\"")
824 (string-append "\"" (assoc-ref inputs "guile")
825 "/bin/guile\""))
826 (("-s")
827 ;; Add '-L' and '-C' flags so that the kernel
828 ;; finds its dependencies.
829 (let ((-L (map (lambda (item)
830 (string-append "\"" item
831 "/share/guile/site/"
832 effective "\""))
833 deps))
834 (-C (map (lambda (item)
835 (string-append "\"" item
836 "/lib/guile/"
837 effective
838 "/site-ccache\""))
839 deps)))
840 (string-append "--no-auto-compile\""
841 (string-join -L ", \"-L\", "
842 'prefix)
843 (string-join -C ", \"-C\", "
844 'prefix)
845 ", \"-s"))))
846 #t))))))
847 (inputs
848 `(("openssl" ,openssl)
849 ("guile" ,guile-2.2)
91f55717 850 ("guile-json" ,guile-json-1)
0791437f
RW
851 ("guile-simple-zmq" ,guile-simple-zmq)))
852 (synopsis "Guile kernel for the Jupyter Notebook")
853 (description
854 "This package provides a Guile 2.x kernel for the Jupyter Notebook. It
855allows users to interact with the Guile REPL through Jupyter.")
856 (home-page "https://github.com/jerry40/guile-kernel")
857 (license license:gpl3+))))
858
859(define-public guile-sparql
860 (package
861 (name "guile-sparql")
862 (version "0.0.7")
863 (source (origin
864 (method url-fetch)
865 (uri (string-append
866 "https://github.com/roelj/guile-sparql/releases/download/"
867 version "/guile-sparql-" version ".tar.gz"))
868 (sha256
869 (base32 "1drnvhsgl0gc5crmb16yyw1j98nkhwwcgssv9vgm36ng43nnzffd"))))
870 (build-system gnu-build-system)
871 (arguments `(#:tests? #f)) ; There are no tests.
872 (native-inputs
873 `(("pkg-config" ,pkg-config)))
874 (inputs
875 `(("guile" ,guile-2.2)))
876 (home-page "https://github.com/roelj/guile-sparql")
877 (synopsis "SPARQL module for Guile")
878 (description "This package provides the functionality to query a SPARQL
879endpoint. Additionally, it provides an interface to write SPARQL queries
880using S-expressions.")
881 (license license:gpl3+)))
882
883(define-public guile-debbugs
884 (package
885 (name "guile-debbugs")
886 (version "0.0.2")
887 (source (origin
888 (method url-fetch)
889 (uri (string-append "mirror://gnu/guile-debbugs/guile-debbugs-"
890 version ".tar.gz"))
891 (sha256
892 (base32
893 "16l8910p57im6s3j93xhdaqvgfy6ms5n97177mrch3y961z5hy0i"))
894 (modules '((guix build utils)))
895 (snippet
896 '(substitute* "Makefile.in"
897 (("^godir = (.*)/ccache" _ prefix)
898 (string-append "godir = " prefix "/site-ccache"))))))
899 (build-system gnu-build-system)
900 (native-inputs
901 `(("guile" ,guile-2.2)
902 ("pkg-config" ,pkg-config)))
903 (home-page "https://savannah.gnu.org/projects/guile-debbugs/")
904 (synopsis "Guile interface to the Debbugs bug tracking service")
905 (description
906 "This package provides a Guile library to communicate with a Debbugs bug
907tracker's SOAP service, such as @url{https://bugs.gnu.org}.")
908 (license license:gpl3+)))
909
910(define-public guile-email
50771f5b
AI
911 (package
912 (name "guile-email")
2c33a849 913 (version "0.2.1")
50771f5b
AI
914 (source
915 (origin
916 (method url-fetch)
917 (uri (string-append
db18d87a
AI
918 "https://guile-email.systemreboot.net/releases/guile-email-"
919 version ".tar.lz"))
50771f5b
AI
920 (sha256
921 (base32
2c33a849 922 "1ph3pb69hr3d8mj05fmbpf5rc67dlm8qnb35cc7cxz8ingvl7kv3"))))
50771f5b
AI
923 (build-system gnu-build-system)
924 (native-inputs
925 `(("pkg-config" ,pkg-config)
db18d87a 926 ("lzip" ,lzip)))
50771f5b
AI
927 (inputs
928 `(("guile" ,guile-2.2)))
db18d87a 929 (arguments
2c33a849 930 '(#:make-flags '("GUILE_AUTO_COMPILE=0"))) ; to prevent guild warnings
db18d87a 931 (home-page "https://guile-email.systemreboot.net")
50771f5b 932 (synopsis "Guile email parser")
db18d87a
AI
933 (description "guile-email is a collection of email utilities implemented
934in pure guile. It supports parsing MIME (Multipurpose Internet Mail
935Extensions) compliant email messages and reading emails from the mbox
936format.")
50771f5b 937 (license license:agpl3+)))
0791437f
RW
938
939(define-public guile-debbugs-next
014c3012
RW
940 (let ((commit "fb0ae064037a38a0d526e08b4ad24c52e205edb9")
941 (revision "2"))
0791437f
RW
942 (package (inherit guile-debbugs)
943 (name "guile-debbugs")
944 (version (git-version "0.0.3" revision commit))
945 (source (origin
946 (method git-fetch)
947 (uri (git-reference
948 (url "https://git.savannah.gnu.org/git/guile-debbugs.git")
949 (commit commit)))
950 (file-name (git-file-name name version))
951 (sha256
952 (base32
014c3012 953 "195sacx2xc1mzzfljj62nfpi8mxn0rc6dabxckizjksnhb5irfwy"))))
0791437f
RW
954 (build-system gnu-build-system)
955 (native-inputs
956 `(("pkg-config" ,pkg-config)
957 ("autoconf" ,autoconf)
958 ("automake" ,automake)
959 ("texinfo" ,texinfo)))
960 (inputs
961 `(("guile" ,guile-2.2)
962 ("guile-email" ,guile-email))))))
963
0791437f 964(define-public guile-newt
442a11f6
MO
965 (package
966 (name "guile-newt")
967 (version "0.0.1")
968 (source (origin
969 (method git-fetch)
970 (uri (git-reference
971 (url "https://gitlab.com/mothacehe/guile-newt")
972 (commit version)))
973 (file-name (git-file-name name version))
974 (sha256
975 (base32
976 "1w7qy4dw1f4bx622l6hw8mv49sf1ha8kch8j4nganyk8fj0wn695"))))
977 (build-system gnu-build-system)
978 (arguments
979 '(#:make-flags
980 '("GUILE_AUTO_COMPILE=0"))) ;to prevent guild warnings
981 (inputs
982 `(("guile" ,guile-2.2)
983 ("newt" ,newt)))
984 (native-inputs
985 `(("autoconf" ,autoconf)
986 ("automake" ,automake)
987 ("pkg-config" ,pkg-config)))
988 (synopsis "Guile bindings to Newt")
989 (description
990 "This package provides bindings for Newt, a programming library for
0791437f
RW
991color text mode, widget based user interfaces. The bindings are written in pure
992Scheme by using Guile’s foreign function interface.")
442a11f6
MO
993 (home-page "https://gitlab.com/mothacehe/guile-newt")
994 (license license:gpl3+)))
0791437f
RW
995
996(define-public guile-mastodon
997 (package
998 (name "guile-mastodon")
999 (version "0.0.1")
1000 (source (origin
1001 (method git-fetch)
1002 (uri (git-reference
1003 (url "https://framagit.org/prouby/guile-mastodon.git")
1004 (commit (string-append "v" version))))
1005 (file-name (git-file-name name version))
1006 (sha256
1007 (base32
1008 "1vblf3d1bbwna3l09p2ap5y8ycvl549bz6whgk78imyfmn28ygry"))))
1009 (build-system gnu-build-system)
1010 (native-inputs
1011 `(("autoconf" ,autoconf)
1012 ("automake" ,automake)
1013 ("pkg-config" ,pkg-config)))
1014 (inputs
1015 `(("guile" ,guile-2.2)
1016 ("gnutls" ,gnutls)
91f55717 1017 ("guile-json" ,guile-json-1)))
0791437f
RW
1018 (home-page "https://framagit.org/prouby/guile-mastodon")
1019 (synopsis "Guile Mastodon REST API module")
1020 (description "This package provides Guile modules to access the
1021@uref{https://docs.joinmastodon.org/api/, REST API of Mastodon}, a federated
1022microblogging service.")
1023 (license license:gpl3+)))
1024
0791437f 1025(define-public guile-parted
dbcd503c
MO
1026 (package
1027 (name "guile-parted")
a3246602 1028 (version "0.0.2")
dbcd503c
MO
1029 (source (origin
1030 (method git-fetch)
1031 (uri (git-reference
1032 (url "https://gitlab.com/mothacehe/guile-parted")
1033 (commit version)))
1034 (file-name (git-file-name name version))
1035 (sha256
1036 (base32
a3246602 1037 "01qmv6xnbbq3wih0dl9bscvca2d7zx7bjiqf35y6dkaqsp8nvdxf"))))
dbcd503c
MO
1038 (build-system gnu-build-system)
1039 (arguments
1040 '(#:make-flags
1041 '("GUILE_AUTO_COMPILE=0"))) ;to prevent guild warnings
1042 (inputs
1043 `(("guile" ,guile-2.2)
1044 ("parted" ,parted)))
1045 (propagated-inputs
1046 `(("guile-bytestructures" ,guile-bytestructures)))
1047 (native-inputs
1048 `(("autoconf" ,autoconf)
1049 ("automake" ,automake)
1050 ("pkg-config" ,pkg-config)))
1051 (synopsis "Guile bindings to GNU Parted")
1052 (description
1053 "This package provides bindings for GNU Parted library, a C library
1054allowing disk partition tables creation and manipulation. The bindings are
0791437f 1055written in pure Scheme by using Guile's foreign function interface.")
dbcd503c
MO
1056 (home-page "https://gitlab.com/mothacehe/guile-parted")
1057 (license license:gpl3+)))
0791437f
RW
1058
1059(define-public guile-xosd
1060 (package
1061 (name "guile-xosd")
1062 (version "0.2.1")
1063 (source (origin
1064 (method url-fetch)
1065 (uri (string-append "https://github.com/alezost/" name
1066 "/releases/download/v" version
1067 "/" name "-" version ".tar.gz"))
1068 (sha256
1069 (base32
1070 "1ri5065c16kmgrf2pysn2ymxjqi5302lhpb07wkl1jr75ym8fn8p"))))
1071 (build-system gnu-build-system)
1072 (native-inputs
1073 `(("pkg-config" ,pkg-config)))
1074 (inputs
1075 `(("guile" ,guile-2.2)
1076 ("libx11" ,libx11)
1077 ("libxext" ,libxext)
1078 ("libxinerama" ,libxinerama)
1079 ("xosd" ,xosd)))
1080 (home-page "https://github.com/alezost/guile-xosd")
1081 (synopsis "XOSD bindings for Guile")
1082 (description
1083 "Guile-XOSD provides Guile bindings for @code{libxosd},
1084@uref{http://sourceforge.net/projects/libxosd/, the X On Screen Display
1085library}.")
1086 (license license:gpl3+)))
1087
1088(define-public guile-dbi
1089 (package
1090 (name "guile-dbi")
1091 (version "2.1.6")
1092 (source (origin
1093 (method url-fetch)
1094 (uri (string-append
1095 "http://download.gna.org/guile-dbi/guile-dbi-"
1096 version ".tar.gz"))
1097 (sha256
1098 (base32
1099 "116njrprhgrsv1qm904sp3b02rq01fx639r433d657gyhw3x159n"))))
1100 (build-system gnu-build-system)
1101 (arguments
1102 '(#:configure-flags
1103 (list (string-append
1104 "--with-guile-site-dir=" %output "/share/guile/site/2.2"))
1105 #:make-flags
406ef442
CB
1106 (list (string-append
1107 "LDFLAGS=-Wl,-rpath=" %output "/lib:"
1108 (assoc-ref %build-inputs "guile-dbd-sqlite3") "/lib" ":"
1109 (assoc-ref %build-inputs "guile-dbd-postgresql") "/lib"))
0791437f
RW
1110 #:phases
1111 (modify-phases %standard-phases
1112 (add-after 'install 'patch-extension-path
1113 (lambda* (#:key outputs #:allow-other-keys)
1114 (let* ((out (assoc-ref outputs "out"))
1115 (dbi.scm (string-append
1116 out "/share/guile/site/2.2/dbi/dbi.scm"))
1117 (ext (string-append out "/lib/libguile-dbi")))
1118 (substitute* dbi.scm (("libguile-dbi") ext))
1119 #t))))))
1120 (inputs
406ef442
CB
1121 `(("guile-dbd-sqlite3" ,guile-dbd-sqlite3)
1122 ("guile-dbd-postgresql" ,guile-dbd-postgresql))) ; only shared library, no scheme files
0791437f
RW
1123 (propagated-inputs
1124 `(("guile" ,guile-2.2)))
1125 (synopsis "Guile database abstraction layer")
1126 (home-page "http://home.gna.org/guile-dbi/guile-dbi.html")
1127 (description
1128 "guile-dbi is a library for Guile that provides a convenient interface to
1129SQL databases. Database programming with guile-dbi is generic in that the same
1130programming interface is presented regardless of which database system is used.
1131It currently supports MySQL, Postgres and SQLite3.")
1132 (license license:gpl2+)))
1133
1134(define guile-dbi-bootstrap
1135 (package
1136 (inherit guile-dbi)
1137 (name "guile-dbi-bootstrap")
1138 (inputs '())
1139 (arguments
1140 (substitute-keyword-arguments (package-arguments guile-dbi)
1141 ((#:make-flags _) '(list))))))
1142
1143(define-public guile-dbd-sqlite3
1144 (package
1145 (name "guile-dbd-sqlite3")
1146 (version "2.1.6")
1147 (source (origin
1148 (method url-fetch)
1149 (uri (string-append
1150 "http://download.gna.org/guile-dbi/guile-dbd-sqlite3-"
1151 version ".tar.gz"))
1152 (sha256
1153 (base32
1154 "0rg71jchxd2y8x496s8zmfmikr5g8zxi8zv2ar3f7a23pph92iw2"))))
1155 (build-system gnu-build-system)
1156 (native-inputs
1157 `(("pkg-config" ,pkg-config)
1158 ("guile-dbi-bootstrap" ,guile-dbi-bootstrap))) ; only required for headers
1159 (inputs
1160 `(("sqlite" ,sqlite)
1161 ("zlib" ,(@ (gnu packages compression) zlib))))
1162 (synopsis "Guile DBI driver for SQLite")
1163 (home-page "https://github.com/jkalbhenn/guile-dbd-sqlite3")
1164 (description
1165 "guile-dbi is a library for Guile that provides a convenient interface to
1166SQL databases. This package implements the interface for SQLite.")
1167 (license license:gpl2+)))
1168
406ef442
CB
1169(define-public guile-dbd-postgresql
1170 (let ((commit "e97589b6b018b206c901e4cc24db463407a4036b")
1171 (revision 0))
1172 (package
1173 (name "guile-dbd-postgresql")
1174 (version (string-append
1175 "2.1.6-" (number->string revision) "." (string-take commit 7)))
1176 (source
1177 (origin
1178 (method git-fetch)
1179 (uri (git-reference
1180 (url "https://github.com/opencog/guile-dbi.git")
1181 (commit commit)))
1182 (file-name (git-file-name name version))
1183 (sha256
1184 (base32 "0n1gv9a0kdys10a4qmnrwvg5sydwb03880asri4gqdchcj3fimni"))))
1185 (build-system gnu-build-system)
1186 (arguments
1187 '(#:phases
1188 (modify-phases %standard-phases
1189 (add-after 'unpack 'chdir
1190 (lambda _
1191 ;; The upstream Git repository contains all the code, so change
1192 ;; to the relevant directory.
1193 (chdir "guile-dbd-postgresql")
1194 #t))
1195 (add-after 'chdir 'patch-src/Makefile.am
1196 (lambda* (#:key inputs #:allow-other-keys)
1197 (substitute* "src/Makefile.am"
1198 (("/usr/include")
1199 (string-append (assoc-ref inputs "postgresql") "/include")))
1200 #t))
1201 (add-after 'patch-src/Makefile.am 'patch-src
1202 (lambda _
1203 (substitute* "src/guile-dbd-postgresql.c"
1204 (("postgresql/libpq-fe\\.h") "libpq-fe.h"))
1205 #t)))))
1206 (native-inputs
1207 `(("pkg-config" ,pkg-config)
1208 ("automake" ,automake)
1209 ("autoconf" ,autoconf)
1210 ("perl" ,perl)
1211 ("libtool" ,libtool)
1212 ("guile-dbi-bootstrap" ,guile-dbi-bootstrap)))
1213 (inputs
1214 `(("postgresql" ,postgresql)
1215 ("zlib" ,zlib)))
1216 (synopsis "Guile DBI driver for PostgreSQL")
1217 (home-page
1218 "https://github.com/opencog/guile-dbi/tree/master/guile-dbd-postgresql")
1219 (description
1220 "@code{guile-dbi} is a library for Guile that provides a convenient
1221interface to SQL databases. This package implements the interface for
1222PostgreSQL.")
1223 (license license:gpl2+))))
1224
0791437f
RW
1225(define-public guile-config
1226 (package
1227 (name "guile-config")
1228 (version "0.3")
1229 (source
1230 (origin
1231 (method git-fetch)
1232 (uri (git-reference
1233 (url "https://gitlab.com/a-sassmannshausen/guile-config")
1234 (commit "ce12de3f438c6b2b59c43ee21bcd58251835fdf3")))
1235 (file-name "guile-config-0.3-checkout")
1236 (sha256 (base32 "02zbpin0r9m2vxmr7mv68v3xdn247dcck56kbzjn0gj4c2rhih85"))))
1237 (build-system gnu-build-system)
1238 (native-inputs
1239 `(("autoconf" ,autoconf)
1240 ("automake" ,automake)
1241 ("pkg-config" ,pkg-config)
1242 ("texinfo" ,texinfo)))
1243 (inputs `(("guile" ,guile-2.2)))
1244 (synopsis
1245 "Guile application configuration parsing library.")
1246 (description
1247 "Guile Config is a library providing a declarative approach to
1248application configuration specification. The library provides clean
1249configuration declaration forms, and processors that take care of:
1250configuration file creation; configuration file parsing; command-line
1251parameter parsing using getopt-long; basic GNU command-line parameter
1252generation (--help, --usage, --version); automatic output generation for the
1253above command-line parameters.")
1254 (home-page
1255 "https://gitlab.com/a-sassmannshausen/guile-config")
1256 (license license:gpl3+)))
1257
1258(define-public guile-hall
1259 (package
1260 (name "guile-hall")
63bf0afd 1261 (version "0.2")
0791437f 1262 (source
feb11b08
RW
1263 (origin
1264 (method git-fetch)
1265 (uri (git-reference
1266 (url "https://gitlab.com/a-sassmannshausen/guile-hall")
1267 (commit (string-append "v" version))))
1268 (file-name (git-file-name name version))
1269 (sha256 (base32
1270 "1bkbqgj24xh5b65sw2m98iggpi67b72szx1dsiq3cpzlcxplmgaz"))))
0791437f
RW
1271 (build-system gnu-build-system)
1272 (arguments
63bf0afd
AS
1273 `(#:modules
1274 ((ice-9 match)
1275 (ice-9 ftw)
1276 ,@%gnu-build-system-modules)
1277 #:phases
1278 (modify-phases
1279 %standard-phases
1280 (add-after 'install 'hall-wrap-binaries
1281 (lambda* (#:key inputs outputs #:allow-other-keys)
1282 (let* ((compiled-dir
1283 (lambda (out version)
1284 (string-append
1285 out "/lib/guile/" version "/site-ccache")))
1286 (uncompiled-dir
1287 (lambda (out version)
1288 (string-append
1289 out "/share/guile/site"
1290 (if (string-null? version) "" "/") version)))
1291 (dep-path
1292 (lambda (env modules path)
1293 (list env ":" 'prefix
1294 (cons modules
1295 (map (lambda (input)
1296 (string-append
1297 (assoc-ref inputs input)
1298 path))
1299 ,''("guile-config"))))))
1300 (out (assoc-ref outputs "out"))
1301 (bin (string-append out "/bin/"))
1302 (site (uncompiled-dir out "")))
1303 (match (scandir site)
1304 (("." ".." version)
1305 (for-each
1306 (lambda (file)
1307 (wrap-program
1308 (string-append bin file)
1309 (dep-path
1310 "GUILE_LOAD_PATH"
1311 (uncompiled-dir out version)
1312 (uncompiled-dir "" version))
1313 (dep-path
1314 "GUILE_LOAD_COMPILED_PATH"
1315 (compiled-dir out version)
1316 (compiled-dir "" version))))
1317 ,''("hall"))
1318 #t))))))))
0791437f 1319 (native-inputs
63bf0afd
AS
1320 `(("autoconf" ,autoconf)
1321 ("automake" ,automake)
1322 ("pkg-config" ,pkg-config)
1323 ("texinfo" ,texinfo)))
0791437f
RW
1324 (inputs `(("guile" ,guile-2.2)))
1325 (propagated-inputs
3c3e6620 1326 `(("guile-config" ,guile-config)))
0791437f
RW
1327 (synopsis "Guile project tooling")
1328 (description
3c3e6620
RW
1329 "Hall is a command-line application and a set of Guile libraries that
1330allow you to quickly create and publish Guile projects. It allows you to
1331transparently support the GNU build system, manage a project hierarchy &
1332provides tight coupling to Guix.")
1333 (home-page "https://gitlab.com/a-sassmannshausen/guile-hall")
06085fac 1334 (license license:gpl3+)))
0791437f
RW
1335
1336(define-public guile-ics
1337 (package
1338 (name "guile-ics")
1339 (version "0.2.0")
1340 (source (origin
1341 (method git-fetch)
1342 (uri (git-reference
1343 (url "https://github.com/artyom-poptsov/guile-ics")
1344 (commit (string-append "v" version))))
1345 (file-name (string-append name "-" version "-checkout"))
1346 (sha256
1347 (base32
1348 "0qjjvadr7gibdq9jvwkmlkb4afsw9n2shfj9phpiadinxk3p4m2g"))))
1349 (build-system gnu-build-system)
1350 (native-inputs
1351 `(("autoconf" ,autoconf-wrapper)
1352 ("automake" ,automake)
1353 ("texinfo" ,texinfo)
1354 ;; Gettext brings 'AC_LIB_LINKFLAGS_FROM_LIBS'.
1355 ("gettext" ,gettext-minimal)
1356 ("pkg-config" ,pkg-config)))
1357 (inputs `(("guile" ,guile-2.2) ("which" ,which)))
1358 (propagated-inputs `(("guile-lib" ,guile-lib)))
1359 (home-page "https://github.com/artyom-poptsov/guile-ics")
1360 (synopsis "Guile parser library for the iCalendar format")
1361 (description
1362 "Guile-ICS is an iCalendar (RFC5545) format parser library written in
1363pure Scheme. The library can be used to read and write iCalendar data.
1364
1365The library is shipped with documentation in Info format and usage examples.")
1366 (license license:gpl3+)))
1367
1368(define-public guile-wisp
1369 (package
1370 (name "guile-wisp")
65610f73 1371 (version "1.0.2")
0791437f
RW
1372 (source (origin
1373 (method url-fetch)
1374 (uri (string-append "https://bitbucket.org/ArneBab/"
1375 "wisp/downloads/wisp-"
1376 version ".tar.gz"))
1377 (sha256
1378 (base32
65610f73 1379 "03pz7pj9jyallynhflp5s7qax8dj1fs8la434wrfgz7g1kgjnvf6"))))
0791437f
RW
1380 (build-system gnu-build-system)
1381 (arguments
1382 `(#:modules ((guix build gnu-build-system)
15218d4e 1383 ((guix build emacs-build-system) #:prefix emacs:)
0791437f 1384 (guix build utils)
15218d4e 1385 (guix build emacs-utils)
0791437f
RW
1386 (ice-9 rdelim)
1387 (ice-9 popen))
15218d4e
RW
1388 #:imported-modules (,@%gnu-build-system-modules
1389 (guix build emacs-build-system)
1390 (guix build emacs-utils))
0791437f
RW
1391 #:phases
1392 (modify-phases %standard-phases
1393 (add-before 'configure 'patch-/usr/bin/env
1394 (lambda _
1395 (substitute* "Makefile.in"
65610f73 1396 (("/usr/bin/env bash") (which "bash")))
0791437f
RW
1397 #t))
1398 ;; auto compilation breaks, but if we set HOME to /tmp,
1399 ;; that works ok
1400 (add-before 'check 'auto-compile-hacky-workaround
1401 (lambda _ (setenv "HOME" "/tmp") #t))
1402 (add-after 'install 'install-go-files
1403 (lambda* (#:key outputs inputs #:allow-other-keys)
1404 (let* ((out (assoc-ref outputs "out"))
1405 (effective (read-line
1406 (open-pipe* OPEN_READ
1407 "guile" "-c"
1408 "(display (effective-version))")))
1409 (module-dir (string-append out "/share/guile/site/"
1410 effective))
1411 (object-dir (string-append out "/lib/guile/" effective
1412 "/site-ccache"))
1413 (prefix (string-length module-dir)))
1414 ;; compile to the destination
1415 (for-each (lambda (file)
1416 (let* ((base (string-drop (string-drop-right file 4)
1417 prefix))
1418 (go (string-append object-dir base ".go")))
1419 (invoke "guild" "compile" "-L" module-dir
1420 file "-o" go)))
1421 (find-files module-dir "\\.scm$"))
15218d4e
RW
1422 #t)))
1423 (add-after 'install 'install-emacs-files
1424 (assoc-ref emacs:%standard-phases 'install))
1425 (add-after 'install-emacs-files 'compile-emacs-files
1426 (assoc-ref emacs:%standard-phases 'build))
1427 (add-after 'compile-emacs-files 'make-autoloads
1428 (assoc-ref emacs:%standard-phases 'make-autoloads)))))
17f90b67 1429 (home-page "https://www.draketo.de/english/wisp")
0791437f
RW
1430 (inputs
1431 `(("guile" ,guile-2.2)))
1432 (native-inputs
15218d4e
RW
1433 `(("emacs" ,emacs-minimal)
1434 ("python" ,python)
0791437f
RW
1435 ("pkg-config" ,pkg-config)))
1436 (synopsis "Whitespace to lisp syntax for Guile")
1437 (description "Wisp is a syntax for Guile which provides a Python-like
1438whitespace-significant language. It may be easier on the eyes for some
1439users and in some situations.")
1440 (license license:gpl3+)))
1441
1442(define-public guile-sly
1443 (package
1444 (name "guile-sly")
1445 (version "0.1")
1446 (source (origin
1447 (method url-fetch)
1448 (uri (string-append "https://files.dthompson.us/sly/sly-"
1449 version ".tar.gz"))
1450 (sha256
1451 (base32
1452 "1svzlbz2vripmyq2kjh0rig16bsrnbkwbsm558pjln9l65mcl4qq"))
1453 (modules '((guix build utils)))
1454 (snippet
1455 '(begin
1456 (substitute* "configure"
1457 (("_guile_required_version=\"2.0.11\"")
1458 "_guile_required_version=\"2\"")
1459 (("ac_subst_vars='")
1460 "ac_subst_vars='GUILE_EFFECTIVE_VERSION\n"))
1461 (substitute* (find-files "." "Makefile.in")
1462 (("moddir = .*$")
1463 (string-append
1464 "moddir = "
1465 "$(prefix)/share/guile/site/@GUILE_EFFECTIVE_VERSION@\n"))
1466 (("godir = .*$")
1467 (string-append
1468 "godir = "
1469 "$(prefix)/lib/guile/@GUILE_EFFECTIVE_VERSION@/site-ccache\n")))
1470 #t))))
1471 (build-system gnu-build-system)
1472 (arguments
1473 '(#:configure-flags
1474 (list (string-append "--with-libfreeimage-prefix="
1475 (assoc-ref %build-inputs "freeimage"))
1476 (string-append "--with-libgslcblas-prefix="
1477 (assoc-ref %build-inputs "gsl")))))
1478 (native-inputs
1479 `(("pkg-config" ,pkg-config)))
1480 (propagated-inputs
1481 `(("guile-sdl" ,guile-sdl)
1482 ("guile-opengl" ,guile-opengl)))
1483 (inputs
1484 `(("guile" ,guile-2.2)
1485 ("gsl" ,gsl)
1486 ("freeimage" ,freeimage)
1487 ("mesa" ,mesa)))
1488 (synopsis "2D/3D game engine for GNU Guile")
1489 (description "Sly is a 2D/3D game engine written in Guile Scheme. Sly
1490features a functional reactive programming interface and live coding
1491capabilities.")
1492 (home-page "https://dthompson.us/projects/sly.html")
1493 (license license:gpl3+)))
1494
1495(define-public g-wrap
1496 (package
1497 (name "g-wrap")
1498 (version "1.9.15")
1499 (source (origin
1500 (method url-fetch)
1501 (uri (string-append "mirror://savannah/g-wrap/g-wrap-"
1502 version ".tar.gz"))
1503 (sha256
1504 (base32
1505 "0ak0bha37dfpj9kmyw1r8fj8nva639aw5xr66wr5gd3l1rqf5xhg"))))
1506 (build-system gnu-build-system)
1507 (native-inputs
1508 `(("pkg-config" ,pkg-config)))
1509 (propagated-inputs
1510 `(("guile" ,guile-2.2)
1511 ("guile-lib" ,guile-lib)))
1512 (inputs
1513 `(("libffi" ,libffi)))
1514 (arguments
1515 `(#:configure-flags '("--disable-Werror")
1516 #:phases
1517 (modify-phases %standard-phases
1518 (add-before 'configure 'pre-configure
1519 (lambda* (#:key outputs #:allow-other-keys)
1520 (let ((out (assoc-ref outputs "out")))
1521 (substitute* (find-files "." "^Makefile.in$")
1522 (("guilemoduledir =.*guile/site" all)
1523 (string-append all "/@GUILE_EFFECTIVE_VERSION@")))
1524 #t))))))
1525 (synopsis "Generate C bindings for Guile")
1526 (description "G-Wrap is a tool and Guile library for generating function
1527wrappers for inter-language calls. It currently only supports generating Guile
1528wrappers for C functions. Given a definition of the types and prototypes for
1529a given C interface, G-Wrap will automatically generate the C code that
1530provides access to that interface and its types from the Scheme level.")
1531 (home-page "https://www.nongnu.org/g-wrap/index.html")
1532 (license license:lgpl2.1+)))
1533
1534(define-public guile-miniadapton
1535 (let ((commit "1b5749422304567c96ac5367f2221dda9eff5880")
1536 (revision "1"))
1537 (package
1538 (name "guile-miniadapton")
1539 (version (string-append "0-" revision "." (string-take commit 9)))
1540 (source (origin
1541 (method git-fetch)
1542 (uri (git-reference
1543 (url "https://github.com/fisherdj/miniAdapton.git")
1544 (commit commit)))
1545 (file-name (string-append name "-" version "-checkout"))
1546 (sha256
1547 (base32
1548 "09q51zkw2fypad5xixskfzw2cjhjgs5cswdp3i7cpp651rb3zndh"))))
1549 (build-system guile-build-system)
1550 (native-inputs
1551 `(("guile" ,guile-2.2)))
1552 (home-page "https://github.com/fisherdj/miniAdapton")
1553 (synopsis "Minimal implementation of incremental computation in Guile
1554Scheme")
1555 (description "This package provides a complete Scheme implementation of
1556miniAdapton, which implements the core functionality of the Adapton system for
1557incremental computation (also known as self-adjusting computation). Like
1558Adapton, miniAdapton allows programmers to safely combine mutation and
1559memoization. miniAdapton is built on top of an even simpler system,
1560microAdapton. Both miniAdapton and microAdapton are designed to be easy to
1561understand, extend, and port to host languages other than Scheme.")
1562 (license license:expat))))
1563
1564(define-public guile-reader
1565 (package
1566 (name "guile-reader")
1567 (version "0.6.2")
1568 (source (origin
1569 (method url-fetch)
1570 (uri (string-append "mirror://savannah/guile-reader/guile-reader-"
1571 version ".tar.gz"))
1572 (sha256
1573 (base32
1574 "0592s2s8ampqmqwilc4fvcild6rb9gy79di6vxv5kcdmv23abkgx"))))
1575 (build-system gnu-build-system)
1576 (native-inputs `(("pkgconfig" ,pkg-config)
1577 ("gperf" ,gperf-3.0)))
1578 (inputs `(("guile" ,guile-2.2)))
1579 (synopsis "Framework for building readers for GNU Guile")
1580 (description
1581 "Guile-Reader is a simple framework for building readers for GNU Guile.
1582
1583The idea is to make it easy to build procedures that extend Guile’s read
1584procedure. Readers supporting various syntax variants can easily be written,
1585possibly by re-using existing “token readers” of a standard Scheme
1586readers. For example, it is used to implement Skribilo’s R5RS-derived
1587document syntax.
1588
1589Guile-Reader’s approach is similar to Common Lisp’s “read table”, but
1590hopefully more powerful and flexible (for instance, one may instantiate as
1591many readers as needed).")
1592 (home-page "https://www.nongnu.org/guile-reader/")
1593 (license license:gpl3+)))
1594
0791437f
RW
1595(define-public guile-ncurses
1596 (package
1597 (name "guile-ncurses")
2b155e3a 1598 (version "3.0")
0791437f
RW
1599 (source (origin
1600 (method url-fetch)
1601 (uri (string-append "mirror://gnu/guile-ncurses/guile-ncurses-"
1602 version ".tar.gz"))
1603 (sha256
1604 (base32
2b155e3a 1605 "038xbffalhymg26lvmzgf7ljilxz2f2zmqg5r5nfzbipfbprwjhf"))))
0791437f
RW
1606 (build-system gnu-build-system)
1607 (inputs `(("ncurses" ,ncurses)
1608 ("guile" ,guile-2.2)))
1609 (native-inputs `(("pkg-config" ,pkg-config)))
1610 (arguments
1611 '(#:configure-flags (list "--with-ncursesw" ; Unicode support
1612 "--with-gnu-filesystem-hierarchy")
1613 #:phases
1614 (modify-phases %standard-phases
1615 (add-before 'build 'fix-libguile-ncurses-file-name
1616 (lambda* (#:key outputs #:allow-other-keys)
1617 (invoke "make" "install"
1618 "-C" "src/ncurses"
1619 "-j" (number->string
1620 (parallel-job-count)))
1621 (let* ((out (assoc-ref outputs "out"))
1622 (dir "src/ncurses")
1623 (files (find-files dir ".scm")))
1624 (substitute* files
1625 (("\"libguile-ncurses\"")
1626 (format #f "\"~a/lib/guile/2.2/libguile-ncurses\""
1627 out)))
1628 #t))))))
1629 (home-page "https://www.gnu.org/software/guile-ncurses/")
1630 (synopsis "Guile bindings to ncurses")
1631 (description
1632 "guile-ncurses provides Guile language bindings for the ncurses
1633library.")
1634 (license license:lgpl3+)))
1635
1636(define-public guile-ncurses/gpm
1637 (package
1638 (inherit guile-ncurses)
1639 (name "guile-ncurses-with-gpm")
1640 (inputs `(("ncurses" ,ncurses/gpm)
1641 ("guile" ,guile-2.2)))))
1642
1643(define-public guile-lib
1644 (package
1645 (name "guile-lib")
1646 (version "0.2.6.1")
1647 (source (origin
1648 (method url-fetch)
1649 (uri (string-append "mirror://savannah/guile-lib/guile-lib-"
1650 version ".tar.gz"))
1651 (sha256
1652 (base32
1653 "0aizxdif5dpch9cvs8zz5g8ds5s4xhfnwza2il5ji7fv2h7ks7bd"))))
1654 (build-system gnu-build-system)
1655 (arguments
1656 '(#:make-flags
1657 '("GUILE_AUTO_COMPILE=0") ; to prevent guild errors
1658 #:phases
1659 (modify-phases %standard-phases
1660 (add-before 'configure 'patch-module-dir
1661 (lambda _
1662 (substitute* "src/Makefile.in"
1663 (("^moddir = ([[:graph:]]+)")
1664 "moddir = $(datadir)/guile/site/@GUILE_EFFECTIVE_VERSION@\n")
1665 (("^godir = ([[:graph:]]+)")
1666 "godir = \
1667$(libdir)/guile/@GUILE_EFFECTIVE_VERSION@/site-ccache\n"))
1668 #t)))))
1669 (native-inputs `(("pkg-config" ,pkg-config)))
1670 (inputs `(("guile" ,guile-2.2)))
1671 (home-page "https://www.nongnu.org/guile-lib/")
1672 (synopsis "Collection of useful Guile Scheme modules")
1673 (description
1674 "Guile-Lib is intended as an accumulation place for pure-scheme Guile
1675modules, allowing for people to cooperate integrating their generic Guile
1676modules into a coherent library. Think \"a down-scaled, limited-scope CPAN
1677for Guile\".")
1678
1679 ;; The whole is under GPLv3+, but some modules are under laxer
1680 ;; distribution terms such as LGPL and public domain. See `COPYING' for
1681 ;; details.
1682 (license license:gpl3+)))
1683
1684(define-public guile2.0-lib
1685 (package
1686 (inherit guile-lib)
1687 (name "guile2.0-lib")
1688 (inputs `(("guile" ,guile-2.0)))))
1689
0791437f
RW
1690(define-public guile-minikanren
1691 (package
1692 (name "guile-minikanren")
1693 (version "20150424.e844d85")
1694 (source (origin
1695 (method git-fetch)
1696 (uri (git-reference
1697 (url "https://github.com/ijp/minikanren.git")
1698 (commit "e844d85512f8c055d3f96143ee506007389a25e3")))
1699 (file-name (string-append name "-" version "-checkout"))
1700 (sha256
1701 (base32
1702 "0r50jlpzi940jlmxyy3ddqqwmj5r12gb4bcv0ssini9v8km13xz6"))))
1703 (build-system guile-build-system)
1704 (native-inputs
1705 `(("guile" ,guile-2.2)))
1706 (home-page "https://github.com/ijp/minikanren")
1707 (synopsis "MiniKanren declarative logic system, packaged for Guile")
1708 (description
1709 "MiniKanren is a relational programming extension to the Scheme
1710programming Language, written as a smaller version of Kanren suitable for
1711pedagogical purposes. It is featured in the book, The Reasoned Schemer,
1712written by Dan Friedman, William Byrd, and Oleg Kiselyov.
1713
1714This is Ian Price's r6rs packaged version of miniKanren, which deviates
1715slightly from miniKanren mainline.
1716
1717See http://minikanren.org/ for more on miniKanren generally.")
1718 (license license:expat)))
1719
1720(define-public guile2.0-minikanren
1721 (package
1722 (inherit guile-minikanren)
1723 (name "guile2.0-minikanren")
1724 (native-inputs `(("guile" ,guile-2.0)))))
1725
89a99d53
LC
1726(define-public guile3.0-minikanren
1727 (package
1728 (inherit guile-minikanren)
1729 (name "guile3.0-minikanren")
1730 (native-inputs `(("guile" ,guile-next)))))
1731
0791437f
RW
1732(define-public guile-irregex
1733 (package
1734 (name "guile-irregex")
1735 (version "0.9.6")
1736 (source (origin
1737 (method url-fetch)
1738 (uri (string-append
1739 "http://synthcode.com/scheme/irregex/irregex-"
1740 version ".tar.gz"))
1741 (sha256
1742 (base32
1743 "1ia3m7dp3lcxa048q0gqbiwwsyvn99baw6xkhb4bhhzn4k7bwyqq"))))
1744 (build-system guile-build-system)
1745 (arguments
1746 '(#:phases (modify-phases %standard-phases
1747 (add-after 'unpack 'move-files-around
1748 (lambda _
1749 ;; Move the relevant source files to src/ and create the
1750 ;; rx/ directory to match the expected module hierarchy.
1751 (mkdir-p "src/rx/source")
1752 (rename-file "irregex-guile.scm"
1753 "src/rx/irregex.scm")
1754 (rename-file "irregex.scm"
1755 "src/rx/source/irregex.scm")
1756 ;; Not really reachable via guile's packaging system,
1757 ;; but nice to have around.
1758 (rename-file "irregex-utils.scm"
1759 "src/rx/source/irregex-utils.scm")
1760 #t)))
1761 #:source-directory "src"))
1762 (native-inputs
1763 `(("guile" ,guile-2.2)))
1764 (home-page "http://synthcode.com/scheme/irregex")
1765 (synopsis "S-expression based regular expressions")
1766 (description
1767 "Irregex is an s-expression based alternative to your classic
1768string-based regular expressions. It implements SRFI 115 and is deeply
1769inspired by the SCSH regular expression system.")
1770 (license license:bsd-3)))
1771
1772(define-public guile2.0-irregex
1773 (package
1774 (inherit guile-irregex)
1775 (name "guile2.0-irregex")
1776 (native-inputs `(("guile" ,guile-2.0)))))
1777
89a99d53
LC
1778(define-public guile3.0-irregex
1779 (package
1780 (inherit guile-irregex)
1781 (name "guile3.0-irregex")
1782 (native-inputs `(("guile" ,guile-next)))))
1783
0791437f
RW
1784(define-public haunt
1785 (package
1786 (name "haunt")
1787 (version "0.2.4")
1788 (source (origin
1789 (method url-fetch)
1790 (uri (string-append "https://files.dthompson.us/haunt/haunt-"
1791 version ".tar.gz"))
1792 (sha256
1793 (base32
1794 "056z4znikk83nr5mr0x2ac3iinqbywa2bvb37mhr566a1q50isfc"))))
1795 (build-system gnu-build-system)
1796 (arguments
1797 `(#:modules ((ice-9 match) (ice-9 ftw)
1798 ,@%gnu-build-system-modules)
1799 #:tests? #f ; test suite is non-deterministic :(
1800 #:phases (modify-phases %standard-phases
1801 (add-after 'install 'wrap-haunt
1802 (lambda* (#:key inputs outputs #:allow-other-keys)
1803 ;; Wrap the 'haunt' command to refer to the right
1804 ;; modules.
1805 (let* ((out (assoc-ref outputs "out"))
1806 (bin (string-append out "/bin"))
1807 (site (string-append
1808 out "/share/guile/site"))
1809 (deps (list (assoc-ref inputs "guile-reader")
1810 (assoc-ref inputs "guile-commonmark"))))
1811 (match (scandir site)
1812 (("." ".." version)
1813 (let ((modules (string-append site "/" version))
1814 (compiled-modules (string-append
1815 out "/lib/guile/" version
1816 "/site-ccache")))
1817 (wrap-program (string-append bin "/haunt")
1818 `("GUILE_LOAD_PATH" ":" prefix
1819 (,modules
1820 ,@(map (lambda (dep)
1821 (string-append dep
1822 "/share/guile/site/"
1823 version))
1824 deps)))
1825 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
1826 (,compiled-modules
1827 ,@(map (lambda (dep)
1828 (string-append dep "/lib/guile/"
1829 version
1830 "/site-ccache"))
1831 deps))))
1832 #t)))))))))
1833 (native-inputs
1834 `(("pkg-config" ,pkg-config)
1835 ("texinfo" ,texinfo)))
1836 (inputs
1837 `(("guile" ,guile-2.2)))
1838 (propagated-inputs
1839 `(("guile-reader" ,guile-reader)
1840 ("guile-commonmark" ,guile-commonmark)))
1841 (synopsis "Functional static site generator")
1842 (description "Haunt is a static site generator written in Guile
1843Scheme. Haunt features a functional build system and an extensible
1844interface for reading articles in any format.")
1845 (home-page "http://haunt.dthompson.us")
1846 (license license:gpl3+)))
1847
1848(define-public guile2.0-haunt
1849 (package
1850 (inherit haunt)
1851 (name "guile2.0-haunt")
1852 (inputs `(("guile" ,guile-2.0)))))
1853
0791437f
RW
1854(define-public guile-redis
1855 (package
1856 (name "guile-redis")
f57bf15c 1857 (version "1.3.0")
0791437f
RW
1858 (home-page "https://github.com/aconchillo/guile-redis")
1859 (source (origin
1860 (method url-fetch)
1861 (uri (string-append home-page "/archive/" version ".tar.gz"))
1862 (sha256
1863 (base32
f57bf15c 1864 "1li70a2716my9q9zfq0qn2x5d1cir9k2vx0jm9glm464yaf1vj39"))))
0791437f
RW
1865 (build-system gnu-build-system)
1866 (native-inputs
1867 `(("autoconf" ,autoconf)
1868 ("automake" ,automake)
1869 ("pkg-config" ,pkg-config)
1870 ("guile" ,guile-2.2)))
1871 (synopsis "Redis client library for Guile")
1872 (description "Guile-redis provides a Scheme interface to the Redis
1873key-value cache and store.")
1874 (license license:lgpl3+)))
1875
1876(define-public guile2.0-redis
1877 (package
1878 (inherit guile-redis)
1879 (name "guile2.0-redis")
1880 (native-inputs `(("guile" ,guile-2.0)
1881 ,@(alist-delete "guile"
1882 (package-native-inputs guile-redis))))))
1883
0791437f
RW
1884(define-public guile-commonmark
1885 (package
1886 (name "guile-commonmark")
b552e307 1887 (version "0.1.2")
0791437f
RW
1888 (source (origin
1889 (method url-fetch)
1890 (uri (string-append "https://github.com/OrangeShark/" name
1891 "/releases/download/v" version
1892 "/" name "-" version ".tar.gz"))
1893 (sha256
1894 (base32
b552e307 1895 "17lrsdisa3kckh24q114vfmzdc4wkqa6ccwl4hdlrng5wpn1iman"))))
0791437f
RW
1896 (build-system gnu-build-system)
1897 (inputs
1898 `(("guile" ,guile-2.2)))
1899 (native-inputs
1900 `(("pkg-config" ,pkg-config)))
1901 (synopsis "CommonMark parser for Guile")
1902 (description
1903 "guile-commonmark is a library for parsing CommonMark, a fully specified
1904variant of Markdown. The library is written in Guile Scheme and is designed
1905to transform a CommonMark document to SXML. guile-commonmark tries to closely
1906follow the @uref{http://commonmark.org/, CommonMark spec}, the main difference
1907is no support for parsing block and inline level HTML.")
1908 (home-page "https://github.com/OrangeShark/guile-commonmark")
1909 (license license:lgpl3+)))
1910
1911(define-public guile2.0-commonmark
1912 (package
1913 (inherit guile-commonmark)
1914 (name "guile2.0-commonmark")
1915 (inputs `(("guile" ,guile-2.0)))))
1916
0791437f
RW
1917(define-public mcron
1918 (package
1919 (name "mcron")
f61f424d 1920 (version "1.1.2")
0791437f
RW
1921 (source (origin
1922 (method url-fetch)
1923 (uri (string-append "mirror://gnu/mcron/mcron-"
1924 version ".tar.gz"))
1925 (sha256
1926 (base32
f61f424d 1927 "069m3ri7nc8lgy3h9ka7gj3v3anqj69x9jw4l3cfq65nqkxsch4g"))))
0791437f
RW
1928 (build-system gnu-build-system)
1929 (arguments
1930 '(#:phases (modify-phases %standard-phases
0791437f
RW
1931 (add-before 'check 'adjust-tests
1932 (lambda _
1933 (substitute* "tests/job-specifier.scm"
1934 ;; (getpw) fails with "entry not found" in the build
1935 ;; environment, so pass an argument.
1936 (("\\(getpw\\)")
1937 "(getpwnam (getuid))")
1938 ;; The build environment lacks an entry for root in
1939 ;; /etc/passwd.
1940 (("\\(getpw 0\\)")
1941 "(getpwnam \"nobody\")")
1942
1943 ;; FIXME: Skip the 4 faulty tests (see above).
1944 (("\\(test-equal \"next-year\"" all)
1945 (string-append "(test-skip 4)\n" all)))
1946 #t)))))
f61f424d
EF
1947 (native-inputs `(("autoconf" ,autoconf)
1948 ("automake" ,automake)
1949 ("help2man" ,help2man)
1950 ("pkg-config" ,pkg-config)
1951 ("texinfo" ,texinfo)
0791437f 1952 ("tzdata" ,tzdata-for-tests)))
f61f424d 1953 (inputs `(("guile" ,guile-2.2)))
0791437f
RW
1954 (home-page "https://www.gnu.org/software/mcron/")
1955 (synopsis "Run jobs at scheduled times")
1956 (description
1957 "GNU Mcron is a complete replacement for Vixie cron. It is used to run
1958tasks on a schedule, such as every hour or every Monday. Mcron is written in
1959Guile, so its configuration can be written in Scheme; the original cron
1960format is also supported.")
1961 (license license:gpl3+)))
1962
1963(define-public mcron2
1964 ;; This was mthl's mcron development branch, and it became mcron 1.1.
1965 (deprecated-package "mcron2" mcron))
6bb5f88e
RW
1966
1967(define-public guile-picture-language
d1a3a8e1
RW
1968 (let ((commit "91d10c96708d732145006dd2802acc4de08b632e")
1969 (revision "1"))
6bb5f88e
RW
1970 (package
1971 (name "guile-picture-language")
d1a3a8e1 1972 (version (git-version "0.0.1" revision commit))
6bb5f88e
RW
1973 (source (origin
1974 (method git-fetch)
1975 (uri (git-reference
1976 (url "https://git.elephly.net/software/guile-picture-language.git")
1977 (commit commit)))
1978 (sha256
1979 (base32
d1a3a8e1
RW
1980 "1ydvw9dvssdvlvhh1dr8inyzy2x6m41qgp8hsivca1xysr4gc23a"))))
1981 (build-system gnu-build-system)
6bb5f88e
RW
1982 (inputs
1983 `(("guile" ,guile-2.2)))
d1a3a8e1
RW
1984 (native-inputs
1985 `(("autoconf" ,autoconf)
1986 ("automake" ,automake)
1987 ("imagemagick" ,imagemagick)
1988 ("pkg-config" ,pkg-config)
1989 ("texinfo" ,texinfo)))
6bb5f88e
RW
1990 (home-page "https://git.elephly.net/software/guile-picture-language.git")
1991 (synopsis "Picture language for Guile")
1992 (description
1993 "This package provides a simple SVG-based picture language for Guile.
1994The picture values can directly be displayed in Geiser.")
1995 (license license:lgpl3+))))
5531782d
RW
1996
1997(define-public guile-studio
258e63bf
RW
1998 (let ((commit "98fbbbd08de396cd8a0e45f2a4badf1c733a5772")
1999 (revision "3"))
5531782d
RW
2000 (package
2001 (name "guile-studio")
258e63bf 2002 (version (git-version "0.0.1" revision commit))
5531782d
RW
2003 (source (origin
2004 (method git-fetch)
2005 (uri (git-reference
2006 (url "https://git.elephly.net/software/guile-studio.git")
2007 (commit commit)))
2008 (sha256
2009 (base32
258e63bf 2010 "0rxl5gv2mavycwkl33lcwyb3z71j2f4zyzk60k7vl3hzszpr08iq"))))
5531782d
RW
2011 (build-system gnu-build-system)
2012 (arguments
2013 `(#:tests? #f ; there are none
258e63bf
RW
2014 #:make-flags
2015 (list (string-append "ICONS_DIR="
2016 (assoc-ref %build-inputs "adwaita-icon-theme")
2017 "/share/icons/Adwaita/")
2018 (string-append "PICT_DIR="
2019 (assoc-ref %build-inputs "guile-picture-language"))
2020 (string-append "EMACS_DIR="
2021 (assoc-ref %build-inputs "emacs"))
2022 (string-append "GUILE_DIR="
2023 (assoc-ref %build-inputs "guile"))
2024 (string-join (cons "INPUTS=" (map cdr %build-inputs)))
2025 (string-append "PREFIX=" (assoc-ref %outputs "out")))
5531782d
RW
2026 #:phases
2027 (modify-phases %standard-phases
2028 (delete 'configure)
5531782d
RW
2029 (delete 'install))))
2030 (inputs
2031 `(("guile" ,guile-2.2)
2032 ("guile-picture-language" ,guile-picture-language)
2033 ("emacs" ,emacs)
2034 ("emacs-geiser" ,emacs-geiser)
2035 ("emacs-company" ,emacs-company)
2036 ("emacs-flycheck" ,emacs-flycheck)
2037 ("emacs-smart-mode-line" ,emacs-smart-mode-line)
2038 ("emacs-paren-face" ,emacs-paren-face)
2039 ("adwaita-icon-theme" ,adwaita-icon-theme)))
258e63bf
RW
2040 (native-inputs
2041 `(("texinfo" ,texinfo)))
5531782d
RW
2042 (home-page "https://gnu.org/software/guile")
2043 (synopsis "IDE for Guile")
2044 (description
2045 "This is Emacs with a few settings that make working with Guile easier
2046for people new to Emacs. Features include: CUA mode, Geiser, tool bar icons
2047to evaluate Guile buffers, support for Guile's very own picture language, code
2048completion, a simple mode line, etc.")
2049 (license license:gpl3+))))
9f8698ad
RW
2050
2051(define-public guile-stis-parser
2052 (let ((commit "6e85d37ffc333b722f4413a6c648263701eb75bd")
2053 (revision "1"))
2054 (package
2055 (name "guile-stis-parser")
2056 (version (git-version "0" revision commit))
2057 (source (origin
2058 (method git-fetch)
2059 (uri (git-reference
2060 (url "https://gitlab.com/tampe/stis-parser")
2061 (commit commit)))
29e76f07 2062 (file-name (git-file-name name version))
9f8698ad
RW
2063 (sha256
2064 (base32
2065 "0v4hvq7rlpbra1ni73lf8k6sdmjlflr50yi3p1f24g85h77pc7c0"))))
2066 (build-system gnu-build-system)
2067 (arguments
2068 `(#:parallel-build? #f ; not supported
2069 #:phases
2070 (modify-phases %standard-phases
2071 (add-after 'unpack 'chdir
2072 (lambda _ (chdir "modules") #t))
8318b3ed
RW
2073 (add-after 'chdir 'use-canonical-directory-for-go-files
2074 (lambda _
2075 (substitute* "Makefile.am"
2076 (("/ccache") "/site-ccache"))
2077 #t))
9f8698ad
RW
2078 (add-after 'chdir 'delete-broken-symlink
2079 (lambda _
2080 (delete-file "parser/stis-parser/lang/.#calc.scm")
2081 #t)))))
2082 (inputs
2083 `(("guile" ,guile-2.2)))
2084 (native-inputs
2085 `(("autoconf" ,autoconf)
2086 ("automake" ,automake)
2087 ("pkg-config" ,pkg-config)))
2088 (home-page "https://gitlab.com/tampe/stis-parser")
2089 (synopsis "Parser combinator framework")
2090 (description
2091 "This package provides a functional parser combinator library that
2092supports backtracking and a small logical framework. The idea is to build up
2093chunks that are memoized and there is no clear scanner/parser separation,
2094chunks can be expressions as well as simple tokens.")
2095 (license license:lgpl2.0+))))
12d73f9c
RW
2096
2097(define-public guile-persist
2098 (let ((commit "b14927b0368af51c024560aee5f55724aee35233")
2099 (revision "1"))
2100 (package
2101 (name "guile-persist")
2102 (version (git-version "0" revision commit))
2103 (source (origin
2104 (method git-fetch)
2105 (uri (git-reference
2106 (url "https://gitlab.com/tampe/guile-persist")
2107 (commit commit)))
2108 (file-name (git-file-name name version))
2109 (sha256
2110 (base32
85a411bc
LC
2111 "0z5nf377wh8yj6n3sx2ddn4bdx1qrqnw899dlqjhg0q69qzil522"))
2112 (modules '((guix build utils)))
2113 (snippet
2114 '(begin
2115 ;; Install .go files in the right place.
2116 (substitute* "Makefile.am"
2117 (("/ccache") "/site-ccache"))
2118 #t))))
12d73f9c
RW
2119 (build-system gnu-build-system)
2120 (arguments
2121 `(#:phases
2122 (modify-phases %standard-phases
2123 (add-after 'unpack 'patch-prefix
2124 (lambda* (#:key inputs outputs #:allow-other-keys)
2125 (substitute* "src/Makefile.am"
2126 (("/usr/local/lib/guile")
2127 (string-append (assoc-ref outputs "out") "/lib/guile"))
2128 (("/usr/local/include/guile")
2129 (string-append (assoc-ref inputs "guile") "/include/guile"))
2130 (("-L/usr/local/lib")
8f052528
RW
2131 (string-append "-L" (assoc-ref inputs "guile") "/lib"))
2132 ;; Use canonical directory for go files.
2133 (("/ccache") "/site-ccache"))
12d73f9c
RW
2134 #t))
2135 (add-after 'unpack 'patch-library-reference
2136 (lambda* (#:key outputs #:allow-other-keys)
2137 (let ((out (assoc-ref outputs "out")))
2138 (substitute* "persist/persistance.scm"
2139 (("\"libguile-persist\"")
2140 (format #f "\"~a/lib/guile/2.2/extensions/libguile-persist\"" out)))
2141 #t))))))
2142 (inputs
2143 `(("guile" ,guile-2.2)))
2144 (native-inputs
2145 `(("autoconf" ,autoconf)
2146 ("automake" ,automake)
2147 ("libtool" ,libtool)
2148 ("pkg-config" ,pkg-config)))
2149 (home-page "https://gitlab.com/tampe/guile-persist")
028053f2 2150 (synopsis "Persistence programming framework for Guile")
12d73f9c
RW
2151 (description
2152 "This is a serialization library for serializing objects like classes
2153and objects, closures and structs. This currently does not support
2154serializing continuations or delimited continuations.")
2155 (license license:lgpl2.0+))))
6d37301b
RW
2156
2157(define-public python-on-guile
5d5edb88
LC
2158 (let ((commit "00a51a23247f1edc4ae8eda72b30df5cd7d0015f")
2159 (revision "3"))
6d37301b
RW
2160 (package
2161 (name "python-on-guile")
2162 (version (git-version "0.1.0" revision commit))
2163 (source (origin
2164 (method git-fetch)
2165 (uri (git-reference
4088ae42 2166 (url "https://git.elephly.net/software/python-on-guile.git")
6d37301b
RW
2167 (commit commit)))
2168 (file-name (git-file-name name version))
2169 (sha256
2170 (base32
5d5edb88 2171 "03rpnqr08rqr3gay128g564rwk8w4jbj28ss6b46z1d4vjs4nk68"))))
6d37301b
RW
2172 (build-system gnu-build-system)
2173 (arguments
2174 `(#:parallel-build? #f ; not supported
83817158
LC
2175 #:make-flags '("GUILE_AUTO_COMPILE=0") ;to prevent guild warnings
2176
6d37301b
RW
2177 #:phases
2178 (modify-phases %standard-phases
2179 (add-after 'unpack 'chdir
83817158
LC
2180 (lambda _ (chdir "modules") #t))
2181 (add-after 'install 'wrap
2182 (lambda* (#:key outputs #:allow-other-keys)
2183 ;; Wrap the 'python' executable so it can find its
2184 ;; dependencies.
2185 (let ((out (assoc-ref outputs "out")))
2186 (wrap-program (string-append out "/bin/python")
2187 `("GUILE_LOAD_PATH" ":" prefix
2188 (,(getenv "GUILE_LOAD_PATH")))
2189 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
2190 (,(getenv "GUILE_LOAD_COMPILED_PATH"))))
2191 #t))))))
6d37301b
RW
2192 (inputs
2193 `(("guile" ,guile-2.2)))
2194 (propagated-inputs
2195 `(("guile-persist" ,guile-persist)
2196 ("guile-readline" ,guile-readline)
2197 ("guile-stis-parser" ,guile-stis-parser)))
2198 (native-inputs
2199 `(("autoconf" ,autoconf)
2200 ("automake" ,automake)
2201 ("libtool" ,libtool)
2202 ("pkg-config" ,pkg-config)))
2203 (home-page "https://gitlab.com/python-on-guile/python-on-guile/")
2204 (synopsis "Python implementation in Guile")
2205 (description
2206 "This package allows you to compile a Guile Python file to any target
2207from @code{tree-il}.")
2208 (license license:lgpl2.0+))))
b97b4624
RW
2209
2210(define-public guile-file-names
2211 (package
2212 (name "guile-file-names")
481eca80 2213 (version "0.2")
b97b4624
RW
2214 (source (origin
2215 (method url-fetch)
2216 (uri (string-append "http://brandon.invergo.net/software/download/"
2217 "guile-file-names/guile-file-names-"
2218 version ".tar.gz"))
2219 (sha256
2220 (base32
481eca80 2221 "1kwx5hanl40960w2nhyga7ry4l6c3c57zdrihk4yajj87vn3pmi8"))))
b97b4624
RW
2222 (build-system gnu-build-system)
2223 (arguments
2224 `(#:phases
2225 (modify-phases %standard-phases
481eca80 2226 (add-after 'unpack 'fix-target-directory
b97b4624 2227 (lambda _
481eca80 2228 (substitute* "src/Makefile.in"
b97b4624
RW
2229 (("guilemoddir = \\$\\(GUILE_SITE\\)")
2230 "guilemoddir = $(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
2231 #t)))))
2232 (inputs
2233 `(("guile" ,guile-2.2)))
2234 (native-inputs
2235 `(("pkg-config" ,pkg-config)))
2236 (home-page "https://gitlab.com/brandoninvergo/guile-file-names")
2237 (synopsis "Manipulate file names")
2238 (description
2239 "The @code{(file-names)} module provides tools for manipulating file
2240names. The module was built on the idea that doing anything more than a
2241non-trivial modification of a file name string is a pain (making sure all
2242slashes are present and accounted for, resolving @code{.} and @code{..}, etc).
2243Inevitably, you have to break the string up into chunks and operate on that
2244list of components. This module takes care of that for you.")
2245 (license license:lgpl3+)))
bdf2dd79
JN
2246
2247(define-public guile-gi
bb6c8f20
RW
2248 (package
2249 (name "guile-gi")
6153fa0a 2250 (version "0.2.0")
bb6c8f20
RW
2251 (source (origin
2252 (method url-fetch)
2253 (uri (string-append "http://lonelycactus.com/tarball/guile_gi-"
2254 version ".tar.gz"))
2255 (sha256
2256 (base32
6153fa0a 2257 "1n4pbrmbrjkrx826a4m31ag5c35rgkj1sirqh4qalk7gg67cfb41"))))
bb6c8f20
RW
2258 (build-system gnu-build-system)
2259 (arguments
6153fa0a 2260 `(#:configure-flags '("--with-gnu-filesystem-hierarchy")))
bb6c8f20
RW
2261 (native-inputs
2262 `(("gettext" ,gnu-gettext)
6153fa0a 2263 ("glib:bin" ,glib "bin") ; for glib-compile-resources
bb6c8f20
RW
2264 ("libtool" ,libtool)
2265 ("pkg-config" ,pkg-config)))
2266 (propagated-inputs
2267 `(("glib" ,glib)
2268 ("gobject-introspection" ,gobject-introspection)
2269 ("gssettings-desktop-schemas" ,gsettings-desktop-schemas)
2270 ("gtk+" ,gtk+)
2271 ("guile-lib" ,guile-lib)
2272 ("webkitgtk" ,webkitgtk)))
2273 (inputs `(("guile" ,guile-2.2)))
2274 (home-page "https://github.com/spk121/guile-gi")
2275 (synopsis "GObject bindings for Guile")
2276 (description
2277 "Guile-GI is a library for Guile that allows using GObject-based
bdf2dd79
JN
2278libraries, such as GTK+3. Its README comes with the disclaimer: This is
2279pre-alpha code.")
bb6c8f20 2280 (license license:gpl3+)))
dec4b3aa
LC
2281
2282(define-public guile-srfi-159
2283 (let ((commit "1bd98abda2ae4ef8f36761a167903e55c6bda7bb")
2284 (revision "0"))
2285 (package
2286 (name "guile-srfi-159")
2287 (version (git-version "0" revision commit))
2288 (home-page "https://bitbucket.org/bjoli/guile-srfi-159")
2289 (source (origin
2290 (method hg-fetch)
2291 (uri (hg-reference (changeset commit)
2292 (url home-page)))
2293 (sha256
2294 (base32
2295 "1zw6cmcy7xdbfiz3nz9arqnn7l2daidaps6ixkcrc9b6k51fdv3p"))
2296 (file-name (git-file-name name version))))
2297 (build-system guile-build-system)
2298 (arguments
2299 ;; The *-impl.scm files are actually included from module files; they
2300 ;; should not be compiled separately, but they must be installed.
2301 '(#:not-compiled-file-regexp "-impl\\.scm$"))
2302 (inputs
2303 `(("guile" ,guile-2.2)))
2304 (synopsis "Formatting combinators for Guile")
2305 (description
2306 "The @code{(srfi-159)} module and its sub-modules implement the
2307formatting combinators specified by
2308@uref{https://srfi.schemers.org/srfi-159/srfi-159.html, SRFI-159}. These are
2309more expressive and flexible than the traditional @code{format} procedure.")
2310 (license license:bsd-3))))
f0de9544
JN
2311
2312(define-public emacsy
48eb71ae
JN
2313 (package
2314 (name "emacsy")
2315 (version "0.4.1")
2316 (source (origin
2317 (method url-fetch)
2318 (uri (string-append
2319 "https://download.savannah.nongnu.org/releases/"
2320 name "/" name "-" version ".tar.gz"))
2321 (sha256
2322 (base32
2323 "1cpb85dl1nibd34c2x2h7vfmjpkgh353p5b1w20v6cs6gmvgg4np"))))
2324 (build-system gnu-build-system)
2325 (native-inputs
2326 `(("autoconf" ,autoconf)
2327 ("automake" ,automake)
2328 ("bzip2" ,bzip2)
2329 ("guile" ,guile-2.2)
2330 ("gettext" ,gnu-gettext)
2331 ("libtool" ,libtool)
2332 ("perl" ,perl)
2333 ("pkg-config" ,pkg-config)
2334 ("texinfo" ,texinfo)
1aa026aa 2335 ("texlive" ,(texlive-union (list texlive-generic-epsf)))))
114f02ba 2336 (inputs
48eb71ae
JN
2337 `(("dbus-glib" ,dbus-glib)
2338 ("guile" ,guile-2.2)
2339 ("guile-lib" ,guile-lib)
2340 ("guile-readline" ,guile-readline)
48eb71ae 2341 ("freeglut" ,freeglut)
48eb71ae 2342 ("webkitgtk" ,webkitgtk)))
114f02ba
AS
2343 (propagated-inputs
2344 `(("glib-networking" ,glib-networking)
2345 ("gssettings-desktop-schemas" ,gsettings-desktop-schemas)))
48eb71ae 2346 (arguments
114f02ba
AS
2347 `(#:modules ((guix build gnu-build-system)
2348 (guix build utils)
2349 (ice-9 popen)
2350 (ice-9 rdelim)
2351 (ice-9 regex)
2352 (ice-9 ftw)
2353 (srfi srfi-26))
2354 #:phases
48eb71ae
JN
2355 (modify-phases %standard-phases
2356 (add-before 'configure 'setenv
2357 (lambda _
2358 (setenv "GUILE_AUTO_COMPILE" "0")
114f02ba
AS
2359 #t))
2360 (add-after 'install 'wrap-binaries
2361 (lambda* (#:key inputs outputs #:allow-other-keys)
2362 (let* ((out (assoc-ref outputs "out"))
2363 (effective (read-line
2364 (open-pipe* OPEN_READ
2365 "guile" "-c"
2366 "(display (effective-version))")))
2367 (deps (map (cut assoc-ref inputs <>)
2368 '("guile-lib" "guile-readline")))
2369 (scm-path (map (cut string-append <> "/share/guile/site/"
2370 effective) `(,out ,@deps)))
2371 (go-path (map (cut string-append <> "/lib/guile/" effective
2372 "/site-ccache/") `(,out ,@deps)))
2373 (examples (filter (cut string-match "emacsy" <>)
2374 (scandir (string-append out "/bin/"))))
2375 (progs (map (cut string-append out "/bin/" <>)
2376 examples)))
2377 (map (cut wrap-program <>
2378 `("GUILE_LOAD_PATH" ":" prefix ,scm-path)
2379 `("GUILE_LOAD_COMPILED_PATH" ":" prefix ,go-path))
2380 progs)
2381 #t))))))
48eb71ae
JN
2382 (home-page "https://savannah.nongnu.org/projects/emacsy")
2383 (synopsis "Embeddable GNU Emacs-like library using Guile")
2384 (description
2385 "Emacsy is an embeddable Emacs-like library that uses GNU Guile
f0de9544
JN
2386as extension language. Emacsy can give a C program an Emacsy feel with
2387keymaps, minibuffer, recordable macros, history, tab completion, major
2388and minor modes, etc., and can also be used as a pure Guile library. It
48eb71ae
JN
2389comes with a simple counter example using FreeGLUT and browser examples
2390in C using Gtk+-3 and WebKitGtk.")
2391 (license license:gpl3+)))
2135610c 2392
c99f32b9
AS
2393(define-public emacsy-minimal
2394 (let ((commit "f3bf0dbd803d7805b6ae8303253507ad13922293"))
2395 (package
2396 (inherit emacsy)
2397 (name "emacsy-minimal")
2398 (version (git-version "v0.4.1" "19" commit))
2399 (source (origin
2400 (method git-fetch)
2401 (uri (git-reference
2402 (url "https://git.savannah.gnu.org/git/emacsy.git")
2403 (commit commit)))
2404 (file-name (git-file-name name version))
2405 (sha256
2406 (base32
2407 "0ivy28km1p7nlrf63xx3hvrpxf5ld5amk1wcan3k7sqv1kq9mqdb"))))
2408 (build-system gnu-build-system)
2409 (inputs
2410 `(("guile" ,guile-2.2)
2411 ("guile-lib" ,guile-lib)
2412 ("guile-readline" ,guile-readline)))
2413 (propagated-inputs '())
2414 (arguments
2415 `(#:configure-flags '("--without-examples")
2416 #:phases
2417 (modify-phases %standard-phases
2418 (add-before 'configure 'setenv
2419 (lambda _
2420 (setenv "GUILE_AUTO_COMPILE" "0")
2421 #t))))))))
2422
2135610c
LC
2423(define-public guile-jpeg
2424 (let ((commit "6a1673578b297c2c1b28e44a76bd5c49e76a5046")
2425 (revision "0"))
2426 (package
2427 (name "guile-jpeg")
2428 (version (git-version "0.0" revision commit))
2429 (home-page "https://gitlab.com/wingo/guile-jpeg")
2430 (source (origin
2431 (method git-fetch)
2432 (uri (git-reference (url home-page)
2433 (commit commit)))
2434 (sha256
2435 (base32
2436 "05z9m408w3h6aqb5k3r3qa7khir0k10rxwvsrzhkcq1hr5vbmr4m"))
2437 (file-name (git-file-name name version))
2438 (modules '((guix build utils)))
2439 (snippet
2440 '(begin
2441 ;; Install .go files in the right place.
2442 (substitute* "Makefile.am"
2443 (("/ccache") "/site-ccache"))
2444 #t))))
2445 (build-system gnu-build-system)
2446 (native-inputs
2447 `(("autoconf" ,autoconf)
2448 ("automake" ,automake)
2449 ("pkg-config" ,pkg-config)
2450 ("guile" ,guile-2.2)))
2451 (synopsis "JPEG file parsing library for Guile")
2452 (description
2453 "Guile-JPEG is a Scheme library to parse JPEG image files and to
2454perform geometrical transforms on JPEG images.")
2455 (license license:gpl3+))))
e8c2da41
AS
2456
2457(define-public nomad
2458 (package
2459 (name "nomad")
2460 (version "0.1.1-alpha")
2461 (source (origin
2462 (method git-fetch)
2463 (uri (git-reference
2464 (url "https://git.savannah.gnu.org/git/nomad.git")
2465 (commit version)))
2466 (file-name (git-file-name name version))
2467 (sha256
2468 (base32
2469 "0abz07hl5dh802ciy71xzkvkhyryypq1i94wna40a2wndbd73f7z"))))
2470 (build-system gnu-build-system)
2471 (native-inputs
2472 `(("autoconf" ,autoconf)
2473 ("automake" ,automake)
2474 ("bash" ,bash)
2475 ("pkg-config" ,pkg-config)
2476 ("libtool" ,libtool)
2477 ("guile" ,guile-2.2)
2478 ("glib:bin" ,glib "bin")))
2479 (inputs
2480 `(("guile" ,guile-2.2)
2481 ("guile-lib" ,guile-lib)
2482 ("guile-gcrypt" ,guile-gcrypt)
2483 ("guile-readline" ,guile-readline)
2484 ("gnutls" ,gnutls)
2485 ("shroud" ,shroud)
2486 ("emacsy" ,emacsy-minimal)
2487 ("glib" ,glib)
2488 ("dbus-glib" ,dbus-glib)
2489 ("gtk+" ,gtk+)
2490 ("gtksourceview" ,gtksourceview)
2491 ("webkitgtk" ,webkitgtk)
2492 ("xorg-server" ,xorg-server)))
2493 (propagated-inputs
2494 `(("glib" ,glib)
2495 ("glib-networking" ,glib-networking)
2496 ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)))
2497 (arguments
2498 `(#:modules ((guix build gnu-build-system)
2499 (guix build utils)
2500 (ice-9 popen)
2501 (ice-9 rdelim)
2502 (srfi srfi-26))
2503 #:phases
2504 (modify-phases %standard-phases
2505 (add-before 'check 'start-xorg-server
2506 (lambda* (#:key inputs #:allow-other-keys)
2507 ;; The test suite requires a running X server.
2508 (system (format #f "~a/bin/Xvfb :1 &"
2509 (assoc-ref inputs "xorg-server")))
2510 (setenv "DISPLAY" ":1")
2511 #t))
2512 (add-after 'install 'wrap-binaries
2513 (lambda* (#:key inputs outputs #:allow-other-keys)
2514 (let* ((out (assoc-ref outputs "out"))
2515 (gio-deps (map (cut assoc-ref inputs <>) '("glib-networking"
2516 "glib")))
2517 (gio-mod-path (map (cut string-append <> "/lib/gio/modules")
2518 gio-deps))
2519 (effective (read-line (open-pipe*
2520 OPEN_READ
2521 "guile" "-c"
2522 "(display (effective-version))")))
2523 (deps (map (cut assoc-ref inputs <>)
2524 '("emacsy" "guile-lib" "guile-readline"
2525 "shroud")))
2526 (scm-path (map (cut string-append <>
2527 "/share/guile/site/" effective)
2528 `(,out ,@deps)))
2529 (go-path (map (cut string-append <>
2530 "/lib/guile/" effective "/site-ccache")
2531 `(,out ,@deps)))
2532 (progs (map (cut string-append out "/bin/" <>)
2533 '("nomad"))))
2534 (map (cut wrap-program <>
2535 `("GIO_EXTRA_MODULES" ":" prefix ,gio-mod-path)
2536 `("GUILE_LOAD_PATH" ":" prefix ,scm-path)
2537 `("GUILE_LOAD_COMPILED_PATH" ":"
2538 prefix ,go-path))
2539 progs)
2540 #t))))))
2541 (home-page "https://savannah.nongnu.org/projects/nomad/")
2542 (synopsis "Extensible Web Browser in Guile Scheme")
2543 (description "Nomad is an Emacs-like Web Browser built using Webkitgtk and
2544Emacsy. It has a small C layer and most browser features are fully
2545programmable in Guile. It has hooks, keymaps, and self documentation
2546features.")
2547 (license license:gpl3+)))
248965c9
RW
2548
2549(define-public guile-cv
2550 (package
2551 (name "guile-cv")
2552 (version "0.2.1")
2553 (source (origin
2554 (method url-fetch)
2555 (uri (string-append "mirror://gnu/guile-cv/guile-cv-"
2556 version ".tar.gz"))
2557 (sha256
2558 (base32
2559 "0qdf0s2h1xj5lbhnc1pfw69i3zg08pqy2y6869b92ydfis8r82j9"))))
2560 (build-system gnu-build-system)
2561 (arguments
2562 `(#:phases
2563 (modify-phases %standard-phases
2564 (add-after 'unpack 'prepare-build
2565 (lambda* (#:key inputs outputs #:allow-other-keys)
2566 (substitute* "configure"
2567 (("SITEDIR=\"\\$datadir/guile-cv\"")
2568 "SITEDIR=\"$datadir/guile/site/$GUILE_EFFECTIVE_VERSION\"")
2569 (("SITECCACHEDIR=\"\\$libdir/guile-cv/")
2570 "SITECCACHEDIR=\"$libdir/"))
2571 (substitute* "cv/init.scm"
2572 (("\\(dynamic-link \"libvigra_c\"\\)")
2573 (string-append "(dynamic-link \""
2574 (assoc-ref inputs "vigra-c")
2575 "/lib/libvigra_c\")"))
2576 (("\\(dynamic-link \"libguile-cv\"\\)")
2577 (format #f "~s"
2578 `(dynamic-link
2579 (format #f "~alibguile-cv"
2580 (if (getenv "GUILE_CV_UNINSTALLED")
2581 ""
2582 ,(format #f "~a/lib/"
2583 (assoc-ref outputs "out"))))))))
2584 (setenv "GUILE_CV_UNINSTALLED" "1")
2585 ;; Only needed to satisfy the configure script.
2586 (setenv "LD_LIBRARY_PATH"
2587 (string-append (assoc-ref inputs "vigra-c") "/lib"))
2588 #t)))))
2589 (inputs
2590 `(("vigra" ,vigra)
2591 ("vigra-c" ,vigra-c)
2592 ("guile" ,guile-2.2)))
2593 (native-inputs
2594 `(("texlive" ,(texlive-union (list texlive-booktabs
2595 texlive-lm
2596 texlive-siunitx
2597 texlive-standalone
2598 texlive-xcolor
2599 texlive-fonts-iwona)))
2600 ("pkg-config" ,pkg-config)))
2601 (propagated-inputs
2602 `(("guile-lib" ,guile-lib)))
2603 (home-page "https://www.gnu.org/software/guile-cv/")
2604 (synopsis "Computer vision library for Guile")
2605 (description "Guile-CV is a Computer Vision functional programming library
2606for the Guile Scheme language. It is based on Vigra (Vision with Generic
2607Algorithms), a C++ image processing and analysis library. Guile-CV contains
2608bindings to Vigra C (a C wrapper to most of the Vigra functionality) and is
2609enriched with pure Guile Scheme algorithms, all accessible through a nice,
2610clean and easy to use high level API.")
2611 (license license:gpl3+)))
7ff157c1
RW
2612
2613(define-public guile-ffi-fftw
2614 (let ((commit "95d7ffb55860f3163c5283ecec1ef43bc3d174dd")
2615 (revision "1"))
2616 (package
2617 (name "guile-ffi-fftw")
2618 (version (git-version "0" revision commit))
2619 (source (origin
2620 (method git-fetch)
2621 (uri (git-reference
2622 (url "https://github.com/lloda/guile-ffi-fftw.git")
2623 (commit commit)))
2624 (file-name (git-file-name "guile-ffi-fftw" version))
2625 (sha256
2626 (base32
2627 "0v9vk9cr4x9gn36lihi9gfkxyiqak0i598v5li6qw8bg95004p49"))))
2628 (build-system guile-build-system)
2629 (arguments
2630 `(#:source-directory "mod"
2631 #:phases
2632 (modify-phases %standard-phases
2633 (add-after 'unpack 'prepare-build
2634 (lambda* (#:key inputs #:allow-other-keys)
2635 (substitute* "mod/ffi/fftw.scm"
2636 (("\\(getenv \"GUILE_FFI_FFTW_LIBFFTW3_PATH\"\\)")
2637 (format #f "\"~a/lib\"" (assoc-ref inputs "fftw"))))
2638 #t))
2639 (add-after 'build 'check
2640 (lambda _
2641 (invoke "guile" "-L" "mod"
2642 "-s" "test/test-ffi-fftw.scm"))))))
2643 (inputs
2644 `(("fftw" ,fftw)
2645 ("guile" ,guile-2.2)))
2646 (home-page "https://github.com/lloda/guile-ffi-fftw/")
2647 (synopsis "Access FFTW through Guile's FFI")
2648 (description "This is a minimal set of Guile FFI bindings for the FFTW
2649library's ‘guru interface’. It provides two functions: @code{fftw-dft! rank
2650sign in out} and @code{fftw-dft rank sign in}. These bindings being minimal,
2651there is no support for computing & reusing plans, or split r/i transforms, or
2652anything other than straight complex DFTs.")
2653 ;; TODO: This might actually be LGPLv3+
2654 ;; See https://github.com/lloda/guile-ffi-fftw/issues/1
2655 (license license:gpl3+))))