gnu: nfs-utils: Fix location of external util-linux binaries.
[jackhill/guix/guix.git] / gnu / packages / guile-xyz.scm
CommitLineData
0791437f 1;;; GNU Guix --- Functional package management for GNU
f918a8d9 2;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès <ludo@gnu.org>
0791437f
RW
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>
195e1c1b 6;;; Copyright © 2016, 2017, 2018, 2019, 2020 Ricardo Wurmus <rekado@elephly.net>
0791437f 7;;; Copyright © 2016 Erik Edrosa <erik.edrosa@gmail.com>
a52aa7fd 8;;; Copyright © 2016, 2019, 2020 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>
f6145358 15;;; Copyright © 2017, 2018, 2019, 2020 Mathieu Othacehe <m.othacehe@gmail.com>
0791437f 16;;; Copyright © 2017 Theodoros Foradis <theodoros@foradis.org>
3c986a7d 17;;; Copyright © 2017 Nikita <nikita@n0.is>
0791437f
RW
18;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
19;;; Copyright © 2018 Maxim Cournoyer <maxim.cournoyer@gmail.com>
69bb61f1 20;;; Copyright © 2018, 2019, 2020 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>
be789065 24;;; Copyright © 2019, 2020 Amar Singh <nly@disroot.org>
f9ec89f4 25;;; Copyright © 2019 Timothy Sample <samplet@ngyro.com>
3c566eba 26;;; Copyright © 2019, 2020 Martin Becze <mjbecze@riseup.net>
8ffc20ef 27;;; Copyright © 2020 Evan Straw <evan.straw99@gmail.com>
b7e1e556 28;;; Copyright © 2020 Jack Hill <jackhill@jackhill.us>
c08f235b 29;;; Copyright © 2020 Julien Lepiler <julien@lepiller.eu>
3a71dac0 30;;; Copyright © 2020 Marius Bakke <marius@gnu.org>
d282a82c 31;;; Copyright © 2020 Masaya Tojo <masaya@tojo.tokyo>
c984b70c 32;;; Copyright © 2020 Jesse Gibbons <jgibbons2357@gmail.com>
a987f128 33;;; Copyright © 2020 Mike Rosset <mike.rosset@gmail.com>
d22d129d 34;;; Copyright © 2020 Leo Prikler <leo.prikler@student.tugraz.at>
0791437f
RW
35;;;
36;;; This file is part of GNU Guix.
37;;;
38;;; GNU Guix is free software; you can redistribute it and/or modify it
39;;; under the terms of the GNU General Public License as published by
40;;; the Free Software Foundation; either version 3 of the License, or (at
41;;; your option) any later version.
42;;;
43;;; GNU Guix is distributed in the hope that it will be useful, but
44;;; WITHOUT ANY WARRANTY; without even the implied warranty of
45;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
46;;; GNU General Public License for more details.
47;;;
48;;; You should have received a copy of the GNU General Public License
49;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
50
51(define-module (gnu packages guile-xyz)
52 #:use-module ((guix licenses) #:prefix license:)
53 #:use-module (gnu packages)
7ff157c1 54 #:use-module (gnu packages algebra)
0791437f
RW
55 #:use-module (gnu packages aspell)
56 #:use-module (gnu packages autotools)
465a951c 57 #:use-module (gnu packages avahi)
0791437f
RW
58 #:use-module (gnu packages base)
59 #:use-module (gnu packages bash)
60 #:use-module (gnu packages compression)
406ef442 61 #:use-module (gnu packages databases)
0791437f 62 #:use-module (gnu packages disk)
15218d4e 63 #:use-module (gnu packages emacs)
5531782d 64 #:use-module (gnu packages emacs-xyz)
0791437f
RW
65 #:use-module (gnu packages gawk)
66 #:use-module (gnu packages gettext)
67 #:use-module (gnu packages gl)
bdf2dd79 68 #:use-module (gnu packages glib)
5531782d 69 #:use-module (gnu packages gnome)
e8c2da41 70 #:use-module (gnu packages gnupg)
0791437f 71 #:use-module (gnu packages gperf)
a987f128 72 #:use-module (gnu packages gstreamer)
bdf2dd79 73 #:use-module (gnu packages gtk)
0791437f
RW
74 #:use-module (gnu packages guile)
75 #:use-module (gnu packages hurd)
76 #:use-module (gnu packages image)
d1a3a8e1 77 #:use-module (gnu packages imagemagick)
0791437f
RW
78 #:use-module (gnu packages libffi)
79 #:use-module (gnu packages libunistring)
80 #:use-module (gnu packages linux)
81 #:use-module (gnu packages man)
82 #:use-module (gnu packages maths)
83 #:use-module (gnu packages multiprecision)
84 #:use-module (gnu packages ncurses)
85 #:use-module (gnu packages networking)
f0de9544 86 #:use-module (gnu packages noweb)
1a37fd1e 87 #:use-module (gnu packages nss)
e8c2da41 88 #:use-module (gnu packages password-utils)
406ef442 89 #:use-module (gnu packages perl)
0791437f
RW
90 #:use-module (gnu packages pkg-config)
91 #:use-module (gnu packages python)
92 #:use-module (gnu packages readline)
93 #:use-module (gnu packages sdl)
69bb61f1 94 #:use-module (gnu packages search)
0791437f
RW
95 #:use-module (gnu packages slang)
96 #:use-module (gnu packages sqlite)
69bb61f1 97 #:use-module (gnu packages swig)
f0de9544 98 #:use-module (gnu packages tex)
0791437f
RW
99 #:use-module (gnu packages texinfo)
100 #:use-module (gnu packages tls)
101 #:use-module (gnu packages version-control)
bdf2dd79 102 #:use-module (gnu packages webkit)
0791437f
RW
103 #:use-module (gnu packages xdisorg)
104 #:use-module (gnu packages xorg)
105 #:use-module (guix packages)
106 #:use-module (guix download)
107 #:use-module (guix git-download)
dec4b3aa 108 #:use-module (guix hg-download)
e4ef0d7c 109 #:use-module (guix build-system glib-or-gtk)
0791437f
RW
110 #:use-module (guix build-system gnu)
111 #:use-module (guix build-system guile)
112 #:use-module (guix utils)
113 #:use-module (ice-9 match)
114 #:use-module ((srfi srfi-1) #:select (alist-delete)))
115
116(define-public artanis
1a37fd1e
RW
117 (package
118 (name "artanis")
119 (version "0.4.1")
120 (source (origin
121 (method url-fetch)
122 (uri (string-append "mirror://gnu/artanis/artanis-"
123 version ".tar.gz"))
124 (sha256
125 (base32
126 "0nnmdfx5xwcc3kck64var7msz7g3qk817d7bv9l159nkmic0v9w4"))
127 (modules '((guix build utils)))
128 (snippet
129 '(begin
130 ;; Unbundle guile-redis and guile-json
131 (delete-file-recursively "artanis/third-party/json.scm")
132 (delete-file-recursively "artanis/third-party/json")
133 (delete-file-recursively "artanis/third-party/redis.scm")
134 (delete-file-recursively "artanis/third-party/redis")
135 (substitute* '("artanis/artanis.scm"
136 "artanis/lpc.scm"
137 "artanis/oht.scm")
138 (("(#:use-module \\()artanis third-party (json\\))" _
139 use-module json)
140 (string-append use-module json)))
141 (substitute* '("artanis/lpc.scm"
142 "artanis/session.scm")
143 (("(#:use-module \\()artanis third-party (redis\\))" _
144 use-module redis)
145 (string-append use-module redis)))
146 (substitute* "artanis/oht.scm"
147 (("([[:punct:][:space:]]+)(->json-string)([[:punct:][:space:]]+)"
148 _ pre json-string post)
149 (string-append pre
150 "scm" json-string
151 post)))
152 (substitute* "artanis/artanis.scm"
153 (("[[:punct:][:space:]]+->json-string[[:punct:][:space:]]+")
154 ""))
155 #t))))
156 (build-system gnu-build-system)
157 (inputs
158 `(("guile" ,guile-2.2)
159 ("nss" ,nss)))
160 ;; FIXME the bundled csv contains one more exported procedure
161 ;; (sxml->csv-string) than guile-csv. The author is maintainer of both
162 ;; projects.
163 ;; TODO: Add guile-dbi and guile-dbd optional dependencies.
164 (propagated-inputs
d282a82c 165 `(("guile-json" ,guile-json-1) ; This ia already using guile-2.2.
a7a8337b 166 ("guile-readline" ,guile2.2-readline)
d282a82c 167 ("guile-redis" ,guile2.2-redis)))
1a37fd1e
RW
168 (native-inputs
169 `(("bash" ,bash) ;for the `source' builtin
170 ("pkgconfig" ,pkg-config)
171 ("util-linux" ,util-linux))) ;for the `script' command
172 (arguments
173 '(#:make-flags
174 ;; TODO: The documentation must be built with the `docs' target.
175 (let* ((out (assoc-ref %outputs "out"))
176 (scm (string-append out "/share/guile/site/2.2"))
177 (go (string-append out "/lib/guile/2.2/site-ccache")))
178 ;; Don't use (%site-dir) for site paths.
179 (list (string-append "MOD_PATH=" scm)
180 (string-append "MOD_COMPILED_PATH=" go)))
181 #:test-target "test"
182 #:phases
183 (modify-phases %standard-phases
184 (add-after 'unpack 'patch-site-dir
185 (lambda* (#:key outputs #:allow-other-keys)
186 (substitute* "artanis/commands/help.scm"
187 (("\\(%site-dir\\)")
188 (string-append "\""
189 (assoc-ref outputs "out")
190 "/share/guile/site/2.2\"")))))
191 (add-after 'unpack 'patch-reference-to-libnss
192 (lambda* (#:key inputs #:allow-other-keys)
193 (substitute* "artanis/security/nss.scm"
194 (("ffi-binding \"libnss3\"")
195 (string-append
196 "ffi-binding \""
197 (assoc-ref inputs "nss") "/lib/nss/libnss3.so"
198 "\"")))
199 #t))
200 (add-before 'install 'substitute-root-dir
201 (lambda* (#:key outputs #:allow-other-keys)
202 (let ((out (assoc-ref outputs "out")))
203 (substitute* "Makefile" ;ignore the execution of bash.bashrc
204 ((" /etc/bash.bashrc") " /dev/null"))
205 (substitute* "Makefile" ;set the root of config files to OUT
206 ((" /etc") (string-append " " out "/etc")))
207 (mkdir-p (string-append out "/bin")) ;for the `art' executable
208 #t)))
209 (add-after 'install 'wrap-art
210 (lambda* (#:key inputs outputs #:allow-other-keys)
211 (let* ((out (assoc-ref outputs "out"))
212 (bin (string-append out "/bin"))
213 (scm (string-append out "/share/guile/site/2.2"))
214 (go (string-append out "/lib/guile/2.2/site-ccache")))
215 (wrap-program (string-append bin "/art")
216 `("GUILE_LOAD_PATH" ":" prefix
217 (,scm ,(getenv "GUILE_LOAD_PATH")))
218 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
219 (,go ,(getenv "GUILE_LOAD_COMPILED_PATH"))))
220 #t))))))
221 (synopsis "Web application framework written in Guile")
222 (description "GNU Artanis is a web application framework written in Guile
0791437f
RW
223Scheme. A web application framework (WAF) is a software framework that is
224designed to support the development of dynamic websites, web applications, web
225services and web resources. The framework aims to alleviate the overhead
226associated with common activities performed in web development. Artanis
227provides several tools for web development: database access, templating
228frameworks, session management, URL-remapping for RESTful, page caching, and
229more.")
1a37fd1e
RW
230 (home-page "https://www.gnu.org/software/artanis/")
231 (license (list license:gpl3+ license:lgpl3+)))) ;dual license
0791437f
RW
232
233;; There has not been any release yet.
234(define-public guildhall
235 (let ((commit "2fe2cc539f4b811bbcd69e58738db03eb5a2b778")
236 (revision "1"))
237 (package
238 (name "guildhall")
239 (version (string-append "0-" revision "." (string-take commit 9)))
240 (source (origin
241 (method git-fetch)
242 (uri (git-reference
b0e7b699 243 (url "https://github.com/ijp/guildhall")
0791437f
RW
244 (commit commit)))
245 (file-name (string-append name "-" version "-checkout"))
246 (sha256
247 (base32
248 "115bym7bg66h3gs399yb2vkzc2ygriaqsn4zbrg8f054mgy8wzn1"))))
249 (build-system gnu-build-system)
250 (arguments
251 `(#:phases
252 (modify-phases %standard-phases
253 ;; Tests fail without this fix because they try to load the bash
254 ;; executable as a Scheme file. See bug report at
255 ;; https://github.com/ijp/guildhall/issues/22
256 (add-after 'unpack 'fix-bug-22
257 (lambda _
258 (substitute* "Makefile.am"
259 (("TESTS_ENVIRONMENT=.*")
260 "AM_TESTS_ENVIRONMENT=srcdir=$(abs_top_srcdir)/tests/
261TEST_EXTENSIONS = .scm
262SCM_LOG_COMPILER= $(top_builddir)/env $(GUILE)
263AM_SCM_LOG_FLAGS = --no-auto-compile -s")
264 ;; FIXME: one of the database tests fails for unknown
265 ;; reasons. It does not fail when run outside of Guix.
266 (("tests/database.scm") ""))
267 #t)))))
268 (inputs
269 `(("guile" ,guile-2.0)))
270 (native-inputs
271 `(("zip" ,zip) ; for tests
272 ("autoconf" ,autoconf)
273 ("automake" ,automake)
274 ("texinfo" ,texinfo)))
275 (synopsis "Package manager for Guile")
276 (description
277 "Guildhall is a package manager written for Guile Scheme. A guild is
278an association of independent craftspeople. A guildhall is where they meet.
279This Guildhall aims to make a virtual space for Guile wizards and journeyfolk
280to share code.
281
282On a practical level, Guildhall lets you share Scheme modules and programs
283over the internet, and install code that has been shared by others. Guildhall
284can handle dependencies, so when a program requires several libraries, and
285each of those has further dependencies, all of the prerequisites for the
286program can be installed in one go.")
287 (home-page "https://github.com/ijp/guildhall")
288 (license license:gpl3+))))
289
290(define-public guile-aspell
291 (package
292 (name "guile-aspell")
293 (version "0.4")
294 (source (origin
295 (method url-fetch)
296 (uri (string-append
297 "http://lonelycactus.com/tarball/guile_aspell-"
298 version ".tar.gz"))
299 (sha256
300 (base32
301 "0vpk5xj9m9qc702z3khmkwhgpb949qbsyz8kw2qycda6qnxk0077"))))
302 (build-system gnu-build-system)
303 (arguments
304 '(#:phases (modify-phases %standard-phases
305 (add-before 'configure 'set-guilesitedir
306 (lambda _
307 (substitute* "Makefile.in"
308 (("^guilesitedir =.*$")
309 "guilesitedir = \
310$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
311 #t))
312 (add-before 'build 'set-libaspell-file-name
313 (lambda* (#:key inputs #:allow-other-keys)
314 (let ((aspell (assoc-ref inputs "aspell")))
315 (substitute* "aspell.scm"
316 (("\"libaspell\\.so\"")
317 (string-append "\"" aspell
318 "/lib/libaspell\"")))
319 #t))))))
320 (native-inputs `(("pkg-config" ,pkg-config)))
321 (inputs `(("guile" ,guile-2.2)
322 ("aspell" ,aspell)))
323 (home-page "https://github.com/spk121/guile-aspell")
324 (synopsis "Spell-checking from Guile")
325 (description
326 "guile-aspell is a Guile Scheme library for comparing a string against a
327dictionary and suggesting spelling corrections.")
328 (license license:gpl3+)))
329
330(define-public guile-bash
331 ;; This project is currently retired. It was initially announced here:
332 ;; <https://lists.gnu.org/archive/html/guile-user/2015-02/msg00003.html>.
333 (let ((commit "1eabc563ca5692b3e08d84f1f0e6fd2283284469")
334 (revision "0"))
335 (package
336 (name "guile-bash")
337 (version (string-append "0.1.6-" revision "." (string-take commit 7)))
338 (home-page
339 "https://anonscm.debian.org/cgit/users/kaction-guest/retired/dev.guile-bash.git")
340 (source (origin
341 (method git-fetch)
342 (uri (git-reference
343 (commit commit)
344 (url home-page)))
345 (sha256
346 (base32
347 "097vny990wp2qpjij6a5a5gwc6fxzg5wk56inhy18iki5v6pif1p"))
348 (file-name (string-append name "-" version "-checkout"))))
349 (build-system gnu-build-system)
350 (arguments
351 '(#:configure-flags
352 ;; Add -I to match 'bash.pc' of Bash 4.4.
353 (list (string-append "CPPFLAGS=-I"
354 (assoc-ref %build-inputs "bash:include")
355 "/include/bash/include")
356
357 ;; The '.a' file is useless.
358 "--disable-static"
359
360 ;; Install 'lib/bash' as Bash 4.4 expects.
361 (string-append "--libdir=" (assoc-ref %outputs "out")
362 "/lib/bash"))))
363 (native-inputs `(("pkg-config" ,pkg-config)
364 ("autoconf" ,autoconf-wrapper)
365 ("automake" ,automake)
366 ("libtool" ,libtool)
367 ;; Gettext brings 'AC_LIB_LINKFLAGS_FROM_LIBS'.
368 ("gettext" ,gettext-minimal)
369
370 ;; Bash with loadable module support, for the test
371 ;; suite.
372 ("bash-full" ,bash)))
373 (inputs `(("guile" ,guile-2.0)
374 ("bash:include" ,bash "include")))
375 (synopsis "Extend Bash using Guile")
376 (description
377 "Guile-Bash provides a shared library and set of Guile modules,
378allowing you to extend Bash in Scheme. Scheme interfaces allow you to access
379the following aspects of Bash:
380
381@itemize
382@item aliases;
383@item setting and getting Bash variables;
384@item creating dynamic variables;
385@item creating Bash functions with a Scheme implementation;
386@item reader macro for output capturing;
387@item reader macro for evaluating raw Bash commands.
388@end itemize
389
390To enable it, run:
391
392@example
393enable -f ~/.guix-profile/lib/bash/libguile-bash.so scm
394@end example
395
396and then run @command{scm example.scm}.")
397 (license license:gpl3+))))
398
399(define-public guile-8sync
400 (package
401 (name "guile-8sync")
402 (version "0.4.2")
403 (source (origin
404 (method url-fetch)
405 (uri (string-append "mirror://gnu/8sync/8sync-" version
406 ".tar.gz"))
407 (sha256
408 (base32
409 "031wm13srak3wsnll7j2mbbi29g1pcm4swdb71ds9yn567pn20qw"))))
410 (build-system gnu-build-system)
411 (native-inputs `(("autoconf" ,autoconf)
412 ("automake" ,automake)
413 ("guile" ,guile-2.2)
414 ("pkg-config" ,pkg-config)
415 ("texinfo" ,texinfo)))
416 (arguments
417 `(#:phases (modify-phases %standard-phases
418 (add-before 'configure 'setenv
419 (lambda _
420 ;; quiet warnings
421 (setenv "GUILE_AUTO_COMPILE" "0")
422 #t)))))
423 (home-page "https://gnu.org/s/8sync/")
424 (synopsis "Asynchronous actor model library for Guile")
425 (description
426 "GNU 8sync (pronounced \"eight-sync\") is an asynchronous programming
427library for GNU Guile based on the actor model.
428
429Note that 8sync is only available for Guile 2.2.")
eee4173c 430 (properties '((upstream-name . "8sync")))
0791437f
RW
431 (license license:lgpl3+)))
432
433(define-public guile-daemon
434 (package
435 (name "guile-daemon")
f975f82d 436 (version "0.1.3")
0791437f
RW
437 (source (origin
438 (method url-fetch)
439 (uri (string-append "https://github.com/alezost/" name
440 "/releases/download/v" version
441 "/" name "-" version ".tar.gz"))
442 (sha256
443 (base32
f975f82d 444 "08gaqrgjlly9k5si72vvpbr4xhq5v52l5ma5y6a7spid5dd057cy"))))
0791437f
RW
445 (build-system gnu-build-system)
446 (native-inputs
447 `(("pkg-config" ,pkg-config)))
448 (inputs
449 `(("guile" ,guile-2.2)))
450 (home-page "https://github.com/alezost/guile-daemon")
451 (synopsis "Evaluate code in a running Guile process")
452 (description
453 "Guile-Daemon is a small Guile program that loads your initial
454configuration file, and then reads and evaluates Guile expressions that
455you send to a FIFO file.")
456 (license license:gpl3+)))
457
458(define-public guile-dsv
459 (package
460 (name "guile-dsv")
14b92004 461 (version "0.3.0")
0791437f
RW
462 (source (origin
463 (method git-fetch)
464 (uri (git-reference
465 (url "https://github.com/artyom-poptsov/guile-dsv")
14b92004 466 (commit "6c867915dc4198eacc548a4834ef0e1aef852795")))
0791437f
RW
467 (file-name (string-append name "-" version "-checkout"))
468 (sha256
469 (base32
14b92004 470 "1mxbbcsmbjfnh4yydqz44ihbkdnzdwz38xanaam128arlb7hwr8n"))))
0791437f
RW
471 (build-system gnu-build-system)
472 (native-inputs
473 `(("autoconf" ,autoconf)
474 ("automake" ,automake)
475 ("pkg-config" ,pkg-config)
476 ("texinfo" ,texinfo)))
f81ce752
JH
477 (inputs `(("guile" ,guile-3.0)))
478 (propagated-inputs `(("guile-lib" ,guile-lib)))
0791437f 479 (arguments
b7e1e556
JH
480 `(#:modules (((guix build guile-build-system)
481 #:select (target-guile-effective-version))
482 ,@%gnu-build-system-modules)
483 #:imported-modules ((guix build guile-build-system)
484 ,@%gnu-build-system-modules)
485 #:phases (modify-phases %standard-phases
f81ce752
JH
486 ;; Support Guile 3.0 in configure from upstream commit
487 ;; 4c724577ccf19bb88580f72f2f6b166a0447ce3f
488 (add-before 'bootstrap 'configure-support-guile3.0
489 (lambda _
490 (substitute* "configure.ac"
491 (("GUILE_PKG.*")
492 "GUILE_PKG([3.0 2.0 2.2])"))
493 #t))
0791437f
RW
494 (add-before 'configure 'set-guilesitedir
495 (lambda _
496 (substitute* "Makefile.in"
497 (("^guilesitedir =.*$")
498 "guilesitedir = \
499$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
500 (substitute* "modules/Makefile.in"
501 (("^guilesitedir =.*$")
502 "guilesitedir = \
503$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
504 (substitute* "modules/dsv/Makefile.in"
505 (("^guilesitedir =.*$")
506 "guilesitedir = \
507$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
b7e1e556
JH
508 #t))
509 (add-after 'install 'wrap-program
510 (lambda* (#:key inputs outputs #:allow-other-keys)
511 (let* ((out (assoc-ref outputs "out"))
512 (bin (string-append out "/bin"))
f81ce752 513 (guile-lib (assoc-ref inputs "guile-lib"))
b7e1e556
JH
514 (version (target-guile-effective-version))
515 (scm (string-append "/share/guile/site/"
516 version))
517 (go (string-append "/lib/guile/"
518 version "/site-ccache")))
519 (wrap-program (string-append bin "/dsv")
520 `("GUILE_LOAD_PATH" prefix
521 (,(string-append out scm)
522 ,(string-append guile-lib scm)))
523 `("GUILE_LOAD_COMPILED_PATH" prefix
524 (,(string-append out go)
525 ,(string-append guile-lib go)))))
0791437f
RW
526 #t)))))
527 (home-page "https://github.com/artyom-poptsov/guile-dsv")
528 (synopsis "DSV module for Guile")
529 (description
530 "Guile-DSV is a GNU Guile module for working with the
531delimiter-separated values (DSV) data format. Guile-DSV supports the
532Unix-style DSV format and RFC 4180 format.")
533 (license license:gpl3+)))
534
f81ce752
JH
535(define-public guile2.2-dsv
536 (package
537 (inherit guile-dsv)
538 (name "guile2.2-dsv")
539 (inputs `(("guile" ,guile-2.2)))
540 (propagated-inputs `(("guile-lib" ,guile2.2-lib)))))
541
0791437f
RW
542(define-public guile-fibers
543 (package
544 (name "guile-fibers")
545 (version "1.0.0")
546 (source (origin
547 (method url-fetch)
548 (uri (string-append "https://wingolog.org/pub/fibers/fibers-"
549 version ".tar.gz"))
550 (sha256
551 (base32
9e016129
LC
552 "0vjkg72ghgdgphzbjz9ig8al8271rq8974viknb2r1rg4lz92ld0"))
553 (modules '((guix build utils)))
554 (snippet
555 '(begin
556 ;; Allow builds with Guile 3.0.
557 (substitute* "configure"
558 (("search=\"2\\.2\"")
559 "search=\"3.0 2.2\""))
560
561 ;; Explicitly include system headers rather than relying on
562 ;; <libguile.h> to do it for us.
563 (substitute* "epoll.c"
564 (("#include.*libguile\\.h.*$" all)
565 (string-append "#include <unistd.h>\n"
566 "#include <string.h>\n"
567 all "\n")))
568
569 ;; Import (ice-9 threads) for 'current-processor-count'.
570 (substitute* "tests/channels.scm"
571 (("#:use-module \\(fibers\\)")
572 (string-append "#:use-module (fibers)\n"
573 "#:use-module (ice-9 threads)\n")))
9af90aaf
CR
574 #t))
575 (patches
576 ;; fixes a resource leak that causes crashes in the tests
577 (search-patches "guile-fibers-destroy-peer-schedulers.patch"))))
0791437f
RW
578 (build-system gnu-build-system)
579 (arguments
b6bee63b
LC
580 '(;; The code uses 'scm_t_uint64' et al., which are deprecated in 3.0.
581 #:configure-flags '("CFLAGS=-Wno-error=deprecated-declarations")
582 #:phases (modify-phases %standard-phases
0791437f
RW
583 (add-after 'install 'mode-guile-objects
584 (lambda* (#:key outputs #:allow-other-keys)
585 ;; .go files are installed to "lib/guile/X.Y/cache".
586 ;; This phase moves them to "…/site-ccache".
587 (let* ((out (assoc-ref outputs "out"))
588 (lib (string-append out "/lib/guile"))
589 (old (car (find-files lib "^ccache$"
590 #:directories? #t)))
591 (new (string-append (dirname old)
592 "/site-ccache")))
593 (rename-file old new)
594 #t))))))
595 (native-inputs
596 `(("texinfo" ,texinfo)
597 ("pkg-config" ,pkg-config)))
598 (inputs
b6bee63b 599 `(("guile" ,guile-3.0)))
0791437f
RW
600 (synopsis "Lightweight concurrency facility for Guile")
601 (description
602 "Fibers is a Guile library that implements a a lightweight concurrency
603facility, inspired by systems like Concurrent ML, Go, and Erlang. A fiber is
604like a \"goroutine\" from the Go language: a lightweight thread-like
605abstraction. Systems built with Fibers can scale up to millions of concurrent
606fibers, tens of thousands of concurrent socket connections, and many parallel
607cores. The Fibers library also provides Concurrent ML-like channels for
608communication between fibers.
609
610Note that Fibers makes use of some Guile 2.1/2.2-specific features and
611is not available for Guile 2.0.")
612 (home-page "https://github.com/wingo/fibers")
613 (license license:lgpl3+)))
614
b6bee63b 615(define-public guile2.0-fibers
9e016129
LC
616 (package
617 (inherit guile-fibers)
b6bee63b
LC
618 (name "guile2.2-fibers")
619 (inputs `(("guile" ,guile-2.2)))))
620
621(define-public guile3.0-fibers
622 (deprecated-package "guile3.0-fibers" guile-fibers))
9e016129 623
d22d129d
LP
624(define-public guile-filesystem
625 (package
626 (name "guile-filesystem")
627 (version "0.1.0")
628 (source (origin
629 (method git-fetch)
630 (uri (git-reference
631 (url "https://gitlab.com/leoprikler/guile-filesystem.git")
632 (commit version)))
633 (file-name (git-file-name name version))
634 (sha256
635 (base32
636 "1shmkc0y9r2sj3kw7hrsnamnp7y8xifkhf3m3rnfxczqg63k67vy"))))
637 (build-system gnu-build-system)
638 (native-inputs
639 `(("autoconf" ,autoconf-wrapper)
640 ("automake" ,automake)
641 ("pkg-config" ,pkg-config)
642 ("texinfo" ,texinfo)))
643 (inputs
644 `(("guile" ,guile-3.0)))
645 (home-page "https://gitlab.com/leoprikler/guile-filesystem")
646 (synopsis "Complementary library to Guile's built-in file system procedures")
647 (description "@code{guile-filesystem} provides a set of utility functions,
648that augment Guile's support for handling files and their names.")
649 (license license:lgpl3+)))
650
651(define-public guile2.0-filesystem
652 (package
653 (inherit guile-filesystem)
654 (name "guile2.0-filesystem")
655 (inputs `(("guile" ,guile-2.0)))))
656
657(define-public guile2.2-filesystem
658 (package
659 (inherit guile-filesystem)
660 (name "guile2.2-filesystem")
661 (inputs `(("guile" ,guile-2.2)))))
662
0791437f
RW
663(define-public guile-syntax-highlight
664 (package
665 (name "guile-syntax-highlight")
666 (version "0.1")
667 (source (origin
668 (method url-fetch)
669 (uri (string-append "https://files.dthompson.us/"
670 "guile-syntax-highlight/"
671 "guile-syntax-highlight-"
672 version ".tar.gz"))
673 (sha256
674 (base32
fb8a77f4
LC
675 "1p771kq15x83483m23bhah1sz6vkalg3drm7x279f4j1cxligkzi"))
676 (modules '((guix build utils)))
677 (snippet
678 '(begin
679 ;; Allow builds with Guile 3.0.
680 (substitute* "configure"
681 (("2\\.2 2\\.0")
682 "3.0 2.2 2.0"))
683 #t))))
0791437f
RW
684 (build-system gnu-build-system)
685 (native-inputs
686 `(("pkg-config" ,pkg-config)))
687 (inputs
b6bee63b 688 `(("guile" ,guile-3.0)))
0791437f
RW
689 (synopsis "General-purpose syntax highlighter for GNU Guile")
690 (description "Guile-syntax-highlight is a general-purpose syntax
691highlighting library for GNU Guile. It can parse code written in various
692programming languages into a simple s-expression that can be converted to
693HTML (via SXML) or any other format for rendering.")
02e052ba 694 (home-page "https://dthompson.us/projects/guile-syntax-highlight.html")
0791437f
RW
695 (license license:lgpl3+)))
696
b6bee63b 697(define-public guile2.2-syntax-highlight
fb8a77f4
LC
698 (package
699 (inherit guile-syntax-highlight)
b6bee63b
LC
700 (name "guile2.2-syntax-highlight")
701 (inputs `(("guile" ,guile-2.2)))))
702
703(define-public guile3.0-syntax-highlight
704 (deprecated-package "guile3.0-syntax-highlight" guile-syntax-highlight))
fb8a77f4 705
0791437f
RW
706(define-public guile-sjson
707 (package
708 (name "guile-sjson")
709 (version "0.2.1")
710 (source (origin
711 (method url-fetch)
712 (uri (string-append "https://dustycloud.org/misc/sjson-" version
713 ".tar.gz"))
714 (sha256
715 (base32
eef54583
RW
716 "1mzmapln79vv10qxaggz9qwcdbag3jnrj19xx8bgkmxss8h03sv3"))
717 (modules '((guix build utils)))
718 (snippet
719 '(begin
720 ;; Allow builds with Guile 3.0.
721 (substitute* "configure"
722 (("2\\.2 2\\.0")
723 "3.0 2.2 2.0"))
724 #t))))
0791437f
RW
725 (build-system gnu-build-system)
726 (native-inputs
727 `(("autoconf" ,autoconf)
728 ("automake" ,automake)
729 ("pkg-config" ,pkg-config)))
730 (inputs
eef54583 731 `(("guile" ,guile-3.0)))
0791437f
RW
732 (home-page "https://gitlab.com/dustyweb/guile-sjson")
733 (synopsis "S-expression based json reader/writer for Guile")
734 (description "guile-sjson is a json reader/writer for Guile.
735It has a nice, simple s-expression based syntax.")
736 (license license:lgpl3+)))
737
eef54583
RW
738(define-public guile2.2-sjson
739 (package
740 (inherit guile-sjson)
741 (name "guile2.2-sjson")
742 (inputs `(("guile" ,guile-2.2)))))
743
61dafdc0 744(define-public guile-squee
f3e96671
CB
745 (let ((commit "7dcd22b54fd56c9e629489191bb27ac80ecea9db")
746 (revision "1"))
61dafdc0
CB
747 (package
748 (name "guile-squee")
749 (version (string-append "0-" revision "." (string-take commit 7)))
750 (source (origin
751 (method git-fetch)
752 (uri (git-reference
753 (url "https://notabug.org/cwebber/guile-squee.git")
754 (commit commit)))
755 (file-name (git-file-name name version))
756 (sha256
757 (base32
f3e96671 758 "1568sk6ada7x9qpfhax0qq1bq93qll1q7nyjrb7h3c1c3lc9sc15"))))
61dafdc0
CB
759 (build-system guile-build-system)
760 (arguments
761 '(#:phases
762 (modify-phases %standard-phases
763 (add-after 'unpack 'patch
764 (lambda* (#:key inputs #:allow-other-keys)
765 (substitute* "squee.scm"
766 (("dynamic-link \"libpq\"")
767 (string-append
768 "dynamic-link \""
769 (assoc-ref inputs "postgresql") "/lib/libpq.so"
770 "\"")))
771 #t)))))
772 (inputs
773 `(("postgresql" ,postgresql)))
774 (native-inputs
ca03dca5 775 `(("guile" ,guile-3.0)))
61dafdc0
CB
776 (home-page "https://notabug.org/cwebber/guile-squee")
777 (synopsis "Connect to PostgreSQL using Guile")
778 (description
779 "@code{squee} is a Guile library for connecting to PostgreSQL databases
780using Guile's foreign function interface.")
6fd72f70 781 (license license:lgpl3+))))
61dafdc0 782
ca03dca5 783(define-public guile2.2-squee
945a73d8
CB
784 (package
785 (inherit guile-squee)
ca03dca5
LC
786 (name "guile2.2-squee")
787 (native-inputs `(("guile" ,guile-2.2)
cfe35814
CB
788 ,@(alist-delete "guile"
789 (package-native-inputs guile-squee))))))
945a73d8 790
ca03dca5
LC
791(define-public guile3.0-squee
792 (deprecated-package "guile3.0-squee" guile-squee))
793
0791437f
RW
794(define-public guile-colorized
795 (package
796 (name "guile-colorized")
797 (version "0.1")
1340ce28
TGR
798 (source
799 (origin
800 (method git-fetch)
801 (uri (git-reference
55f4282e 802 (url "https://gitlab.com/NalaGinrut/guile-colorized.git")
1340ce28
TGR
803 (commit (string-append "v" version))))
804 (file-name (git-file-name name version))
805 (sha256
806 (base32 "10mv8c63159r3qvwwdvsgnsvdg7nc2ghak85zapwqpv4ywrqp9zc"))))
0791437f
RW
807 (build-system guile-build-system)
808 (native-inputs
b6bee63b 809 `(("guile" ,guile-3.0)))
55f4282e 810 (home-page "https://gitlab.com/NalaGinrut/guile-colorized")
0791437f
RW
811 (synopsis "Colorized REPL for Guile")
812 (description
813 "Guile-colorized provides you with a colorized REPL for GNU Guile.")
814 (license license:gpl3+)))
815
b6bee63b 816(define-public guile2.2-colorized
fc870a0d
LC
817 (package
818 (inherit guile-colorized)
b6bee63b
LC
819 (name "guile2.2-colorized")
820 (native-inputs `(("guile" ,guile-2.2)))))
821
822(define-public guile3.0-colorized
823 (deprecated-package "guile3.0-colorized" guile-colorized))
fc870a0d 824
0791437f
RW
825(define-public guile-pfds
826 (package
827 (name "guile-pfds")
828 (version "0.3")
829 (home-page "https://github.com/ijp/pfds")
830 (source (origin
831 (method git-fetch)
832 (uri (git-reference
833 (url home-page)
834 (commit (string-append "v" version))))
835 (sha256
836 (base32
837 "19y33wg94pf0n98dkfqd1zbw93fgky4sawxsxl6s3vyqwl0yi5vh"))
838 (file-name (string-append name "-" version "-checkout"))))
839 (build-system guile-build-system)
840 (arguments
841 '(#:source-directory "src"
45231d17 842 #:compile-flags '("--r6rs" "-Wunbound-variable" "-Warity-mismatch")
0791437f
RW
843 #:phases (modify-phases %standard-phases
844 (add-after 'unpack 'move-files-around
845 (lambda _
846 ;; Move files under a pfds/ directory to reflect the
847 ;; module hierarchy.
848 (mkdir-p "src/pfds")
849 (for-each (lambda (file)
850 (rename-file file
45231d17 851 (string-append "src/pfds/" file)))
0791437f
RW
852 '("bbtrees.sls"
853 "deques"
854 "deques.sls"
855 "dlists.sls"
856 "fingertrees.sls"
857 "hamts.sls"
858 "heaps.sls"
859 "private"
860 "psqs.sls"
861 "queues"
862 "queues.sls"
863 "sequences.sls"
864 "sets.sls"))
0791437f
RW
865 #t)))))
866 (native-inputs
b6bee63b 867 `(("guile" ,guile-3.0)))
0791437f
RW
868 (synopsis "Purely functional data structures for Guile")
869 (description
870 "This package provides purely functional data structures written in R6RS
871Scheme and compiled for Guile. It has been tested with Racket, Guile 2,
872Vicare Scheme and IronScheme. Right now it contains:
873
874@itemize
875@item queues
876@item deques
877@item bbtrees
878@item sets
879@item dlists
880@item priority search queues (PSQs)
881@item finger trees
882@item sequences
883@item heaps
884@item hash array mapped tries (HAMTs).
885@end itemize\n")
886 (license license:bsd-3)))
887
15c3fe24 888(define-public guile-prometheus
3fdb01f1
CB
889 (let ((commit "f661edf72d2dd711dffe4313c2a9360e79b36dd1")
890 (revision "4"))
15c3fe24
CB
891 (package
892 (name "guile-prometheus")
893 (version (git-version "0" revision commit))
894 (source (origin
895 (method git-fetch)
896 (uri (git-reference
897 (url "https://git.cbaines.net/git/guile/prometheus")
898 (commit commit)))
899 (sha256
900 (base32
3fdb01f1 901 "1556rv3b72wxba7yz4nn681k2l8fp70dwx32whyyxg755ma4r76f"))
15c3fe24
CB
902 (file-name (string-append name "-" version "-checkout"))))
903 (build-system gnu-build-system)
904 (native-inputs
905 `(("pkg-config" ,pkg-config)
906 ("autoconf" ,autoconf)
b452f1b1
CB
907 ("automake" ,automake)
908 ("guile" ,guile-3.0)))
15c3fe24
CB
909 (inputs
910 `(("guile" ,guile-3.0)))
911 (home-page "https://git.cbaines.net/guile/prometheus")
912 (synopsis "Prometheus client library for Guile")
913 (description
914 "This Guile library provides instrumentation code intended to be used
915with the Prometheus time series service. Counter, gauge and histogram metric
916types are supported.")
917 (license license:gpl3+))))
918
b6bee63b 919(define-public guile2.2-pfds
77c95ee6
RW
920 (package
921 (inherit guile-pfds)
b6bee63b
LC
922 (name "guile2.2-pfds")
923 (native-inputs `(("guile" ,guile-2.2)))
77c95ee6 924 (arguments
0dd1e277
RW
925 (substitute-keyword-arguments (package-arguments guile-pfds)
926 ((#:phases phases)
927 `(modify-phases ,phases
45231d17
MB
928 (delete 'work-around-guile-bug)
929 (add-after 'move-files-around 'sls->scm
930 (lambda _
931 ;; In Guile <= 2.2.4, there's no way to tell 'guild
932 ;; compile' to accept the ".sls" extension. So...
933 (for-each (lambda (file)
934 (rename-file file
935 (string-append
936 (string-drop-right file 4)
937 ".scm")))
938 (find-files "." "\\.sls$"))
939 #t))))))))
b6bee63b
LC
940
941(define-public guile3.0-pfds
942 (deprecated-package "guile3.0-pfds" guile-pfds))
77c95ee6 943
0791437f
RW
944(define-public guile-aa-tree
945 (package
946 (name "guile-aa-tree")
947 (version "3.1.1")
948 (source (origin
949 (method url-fetch)
950 (uri (string-append "mirror://savannah/guile-aa-tree/guile-aa-tree-"
951 version ".tar.gz"))
952 (sha256
953 (base32
954 "0044c105r3q9vpl17pv3phl1b79kjm1llhkakqgiasixyav01blh"))))
955 (build-system guile-build-system)
956 (native-inputs `(("guile" ,guile-2.2)))
957 ;; https://savannah.nongnu.org/projects/guile-aa-tree
958 (home-page "https://qlfiles.net/guile-aa-tree/")
959 (synopsis "AA tree data structure for Guile")
960 (description
961 "This package provides an implementation of @dfn{AA trees}, a
962self-balancing binary tree data structure, for Guile. It ensure @math{O(log
963n)} worst case performance for core operations. The module provides
964non-mutating insert, delete, and search operations, with support for
965convenient nested tree operations.")
966 (license license:gpl3+)))
967
968(define-public guile-simple-zmq
2a173656
MO
969 (let ((commit "5fc3b7190d31c258ce969c2a5d2ad38c66a09d09")
970 (revision "4"))
0791437f
RW
971 (package
972 (name "guile-simple-zmq")
973 (version (git-version "0.0.0" revision commit))
974 (source
975 (origin
976 (method git-fetch)
977 (uri (git-reference
978 (url "https://github.com/jerry40/guile-simple-zmq")
979 (commit commit)))
980 (sha256
981 (base32
2a173656 982 "0inhvl5jssvbw3nd129wdahfwyvy1iciq403wzf0algbvl1fqs7z"))
0791437f
RW
983 (file-name (git-file-name name version))))
984 (build-system guile-build-system)
985 (arguments
986 `(#:source-directory "src"
987 #:phases (modify-phases %standard-phases
988 (add-after 'unpack 'set-libzmq-file-name
989 (lambda* (#:key inputs #:allow-other-keys)
990 (substitute* "src/simple-zmq.scm"
991 (("\\(dynamic-link \"libzmq\"\\)")
992 (format #f "(dynamic-link \"~a/lib/libzmq.so\")"
993 (assoc-ref inputs "zeromq"))))
994 #t)))))
995 (native-inputs
b6bee63b 996 `(("guile" ,guile-3.0)))
0791437f
RW
997 (inputs
998 `(("zeromq" ,zeromq)))
999 (home-page "https://github.com/jerry40/guile-simple-zmq")
1000 (synopsis "Guile wrapper over ZeroMQ library")
1001 (description
1002 "This package provides a Guile programming interface to the ZeroMQ
1003messaging library.")
1004 (license license:gpl3+))))
1005
b6bee63b 1006(define-public guile2.2-simple-zmq
015bb1c8
LC
1007 (package
1008 (inherit guile-simple-zmq)
b6bee63b
LC
1009 (name "guile2.2-simple-zmq")
1010 (native-inputs `(("guile" ,guile-2.2)))))
1011
1012(define-public guile3.0-simple-zmq
1013 (deprecated-package "guile3.0-simple-zmq" guile-simple-zmq))
015bb1c8 1014
0791437f 1015(define-public jupyter-guile-kernel
c984b70c
JG
1016 (let ((commit "f25fb90b95529b17a006a807bd04e6aee12ea304")
1017 (revision "2"))
0791437f
RW
1018 (package
1019 (name "jupyter-guile-kernel")
1020 (version (git-version "0.0.0" revision commit))
1021 (source
1022 (origin
1023 (method git-fetch)
1024 (uri (git-reference
1025 (url "https://github.com/jerry40/guile-kernel")
1026 (commit commit)))
f1d4d79f 1027 (file-name (git-file-name name version))
0791437f
RW
1028 (sha256
1029 (base32
c984b70c 1030 "0zr1fasdb2yv9kn21yll993y9higqss4jnfs030ndhjb93raa9sr"))))
0791437f
RW
1031 (build-system guile-build-system)
1032 (arguments
1033 '(#:phases (modify-phases %standard-phases
1034 (add-after 'unpack 'set-openssl-file-name
1035 (lambda* (#:key inputs #:allow-other-keys)
1036 ;; Record the absolute file name of the 'openssl'
1037 ;; command.
1038 (substitute* "src/hmac.scm"
1039 (("openssl")
1040 (string-append (assoc-ref inputs "openssl")
1041 "/bin/openssl")))
1042 #t))
1043
1044 ;; XXX: The code uses 'include' to include its own source
1045 ;; files, and "-L src" isn't enough in this case.
1046 (add-before 'build 'chdir
1047 (lambda _ (chdir "src") #t))
1048 (add-after 'build 'chdir-back
1049 (lambda _ (chdir "..") #t))
1050
1051 (add-after 'install 'install-kernel
1052 (lambda* (#:key inputs outputs #:allow-other-keys)
1053 (let* ((out (assoc-ref outputs "out"))
1054 (json (assoc-ref inputs "guile-json"))
1055 (zmq (assoc-ref inputs "guile-simple-zmq"))
1056 (deps (list json zmq))
1057 (dir (string-append
1058 out "/share/jupyter/kernels/guile"))
1059 (effective (target-guile-effective-version)))
1060 ;; Install kernel.
1061 (install-file "src/kernel.json" dir)
1062
1063 ;; Fix hard-coded file name in the kernel.
1064 (substitute* (string-append dir "/kernel.json")
c984b70c 1065 (("/usr/local/.*/guile-jupyter-kernel.scm")
0791437f
RW
1066 (string-append out "/share/guile/site/"
1067 (target-guile-effective-version)
1068 "/guile-jupyter-kernel.scm"))
1069 (("\"guile\"")
1070 (string-append "\"" (assoc-ref inputs "guile")
1071 "/bin/guile\""))
1072 (("-s")
1073 ;; Add '-L' and '-C' flags so that the kernel
1074 ;; finds its dependencies.
1075 (let ((-L (map (lambda (item)
1076 (string-append "\"" item
1077 "/share/guile/site/"
1078 effective "\""))
1079 deps))
1080 (-C (map (lambda (item)
1081 (string-append "\"" item
1082 "/lib/guile/"
1083 effective
1084 "/site-ccache\""))
1085 deps)))
c984b70c
JG
1086 (string-append "--no-auto-compile\""
1087 (string-join -L ", \"-L\", "
1088 'prefix)
1089 (string-join -C ", \"-C\", "
1090 'prefix)
1091 ", \"-s"))))
0791437f
RW
1092 #t))))))
1093 (inputs
1094 `(("openssl" ,openssl)
c984b70c
JG
1095 ("guile" ,guile-3.0)
1096 ("guile-json" ,guile-json-3)
0791437f
RW
1097 ("guile-simple-zmq" ,guile-simple-zmq)))
1098 (synopsis "Guile kernel for the Jupyter Notebook")
1099 (description
1100 "This package provides a Guile 2.x kernel for the Jupyter Notebook. It
1101allows users to interact with the Guile REPL through Jupyter.")
1102 (home-page "https://github.com/jerry40/guile-kernel")
1103 (license license:gpl3+))))
1104
1105(define-public guile-sparql
1106 (package
1107 (name "guile-sparql")
22213308 1108 (version "0.0.8")
0791437f
RW
1109 (source (origin
1110 (method url-fetch)
1111 (uri (string-append
1112 "https://github.com/roelj/guile-sparql/releases/download/"
1113 version "/guile-sparql-" version ".tar.gz"))
1114 (sha256
22213308 1115 (base32 "1jf4972f9fpm0rd865xpnc9mzl3xv6vhfnp0iygadydy905z9nln"))))
0791437f 1116 (build-system gnu-build-system)
0791437f
RW
1117 (native-inputs
1118 `(("pkg-config" ,pkg-config)))
1119 (inputs
22213308 1120 `(("guile" ,guile-3.0)))
0791437f
RW
1121 (home-page "https://github.com/roelj/guile-sparql")
1122 (synopsis "SPARQL module for Guile")
1123 (description "This package provides the functionality to query a SPARQL
1124endpoint. Additionally, it provides an interface to write SPARQL queries
1125using S-expressions.")
1126 (license license:gpl3+)))
1127
1128(define-public guile-debbugs
1129 (package
1130 (name "guile-debbugs")
5144f542 1131 (version "0.0.3")
0791437f
RW
1132 (source (origin
1133 (method url-fetch)
1134 (uri (string-append "mirror://gnu/guile-debbugs/guile-debbugs-"
1135 version ".tar.gz"))
1136 (sha256
1137 (base32
5144f542 1138 "1cc63nw3xdfjrfk8c58r6d5lidmfq5cpqcy32yd5xp81yccprvn9"))))
0791437f 1139 (build-system gnu-build-system)
5144f542
RW
1140 (propagated-inputs
1141 `(("guile-email" ,guile-email)))
0791437f 1142 (native-inputs
cd23eb06 1143 `(("guile" ,guile-3.0)
0791437f
RW
1144 ("pkg-config" ,pkg-config)))
1145 (home-page "https://savannah.gnu.org/projects/guile-debbugs/")
1146 (synopsis "Guile interface to the Debbugs bug tracking service")
1147 (description
1148 "This package provides a Guile library to communicate with a Debbugs bug
1149tracker's SOAP service, such as @url{https://bugs.gnu.org}.")
1150 (license license:gpl3+)))
1151
1152(define-public guile-email
50771f5b
AI
1153 (package
1154 (name "guile-email")
223cb7c6 1155 (version "0.2.2")
50771f5b
AI
1156 (source
1157 (origin
1158 (method url-fetch)
1159 (uri (string-append
db18d87a
AI
1160 "https://guile-email.systemreboot.net/releases/guile-email-"
1161 version ".tar.lz"))
50771f5b
AI
1162 (sha256
1163 (base32
223cb7c6 1164 "1rc8r0fgvflnyq5ckl7ii8sghpsgpkzxa8vskjr1ak2kyar6m35k"))))
50771f5b
AI
1165 (build-system gnu-build-system)
1166 (native-inputs
1167 `(("pkg-config" ,pkg-config)
db18d87a 1168 ("lzip" ,lzip)))
50771f5b 1169 (inputs
ca6c1509 1170 `(("guile" ,guile-3.0)))
db18d87a 1171 (arguments
2c33a849 1172 '(#:make-flags '("GUILE_AUTO_COMPILE=0"))) ; to prevent guild warnings
db18d87a 1173 (home-page "https://guile-email.systemreboot.net")
50771f5b 1174 (synopsis "Guile email parser")
db18d87a
AI
1175 (description "guile-email is a collection of email utilities implemented
1176in pure guile. It supports parsing MIME (Multipurpose Internet Mail
1177Extensions) compliant email messages and reading emails from the mbox
1178format.")
50771f5b 1179 (license license:agpl3+)))
0791437f 1180
8b3b1f34
RW
1181(define-public guile-email-latest
1182 (let ((commit "03e9cacb826bd4a56d3d834fe5526e497d7c57eb")
1183 (revision "1"))
1184 (package
1185 (inherit guile-email)
1186 (name "guile-email-latest")
1187 (version (git-version "0.2.2" revision commit))
1188 (source
1189 (origin
1190 (method git-fetch)
1191 (uri (git-reference
1192 (url "https://git.systemreboot.net/guile-email")
1193 (commit commit)))
1194 (file-name (git-file-name name version))
1195 (sha256
1196 (base32
1197 "1a15gdlbmzx220xg82fgyd0zk2wqn13ddmzs13nhgfzx8d5cns68"))))
1198 (native-inputs
1199 `(("pkg-config" ,pkg-config)
1200 ("autoconf" ,autoconf)
1201 ("automake" ,automake)
1202 ("texinfo" ,texinfo))))))
1203
ca6c1509 1204(define-public guile2.2-email
63a847cb
CB
1205 (package
1206 (inherit guile-email)
ca6c1509
LC
1207 (name "guile2.2-email")
1208 (inputs `(("guile" ,guile-2.2)
63a847cb
CB
1209 ,@(alist-delete "guile" (package-inputs guile-email))))))
1210
ca6c1509
LC
1211(define-public guile3.0-email
1212 (deprecated-package "guile3.0-email" guile-email))
1213
0791437f 1214(define-public guile-newt
442a11f6
MO
1215 (package
1216 (name "guile-newt")
f52c1f5f 1217 (version "0.0.2")
442a11f6
MO
1218 (source (origin
1219 (method git-fetch)
1220 (uri (git-reference
1221 (url "https://gitlab.com/mothacehe/guile-newt")
1222 (commit version)))
1223 (file-name (git-file-name name version))
1224 (sha256
1225 (base32
f52c1f5f 1226 "1gksd1lzgjjh1p9vczghg8jw995d22hm34kbsiv8rcryirv2xy09"))))
442a11f6
MO
1227 (build-system gnu-build-system)
1228 (arguments
1229 '(#:make-flags
1230 '("GUILE_AUTO_COMPILE=0"))) ;to prevent guild warnings
1231 (inputs
b6bee63b 1232 `(("guile" ,guile-3.0)
442a11f6
MO
1233 ("newt" ,newt)))
1234 (native-inputs
1235 `(("autoconf" ,autoconf)
1236 ("automake" ,automake)
1237 ("pkg-config" ,pkg-config)))
1238 (synopsis "Guile bindings to Newt")
1239 (description
1240 "This package provides bindings for Newt, a programming library for
0791437f
RW
1241color text mode, widget based user interfaces. The bindings are written in pure
1242Scheme by using Guile’s foreign function interface.")
442a11f6
MO
1243 (home-page "https://gitlab.com/mothacehe/guile-newt")
1244 (license license:gpl3+)))
0791437f 1245
b6bee63b 1246(define-public guile2.2-newt
e7fc7746
LC
1247 (package
1248 (inherit guile-newt)
b6bee63b 1249 (name "guile2.2-newt")
318e1a93 1250 (inputs `(("guile" ,guile-2.2)
e7fc7746
LC
1251 ,@(alist-delete "guile" (package-inputs guile-newt))))))
1252
b6bee63b
LC
1253(define-public guile3.0-newt
1254 (deprecated-package "guile3.0-newt" guile-newt))
1255
0791437f
RW
1256(define-public guile-mastodon
1257 (package
1258 (name "guile-mastodon")
1259 (version "0.0.1")
1260 (source (origin
1261 (method git-fetch)
1262 (uri (git-reference
1263 (url "https://framagit.org/prouby/guile-mastodon.git")
1264 (commit (string-append "v" version))))
1265 (file-name (git-file-name name version))
1266 (sha256
1267 (base32
1268 "1vblf3d1bbwna3l09p2ap5y8ycvl549bz6whgk78imyfmn28ygry"))))
1269 (build-system gnu-build-system)
1270 (native-inputs
1271 `(("autoconf" ,autoconf)
1272 ("automake" ,automake)
1273 ("pkg-config" ,pkg-config)))
1274 (inputs
1275 `(("guile" ,guile-2.2)
1276 ("gnutls" ,gnutls)
91f55717 1277 ("guile-json" ,guile-json-1)))
0791437f
RW
1278 (home-page "https://framagit.org/prouby/guile-mastodon")
1279 (synopsis "Guile Mastodon REST API module")
1280 (description "This package provides Guile modules to access the
1281@uref{https://docs.joinmastodon.org/api/, REST API of Mastodon}, a federated
1282microblogging service.")
1283 (license license:gpl3+)))
1284
0791437f 1285(define-public guile-parted
dbcd503c
MO
1286 (package
1287 (name "guile-parted")
575032c8 1288 (version "0.0.4")
dbcd503c
MO
1289 (source (origin
1290 (method git-fetch)
1291 (uri (git-reference
1292 (url "https://gitlab.com/mothacehe/guile-parted")
1293 (commit version)))
1294 (file-name (git-file-name name version))
1295 (sha256
1296 (base32
575032c8 1297 "0b7h8psfm9gmmwb65pp5zwzglvwnfmw5j40g09hhf3f7kwxc0mv2"))
f6145358 1298 (modules '((guix build utils)))))
dbcd503c
MO
1299 (build-system gnu-build-system)
1300 (arguments
1301 '(#:make-flags
1302 '("GUILE_AUTO_COMPILE=0"))) ;to prevent guild warnings
1303 (inputs
b6bee63b 1304 `(("guile" ,guile-3.0)
dbcd503c
MO
1305 ("parted" ,parted)))
1306 (propagated-inputs
1307 `(("guile-bytestructures" ,guile-bytestructures)))
1308 (native-inputs
1309 `(("autoconf" ,autoconf)
1310 ("automake" ,automake)
1311 ("pkg-config" ,pkg-config)))
1312 (synopsis "Guile bindings to GNU Parted")
1313 (description
1314 "This package provides bindings for GNU Parted library, a C library
1315allowing disk partition tables creation and manipulation. The bindings are
0791437f 1316written in pure Scheme by using Guile's foreign function interface.")
dbcd503c
MO
1317 (home-page "https://gitlab.com/mothacehe/guile-parted")
1318 (license license:gpl3+)))
0791437f 1319
b6bee63b 1320(define-public guile2.2-parted
e5b95558
LC
1321 (package
1322 (inherit guile-parted)
b6bee63b 1323 (name "guile2.2-parted")
318e1a93 1324 (inputs `(("guile" ,guile-2.2)
e5b95558
LC
1325 ,@(alist-delete "guile" (package-inputs guile-parted))))
1326 (propagated-inputs
b6bee63b
LC
1327 `(("guile-bytestructures" ,guile2.2-bytestructures)))))
1328
1329(define-public guile3.0-parted
1330 (deprecated-package "guile3.0-parted" guile-parted))
e5b95558 1331
0791437f
RW
1332(define-public guile-xosd
1333 (package
1334 (name "guile-xosd")
1335 (version "0.2.1")
1336 (source (origin
1337 (method url-fetch)
1338 (uri (string-append "https://github.com/alezost/" name
1339 "/releases/download/v" version
1340 "/" name "-" version ".tar.gz"))
1341 (sha256
1342 (base32
1343 "1ri5065c16kmgrf2pysn2ymxjqi5302lhpb07wkl1jr75ym8fn8p"))))
1344 (build-system gnu-build-system)
1345 (native-inputs
1346 `(("pkg-config" ,pkg-config)))
1347 (inputs
1348 `(("guile" ,guile-2.2)
1349 ("libx11" ,libx11)
1350 ("libxext" ,libxext)
1351 ("libxinerama" ,libxinerama)
1352 ("xosd" ,xosd)))
1353 (home-page "https://github.com/alezost/guile-xosd")
1354 (synopsis "XOSD bindings for Guile")
1355 (description
1356 "Guile-XOSD provides Guile bindings for @code{libxosd},
1357@uref{http://sourceforge.net/projects/libxosd/, the X On Screen Display
1358library}.")
1359 (license license:gpl3+)))
1360
1361(define-public guile-dbi
1362 (package
1363 (name "guile-dbi")
1364 (version "2.1.6")
1365 (source (origin
1366 (method url-fetch)
1367 (uri (string-append
1368 "http://download.gna.org/guile-dbi/guile-dbi-"
1369 version ".tar.gz"))
1370 (sha256
1371 (base32
1372 "116njrprhgrsv1qm904sp3b02rq01fx639r433d657gyhw3x159n"))))
1373 (build-system gnu-build-system)
1374 (arguments
1375 '(#:configure-flags
1376 (list (string-append
1377 "--with-guile-site-dir=" %output "/share/guile/site/2.2"))
1378 #:make-flags
406ef442
CB
1379 (list (string-append
1380 "LDFLAGS=-Wl,-rpath=" %output "/lib:"
1381 (assoc-ref %build-inputs "guile-dbd-sqlite3") "/lib" ":"
1382 (assoc-ref %build-inputs "guile-dbd-postgresql") "/lib"))
0791437f
RW
1383 #:phases
1384 (modify-phases %standard-phases
1385 (add-after 'install 'patch-extension-path
1386 (lambda* (#:key outputs #:allow-other-keys)
1387 (let* ((out (assoc-ref outputs "out"))
1388 (dbi.scm (string-append
1389 out "/share/guile/site/2.2/dbi/dbi.scm"))
1390 (ext (string-append out "/lib/libguile-dbi")))
1391 (substitute* dbi.scm (("libguile-dbi") ext))
1392 #t))))))
1393 (inputs
406ef442
CB
1394 `(("guile-dbd-sqlite3" ,guile-dbd-sqlite3)
1395 ("guile-dbd-postgresql" ,guile-dbd-postgresql))) ; only shared library, no scheme files
0791437f
RW
1396 (propagated-inputs
1397 `(("guile" ,guile-2.2)))
1398 (synopsis "Guile database abstraction layer")
1399 (home-page "http://home.gna.org/guile-dbi/guile-dbi.html")
1400 (description
1401 "guile-dbi is a library for Guile that provides a convenient interface to
1402SQL databases. Database programming with guile-dbi is generic in that the same
1403programming interface is presented regardless of which database system is used.
1404It currently supports MySQL, Postgres and SQLite3.")
1405 (license license:gpl2+)))
1406
1407(define guile-dbi-bootstrap
1408 (package
1409 (inherit guile-dbi)
1410 (name "guile-dbi-bootstrap")
1411 (inputs '())
1412 (arguments
1413 (substitute-keyword-arguments (package-arguments guile-dbi)
1414 ((#:make-flags _) '(list))))))
1415
1416(define-public guile-dbd-sqlite3
1417 (package
1418 (name "guile-dbd-sqlite3")
1419 (version "2.1.6")
1420 (source (origin
1421 (method url-fetch)
1422 (uri (string-append
1423 "http://download.gna.org/guile-dbi/guile-dbd-sqlite3-"
1424 version ".tar.gz"))
1425 (sha256
1426 (base32
1427 "0rg71jchxd2y8x496s8zmfmikr5g8zxi8zv2ar3f7a23pph92iw2"))))
1428 (build-system gnu-build-system)
1429 (native-inputs
1430 `(("pkg-config" ,pkg-config)
1431 ("guile-dbi-bootstrap" ,guile-dbi-bootstrap))) ; only required for headers
1432 (inputs
1433 `(("sqlite" ,sqlite)
1434 ("zlib" ,(@ (gnu packages compression) zlib))))
1435 (synopsis "Guile DBI driver for SQLite")
1436 (home-page "https://github.com/jkalbhenn/guile-dbd-sqlite3")
1437 (description
1438 "guile-dbi is a library for Guile that provides a convenient interface to
1439SQL databases. This package implements the interface for SQLite.")
1440 (license license:gpl2+)))
1441
406ef442
CB
1442(define-public guile-dbd-postgresql
1443 (let ((commit "e97589b6b018b206c901e4cc24db463407a4036b")
1444 (revision 0))
1445 (package
1446 (name "guile-dbd-postgresql")
1447 (version (string-append
1448 "2.1.6-" (number->string revision) "." (string-take commit 7)))
1449 (source
1450 (origin
1451 (method git-fetch)
1452 (uri (git-reference
b0e7b699 1453 (url "https://github.com/opencog/guile-dbi")
406ef442
CB
1454 (commit commit)))
1455 (file-name (git-file-name name version))
1456 (sha256
1457 (base32 "0n1gv9a0kdys10a4qmnrwvg5sydwb03880asri4gqdchcj3fimni"))))
1458 (build-system gnu-build-system)
1459 (arguments
1460 '(#:phases
1461 (modify-phases %standard-phases
1462 (add-after 'unpack 'chdir
1463 (lambda _
1464 ;; The upstream Git repository contains all the code, so change
1465 ;; to the relevant directory.
1466 (chdir "guile-dbd-postgresql")
1467 #t))
1468 (add-after 'chdir 'patch-src/Makefile.am
1469 (lambda* (#:key inputs #:allow-other-keys)
1470 (substitute* "src/Makefile.am"
1471 (("/usr/include")
1472 (string-append (assoc-ref inputs "postgresql") "/include")))
1473 #t))
1474 (add-after 'patch-src/Makefile.am 'patch-src
1475 (lambda _
1476 (substitute* "src/guile-dbd-postgresql.c"
1477 (("postgresql/libpq-fe\\.h") "libpq-fe.h"))
1478 #t)))))
1479 (native-inputs
1480 `(("pkg-config" ,pkg-config)
1481 ("automake" ,automake)
1482 ("autoconf" ,autoconf)
1483 ("perl" ,perl)
1484 ("libtool" ,libtool)
1485 ("guile-dbi-bootstrap" ,guile-dbi-bootstrap)))
1486 (inputs
1487 `(("postgresql" ,postgresql)
1488 ("zlib" ,zlib)))
1489 (synopsis "Guile DBI driver for PostgreSQL")
1490 (home-page
1491 "https://github.com/opencog/guile-dbi/tree/master/guile-dbd-postgresql")
1492 (description
1493 "@code{guile-dbi} is a library for Guile that provides a convenient
1494interface to SQL databases. This package implements the interface for
1495PostgreSQL.")
1496 (license license:gpl2+))))
1497
0791437f
RW
1498(define-public guile-config
1499 (package
1500 (name "guile-config")
aed0d0fd 1501 (version "0.4.2")
0791437f
RW
1502 (source
1503 (origin
1504 (method git-fetch)
1505 (uri (git-reference
1506 (url "https://gitlab.com/a-sassmannshausen/guile-config")
529d1d96 1507 (commit version)))
91e29547
AS
1508 (file-name (git-file-name name version))
1509 (sha256 (base32
aed0d0fd 1510 "09028ylbddjdp3d67zdjz3pnsjqz6zs2bfck5rr3dfaa0qjap40n"))))
0791437f
RW
1511 (build-system gnu-build-system)
1512 (native-inputs
1513 `(("autoconf" ,autoconf)
1514 ("automake" ,automake)
1515 ("pkg-config" ,pkg-config)
1516 ("texinfo" ,texinfo)))
b6bee63b 1517 (inputs `(("guile" ,guile-3.0)))
0791437f
RW
1518 (synopsis
1519 "Guile application configuration parsing library.")
1520 (description
1521 "Guile Config is a library providing a declarative approach to
1522application configuration specification. The library provides clean
1523configuration declaration forms, and processors that take care of:
1524configuration file creation; configuration file parsing; command-line
1525parameter parsing using getopt-long; basic GNU command-line parameter
1526generation (--help, --usage, --version); automatic output generation for the
1527above command-line parameters.")
1528 (home-page
1529 "https://gitlab.com/a-sassmannshausen/guile-config")
1530 (license license:gpl3+)))
1531
b6bee63b 1532(define-public guile2.2-config
0ac6b836
AS
1533 (package
1534 (inherit guile-config)
b6bee63b
LC
1535 (name "guile2.2-config")
1536 (inputs `(("guile" ,guile-2.2)
0ac6b836
AS
1537 ,@(alist-delete "guile" (package-inputs guile-config))))))
1538
b6bee63b
LC
1539(define-public guile3.0-config
1540 (deprecated-package "guile3.0-config" guile-config))
1541
0791437f
RW
1542(define-public guile-hall
1543 (package
1544 (name "guile-hall")
63fe1dc0 1545 (version "0.3.1")
0791437f 1546 (source
feb11b08
RW
1547 (origin
1548 (method git-fetch)
1549 (uri (git-reference
1550 (url "https://gitlab.com/a-sassmannshausen/guile-hall")
a3dfe052 1551 (commit version)))
63fe1dc0 1552 (file-name "guile-hall-0.3.1-checkout")
a3dfe052 1553 (sha256
63fe1dc0 1554 (base32 "1s24nigdra6rvclvy15l2aw00c3aq9vv8qwxylzs60darbl36206"))))
0791437f
RW
1555 (build-system gnu-build-system)
1556 (arguments
63bf0afd
AS
1557 `(#:modules
1558 ((ice-9 match)
1559 (ice-9 ftw)
1560 ,@%gnu-build-system-modules)
1561 #:phases
1562 (modify-phases
1563 %standard-phases
1564 (add-after 'install 'hall-wrap-binaries
1565 (lambda* (#:key inputs outputs #:allow-other-keys)
1566 (let* ((compiled-dir
1567 (lambda (out version)
1568 (string-append
1569 out "/lib/guile/" version "/site-ccache")))
1570 (uncompiled-dir
1571 (lambda (out version)
1572 (string-append
1573 out "/share/guile/site"
1574 (if (string-null? version) "" "/") version)))
1575 (dep-path
1576 (lambda (env modules path)
1577 (list env ":" 'prefix
1578 (cons modules
1579 (map (lambda (input)
1580 (string-append
1581 (assoc-ref inputs input)
1582 path))
1583 ,''("guile-config"))))))
1584 (out (assoc-ref outputs "out"))
1585 (bin (string-append out "/bin/"))
1586 (site (uncompiled-dir out "")))
1587 (match (scandir site)
1588 (("." ".." version)
1589 (for-each
1590 (lambda (file)
1591 (wrap-program
1592 (string-append bin file)
1593 (dep-path
1594 "GUILE_LOAD_PATH"
1595 (uncompiled-dir out version)
1596 (uncompiled-dir "" version))
1597 (dep-path
1598 "GUILE_LOAD_COMPILED_PATH"
1599 (compiled-dir out version)
1600 (compiled-dir "" version))))
1601 ,''("hall"))
1602 #t))))))))
0791437f 1603 (native-inputs
63bf0afd
AS
1604 `(("autoconf" ,autoconf)
1605 ("automake" ,automake)
1606 ("pkg-config" ,pkg-config)
1607 ("texinfo" ,texinfo)))
b6bee63b 1608 (inputs `(("guile" ,guile-3.0)))
0791437f 1609 (propagated-inputs
3c3e6620 1610 `(("guile-config" ,guile-config)))
0791437f
RW
1611 (synopsis "Guile project tooling")
1612 (description
3c3e6620
RW
1613 "Hall is a command-line application and a set of Guile libraries that
1614allow you to quickly create and publish Guile projects. It allows you to
1615transparently support the GNU build system, manage a project hierarchy &
1616provides tight coupling to Guix.")
1617 (home-page "https://gitlab.com/a-sassmannshausen/guile-hall")
06085fac 1618 (license license:gpl3+)))
0791437f 1619
b6bee63b 1620(define-public guile2.2-hall
df18ea6f
AS
1621 (package
1622 (inherit guile-hall)
b6bee63b
LC
1623 (name "guile2.2-hall")
1624 (inputs `(("guile" ,guile-2.2)
df18ea6f
AS
1625 ,@(alist-delete "guile" (package-inputs guile-hall))))
1626 (propagated-inputs
b6bee63b 1627 `(("guile-config" ,guile2.2-config)
df18ea6f
AS
1628 ,@(alist-delete "guile-config"
1629 (package-propagated-inputs guile-hall))))))
1630
b6bee63b
LC
1631(define-public guile3.0-hall
1632 (deprecated-package "guile3.0-hall" guile-hall))
1633
0791437f
RW
1634(define-public guile-ics
1635 (package
1636 (name "guile-ics")
1637 (version "0.2.0")
1638 (source (origin
1639 (method git-fetch)
1640 (uri (git-reference
1641 (url "https://github.com/artyom-poptsov/guile-ics")
1642 (commit (string-append "v" version))))
1643 (file-name (string-append name "-" version "-checkout"))
1644 (sha256
1645 (base32
6713589d
LC
1646 "0qjjvadr7gibdq9jvwkmlkb4afsw9n2shfj9phpiadinxk3p4m2g"))
1647 (modules '((guix build utils)))
1648 (snippet
1649 '(begin
1650 ;; Allow builds with Guile 3.0.
1651 (substitute* "configure.ac"
1652 (("^GUILE_PKG.*")
1653 "GUILE_PKG([3.0 2.2 2.0])\n"))
1654 #t))))
0791437f
RW
1655 (build-system gnu-build-system)
1656 (native-inputs
1657 `(("autoconf" ,autoconf-wrapper)
1658 ("automake" ,automake)
1659 ("texinfo" ,texinfo)
1660 ;; Gettext brings 'AC_LIB_LINKFLAGS_FROM_LIBS'.
1661 ("gettext" ,gettext-minimal)
1662 ("pkg-config" ,pkg-config)))
b6bee63b 1663 (inputs `(("guile" ,guile-3.0) ("which" ,which)))
0791437f
RW
1664 (propagated-inputs `(("guile-lib" ,guile-lib)))
1665 (home-page "https://github.com/artyom-poptsov/guile-ics")
1666 (synopsis "Guile parser library for the iCalendar format")
1667 (description
1668 "Guile-ICS is an iCalendar (RFC5545) format parser library written in
1669pure Scheme. The library can be used to read and write iCalendar data.
1670
1671The library is shipped with documentation in Info format and usage examples.")
1672 (license license:gpl3+)))
1673
b6bee63b 1674(define-public guile2.2-ics
6713589d
LC
1675 (package
1676 (inherit guile-ics)
b6bee63b
LC
1677 (name "guile2.2-ics")
1678 (inputs `(("guile" ,guile-2.2)
6713589d 1679 ,@(alist-delete "guile" (package-inputs guile-ics))))
b6bee63b
LC
1680 (propagated-inputs `(("guile-lib" ,guile2.2-lib)))))
1681
1682(define-public guile3.0-ics
1683 (deprecated-package "guile3.0-ics" guile-ics))
6713589d 1684
0791437f
RW
1685(define-public guile-wisp
1686 (package
1687 (name "guile-wisp")
8b030edf 1688 (version "1.0.3")
0791437f 1689 (source (origin
8b030edf
AB
1690 (method hg-fetch)
1691 (uri (hg-reference
1692 (url "https://hg.sr.ht/~arnebab/wisp")
1693 (changeset (string-append "v" version))))
1694 (file-name (git-file-name name version))
0791437f
RW
1695 (sha256
1696 (base32
8b030edf 1697 "10g97jz3ahpb5mg933ajsc3pa9jxlg14f42yf01qwx0dwq1b06d5"))))
0791437f
RW
1698 (build-system gnu-build-system)
1699 (arguments
1700 `(#:modules ((guix build gnu-build-system)
15218d4e 1701 ((guix build emacs-build-system) #:prefix emacs:)
0791437f 1702 (guix build utils)
15218d4e 1703 (guix build emacs-utils)
0791437f
RW
1704 (ice-9 rdelim)
1705 (ice-9 popen))
15218d4e
RW
1706 #:imported-modules (,@%gnu-build-system-modules
1707 (guix build emacs-build-system)
1708 (guix build emacs-utils))
0791437f
RW
1709 #:phases
1710 (modify-phases %standard-phases
8b030edf 1711 (replace 'bootstrap
b6bee63b 1712 (lambda _
8b030edf 1713 (invoke "autoreconf" "-vif")
b6bee63b 1714 #t))
0791437f
RW
1715 (add-before 'configure 'patch-/usr/bin/env
1716 (lambda _
1717 (substitute* "Makefile.in"
65610f73 1718 (("/usr/bin/env bash") (which "bash")))
0791437f
RW
1719 #t))
1720 ;; auto compilation breaks, but if we set HOME to /tmp,
1721 ;; that works ok
1722 (add-before 'check 'auto-compile-hacky-workaround
1723 (lambda _ (setenv "HOME" "/tmp") #t))
1724 (add-after 'install 'install-go-files
1725 (lambda* (#:key outputs inputs #:allow-other-keys)
1726 (let* ((out (assoc-ref outputs "out"))
1727 (effective (read-line
1728 (open-pipe* OPEN_READ
1729 "guile" "-c"
1730 "(display (effective-version))")))
1731 (module-dir (string-append out "/share/guile/site/"
1732 effective))
1733 (object-dir (string-append out "/lib/guile/" effective
1734 "/site-ccache"))
1735 (prefix (string-length module-dir)))
1736 ;; compile to the destination
1737 (for-each (lambda (file)
1738 (let* ((base (string-drop (string-drop-right file 4)
1739 prefix))
1740 (go (string-append object-dir base ".go")))
1741 (invoke "guild" "compile" "-L" module-dir
1742 file "-o" go)))
1743 (find-files module-dir "\\.scm$"))
15218d4e
RW
1744 #t)))
1745 (add-after 'install 'install-emacs-files
1746 (assoc-ref emacs:%standard-phases 'install))
1747 (add-after 'install-emacs-files 'compile-emacs-files
1748 (assoc-ref emacs:%standard-phases 'build))
1749 (add-after 'compile-emacs-files 'make-autoloads
1750 (assoc-ref emacs:%standard-phases 'make-autoloads)))))
17f90b67 1751 (home-page "https://www.draketo.de/english/wisp")
0791437f 1752 (inputs
b6bee63b 1753 `(("guile" ,guile-3.0)))
0791437f 1754 (native-inputs
8b030edf
AB
1755 `(("autoconf" ,autoconf)
1756 ("automake" ,automake)
1757 ("emacs" ,emacs-minimal)
15218d4e 1758 ("python" ,python)
0791437f
RW
1759 ("pkg-config" ,pkg-config)))
1760 (synopsis "Whitespace to lisp syntax for Guile")
1761 (description "Wisp is a syntax for Guile which provides a Python-like
1762whitespace-significant language. It may be easier on the eyes for some
1763users and in some situations.")
1764 (license license:gpl3+)))
1765
b6bee63b 1766(define-public guile2.2-wisp
b0b725ed
RW
1767 (package
1768 (inherit guile-wisp)
b6bee63b
LC
1769 (name "guile2.2-wisp")
1770 (inputs `(("guile" ,guile-2.2)))))
1771
1772(define-public guile3.0-wisp
1773 (deprecated-package "guile3.0-wisp" guile-wisp))
b0b725ed 1774
0791437f
RW
1775(define-public guile-sly
1776 (package
1777 (name "guile-sly")
1778 (version "0.1")
1779 (source (origin
1780 (method url-fetch)
1781 (uri (string-append "https://files.dthompson.us/sly/sly-"
1782 version ".tar.gz"))
1783 (sha256
1784 (base32
1785 "1svzlbz2vripmyq2kjh0rig16bsrnbkwbsm558pjln9l65mcl4qq"))
1786 (modules '((guix build utils)))
1787 (snippet
1788 '(begin
1789 (substitute* "configure"
1790 (("_guile_required_version=\"2.0.11\"")
1791 "_guile_required_version=\"2\"")
1792 (("ac_subst_vars='")
1793 "ac_subst_vars='GUILE_EFFECTIVE_VERSION\n"))
1794 (substitute* (find-files "." "Makefile.in")
1795 (("moddir = .*$")
1796 (string-append
1797 "moddir = "
1798 "$(prefix)/share/guile/site/@GUILE_EFFECTIVE_VERSION@\n"))
1799 (("godir = .*$")
1800 (string-append
1801 "godir = "
1802 "$(prefix)/lib/guile/@GUILE_EFFECTIVE_VERSION@/site-ccache\n")))
1803 #t))))
1804 (build-system gnu-build-system)
1805 (arguments
1806 '(#:configure-flags
1807 (list (string-append "--with-libfreeimage-prefix="
1808 (assoc-ref %build-inputs "freeimage"))
1809 (string-append "--with-libgslcblas-prefix="
1810 (assoc-ref %build-inputs "gsl")))))
1811 (native-inputs
1812 `(("pkg-config" ,pkg-config)))
1813 (propagated-inputs
1814 `(("guile-sdl" ,guile-sdl)
1815 ("guile-opengl" ,guile-opengl)))
1816 (inputs
1817 `(("guile" ,guile-2.2)
1818 ("gsl" ,gsl)
1819 ("freeimage" ,freeimage)
1820 ("mesa" ,mesa)))
1821 (synopsis "2D/3D game engine for GNU Guile")
1822 (description "Sly is a 2D/3D game engine written in Guile Scheme. Sly
1823features a functional reactive programming interface and live coding
1824capabilities.")
1825 (home-page "https://dthompson.us/projects/sly.html")
1826 (license license:gpl3+)))
1827
dfe277a5 1828(define-public g-golf
f2d36d4f
MR
1829 (let ((commit "ef830107b9765bd6a2da848d0cbe45e11374c0b5")
1830 (revision "839"))
dfe277a5
VS
1831 (package
1832 (name "g-golf")
30d59b31
MR
1833 (version (git-version "0.1.0" revision commit))
1834 (source
1835 (origin
1836 (method git-fetch)
1837 (uri (git-reference
1838 (url "https://git.savannah.gnu.org/git/g-golf.git")
1839 (commit commit)))
1840 (file-name (git-file-name name version))
1841 (sha256
f2d36d4f 1842 (base32 "0r472hvmf447kqvkahp1wy4irb5gy8y793hm8r9rc511smdx66cw"))))
dfe277a5
VS
1843 (build-system gnu-build-system)
1844 (native-inputs
1845 `(("autoconf" ,autoconf)
1846 ("automake" ,automake)
1847 ("texinfo" ,texinfo)
1848 ("gettext" ,gettext-minimal)
1849 ("libtool" ,libtool)
85fcceee
MR
1850 ("pkg-config" ,pkg-config)
1851 ("xorg-server" ,xorg-server)))
dfe277a5
VS
1852 (inputs
1853 `(("guile" ,guile-2.2)
85fcceee 1854 ("guile-lib" ,guile2.2-lib)
dfe277a5
VS
1855 ("clutter" ,clutter)
1856 ("gtk" ,gtk+)
1857 ("glib" ,glib)))
1858 (propagated-inputs
1859 `(("gobject-introspection" ,gobject-introspection)))
1860 (arguments
1861 `(#:phases
1862 (modify-phases %standard-phases
1863 (add-before 'configure 'tests-work-arounds
1864 (lambda* (#:key inputs #:allow-other-keys)
1865 ;; In build environment, There is no /dev/tty
1866 (substitute*
1867 "test-suite/tests/gobject.scm"
1868 (("/dev/tty") "/dev/null"))))
1869 (add-before 'configure 'substitute-libs
1870 (lambda* (#:key inputs outputs #:allow-other-keys)
1871 (let* ((get (lambda (key lib)
1872 (string-append (assoc-ref inputs key) "/lib/" lib)))
1873 (libgi (get "gobject-introspection" "libgirepository-1.0"))
1874 (libglib (get "glib" "libglib-2.0"))
1875 (libgobject (get "glib" "libgobject-2.0"))
1876 (libgdk (get "gtk" "libgdk-3")))
1877 (substitute* "configure"
1878 (("SITEDIR=\"\\$datadir/g-golf\"")
1879 "SITEDIR=\"$datadir/guile/site/$GUILE_EFFECTIVE_VERSION\"")
1880 (("SITECCACHEDIR=\"\\$libdir/g-golf/")
1881 "SITECCACHEDIR=\"$libdir/"))
1882 (substitute* "g-golf/init.scm"
1883 (("libgirepository-1.0") libgi)
1884 (("libglib-2.0") libglib)
1885 (("libgdk-3") libgdk)
1886 (("libgobject-2.0") libgobject)
1887 (("\\(dynamic-link \"libg-golf\"\\)")
1888 (format #f "~s"
1889 `(dynamic-link
1890 (format #f "~alibg-golf"
1891 (if (getenv "GUILE_GGOLF_UNINSTALLED")
1892 ""
1893 ,(format #f "~a/lib/"
1894 (assoc-ref outputs "out"))))))))
1895 (setenv "GUILE_AUTO_COMPILE" "0")
1896 (setenv "GUILE_GGOLF_UNINSTALLED" "1")
85fcceee
MR
1897 #t)))
1898 (add-before 'check 'start-xorg-server
1899 (lambda* (#:key inputs #:allow-other-keys)
1900 ;; The test suite requires a running X server.
1901 (system (format #f "~a/bin/Xvfb :1 &"
1902 (assoc-ref inputs "xorg-server")))
1903 (setenv "DISPLAY" ":1")
1904 #t)))))
dfe277a5
VS
1905 (home-page "https://www.gnu.org/software/g-golf/")
1906 (synopsis "Guile bindings for GObject Introspection")
1907 (description
1908 "G-Golf (Gnome: (Guile Object Library for)) is a library for developing
1909modern applications in Guile Scheme. It comprises a direct binding to the
1910GObject Introspection API and higher-level functionality for importing Gnome
1911libraries and making GObject classes (and methods) available in Guile's
1912object-oriented programming system, GOOPS.")
1913 (license license:lgpl3+))))
1914
0791437f
RW
1915(define-public g-wrap
1916 (package
1917 (name "g-wrap")
1918 (version "1.9.15")
1919 (source (origin
1920 (method url-fetch)
1921 (uri (string-append "mirror://savannah/g-wrap/g-wrap-"
1922 version ".tar.gz"))
1923 (sha256
1924 (base32
1925 "0ak0bha37dfpj9kmyw1r8fj8nva639aw5xr66wr5gd3l1rqf5xhg"))))
1926 (build-system gnu-build-system)
1927 (native-inputs
1928 `(("pkg-config" ,pkg-config)))
1929 (propagated-inputs
1930 `(("guile" ,guile-2.2)
1931 ("guile-lib" ,guile-lib)))
1932 (inputs
1933 `(("libffi" ,libffi)))
1934 (arguments
1935 `(#:configure-flags '("--disable-Werror")
1936 #:phases
1937 (modify-phases %standard-phases
1938 (add-before 'configure 'pre-configure
1939 (lambda* (#:key outputs #:allow-other-keys)
1940 (let ((out (assoc-ref outputs "out")))
1941 (substitute* (find-files "." "^Makefile.in$")
1942 (("guilemoduledir =.*guile/site" all)
1943 (string-append all "/@GUILE_EFFECTIVE_VERSION@")))
1944 #t))))))
1945 (synopsis "Generate C bindings for Guile")
1946 (description "G-Wrap is a tool and Guile library for generating function
1947wrappers for inter-language calls. It currently only supports generating Guile
1948wrappers for C functions. Given a definition of the types and prototypes for
1949a given C interface, G-Wrap will automatically generate the C code that
1950provides access to that interface and its types from the Scheme level.")
1951 (home-page "https://www.nongnu.org/g-wrap/index.html")
1952 (license license:lgpl2.1+)))
1953
1954(define-public guile-miniadapton
1955 (let ((commit "1b5749422304567c96ac5367f2221dda9eff5880")
1956 (revision "1"))
1957 (package
1958 (name "guile-miniadapton")
1959 (version (string-append "0-" revision "." (string-take commit 9)))
1960 (source (origin
1961 (method git-fetch)
1962 (uri (git-reference
b0e7b699 1963 (url "https://github.com/fisherdj/miniAdapton")
0791437f
RW
1964 (commit commit)))
1965 (file-name (string-append name "-" version "-checkout"))
1966 (sha256
1967 (base32
1968 "09q51zkw2fypad5xixskfzw2cjhjgs5cswdp3i7cpp651rb3zndh"))))
1969 (build-system guile-build-system)
1970 (native-inputs
1971 `(("guile" ,guile-2.2)))
1972 (home-page "https://github.com/fisherdj/miniAdapton")
1973 (synopsis "Minimal implementation of incremental computation in Guile
1974Scheme")
1975 (description "This package provides a complete Scheme implementation of
1976miniAdapton, which implements the core functionality of the Adapton system for
1977incremental computation (also known as self-adjusting computation). Like
1978Adapton, miniAdapton allows programmers to safely combine mutation and
1979memoization. miniAdapton is built on top of an even simpler system,
1980microAdapton. Both miniAdapton and microAdapton are designed to be easy to
1981understand, extend, and port to host languages other than Scheme.")
1982 (license license:expat))))
1983
1984(define-public guile-reader
1985 (package
1986 (name "guile-reader")
a7c69419 1987 (version "0.6.3")
0791437f
RW
1988 (source (origin
1989 (method url-fetch)
1990 (uri (string-append "mirror://savannah/guile-reader/guile-reader-"
1991 version ".tar.gz"))
1992 (sha256
1993 (base32
a7c69419 1994 "1fyjckmygkhq22lq8nqc86yl5zzbqd7a944dnz5c1f6vx92b9hiq"))))
0791437f
RW
1995 (build-system gnu-build-system)
1996 (native-inputs `(("pkgconfig" ,pkg-config)
a7c69419 1997 ("gperf" ,gperf)))
c20e697e 1998 (inputs `(("guile" ,guile-3.0)))
0791437f
RW
1999 (synopsis "Framework for building readers for GNU Guile")
2000 (description
2001 "Guile-Reader is a simple framework for building readers for GNU Guile.
2002
2003The idea is to make it easy to build procedures that extend Guile’s read
2004procedure. Readers supporting various syntax variants can easily be written,
2005possibly by re-using existing “token readers” of a standard Scheme
2006readers. For example, it is used to implement Skribilo’s R5RS-derived
2007document syntax.
2008
2009Guile-Reader’s approach is similar to Common Lisp’s “read table”, but
2010hopefully more powerful and flexible (for instance, one may instantiate as
2011many readers as needed).")
2012 (home-page "https://www.nongnu.org/guile-reader/")
2013 (license license:gpl3+)))
2014
c20e697e
LC
2015(define-public guile2.2-reader
2016 (package
2017 (inherit guile-reader)
2018 (name "guile2.2-reader")
2019 (inputs `(("guile" ,guile-2.2)))))
2020
0791437f
RW
2021(define-public guile-ncurses
2022 (package
2023 (name "guile-ncurses")
2b155e3a 2024 (version "3.0")
0791437f
RW
2025 (source (origin
2026 (method url-fetch)
2027 (uri (string-append "mirror://gnu/guile-ncurses/guile-ncurses-"
2028 version ".tar.gz"))
2029 (sha256
2030 (base32
2b155e3a 2031 "038xbffalhymg26lvmzgf7ljilxz2f2zmqg5r5nfzbipfbprwjhf"))))
0791437f
RW
2032 (build-system gnu-build-system)
2033 (inputs `(("ncurses" ,ncurses)
b01a73b0 2034 ("guile" ,guile-3.0)))
0791437f
RW
2035 (native-inputs `(("pkg-config" ,pkg-config)))
2036 (arguments
3c566eba
MB
2037 `(#:modules ((guix build gnu-build-system)
2038 ((guix build guile-build-system)
2039 #:select (target-guile-effective-version))
2040 (guix build utils))
2041 #:imported-modules ((guix build guile-build-system)
2042 ,@%gnu-build-system-modules)
2043 #:configure-flags (list "--with-ncursesw" ; Unicode support
0791437f
RW
2044 "--with-gnu-filesystem-hierarchy")
2045 #:phases
2046 (modify-phases %standard-phases
2047 (add-before 'build 'fix-libguile-ncurses-file-name
2048 (lambda* (#:key outputs #:allow-other-keys)
2049 (invoke "make" "install"
2050 "-C" "src/ncurses"
2051 "-j" (number->string
2052 (parallel-job-count)))
2053 (let* ((out (assoc-ref outputs "out"))
2054 (dir "src/ncurses")
2055 (files (find-files dir ".scm")))
2056 (substitute* files
2057 (("\"libguile-ncurses\"")
3c566eba
MB
2058 (format #f "\"~a/lib/guile/~a/libguile-ncurses\""
2059 out (target-guile-effective-version))))
0791437f
RW
2060 #t))))))
2061 (home-page "https://www.gnu.org/software/guile-ncurses/")
2062 (synopsis "Guile bindings to ncurses")
2063 (description
2064 "guile-ncurses provides Guile language bindings for the ncurses
2065library.")
2066 (license license:lgpl3+)))
2067
b01a73b0 2068(define-public guile2.2-ncurses
3c566eba
MB
2069 (package
2070 (inherit guile-ncurses)
b01a73b0 2071 (name "guile2.2-ncurses")
3c566eba 2072 (inputs `(("ncurses" ,ncurses)
b01a73b0
RW
2073 ("guile" ,guile-2.2)))))
2074
2075(define-public guile3.0-ncurses
2076 (deprecated-package "guile3.0-ncurses" guile-ncurses))
3c566eba 2077
0791437f
RW
2078(define-public guile-ncurses/gpm
2079 (package
2080 (inherit guile-ncurses)
2081 (name "guile-ncurses-with-gpm")
2082 (inputs `(("ncurses" ,ncurses/gpm)
2083 ("guile" ,guile-2.2)))))
2084
87001355
MB
2085(define-public guile3.0-ncurses/gpm
2086 (package
2087 (inherit guile3.0-ncurses)
2088 (name "guile3.0-ncurses-with-gpm")
2089 (inputs `(("ncurses" ,ncurses/gpm)
2090 ("guile" ,guile-3.0)))))
2091
0791437f
RW
2092(define-public guile-lib
2093 (package
2094 (name "guile-lib")
2095 (version "0.2.6.1")
2096 (source (origin
2097 (method url-fetch)
2098 (uri (string-append "mirror://savannah/guile-lib/guile-lib-"
2099 version ".tar.gz"))
2100 (sha256
2101 (base32
675f1940
LC
2102 "0aizxdif5dpch9cvs8zz5g8ds5s4xhfnwza2il5ji7fv2h7ks7bd"))
2103 (modules '((guix build utils)))
2104 (snippet
2105 '(begin
2106 ;; Work around miscompilation on Guile 3.0.0 at -O2:
2107 ;; <https://bugs.gnu.org/39251>.
2108 (substitute* "src/md5.scm"
2109 (("\\(define f-ash ash\\)")
2110 "(define f-ash (@ (guile) ash))\n")
2111 (("\\(define f-add \\+\\)")
2112 "(define f-add (@ (guile) +))\n"))
2113 #t))))
0791437f
RW
2114 (build-system gnu-build-system)
2115 (arguments
2116 '(#:make-flags
2117 '("GUILE_AUTO_COMPILE=0") ; to prevent guild errors
2118 #:phases
2119 (modify-phases %standard-phases
2120 (add-before 'configure 'patch-module-dir
2121 (lambda _
2122 (substitute* "src/Makefile.in"
2123 (("^moddir = ([[:graph:]]+)")
2124 "moddir = $(datadir)/guile/site/@GUILE_EFFECTIVE_VERSION@\n")
2125 (("^godir = ([[:graph:]]+)")
2126 "godir = \
2127$(libdir)/guile/@GUILE_EFFECTIVE_VERSION@/site-ccache\n"))
2128 #t)))))
7306c679
CB
2129 (native-inputs
2130 `(("guile" ,guile-3.0)
2131 ("pkg-config" ,pkg-config)))
2132 (inputs
2133 `(("guile" ,guile-3.0)))
0791437f
RW
2134 (home-page "https://www.nongnu.org/guile-lib/")
2135 (synopsis "Collection of useful Guile Scheme modules")
2136 (description
2137 "Guile-Lib is intended as an accumulation place for pure-scheme Guile
2138modules, allowing for people to cooperate integrating their generic Guile
2139modules into a coherent library. Think \"a down-scaled, limited-scope CPAN
2140for Guile\".")
2141
2142 ;; The whole is under GPLv3+, but some modules are under laxer
2143 ;; distribution terms such as LGPL and public domain. See `COPYING' for
2144 ;; details.
2145 (license license:gpl3+)))
2146
2147(define-public guile2.0-lib
2148 (package
2149 (inherit guile-lib)
2150 (name "guile2.0-lib")
7306c679 2151 (native-inputs `(("pkg-config" ,pkg-config)))
0791437f
RW
2152 (inputs `(("guile" ,guile-2.0)))))
2153
b6bee63b 2154(define-public guile2.2-lib
675f1940
LC
2155 (package
2156 (inherit guile-lib)
b6bee63b 2157 (name "guile2.2-lib")
7306c679 2158 (native-inputs `(("pkg-config" ,pkg-config)))
b6bee63b
LC
2159 (inputs `(("guile" ,guile-2.2)))))
2160
2161(define-public guile3.0-lib
2162 (deprecated-package "guile3.0-lib" guile-lib))
675f1940 2163
0791437f
RW
2164(define-public guile-minikanren
2165 (package
2166 (name "guile-minikanren")
2167 (version "20150424.e844d85")
2168 (source (origin
2169 (method git-fetch)
2170 (uri (git-reference
b0e7b699 2171 (url "https://github.com/ijp/minikanren")
0791437f
RW
2172 (commit "e844d85512f8c055d3f96143ee506007389a25e3")))
2173 (file-name (string-append name "-" version "-checkout"))
2174 (sha256
2175 (base32
2176 "0r50jlpzi940jlmxyy3ddqqwmj5r12gb4bcv0ssini9v8km13xz6"))))
2177 (build-system guile-build-system)
2178 (native-inputs
b6bee63b 2179 `(("guile" ,guile-3.0)))
0791437f
RW
2180 (home-page "https://github.com/ijp/minikanren")
2181 (synopsis "MiniKanren declarative logic system, packaged for Guile")
2182 (description
2183 "MiniKanren is a relational programming extension to the Scheme
2184programming Language, written as a smaller version of Kanren suitable for
2185pedagogical purposes. It is featured in the book, The Reasoned Schemer,
2186written by Dan Friedman, William Byrd, and Oleg Kiselyov.
2187
2188This is Ian Price's r6rs packaged version of miniKanren, which deviates
2189slightly from miniKanren mainline.
2190
2191See http://minikanren.org/ for more on miniKanren generally.")
2192 (license license:expat)))
2193
2194(define-public guile2.0-minikanren
2195 (package
2196 (inherit guile-minikanren)
2197 (name "guile2.0-minikanren")
2198 (native-inputs `(("guile" ,guile-2.0)))))
2199
b6bee63b 2200(define-public guile2.2-minikanren
89a99d53
LC
2201 (package
2202 (inherit guile-minikanren)
b6bee63b
LC
2203 (name "guile2.2-minikanren")
2204 (native-inputs `(("guile" ,guile-2.2)))))
2205
2206(define-public guile3.0-minikanren
2207 (deprecated-package "guile3.0-minikanren" guile-minikanren))
89a99d53 2208
0791437f
RW
2209(define-public guile-irregex
2210 (package
2211 (name "guile-irregex")
2212 (version "0.9.6")
2213 (source (origin
2214 (method url-fetch)
2215 (uri (string-append
2216 "http://synthcode.com/scheme/irregex/irregex-"
2217 version ".tar.gz"))
2218 (sha256
2219 (base32
2220 "1ia3m7dp3lcxa048q0gqbiwwsyvn99baw6xkhb4bhhzn4k7bwyqq"))))
2221 (build-system guile-build-system)
2222 (arguments
2223 '(#:phases (modify-phases %standard-phases
2224 (add-after 'unpack 'move-files-around
2225 (lambda _
2226 ;; Move the relevant source files to src/ and create the
2227 ;; rx/ directory to match the expected module hierarchy.
2228 (mkdir-p "src/rx/source")
2229 (rename-file "irregex-guile.scm"
2230 "src/rx/irregex.scm")
2231 (rename-file "irregex.scm"
2232 "src/rx/source/irregex.scm")
2233 ;; Not really reachable via guile's packaging system,
2234 ;; but nice to have around.
2235 (rename-file "irregex-utils.scm"
2236 "src/rx/source/irregex-utils.scm")
2237 #t)))
2238 #:source-directory "src"))
2239 (native-inputs
b6bee63b 2240 `(("guile" ,guile-3.0)))
0791437f
RW
2241 (home-page "http://synthcode.com/scheme/irregex")
2242 (synopsis "S-expression based regular expressions")
2243 (description
2244 "Irregex is an s-expression based alternative to your classic
2245string-based regular expressions. It implements SRFI 115 and is deeply
2246inspired by the SCSH regular expression system.")
2247 (license license:bsd-3)))
2248
2249(define-public guile2.0-irregex
2250 (package
2251 (inherit guile-irregex)
2252 (name "guile2.0-irregex")
2253 (native-inputs `(("guile" ,guile-2.0)))))
2254
b6bee63b 2255(define-public guile2.2-irregex
89a99d53
LC
2256 (package
2257 (inherit guile-irregex)
b6bee63b
LC
2258 (name "guile2.2-irregex")
2259 (native-inputs `(("guile" ,guile-2.2)))))
2260
2261(define-public guile3.0-irregex
2262 (deprecated-package "guile3.0-irregex" guile-irregex))
89a99d53 2263
0791437f
RW
2264(define-public haunt
2265 (package
2266 (name "haunt")
2267 (version "0.2.4")
2268 (source (origin
2269 (method url-fetch)
2270 (uri (string-append "https://files.dthompson.us/haunt/haunt-"
2271 version ".tar.gz"))
2272 (sha256
2273 (base32
93d94134
LC
2274 "056z4znikk83nr5mr0x2ac3iinqbywa2bvb37mhr566a1q50isfc"))
2275 (modules '((guix build utils)))
2276 (snippet
2277 '(begin
2278 ;; Allow builds with Guile 3.0.
2279 (substitute* "configure"
2280 (("2\\.2 2\\.0")
2281 "3.0 2.2 2.0"))
2282 #t))))
0791437f
RW
2283 (build-system gnu-build-system)
2284 (arguments
2285 `(#:modules ((ice-9 match) (ice-9 ftw)
2286 ,@%gnu-build-system-modules)
2287 #:tests? #f ; test suite is non-deterministic :(
2288 #:phases (modify-phases %standard-phases
2289 (add-after 'install 'wrap-haunt
2290 (lambda* (#:key inputs outputs #:allow-other-keys)
2291 ;; Wrap the 'haunt' command to refer to the right
2292 ;; modules.
2293 (let* ((out (assoc-ref outputs "out"))
2294 (bin (string-append out "/bin"))
2295 (site (string-append
2296 out "/share/guile/site"))
93d94134
LC
2297 (guile-reader (assoc-ref inputs "guile-reader"))
2298 (deps `(,@(if guile-reader
2299 (list guile-reader)
2300 '())
2301 ,(assoc-ref inputs "guile-commonmark"))))
0791437f
RW
2302 (match (scandir site)
2303 (("." ".." version)
2304 (let ((modules (string-append site "/" version))
2305 (compiled-modules (string-append
2306 out "/lib/guile/" version
2307 "/site-ccache")))
2308 (wrap-program (string-append bin "/haunt")
2309 `("GUILE_LOAD_PATH" ":" prefix
2310 (,modules
2311 ,@(map (lambda (dep)
2312 (string-append dep
2313 "/share/guile/site/"
2314 version))
2315 deps)))
2316 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
2317 (,compiled-modules
2318 ,@(map (lambda (dep)
2319 (string-append dep "/lib/guile/"
2320 version
2321 "/site-ccache"))
2322 deps))))
2323 #t)))))))))
2324 (native-inputs
2325 `(("pkg-config" ,pkg-config)
2326 ("texinfo" ,texinfo)))
2327 (inputs
b6bee63b 2328 `(("guile" ,guile-3.0)))
0791437f 2329 (propagated-inputs
c20e697e 2330 `(("guile-reader" ,guile-reader)
0791437f
RW
2331 ("guile-commonmark" ,guile-commonmark)))
2332 (synopsis "Functional static site generator")
2333 (description "Haunt is a static site generator written in Guile
2334Scheme. Haunt features a functional build system and an extensible
2335interface for reading articles in any format.")
5d3bcfef 2336 (home-page "https://dthompson.us/projects/haunt.html")
0791437f
RW
2337 (license license:gpl3+)))
2338
b6bee63b 2339(define-public guile2.2-haunt
93d94134
LC
2340 (package
2341 (inherit haunt)
b6bee63b
LC
2342 (name "guile2.2-haunt")
2343 (inputs `(("guile" ,guile-2.2)))
93d94134 2344 (propagated-inputs
c20e697e 2345 `(("guile-reader" ,guile2.2-reader)
b6bee63b 2346 ("guile-commonmark" ,guile2.2-commonmark)))))
93d94134 2347
0791437f
RW
2348(define-public guile2.0-haunt
2349 (package
2350 (inherit haunt)
2351 (name "guile2.0-haunt")
2352 (inputs `(("guile" ,guile-2.0)))))
2353
b6bee63b
LC
2354(define-public guile3.0-haunt
2355 (deprecated-package "guile3.0-haunt" haunt))
2356
0791437f
RW
2357(define-public guile-redis
2358 (package
2359 (name "guile-redis")
f57bf15c 2360 (version "1.3.0")
0791437f
RW
2361 (home-page "https://github.com/aconchillo/guile-redis")
2362 (source (origin
29fde3bf
EF
2363 (method git-fetch)
2364 (uri (git-reference
2365 (url home-page)
2366 (commit version)))
2367 (file-name (git-file-name name version))
0791437f
RW
2368 (sha256
2369 (base32
29fde3bf 2370 "14izs8daxh7pb7vwpxi5g427qa31137jkaxrb1cy5rpjkwchy723"))))
0791437f
RW
2371 (build-system gnu-build-system)
2372 (native-inputs
2373 `(("autoconf" ,autoconf)
2374 ("automake" ,automake)
2375 ("pkg-config" ,pkg-config)
24e38f24 2376 ("guile" ,guile-3.0)))
0791437f
RW
2377 (synopsis "Redis client library for Guile")
2378 (description "Guile-redis provides a Scheme interface to the Redis
2379key-value cache and store.")
2380 (license license:lgpl3+)))
2381
24e38f24
RW
2382(define-public guile2.2-redis
2383 (package
2384 (inherit guile-redis)
2385 (name "guile2.2-redis")
2386 (native-inputs `(("guile" ,guile-2.2)
2387 ,@(alist-delete "guile"
2388 (package-native-inputs guile-redis))))))
2389
0791437f
RW
2390(define-public guile2.0-redis
2391 (package
2392 (inherit guile-redis)
2393 (name "guile2.0-redis")
2394 (native-inputs `(("guile" ,guile-2.0)
2395 ,@(alist-delete "guile"
2396 (package-native-inputs guile-redis))))))
2397
0791437f
RW
2398(define-public guile-commonmark
2399 (package
2400 (name "guile-commonmark")
b552e307 2401 (version "0.1.2")
0791437f
RW
2402 (source (origin
2403 (method url-fetch)
2404 (uri (string-append "https://github.com/OrangeShark/" name
2405 "/releases/download/v" version
2406 "/" name "-" version ".tar.gz"))
2407 (sha256
2408 (base32
1fa34232
LC
2409 "17lrsdisa3kckh24q114vfmzdc4wkqa6ccwl4hdlrng5wpn1iman"))
2410 (modules '((guix build utils)))
2411 (snippet
2412 '(begin
2413 ;; Allow builds with Guile 3.0.
2414 (substitute* "configure"
2415 (("2\\.2 2\\.0")
2416 "3.0 2.2 2.0"))
2417 #t))))
0791437f
RW
2418 (build-system gnu-build-system)
2419 (inputs
b6bee63b 2420 `(("guile" ,guile-3.0)))
0791437f
RW
2421 (native-inputs
2422 `(("pkg-config" ,pkg-config)))
2423 (synopsis "CommonMark parser for Guile")
2424 (description
2425 "guile-commonmark is a library for parsing CommonMark, a fully specified
2426variant of Markdown. The library is written in Guile Scheme and is designed
2427to transform a CommonMark document to SXML. guile-commonmark tries to closely
2428follow the @uref{http://commonmark.org/, CommonMark spec}, the main difference
2429is no support for parsing block and inline level HTML.")
2430 (home-page "https://github.com/OrangeShark/guile-commonmark")
2431 (license license:lgpl3+)))
2432
b6bee63b 2433(define-public guile2.2-commonmark
1fa34232
LC
2434 (package
2435 (inherit guile-commonmark)
b6bee63b
LC
2436 (name "guile2.2-commonmark")
2437 (inputs `(("guile" ,guile-2.2)))))
1fa34232 2438
0791437f
RW
2439(define-public guile2.0-commonmark
2440 (package
2441 (inherit guile-commonmark)
2442 (name "guile2.0-commonmark")
2443 (inputs `(("guile" ,guile-2.0)))))
2444
b6bee63b
LC
2445(define-public guile3.0-commonmark
2446 (deprecated-package "guile3.0-commonmark" guile-commonmark))
2447
0791437f
RW
2448(define-public mcron
2449 (package
2450 (name "mcron")
8b3b1988 2451 (version "1.2.0")
0791437f
RW
2452 (source (origin
2453 (method url-fetch)
2454 (uri (string-append "mirror://gnu/mcron/mcron-"
2455 version ".tar.gz"))
2456 (sha256
2457 (base32
8b3b1988 2458 "1midrn15d5kqy4zd2029bj1db6gnfhxg8mcgfy4bkp5p9nl4v4rd"))))
0791437f
RW
2459 (build-system gnu-build-system)
2460 (arguments
2461 '(#:phases (modify-phases %standard-phases
0791437f
RW
2462 (add-before 'check 'adjust-tests
2463 (lambda _
2464 (substitute* "tests/job-specifier.scm"
2465 ;; (getpw) fails with "entry not found" in the build
2466 ;; environment, so pass an argument.
2467 (("\\(getpw\\)")
2468 "(getpwnam (getuid))")
2469 ;; The build environment lacks an entry for root in
2470 ;; /etc/passwd.
2471 (("\\(getpw 0\\)")
2472 "(getpwnam \"nobody\")")
2473
2474 ;; FIXME: Skip the 4 faulty tests (see above).
2475 (("\\(test-equal \"next-year\"" all)
2476 (string-append "(test-skip 4)\n" all)))
2477 #t)))))
30ebff69 2478 (native-inputs `(("pkg-config" ,pkg-config)
bbd9c9c9
LC
2479 ("tzdata" ,tzdata-for-tests)
2480 ("guile-native" ;for 'guild compile'
2481 ,@(assoc-ref (package-inputs this-package) "guile"))))
b6bee63b 2482 (inputs `(("guile" ,guile-3.0)))
0791437f
RW
2483 (home-page "https://www.gnu.org/software/mcron/")
2484 (synopsis "Run jobs at scheduled times")
2485 (description
2486 "GNU Mcron is a complete replacement for Vixie cron. It is used to run
2487tasks on a schedule, such as every hour or every Monday. Mcron is written in
2488Guile, so its configuration can be written in Scheme; the original cron
2489format is also supported.")
2490 (license license:gpl3+)))
2491
b6bee63b 2492(define-public guile2.2-mcron
3de0d20b
LC
2493 (package
2494 (inherit mcron)
b6bee63b
LC
2495 (name "guile2.2-mcron")
2496 (inputs `(("guile" ,guile-2.2)))))
2497
2498(define-public guile3.0-mcron
2499 (deprecated-package "guile3.0-mcron" mcron))
3de0d20b 2500
6bb5f88e 2501(define-public guile-picture-language
d1a3a8e1
RW
2502 (let ((commit "91d10c96708d732145006dd2802acc4de08b632e")
2503 (revision "1"))
6bb5f88e
RW
2504 (package
2505 (name "guile-picture-language")
d1a3a8e1 2506 (version (git-version "0.0.1" revision commit))
6bb5f88e
RW
2507 (source (origin
2508 (method git-fetch)
2509 (uri (git-reference
2510 (url "https://git.elephly.net/software/guile-picture-language.git")
2511 (commit commit)))
f1d4d79f 2512 (file-name (git-file-name name version))
6bb5f88e
RW
2513 (sha256
2514 (base32
d1a3a8e1
RW
2515 "1ydvw9dvssdvlvhh1dr8inyzy2x6m41qgp8hsivca1xysr4gc23a"))))
2516 (build-system gnu-build-system)
6bb5f88e 2517 (inputs
b6bee63b 2518 `(("guile" ,guile-3.0)))
d1a3a8e1
RW
2519 (native-inputs
2520 `(("autoconf" ,autoconf)
2521 ("automake" ,automake)
2522 ("imagemagick" ,imagemagick)
2523 ("pkg-config" ,pkg-config)
2524 ("texinfo" ,texinfo)))
6bb5f88e
RW
2525 (home-page "https://git.elephly.net/software/guile-picture-language.git")
2526 (synopsis "Picture language for Guile")
2527 (description
2528 "This package provides a simple SVG-based picture language for Guile.
2529The picture values can directly be displayed in Geiser.")
2530 (license license:lgpl3+))))
5531782d 2531
b6bee63b 2532(define-public guile2.2-picture-language
4f408684
LC
2533 (package
2534 (inherit guile-picture-language)
b6bee63b
LC
2535 (name "guile2.2-picture-language")
2536 (inputs `(("guile" ,guile-2.2)))))
2537
2538(define-public guile3.0-picture-language
2539 (deprecated-package "guile3.0-picture-language"
2540 guile-picture-language))
4f408684 2541
5531782d 2542(define-public guile-studio
0e7731ba 2543 (let ((commit "5c05b03e8a5c450f7358ceec7ea602f29c49d54e")
c6607797
RW
2544 (revision "1"))
2545 (package
2546 (name "guile-studio")
0e7731ba 2547 (version (git-version "0.0.3" revision commit))
c6607797
RW
2548 (source (origin
2549 (method git-fetch)
2550 (uri (git-reference
2551 (url "https://git.elephly.net/software/guile-studio.git")
2552 (commit commit)))
2553 (file-name (git-file-name name version))
2554 (sha256
2555 (base32
0e7731ba 2556 "11wyf6x7mhyhimv0cd57pl39zgav9hc9ljqi3g2g35b264hylpnx"))))
c6607797
RW
2557 (build-system gnu-build-system)
2558 (arguments
2559 `(#:modules
2560 ((ice-9 match)
2561 (srfi srfi-1)
2562 ,@%gnu-build-system-modules)
2563 #:tests? #f ; there are none
2564 #:make-flags
2565 (list (string-append "ICONS_DIR="
2566 (assoc-ref %build-inputs "adwaita-icon-theme")
2567 "/share/icons/Adwaita/")
2568 (string-append "PICT_DIR="
2569 (assoc-ref %build-inputs "guile-picture-language"))
2570 (string-append "EMACS_DIR="
2571 (assoc-ref %build-inputs "emacs"))
2572 (string-append "GUILE_DIR="
2573 (assoc-ref %build-inputs "guile"))
2574 (string-join (cons "INPUTS="
2575 (filter-map
2576 (lambda (input)
2577 (match input
2578 ((label . pkg)
2579 (and (string-prefix? "emacs" label) pkg))))
2580 %build-inputs)))
2581 (string-append "PREFIX=" (assoc-ref %outputs "out")))
2582 #:phases
2583 (modify-phases %standard-phases
2584 (delete 'configure)
2585 (delete 'install))))
2586 (inputs
2587 `(("guile" ,guile-3.0)
2588 ("guile-picture-language" ,guile-picture-language)
2589 ("emacs" ,emacs)
2590 ("emacs-geiser" ,emacs-geiser)
2591 ("emacs-company" ,emacs-company)
2592 ("emacs-flycheck" ,emacs-flycheck)
0e7731ba 2593 ("emacs-flycheck-guile" ,emacs-flycheck-guile)
c6607797
RW
2594 ("emacs-smart-mode-line" ,emacs-smart-mode-line)
2595 ("emacs-paren-face" ,emacs-paren-face)
2596 ("adwaita-icon-theme" ,adwaita-icon-theme)))
2597 (native-inputs
2598 `(("texinfo" ,texinfo)))
2599 (home-page "https://gnu.org/software/guile")
2600 (synopsis "IDE for Guile")
2601 (description
2602 "This is Emacs with a few settings that make working with Guile easier
5531782d
RW
2603for people new to Emacs. Features include: CUA mode, Geiser, tool bar icons
2604to evaluate Guile buffers, support for Guile's very own picture language, code
2605completion, a simple mode line, etc.")
c6607797 2606 (license license:gpl3+))))
9f8698ad
RW
2607
2608(define-public guile-stis-parser
3a71dac0
MB
2609 (package
2610 (name "guile-stis-parser")
2611 (version "1.2.4.1")
2612 (source (origin
2613 (method git-fetch)
2614 (uri (git-reference
2615 (url "https://gitlab.com/tampe/stis-parser")
2616 (commit (string-append "v" version))))
2617 (file-name (git-file-name name version))
2618 (sha256
2619 (base32
2620 "1fvxdfvc80zqhwzq5x3kxyr6j8p4b51yx85fx1gr3d4gy2ddpx5w"))))
2621 (build-system gnu-build-system)
2622 (arguments
2623 `(#:parallel-build? #f ; not supported
2624 #:phases
2625 (modify-phases %standard-phases
2626 (add-after 'unpack 'chdir
2627 (lambda _ (chdir "modules") #t))
2628 (add-after 'chdir 'delete-broken-symlink
2629 (lambda _
2630 (delete-file "parser/stis-parser/lang/.#calc.scm")
2631 #t)))))
2632 (inputs
2633 `(("guile" ,guile-3.0)))
2634 (native-inputs
2635 `(("autoconf" ,autoconf)
2636 ("automake" ,automake)
2637 ("pkg-config" ,pkg-config)))
2638 (home-page "https://gitlab.com/tampe/stis-parser")
2639 (synopsis "Parser combinator framework")
2640 (description
2641 "This package provides a functional parser combinator library that
9f8698ad
RW
2642supports backtracking and a small logical framework. The idea is to build up
2643chunks that are memoized and there is no clear scanner/parser separation,
2644chunks can be expressions as well as simple tokens.")
3a71dac0 2645 (license license:lgpl2.0+)))
12d73f9c
RW
2646
2647(define-public guile-persist
09f0bc87
MB
2648 (package
2649 (name "guile-persist")
2650 (version "1.2.3")
2651 (source (origin
2652 (method git-fetch)
2653 (uri (git-reference
2654 (url "https://gitlab.com/tampe/guile-persist")
2655 (commit (string-append "v" version))))
2656 (file-name (git-file-name name version))
2657 (sha256
2658 (base32
2659 "19f8hqcax4v40858kx2j8fy1cvzc2djj99r0n17dy1xxmwa097qi"))))
2660 (build-system gnu-build-system)
2661 (arguments
2662 `(#:phases
2663 (modify-phases %standard-phases
2664 (add-after 'unpack 'patch-prefix
2665 (lambda* (#:key inputs outputs #:allow-other-keys)
2666 (substitute* "src/Makefile.am"
2667 (("/usr/local/lib/guile")
2668 (string-append (assoc-ref outputs "out") "/lib/guile"))
2669 (("/usr/local/include/guile")
2670 (string-append (assoc-ref inputs "guile") "/include/guile"))
2671 (("-L/usr/local/lib")
2672 (string-append "-L" (assoc-ref inputs "guile") "/lib")))
2673 #t))
2674 (add-after 'unpack 'patch-library-reference
2675 (lambda* (#:key outputs #:allow-other-keys)
2676 (let ((out (assoc-ref outputs "out")))
2677 (substitute* "persist/persistance.scm"
2678 (("\"libguile-persist\"")
2679 (format #f "\"~a/lib/guile/3.0/extensions/libguile-persist\"" out)))
2680 #t))))))
2681 (inputs
2682 `(("guile" ,guile-3.0)))
2683 (native-inputs
2684 `(("autoconf" ,autoconf)
2685 ("automake" ,automake)
2686 ("libtool" ,libtool)
2687 ("pkg-config" ,pkg-config)))
2688 (home-page "https://gitlab.com/tampe/guile-persist")
2689 (synopsis "Persistence programming framework for Guile")
2690 (description
2691 "This is a serialization library for serializing objects like classes
12d73f9c
RW
2692and objects, closures and structs. This currently does not support
2693serializing continuations or delimited continuations.")
09f0bc87 2694 (license license:lgpl2.0+)))
6d37301b
RW
2695
2696(define-public python-on-guile
ac944584
MB
2697 (package
2698 (name "python-on-guile")
cdf6a118 2699 (version "1.2.3.5")
ac944584
MB
2700 (home-page "https://gitlab.com/python-on-guile/python-on-guile")
2701 (source (origin
2702 (method git-fetch)
2703 (uri (git-reference (url home-page)
2704 (commit (string-append "v" version))))
2705 (file-name (git-file-name name version))
2706 (sha256
2707 (base32
cdf6a118 2708 "05xrvcj6a4gzq1ybyin270qz8wamgc7w2skyi9iy6hkpgdhxy8vf"))))
ac944584
MB
2709 (build-system gnu-build-system)
2710 (arguments
2711 `(#:parallel-build? #f ;not supported
2712 #:make-flags '("GUILE_AUTO_COMPILE=0") ;to prevent guild warnings
2713 #:phases
2714 (modify-phases %standard-phases
2715 (add-after 'unpack 'chdir
2716 (lambda _ (chdir "modules") #t))
2717 (add-after 'chdir 'augment-GUILE_LOAD_PATH
2718 (lambda _
2719 ;; TODO: It would be better to patch the Makefile.
2720 (setenv "GUILE_LOAD_PATH"
2721 (string-append ".:"
2722 (getenv "GUILE_LOAD_PATH")))
2723 #t))
2724 (add-after 'install 'wrap
2725 (lambda* (#:key outputs #:allow-other-keys)
2726 ;; Wrap the 'python' executable so it can find its
862d6a91
MB
2727 ;; dependencies and own modules.
2728 (let* ((out (assoc-ref outputs "out"))
2729 (guile-version ,(version-major+minor
2730 (package-version guile-3.0)))
2731 (scm (string-append out "/share/guile/site/"
2732 guile-version))
2733 (ccache (string-append out "/lib/guile/" guile-version
2734 "/site-ccache"))
2735 (load-path (string-join
2736 (cons scm
2737 ;; XXX: cdr because we augment it above.
2738 (cdr (string-split
2739 (getenv "GUILE_LOAD_PATH") #\:)))
2740 ":"))
2741 (compiled-path (string-append
2742 ccache ":"
2743 (getenv "GUILE_LOAD_COMPILED_PATH"))))
ac944584
MB
2744 (wrap-program (string-append out "/bin/python")
2745 `("GUILE_LOAD_PATH" ":" prefix
862d6a91 2746 (,load-path))
ac944584 2747 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
862d6a91 2748 (,compiled-path)))
ac944584
MB
2749 #t))))))
2750 (inputs
4f33bf57
MB
2751 `(("guile" ,guile-3.0)
2752 ("guile-persist" ,guile-persist)
ac944584
MB
2753 ("guile-readline" ,guile-readline)
2754 ("guile-stis-parser" ,guile-stis-parser)))
2755 (native-inputs
2756 `(("autoconf" ,autoconf)
2757 ("automake" ,automake)
2758 ("libtool" ,libtool)
2759 ("pkg-config" ,pkg-config)))
2760 (synopsis "Python implementation in Guile")
2761 (description
2762 "This package allows you to compile a Guile Python file to any target
6d37301b 2763from @code{tree-il}.")
ac944584 2764 (license license:lgpl2.0+)))
b97b4624
RW
2765
2766(define-public guile-file-names
2767 (package
2768 (name "guile-file-names")
72a0706f 2769 (version "0.3")
b97b4624
RW
2770 (source (origin
2771 (method url-fetch)
2772 (uri (string-append "http://brandon.invergo.net/software/download/"
2773 "guile-file-names/guile-file-names-"
2774 version ".tar.gz"))
2775 (sha256
2776 (base32
72a0706f 2777 "01chizdxkhw6aqv629vxka9f5x3534ij7r0jqndawsg2vxm1r9sz"))))
b97b4624
RW
2778 (build-system gnu-build-system)
2779 (arguments
2780 `(#:phases
2781 (modify-phases %standard-phases
481eca80 2782 (add-after 'unpack 'fix-target-directory
b97b4624 2783 (lambda _
481eca80 2784 (substitute* "src/Makefile.in"
b97b4624
RW
2785 (("guilemoddir = \\$\\(GUILE_SITE\\)")
2786 "guilemoddir = $(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
2787 #t)))))
2788 (inputs
2789 `(("guile" ,guile-2.2)))
2790 (native-inputs
2791 `(("pkg-config" ,pkg-config)))
2792 (home-page "https://gitlab.com/brandoninvergo/guile-file-names")
2793 (synopsis "Manipulate file names")
2794 (description
2795 "The @code{(file-names)} module provides tools for manipulating file
2796names. The module was built on the idea that doing anything more than a
2797non-trivial modification of a file name string is a pain (making sure all
2798slashes are present and accounted for, resolving @code{.} and @code{..}, etc).
2799Inevitably, you have to break the string up into chunks and operate on that
2800list of components. This module takes care of that for you.")
2801 (license license:lgpl3+)))
bdf2dd79
JN
2802
2803(define-public guile-gi
bb6c8f20
RW
2804 (package
2805 (name "guile-gi")
c67db509 2806 (version "0.3.0")
bb6c8f20
RW
2807 (source (origin
2808 (method url-fetch)
2809 (uri (string-append "http://lonelycactus.com/tarball/guile_gi-"
2810 version ".tar.gz"))
2811 (sha256
2812 (base32
c67db509 2813 "05xbwrk50h4f9fh8la8fk2wsxbnm0jcyb9phnpkkjq4sqkhkxlbj"))))
e4ef0d7c 2814 (build-system glib-or-gtk-build-system)
bb6c8f20 2815 (arguments
b5d4d5b9 2816 `(#:configure-flags '("--with-gnu-filesystem-hierarchy")
e4ef0d7c 2817 #:modules ((guix build glib-or-gtk-build-system)
a431a635
RW
2818 (guix build utils)
2819 (ice-9 popen)
2820 (ice-9 rdelim))
b5d4d5b9
RW
2821 #:phases
2822 (modify-phases %standard-phases
a431a635
RW
2823 (add-after 'unpack 'patch-references-to-extension
2824 (lambda* (#:key outputs #:allow-other-keys)
2825 (let ((effective (read-line
2826 (open-pipe* OPEN_READ
2827 "guile" "-c"
2828 "(display (effective-version))"))))
2829 (substitute* '("module/gi.scm"
2830 "module/gi/oop.scm"
2831 "module/gi/documentation.scm"
2832 "module/gi/types.scm"
2833 "module/gi/repository.scm")
2834 (("\\(load-extension \"libguile-gi\" \"(.*)\"\\)" m arg)
2835 (format #f "~s"
2836 `(load-extension
2837 (format #f "~alibguile-gi"
2838 (if (getenv "GUILE_GI_UNINSTALLED")
2839 ""
e4ef0d7c 2840 ,(format #f "~a/lib/guile/~a/extensions/"
a431a635
RW
2841 (assoc-ref outputs "out")
2842 effective)))
2843 ,arg)))))
2844 (setenv "GUILE_GI_UNINSTALLED" "1")
2845 #t))
b5d4d5b9
RW
2846 (add-before 'check 'start-xorg-server
2847 (lambda* (#:key inputs #:allow-other-keys)
2848 ;; The init_check test requires a running X server.
2849 (system (format #f "~a/bin/Xvfb :1 &"
2850 (assoc-ref inputs "xorg-server")))
2851 (setenv "DISPLAY" ":1")
2852 #t)))))
bb6c8f20 2853 (native-inputs
f2d97d57 2854 `(("gettext" ,gettext-minimal)
6153fa0a 2855 ("glib:bin" ,glib "bin") ; for glib-compile-resources
bb6c8f20 2856 ("libtool" ,libtool)
b5d4d5b9
RW
2857 ("pkg-config" ,pkg-config)
2858 ("xorg-server" ,xorg-server)))
bb6c8f20
RW
2859 (propagated-inputs
2860 `(("glib" ,glib)
2861 ("gobject-introspection" ,gobject-introspection)
2862 ("gssettings-desktop-schemas" ,gsettings-desktop-schemas)
2863 ("gtk+" ,gtk+)
2864 ("guile-lib" ,guile-lib)
2865 ("webkitgtk" ,webkitgtk)))
b6bee63b 2866 (inputs `(("guile" ,guile-3.0)))
bb6c8f20
RW
2867 (home-page "https://github.com/spk121/guile-gi")
2868 (synopsis "GObject bindings for Guile")
2869 (description
2870 "Guile-GI is a library for Guile that allows using GObject-based
bdf2dd79
JN
2871libraries, such as GTK+3. Its README comes with the disclaimer: This is
2872pre-alpha code.")
bb6c8f20 2873 (license license:gpl3+)))
dec4b3aa 2874
b6bee63b 2875(define-public guile2.2-gi
bfb51f5e
RW
2876 (package
2877 (inherit guile-gi)
b6bee63b 2878 (name "guile2.2-gi")
3d633a1e 2879 (inputs
b6bee63b 2880 `(("guile" ,guile-2.2)
3d633a1e 2881 ,@(alist-delete "guile" (package-inputs guile-gi))))))
bfb51f5e 2882
b6bee63b
LC
2883(define-public guile3.0-gi
2884 (deprecated-package "guile3.0-gi" guile-gi))
2885
fb6b9f3b
MB
2886(define-public guile-srfi-89
2887 (package
2888 (name "guile-srfi-89")
2889 (version "0.0.1")
2890 (source
2891 (origin
2892 (method git-fetch)
2893 (uri (git-reference
2894 (url "https://gitlab.com/mjbecze/guile-srfi-89.git")
2895 (commit version)))
2896 (sha256
2897 (base32
2898 "1981c0rrzxqx3md9jx8ir7j3m2mzg9m72b33p5jvw36zirbzpl20"))
2899 (file-name (git-file-name name version))))
2900 (build-system guile-build-system)
2901 (native-inputs
2902 `(("guile" ,guile-3.0)))
2903 (home-page "https://gitlab.com/mjbecze/guile-srfi-89")
2904 (synopsis "Hygienic implementation of SRFI-89 for Guile")
2905 (description
2906 "This package provides SRFI-89 optional positional and named
2907parameters, which define* and lambda* special forms")
2908 (license license:gpl3+)))
2909
7afbaefe
MB
2910(define-public guile-srfi-145
2911 (package
2912 (name "guile-srfi-145")
2913 (version "0.0.1")
2914 (source
2915 (origin
2916 (method git-fetch)
2917 (uri (git-reference
2918 (url "https://gitlab.com/mjbecze/guile-srfi-145.git")
2919 (commit version)))
2920 (sha256
2921 (base32
2922 "1gssa8cmcp8640fil9z8dpil8v5l279wlalqjcx3fls5jwv13q1b"))
2923 (file-name (git-file-name name version))))
2924 (build-system guile-build-system)
2925 (native-inputs
2926 `(("guile" ,guile-3.0)))
2927 (home-page "https://gitlab.com/mjbecze/guile-srfi-145")
2928 (synopsis "SRFI-145 port for Guile")
2929 (description
2930 "This package provides SRFI-145. This provides the means to
2931denote the invalidity of certain code paths in a Scheme program.")
2932 (license license:gpl3+)))
2933
e0607093
MB
2934(define-public guile-srfi-158
2935 (package
2936 (name "guile-srfi-158")
2937 (version "0.0.1")
2938 (source
2939 (origin
2940 (method git-fetch)
2941 (uri (git-reference
2942 (url "https://gitlab.com/mjbecze/guile-srfi-158.git")
2943 (commit version)))
2944 (sha256
2945 (base32
2946 "0b8hlv1bldbcwkcxi9y8mm6xp5gbgpg7b15bwqxv70iynl9d9a7c"))
2947 (file-name (git-file-name name version))))
2948 (build-system gnu-build-system)
2949 (native-inputs
2950 `(("autoconf" ,autoconf)
2951 ("automake" ,automake)
2952 ("pkg-config" ,pkg-config)))
2953 (inputs
2954 `(("guile" ,guile-3.0)))
2955 (home-page "https://gitlab.com/samplet/guile-srfi-158")
2956 (synopsis "SRFI 158 (Generators and Accumulators) for Guile")
2957 (description "This package provides an implementation of SRFI 158
2958for Guile. SRFI 158 defines utility procedures that create,
2959transform, and consume generators. It also defines procedures that
2960return accumulators. It is implemented by wrapping the sample
2961implementation in a thin Guile compatibility layer.")
2962 (license license:gpl3+)))
2963
dec4b3aa
LC
2964(define-public guile-srfi-159
2965 (let ((commit "1bd98abda2ae4ef8f36761a167903e55c6bda7bb")
2966 (revision "0"))
2967 (package
2968 (name "guile-srfi-159")
2969 (version (git-version "0" revision commit))
2970 (home-page "https://bitbucket.org/bjoli/guile-srfi-159")
2971 (source (origin
2972 (method hg-fetch)
2973 (uri (hg-reference (changeset commit)
2974 (url home-page)))
2975 (sha256
2976 (base32
2977 "1zw6cmcy7xdbfiz3nz9arqnn7l2daidaps6ixkcrc9b6k51fdv3p"))
2978 (file-name (git-file-name name version))))
2979 (build-system guile-build-system)
2980 (arguments
2981 ;; The *-impl.scm files are actually included from module files; they
2982 ;; should not be compiled separately, but they must be installed.
2983 '(#:not-compiled-file-regexp "-impl\\.scm$"))
2984 (inputs
2985 `(("guile" ,guile-2.2)))
2986 (synopsis "Formatting combinators for Guile")
2987 (description
2988 "The @code{(srfi-159)} module and its sub-modules implement the
2989formatting combinators specified by
2990@uref{https://srfi.schemers.org/srfi-159/srfi-159.html, SRFI-159}. These are
2991more expressive and flexible than the traditional @code{format} procedure.")
2992 (license license:bsd-3))))
f0de9544 2993
08a8872f
MB
2994(define-public guile-srfi-180
2995 (let ((commit "9188bf9724c6d320ef804579d222e855b007b193")
2996 (revision "0"))
2997 (package
2998 (name "guile-srfi-180")
2999 (version (git-version "0" revision commit))
3000 (source
3001 (origin
3002 (method git-fetch)
3003 (uri (git-reference
8ed4c468 3004 (url "https://github.com/scheme-requests-for-implementation/srfi-180")
08a8872f
MB
3005 (commit commit)))
3006 (sha256
3007 (base32
3008 "08lf70rsak8mwfij55xc37pg9zg7c87fizmhz7ln46skzj68sl3y"))
3009 (modules '((guix build utils)))
3010 (snippet
3011 '(begin
3012 (delete-file-recursively "srfi/files")
3013 (delete-file "srfi/run-r7rs-checks.guile.scm")
3014 (delete-file "srfi/run-r7rs-checks.scm")
3015 (delete-file "srfi/check.scm")
3016 #t))
3017 (file-name (git-file-name name version))))
3018 (build-system guile-build-system)
3019 (arguments
3020 '(#:not-compiled-file-regexp "body\\.scm$"))
3021 (native-inputs
3022 `(("guile" ,guile-3.0)))
3023 (propagated-inputs
3024 `(("guile-srfi-145" ,guile-srfi-145)))
3025 (home-page "https://srfi.schemers.org/srfi-180/")
3026 (synopsis "JSON parser and printer for Guile")
3027 (description
3028 "This library implements a JavaScript Object Notation (JSON) parser and printer.
3029It also supports parsing JSON objects that may be bigger than memory with a streaming
3030API.")
3031 (license license:expat))))
3032
f0de9544 3033(define-public emacsy
48eb71ae
JN
3034 (package
3035 (name "emacsy")
3036 (version "0.4.1")
3037 (source (origin
3038 (method url-fetch)
3039 (uri (string-append
3040 "https://download.savannah.nongnu.org/releases/"
3041 name "/" name "-" version ".tar.gz"))
3042 (sha256
3043 (base32
3044 "1cpb85dl1nibd34c2x2h7vfmjpkgh353p5b1w20v6cs6gmvgg4np"))))
3045 (build-system gnu-build-system)
3046 (native-inputs
3047 `(("autoconf" ,autoconf)
3048 ("automake" ,automake)
3049 ("bzip2" ,bzip2)
3050 ("guile" ,guile-2.2)
f2d97d57 3051 ("gettext" ,gettext-minimal)
48eb71ae
JN
3052 ("libtool" ,libtool)
3053 ("perl" ,perl)
3054 ("pkg-config" ,pkg-config)
3055 ("texinfo" ,texinfo)
1aa026aa 3056 ("texlive" ,(texlive-union (list texlive-generic-epsf)))))
114f02ba 3057 (inputs
48eb71ae
JN
3058 `(("dbus-glib" ,dbus-glib)
3059 ("guile" ,guile-2.2)
3060 ("guile-lib" ,guile-lib)
3061 ("guile-readline" ,guile-readline)
48eb71ae 3062 ("freeglut" ,freeglut)
48eb71ae 3063 ("webkitgtk" ,webkitgtk)))
114f02ba
AS
3064 (propagated-inputs
3065 `(("glib-networking" ,glib-networking)
3066 ("gssettings-desktop-schemas" ,gsettings-desktop-schemas)))
48eb71ae 3067 (arguments
114f02ba
AS
3068 `(#:modules ((guix build gnu-build-system)
3069 (guix build utils)
3070 (ice-9 popen)
3071 (ice-9 rdelim)
3072 (ice-9 regex)
3073 (ice-9 ftw)
3074 (srfi srfi-26))
3075 #:phases
48eb71ae
JN
3076 (modify-phases %standard-phases
3077 (add-before 'configure 'setenv
3078 (lambda _
3079 (setenv "GUILE_AUTO_COMPILE" "0")
114f02ba
AS
3080 #t))
3081 (add-after 'install 'wrap-binaries
3082 (lambda* (#:key inputs outputs #:allow-other-keys)
3083 (let* ((out (assoc-ref outputs "out"))
3084 (effective (read-line
3085 (open-pipe* OPEN_READ
3086 "guile" "-c"
3087 "(display (effective-version))")))
3088 (deps (map (cut assoc-ref inputs <>)
3089 '("guile-lib" "guile-readline")))
3090 (scm-path (map (cut string-append <> "/share/guile/site/"
3091 effective) `(,out ,@deps)))
3092 (go-path (map (cut string-append <> "/lib/guile/" effective
3093 "/site-ccache/") `(,out ,@deps)))
3094 (examples (filter (cut string-match "emacsy" <>)
3095 (scandir (string-append out "/bin/"))))
3096 (progs (map (cut string-append out "/bin/" <>)
3097 examples)))
3098 (map (cut wrap-program <>
3099 `("GUILE_LOAD_PATH" ":" prefix ,scm-path)
3100 `("GUILE_LOAD_COMPILED_PATH" ":" prefix ,go-path))
3101 progs)
3102 #t))))))
48eb71ae
JN
3103 (home-page "https://savannah.nongnu.org/projects/emacsy")
3104 (synopsis "Embeddable GNU Emacs-like library using Guile")
3105 (description
3106 "Emacsy is an embeddable Emacs-like library that uses GNU Guile
f0de9544
JN
3107as extension language. Emacsy can give a C program an Emacsy feel with
3108keymaps, minibuffer, recordable macros, history, tab completion, major
3109and minor modes, etc., and can also be used as a pure Guile library. It
48eb71ae
JN
3110comes with a simple counter example using FreeGLUT and browser examples
3111in C using Gtk+-3 and WebKitGtk.")
3112 (license license:gpl3+)))
2135610c 3113
c99f32b9 3114(define-public emacsy-minimal
e9db965f 3115 (let ((commit "v0.4.1-37-g5f91ee6"))
c99f32b9
AS
3116 (package
3117 (inherit emacsy)
3118 (name "emacsy-minimal")
9da87078 3119 (version (string-drop commit 1))
bdcb287e
MR
3120 (source
3121 (origin
3122 (method git-fetch)
3123 (uri (git-reference
3124 (url "https://git.savannah.gnu.org/git/emacsy.git")
3125 (commit commit)))
3126 (file-name (git-file-name name version))
3127 (sha256
e9db965f 3128 (base32 "03ym14g9qhjqmryr5z065kynqm8yhmvnbs2djl6vp3i9cmqln8cl"))))
c99f32b9
AS
3129 (build-system gnu-build-system)
3130 (inputs
3131 `(("guile" ,guile-2.2)
8d6ead32
MR
3132 ("guile-lib" ,guile2.2-lib)
3133 ("guile-readline" ,guile2.2-readline)))
c99f32b9
AS
3134 (propagated-inputs '())
3135 (arguments
3136 `(#:configure-flags '("--without-examples")
3137 #:phases
3138 (modify-phases %standard-phases
bdcb287e
MR
3139 (add-before 'configure 'setenv
3140 (lambda _
3141 (setenv "GUILE_AUTO_COMPILE" "0")
3142 #t))))))))
c99f32b9 3143
2135610c
LC
3144(define-public guile-jpeg
3145 (let ((commit "6a1673578b297c2c1b28e44a76bd5c49e76a5046")
3146 (revision "0"))
3147 (package
3148 (name "guile-jpeg")
3149 (version (git-version "0.0" revision commit))
3150 (home-page "https://gitlab.com/wingo/guile-jpeg")
3151 (source (origin
3152 (method git-fetch)
3153 (uri (git-reference (url home-page)
3154 (commit commit)))
3155 (sha256
3156 (base32
3157 "05z9m408w3h6aqb5k3r3qa7khir0k10rxwvsrzhkcq1hr5vbmr4m"))
3158 (file-name (git-file-name name version))
3159 (modules '((guix build utils)))
3160 (snippet
3161 '(begin
3162 ;; Install .go files in the right place.
3163 (substitute* "Makefile.am"
3164 (("/ccache") "/site-ccache"))
3165 #t))))
3166 (build-system gnu-build-system)
3167 (native-inputs
3168 `(("autoconf" ,autoconf)
3169 ("automake" ,automake)
3170 ("pkg-config" ,pkg-config)
3171 ("guile" ,guile-2.2)))
3172 (synopsis "JPEG file parsing library for Guile")
3173 (description
3174 "Guile-JPEG is a Scheme library to parse JPEG image files and to
3175perform geometrical transforms on JPEG images.")
3176 (license license:gpl3+))))
e8c2da41
AS
3177
3178(define-public nomad
3179 (package
3180 (name "nomad")
569cd538 3181 (version "0.2.0-alpha-199-g3e7a475")
e8c2da41
AS
3182 (source (origin
3183 (method git-fetch)
3184 (uri (git-reference
0e5a68a2 3185 (url "https://git.savannah.gnu.org/git/nomad.git/")
e8c2da41
AS
3186 (commit version)))
3187 (file-name (git-file-name name version))
3188 (sha256
3189 (base32
569cd538 3190 "0p0ha6prp7pyadp61clbhc6b55023vxzfwy14j2qygb2mkq7fhic"))))
e8c2da41
AS
3191 (build-system gnu-build-system)
3192 (native-inputs
3193 `(("autoconf" ,autoconf)
3194 ("automake" ,automake)
3195 ("bash" ,bash)
3196 ("pkg-config" ,pkg-config)
3197 ("libtool" ,libtool)
3198 ("guile" ,guile-2.2)
5f1553ce
AS
3199 ("glib:bin" ,glib "bin")
3200 ("texinfo" ,texinfo)
fccc0127 3201 ("gettext" ,gettext-minimal)
5f1553ce 3202 ("perl" ,perl)))
e8c2da41 3203 (inputs
0e5a68a2
MR
3204 `(;; Guile
3205 ("guile" ,guile-2.2)
19cf8342 3206 ("guile-lib" ,guile2.2-lib)
19cf8342 3207 ("guile-readline" ,guile2.2-readline)
a987f128 3208 ("guile-gcrypt" ,guile2.2-gcrypt)
e8c2da41 3209 ("gnutls" ,gnutls)
0e5a68a2 3210 ("g-golf" ,g-golf)
e8c2da41
AS
3211 ("shroud" ,shroud)
3212 ("emacsy" ,emacsy-minimal)
0e5a68a2 3213 ;; Gtk
e8c2da41
AS
3214 ("glib" ,glib)
3215 ("dbus-glib" ,dbus-glib)
0e5a68a2 3216 ("glib-networking" ,glib-networking)
e8c2da41 3217 ("gtk+" ,gtk+)
a987f128 3218 ("gtk+:bin" ,gtk+ "bin")
e8c2da41 3219 ("webkitgtk" ,webkitgtk)
0e5a68a2 3220 ("gtksourceview" ,gtksourceview)
569cd538 3221 ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
0e5a68a2
MR
3222 ("vte" ,vte)
3223 ;; Gstreamer
a987f128
MR
3224 ("gstreamer" ,gstreamer)
3225 ("gst-plugins-base" ,gst-plugins-base)
3226 ("gst-plugins-good" ,gst-plugins-good)
3227 ("gst-plugins-bad" ,gst-plugins-bad)
3228 ("gst-plugins-ugly" ,gst-plugins-ugly)
0e5a68a2
MR
3229 ;; Util
3230 ("xorg-server" ,xorg-server)))
e8c2da41
AS
3231 (arguments
3232 `(#:modules ((guix build gnu-build-system)
3233 (guix build utils)
3234 (ice-9 popen)
3235 (ice-9 rdelim)
3236 (srfi srfi-26))
3237 #:phases
3238 (modify-phases %standard-phases
3239 (add-before 'check 'start-xorg-server
3240 (lambda* (#:key inputs #:allow-other-keys)
3241 ;; The test suite requires a running X server.
3242 (system (format #f "~a/bin/Xvfb :1 &"
3243 (assoc-ref inputs "xorg-server")))
3244 (setenv "DISPLAY" ":1")
3245 #t))
3246 (add-after 'install 'wrap-binaries
3247 (lambda* (#:key inputs outputs #:allow-other-keys)
0e5a68a2
MR
3248 (let* ((out (assoc-ref outputs "out"))
3249 (effective (read-line (open-pipe*
3250 OPEN_READ
3251 "guile" "-c"
3252 "(display (effective-version))")))
3253 (gst-plugins (map (lambda (i)
3254 (string-append (assoc-ref inputs i)
3255 "/lib/gstreamer-1.0"))
3256 `("gstreamer"
3257 "gst-plugins-base"
3258 "gst-plugins-good"
3259 "gst-plugins-bad"
3260 "gst-plugins-ugly")))
3261 (out-append (lambda (. args)
3262 (apply string-append out args)))
3263 (gi-path (out-append "/lib/girepository-1.0"))
3264 (load-path (out-append "/share/guile/site/" effective))
3265 (comp-path (out-append "/lib/guile/"
3266 effective "/site-ccache"))
3267 (ext-path (out-append "/libexec/nomad")))
3268 (wrap-program (string-append out "/bin/nomad")
3269 `("GUILE_LOAD_PATH" ":" prefix
3270 (,load-path
3271 ,(getenv "GUILE_LOAD_PATH")))
3272 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
3273 (,comp-path
3274 ,(getenv "GUILE_LOAD_COMPILED_PATH")))
3275 `("GI_TYPELIB_PATH" ":" prefix
3276 (,gi-path ,(getenv "GI_TYPELIB_PATH")))
3277 `("GIO_EXTRA_MODULES" ":" prefix
3278 (,(getenv "GIO_EXTRA_MODULES")))
3279 `("GST_PLUGIN_SYSTEM_PATH" ":" prefix ,gst-plugins)
3280 `("NOMAD_WEB_EXTENSION_DIR" ":" prefix (,ext-path)))
e8c2da41
AS
3281 #t))))))
3282 (home-page "https://savannah.nongnu.org/projects/nomad/")
3283 (synopsis "Extensible Web Browser in Guile Scheme")
a987f128
MR
3284 (description "Nomad is a Emacs-like web browser that consists of a modular
3285feature-set, fully programmable in Guile Scheme.")
e8c2da41 3286 (license license:gpl3+)))
248965c9
RW
3287
3288(define-public guile-cv
3289 (package
3290 (name "guile-cv")
3291 (version "0.2.1")
3292 (source (origin
3293 (method url-fetch)
3294 (uri (string-append "mirror://gnu/guile-cv/guile-cv-"
3295 version ".tar.gz"))
3296 (sha256
3297 (base32
3298 "0qdf0s2h1xj5lbhnc1pfw69i3zg08pqy2y6869b92ydfis8r82j9"))))
3299 (build-system gnu-build-system)
3300 (arguments
3301 `(#:phases
3302 (modify-phases %standard-phases
3303 (add-after 'unpack 'prepare-build
3304 (lambda* (#:key inputs outputs #:allow-other-keys)
3305 (substitute* "configure"
3306 (("SITEDIR=\"\\$datadir/guile-cv\"")
3307 "SITEDIR=\"$datadir/guile/site/$GUILE_EFFECTIVE_VERSION\"")
3308 (("SITECCACHEDIR=\"\\$libdir/guile-cv/")
3309 "SITECCACHEDIR=\"$libdir/"))
3310 (substitute* "cv/init.scm"
3311 (("\\(dynamic-link \"libvigra_c\"\\)")
3312 (string-append "(dynamic-link \""
3313 (assoc-ref inputs "vigra-c")
3314 "/lib/libvigra_c\")"))
3315 (("\\(dynamic-link \"libguile-cv\"\\)")
3316 (format #f "~s"
3317 `(dynamic-link
3318 (format #f "~alibguile-cv"
3319 (if (getenv "GUILE_CV_UNINSTALLED")
3320 ""
3321 ,(format #f "~a/lib/"
3322 (assoc-ref outputs "out"))))))))
3323 (setenv "GUILE_CV_UNINSTALLED" "1")
3324 ;; Only needed to satisfy the configure script.
3325 (setenv "LD_LIBRARY_PATH"
3326 (string-append (assoc-ref inputs "vigra-c") "/lib"))
3327 #t)))))
3328 (inputs
3329 `(("vigra" ,vigra)
3330 ("vigra-c" ,vigra-c)
3331 ("guile" ,guile-2.2)))
3332 (native-inputs
3333 `(("texlive" ,(texlive-union (list texlive-booktabs
3334 texlive-lm
3335 texlive-siunitx
3336 texlive-standalone
3337 texlive-xcolor
3338 texlive-fonts-iwona)))
3339 ("pkg-config" ,pkg-config)))
3340 (propagated-inputs
3341 `(("guile-lib" ,guile-lib)))
3342 (home-page "https://www.gnu.org/software/guile-cv/")
3343 (synopsis "Computer vision library for Guile")
3344 (description "Guile-CV is a Computer Vision functional programming library
3345for the Guile Scheme language. It is based on Vigra (Vision with Generic
3346Algorithms), a C++ image processing and analysis library. Guile-CV contains
3347bindings to Vigra C (a C wrapper to most of the Vigra functionality) and is
3348enriched with pure Guile Scheme algorithms, all accessible through a nice,
3349clean and easy to use high level API.")
3350 (license license:gpl3+)))
7ff157c1
RW
3351
3352(define-public guile-ffi-fftw
353fb48f
RW
3353 (let ((commit "294ad9e7491dcb40026d2fec9be2af05263be1c0")
3354 (revision "2"))
7ff157c1
RW
3355 (package
3356 (name "guile-ffi-fftw")
3357 (version (git-version "0" revision commit))
3358 (source (origin
3359 (method git-fetch)
3360 (uri (git-reference
b0e7b699 3361 (url "https://github.com/lloda/guile-ffi-fftw")
7ff157c1
RW
3362 (commit commit)))
3363 (file-name (git-file-name "guile-ffi-fftw" version))
3364 (sha256
3365 (base32
353fb48f 3366 "08j40a5p6a8pgvhffmzb5rfdnrav2mksy3gfjkdqy93jfj1z5afg"))))
7ff157c1
RW
3367 (build-system guile-build-system)
3368 (arguments
3369 `(#:source-directory "mod"
3370 #:phases
3371 (modify-phases %standard-phases
3372 (add-after 'unpack 'prepare-build
3373 (lambda* (#:key inputs #:allow-other-keys)
3374 (substitute* "mod/ffi/fftw.scm"
3375 (("\\(getenv \"GUILE_FFI_FFTW_LIBFFTW3_PATH\"\\)")
3376 (format #f "\"~a/lib\"" (assoc-ref inputs "fftw"))))
3377 #t))
3378 (add-after 'build 'check
3379 (lambda _
3380 (invoke "guile" "-L" "mod"
3381 "-s" "test/test-ffi-fftw.scm"))))))
3382 (inputs
3383 `(("fftw" ,fftw)
3384 ("guile" ,guile-2.2)))
3385 (home-page "https://github.com/lloda/guile-ffi-fftw/")
3386 (synopsis "Access FFTW through Guile's FFI")
3387 (description "This is a minimal set of Guile FFI bindings for the FFTW
3388library's ‘guru interface’. It provides two functions: @code{fftw-dft! rank
3389sign in out} and @code{fftw-dft rank sign in}. These bindings being minimal,
3390there is no support for computing & reusing plans, or split r/i transforms, or
3391anything other than straight complex DFTs.")
353fb48f 3392 (license license:lgpl3+))))
f9ec89f4
TS
3393
3394(define-public srfi-64-driver
3395 (package
3396 (name "srfi-64-driver")
3397 (version "0.1")
3398 (source (origin
3399 (method url-fetch)
3400 (uri (string-append "https://files.ngyro.com/srfi-64-driver/"
3401 "srfi-64-driver-" version ".tar.gz"))
3402 (sha256
3403 (base32
3404 "188b6mb7sjjg0a8zldikinglf40ky8mg8rwh5768gjmch6gkk3ph"))))
3405 (build-system gnu-build-system)
3406 (arguments
3407 `(#:tests? #f
3408 #:phases
3409 (modify-phases %standard-phases
3410 (delete 'build))))
3411 (native-inputs
3412 `(("pkg-config" ,pkg-config)))
3413 (inputs
3414 `(("guile" ,guile-2.2)))
3415 (home-page "https://ngyro.com/software/srfi-64-driver.html")
3416 (synopsis "Automake test driver for SRFI 64 test suites")
3417 (description "This package provides an Automake test driver that can
3418run SRFI 64 test suites. It gives Automake insight into the individual
3419tests being run, resulting clearer and more specific output.")
3420 (license license:gpl3+)))
f6bf4b2c
TS
3421
3422(define-public guile-semver
3423 (package
3424 (name "guile-semver")
85ced665 3425 (version "0.1.1")
f6bf4b2c
TS
3426 (source (origin
3427 (method url-fetch)
3428 (uri (string-append "https://files.ngyro.com/guile-semver/"
3429 "guile-semver-" version ".tar.gz"))
3430 (sha256
3431 (base32
85ced665 3432 "109p4n39ln44cxvwdccf9kgb96qx54makvd2ir521ssz6wchjyag"))))
f6bf4b2c
TS
3433 (build-system gnu-build-system)
3434 (native-inputs
85ced665 3435 `(("pkg-config" ,pkg-config)))
f6bf4b2c 3436 (inputs
720e87fe 3437 `(("guile" ,guile-3.0)))
f6bf4b2c
TS
3438 (home-page "https://ngyro.com/software/guile-semver.html")
3439 (synopsis "Semantic Versioning (SemVer) for Guile")
3440 (description "This Guile library provides tools for reading,
3441comparing, and writing Semantic Versions. It also includes ranges in
3442the style of the Node Package Manager (NPM).")
3443 (license license:gpl3+)))
d67fa5c8 3444
b488b64a 3445(define-public guile3.0-semver
720e87fe
LC
3446 (deprecated-package "guile3.0-semver" guile-semver))
3447
3448(define-public guile2.2-semver
b488b64a
MB
3449 (package
3450 (inherit guile-semver)
720e87fe 3451 (name "guile2.2-semver")
b488b64a 3452 (inputs
720e87fe 3453 `(("guile" ,guile-2.2)))))
b488b64a 3454
d67fa5c8
LC
3455(define-public guile-hashing
3456 (package
3457 (name "guile-hashing")
3458 (version "1.2.0")
3459 (home-page "https://github.com/weinholt/hashing")
3460 (source (origin
3461 (method git-fetch)
3462 (uri (git-reference
3463 (url home-page)
3464 (commit (string-append "v" version))))
3465 (file-name (git-file-name name version))
3466 (sha256
3467 (base32
3468 "1362d3lmpv7slmv1zmr9wy8panq9sjr9787gc2hagd646mpsfpkl"))))
3469 (build-system guile-build-system)
3470 (arguments
3471 `(#:modules ((guix build guile-build-system)
3472 (guix build utils)
3473 (srfi srfi-26)
3474 (ice-9 ftw))
3475 #:implicit-inputs? #f ;needs nothing but Guile
3476 #:phases (modify-phases %standard-phases
3477 (add-before 'build 'move-sls-files
3478 (lambda _
3479 ;; Move the source under hashing/ in order to match
3480 ;; module names, and rename .sls files to .scm.
3481 (define (target file)
3482 (string-append "hashing/" file))
3483
3484 (define (sls->scm sls)
3485 (string-append (string-drop-right sls 4)
3486 ".scm"))
3487
3488 (mkdir "hashing")
3489 (for-each (lambda (file)
3490 (rename-file file (sls->scm file)))
3491 (find-files "." "\\.sls$"))
3492 (for-each (lambda (file)
3493 (rename-file file (target file)))
3494 (scandir "." (cut string-suffix? ".scm" <>)))
3495 (rename-file "private" "hashing/private")
3496 #t)))))
3497 (native-inputs
b6bee63b 3498 `(("guile" ,guile-3.0)))
d67fa5c8
LC
3499 (synopsis "Cryprographic hash functions implemented in Scheme")
3500 (description
3501 "The @code{(hashing @dots{})} modules implement cryptographic hash
3502functions in pure R6RS Scheme: CRC, HMAC, MD5, SHA-1, and SHA-2 (SHA-256,
3503SHA-512).")
3504 (license license:expat)))
f918a8d9 3505
b6bee63b 3506(define-public guile2.2-hashing
f918a8d9
LC
3507 (package
3508 (inherit guile-hashing)
b6bee63b 3509 (name "guile2.2-hashing")
f918a8d9 3510 (native-inputs
318e1a93 3511 `(("guile" ,guile-2.2)))))
ef2b1d2c 3512
b6bee63b
LC
3513(define-public guile3.0-hashing
3514 (deprecated-package "guile3.0-hashing" guile-hashing))
3515
60c9264b
LC
3516(define-public guile-packrat
3517 (package
3518 (name "guile-packrat")
3519 (version "0.1.1")
3520 (home-page "https://github.com/weinholt/packrat")
3521 (source (origin
3522 (method git-fetch)
3523 (uri (git-reference
3524 (url home-page)
3525 (commit (string-append "v" version))))
3526 (file-name (git-file-name name version))
3527 (sha256
3528 (base32
3529 "1aga17164fkhbgllqc7ni6fk5zl8mkmgkl5zcsy67x7ngpyalbby"))))
3530 (build-system guile-build-system)
3531 (arguments
3532 `(#:implicit-inputs? #f ;needs nothing but Guile
3533 #:compile-flags '("--r6rs" "-Wunbound-variable" "-Warity-mismatch")
3534 #:not-compiled-file-regexp "/extensible\\.scm$"
3535 #:phases (modify-phases %standard-phases
3536 (add-before 'build 'no-srfi-23
3537 (lambda _
3538 (substitute* "packrat.sls"
3539 (("\\(srfi :23 error\\)")
3540 (object->string '(only (guile) error))))
3541 #t)))))
3542 (native-inputs
3543 `(("guile" ,guile-3.0)))
3544 (synopsis "Packrat parser library in R6RS Scheme")
3545 (description
3546 "This is an R6RS Scheme adaptation of the
3547@uref{https://bford.info/packrat/, packrat parsing}. Packrat parsing is a
3548memoizing, backtracking, recursive-descent parsing technique that runs in time
3549and space linear in the size of the input text.")
3550 (license license:expat)))
3551
97a77eab
LC
3552(define-public guile-ac-d-bus
3553 (package
3554 (name "guile-ac-d-bus")
933fdd55 3555 (version "1.0.0-beta.0")
97a77eab
LC
3556 (home-page "https://gitlab.com/weinholt/ac-d-bus/")
3557 (source (origin
3558 (method git-fetch)
3559 (uri (git-reference
3560 (url home-page)
3561 (commit (string-append "v" version))))
3562 (file-name (git-file-name name version))
3563 (sha256
3564 (base32
933fdd55 3565 "0rl809qimhgz6b0rixakb42r2l4g53jr09a2g0s1hxgab0blz0kb"))))
97a77eab
LC
3566 (build-system guile-build-system)
3567 (arguments
3568 `(#:implicit-inputs? #f ;needs nothing but Guile
3569 #:compile-flags '("--r6rs" "-Wunbound-variable" "-Warity-mismatch")
3570 #:phases (modify-phases %standard-phases
3571 (add-before 'build 'adjust-for-guile
3572 (lambda _
3573 ;; Adjust source file names for Guile.
3574 (define (guile-sls->sls file)
3575 (string-append (string-drop-right
3576 file (string-length ".guile.sls"))
3577 ".sls"))
3578
3579 ;; Remove files targeting other implementations:
3580 ;; *.mosh.sls, etc.
3581 (for-each delete-file
3582 (find-files
3583 "compat"
3584 (lambda (file stat)
3585 (not (string-contains file ".guile.")))))
3586
3587 ;; Rename *.guile.sls to *.sls so the ".guile" bit does
3588 ;; not appear in .go file names.
3589 (for-each (lambda (file)
3590 (rename-file file (guile-sls->sls file)))
3591 (find-files "compat" "\\.guile\\.sls"))
3592
3593 ;; Move directories under d-bus/ to match module names.
3594 (mkdir "d-bus")
3595 (for-each (lambda (directory)
3596 (rename-file directory
3597 (string-append "d-bus/"
3598 directory)))
3599 '("compat" "protocol"))
3600
3601 #t)))))
3602 (native-inputs
3603 `(("guile" ,guile-3.0)))
3604 (propagated-inputs
3605 `(("guile-packrat" ,guile-packrat)))
3606 (synopsis "D-Bus protocol implementation in R6RS Scheme")
3607 (description
3608 "AC/D-Bus is an implementation of the D-Bus wire protocol. D-Bus is an
3609interprocess communication protocol popular on GNU/Linux systems to
3610communicate with a variety of services. Originally designed for desktop
3611environments, it is now used by programs like VLC media player, BlueZ,
3612NetworkManager, Pulseaudio, systemd (including logind and resolved), Polkit,
3613gnome-keyring, and many more.")
3614 (license license:expat)))
3615
ef2b1d2c
RW
3616(define-public guile-webutils
3617 (let ((commit "8541904f761066dc9c27b1153e9a838be9a55299")
3618 (revision "0"))
3619 (package
3620 (name "guile-webutils")
3621 (version (git-version "0.1" revision commit))
3622 (source (origin
3623 (method git-fetch)
3624 (uri (git-reference
3625 (url "https://notabug.org/cwebber/guile-webutils.git")
3626 (commit commit)))
3627 (file-name (git-file-name name version))
3628 (sha256
3629 (base32
0a76d7a9
RW
3630 "1s9n3hbxd7lfpdi0x8wr0cfvlsf6g62ird9gbspxdrp5p05rbi64"))
3631 (modules '((guix build utils)))
3632 (snippet
3633 '(begin
3634 ;; Allow builds with Guile 3.0.
3635 (substitute* "configure.ac"
3636 (("2\\.2 2\\.0")
3637 "3.0 2.2 2.0"))
3638 #t))))
ef2b1d2c
RW
3639 (build-system gnu-build-system)
3640 (native-inputs
3641 `(("autoconf" ,autoconf)
3642 ("automake" ,automake)
3643 ("pkg-config" ,pkg-config)
3644 ("texinfo" ,texinfo)))
3645 (inputs
0a76d7a9 3646 `(("guile" ,guile-3.0)))
ef2b1d2c
RW
3647 (propagated-inputs
3648 `(("guile-irregex" ,guile-irregex)
3649 ("guile-gcrypt" ,guile-gcrypt)))
3650 (home-page "https://notabug.org/cwebber/guile-webutils")
3651 (synopsis "Web application authoring utilities for Guile")
3652 (description
3653 "This package provides tooling to write web applications in Guile, such
3654as signed sessions, multipart message support, etc.")
3655 (license license:gpl3+))))
5479cef8 3656
0a76d7a9
RW
3657(define-public guile2.2-webutils
3658 (package
3659 (inherit guile-webutils)
3660 (name "guile2.2-webutils")
3661 (inputs
3662 `(("guile" ,guile-2.2)))
3663 (propagated-inputs
3664 `(("guile-irregex" ,guile2.2-irregex)
3665 ("guile-gcrypt" ,guile2.2-gcrypt)))))
3666
5479cef8
RW
3667(define-public guile-lens
3668 (let ((commit "14b15d07255f9d3f55d40a3b750d13c9ee3a154f")
3669 (revision "0"))
3670 (package
3671 (name "guile-lens")
3672 (version (git-version "0.1" revision commit))
3673 (source (origin
3674 (method git-fetch)
3675 (uri (git-reference
3676 (url "https://gitlab.com/a-sassmannshausen/guile-lens.git")
3677 (commit commit)))
3678 (file-name (git-file-name name version))
3679 (sha256
3680 (base32
3681 "0w8jzqyla56yrgj7acsgd4nspyir6zgp3vgxid4xmwhg9wmf1ida"))))
3682 (build-system gnu-build-system)
3683 (arguments
3684 '(#:phases
3685 (modify-phases %standard-phases
3686 (add-after 'unpack 'run-hall
3687 (lambda _
3688 (setenv "HOME" "/tmp") ; for ~/.hall
3689 (invoke "hall" "dist" "-x"))))))
3690 (native-inputs
3691 `(("autoconf" ,autoconf)
3692 ("automake" ,automake)
ca24b3fb 3693 ("guile" ,guile-3.0)
5479cef8
RW
3694 ("guile-hall" ,guile-hall)
3695 ("pkg-config" ,pkg-config)
3696 ("texinfo" ,texinfo)))
3697 (home-page "https://gitlab.com/a-sassmannshausen/guile-lens.git")
3698 (synopsis "Composable lenses for data structures in Guile")
3699 (description
3700 "Guile-Lens is a library implementing lenses in Guile. The library is
3701currently a re-implementation of the lentes library for Clojure. Lenses
3702provide composable procedures, which can be used to focus, apply functions
3703over, or update a value in arbitrary data structures.")
3704 (license license:gpl3+))))
69bb61f1 3705
ca24b3fb
RW
3706(define-public guile2.2-lens
3707 (package
3708 (inherit guile-lens)
3709 (name "guile2.2-lens")
3710 (native-inputs
3711 `(("guile" ,guile-2.2)
3712 ,@(alist-delete "guile" (package-native-inputs guile-lens))))))
3713
69bb61f1 3714(define-public guile-xapian
d10e7a34
RW
3715 (package
3716 (name "guile-xapian")
3717 (version "0.1.0")
3718 (home-page "https://git.systemreboot.net/guile-xapian")
3719 (source
3720 (origin
3721 (method git-fetch)
3722 (uri (git-reference (url home-page)
3723 (commit (string-append "v" version))))
3724 (file-name (git-file-name name version))
3725 (sha256
3726 (base32
3727 "16k61f1jn3g48jaf3730b9l0izr5j933jzyri73nmcnjd09gm35i"))))
3728 (build-system gnu-build-system)
3729 (arguments
3730 '(#:make-flags '("GUILE_AUTO_COMPILE=0"))) ; to prevent guild warnings
3731 (inputs
93989aed 3732 `(("guile" ,guile-3.0)
d10e7a34
RW
3733 ("xapian" ,xapian)
3734 ("zlib" ,zlib)))
3735 (native-inputs
3736 `(("autoconf" ,autoconf)
3737 ("autoconf-archive" ,autoconf-archive)
3738 ("automake" ,automake)
3739 ("libtool" ,libtool)
3740 ("pkg-config" ,pkg-config)
3741 ("swig" ,swig)))
3742 (synopsis "Guile bindings for Xapian")
3743 (description "@code{guile-xapian} provides Guile bindings for Xapian, a
69bb61f1
AI
3744search engine library. Xapian is a highly adaptable toolkit which allows
3745developers to easily add advanced indexing and search facilities to their own
3746applications. It has built-in support for several families of weighting
3747models and also supports a rich set of boolean query operators.")
d10e7a34 3748 (license license:gpl2+)))
69bb61f1 3749
93989aed 3750(define-public guile2.2-xapian
69bb61f1
AI
3751 (package
3752 (inherit guile-xapian)
93989aed 3753 (name "guile2.2-xapian")
69bb61f1 3754 (inputs
93989aed 3755 `(("guile" ,guile-2.2)
69bb61f1 3756 ,@(alist-delete "guile" (package-inputs guile-xapian))))))
be789065 3757
93989aed
LC
3758(define-public guile3.0-xapian
3759 (deprecated-package "guile3.0-xapian" guile-xapian))
3760
be789065
AS
3761(define-public guile-torrent
3762 (package
3763 (name "guile-torrent")
3764 (version "0.1.3")
3765 (source (origin (method git-fetch)
3766 (uri (git-reference
3767 (url
8ed4c468 3768 "https://github.com/o-nly/torrent")
be789065
AS
3769 (commit version)))
3770 (file-name (git-file-name name version))
3771 (sha256
3772 (base32
3773 "1yiagi55ncq1x7s9n7salzywjm4l96y3n7y3s47a9anvz87mrmim"))))
3774 (build-system gnu-build-system)
3775 (native-inputs
3776 `(("autoconf" ,autoconf)
3777 ("automake" ,automake)
3778 ("guile" ,guile-2.2)
3779 ("texinfo" ,texinfo)
3780 ("perl" ,perl)
3781 ("pkg-config" ,pkg-config)))
3782 (propagated-inputs
3783 `(("guile-gcrypt" ,guile-gcrypt)))
3784 (home-page "https://github.com/o-nly/torrent")
3785 (synopsis "Torrent library for GNU Guile")
3786 (description "This package provides facilities for working with
3787@code{.torrent} or metainfo files. Implements a bencode reader and writer
3788according to Bitorrent BEP003.")
3789 (license license:gpl3+)))
3c0456c6
RW
3790
3791(define-public guile-irc
3792 (let ((commit "375d3bde9c6ae7ccc9d7cc65817966b6fda8f26a")
3793 (revision "0"))
3794 (package
3795 (name "guile-irc")
3796 (version (git-version "0.3.0" revision commit))
3797 (source (origin
3798 (method git-fetch)
3799 (uri (git-reference
b0e7b699 3800 (url "https://github.com/rekado/guile-irc")
3c0456c6
RW
3801 (commit commit)))
3802 (file-name (git-file-name name version))
3803 (sha256
3804 (base32
3805 "113lcckcywrz9060w1c3fnvr8d7crdsjgsv4h47hgmr1slgadl4y"))))
3806 (build-system gnu-build-system)
3807 (arguments
3808 `(#:configure-flags '("--enable-gnutls=yes")))
3809 (native-inputs
3810 `(("autoconf" ,autoconf)
3811 ("automake" ,automake)
3812 ("texinfo" ,texinfo)))
3813 (inputs
3814 `(("gnutls" ,gnutls)
b4412382 3815 ("guile" ,guile-3.0)))
3c0456c6
RW
3816 (home-page "https://github.com/rekado/guile-irc")
3817 (synopsis "IRC library for Guile")
3818 (description "This package provides a Guile library for @dfn{Internet
3819Relay Chat} (IRC).")
3820 ;; Some file headers incorrectly say LGPLv2+.
3821 (license license:lgpl2.1+))))
8ffc20ef 3822
b141e1d5 3823(define-public guile-websocket
8ffc20ef
ES
3824 (let ((commit "c854e0f84a40d972cbd532bbb89c97ca0126a7cf"))
3825 (package
b141e1d5 3826 (name "guile-websocket")
8ffc20ef
ES
3827 (version "0.1")
3828 (source
3829 (origin
3830 (method git-fetch)
3831 (uri (git-reference
3832 (url "git://dthompson.us/guile-websocket.git")
3833 (commit commit)))
3834 (file-name (git-file-name name version))
3835 (sha256
3836 (base32
3837 "1hymvsfrmq9qxr5cxnsgdz7y757yp1cpsgxmdp3f5wxxxpqgsmzx"))))
3838 (build-system gnu-build-system)
3839 (arguments
3840 '(#:make-flags
3841 '("GUILE_AUTO_COMPILE=0")
3842 #:phases
3843 (modify-phases %standard-phases
3844 ;; The package was developed for Guile 2.0 and has this version
3845 ;; hardcoded in the configure.ac and Makefile.am files. Substitute
3846 ;; 3.0 instead so it can support Guile 3.0.
3847 (add-after 'unpack 'update-guile-version
3848 (lambda _
3849 (substitute* "configure.ac"
3850 (("2.0.9") "3.0.0"))
3851 (substitute* "Makefile.am"
cea91813
LC
3852 (("2.0") "3.0")
3853
3854 ;; Install .go files where they belong.
3855 (("/ccache") "/site-ccache"))
8ffc20ef
ES
3856 #t)))))
3857 (native-inputs
3858 `(("autoconf" ,autoconf)
3859 ("automake" ,automake)))
3860 (inputs
b141e1d5 3861 `(("guile" ,guile-3.0)))
8ffc20ef
ES
3862 (synopsis "Websocket server/client for Guile")
3863 (description "Guile-websocket provides an implementation of the
3864WebSocket protocol as defined by RFC 6455.")
3865 (home-page "https://git.dthompson.us/guile-websocket.git")
3866 (license license:lgpl3+))))
b141e1d5
LC
3867
3868(define-public guile3.0-websocket
3869 (deprecated-package "guile3.0-websocket" guile-websocket))
c08f235b
JL
3870
3871(define-public guile-rdf
3872 (package
3873 (name "guile-rdf")
3874 (version "1.0")
3875 (source
3876 (origin
3877 (method git-fetch)
3878 (uri (git-reference
3879 (url "https://framagit.org/tyreunom/guile-rdf")
3880 (commit version)))
3881 (file-name (git-file-name name version))
3882 (sha256
3883 (base32
3884 "0dwn3app1fscbpmpgvjs5jy1y0gwy3j5gdx8br79af6a88zjlnqf"))))
3885 (build-system gnu-build-system)
3886 (arguments
3887 `(#:tests? #f)); tests require network
3888 (inputs
3889 `(("guile" ,guile-3.0)))
3890 (native-inputs
3891 `(("automake" ,automake)
3892 ("autoconf" ,autoconf)
3893 ("pkg-config" ,pkg-config)
3894 ("texinfo" ,texinfo)))
3895 (home-page "https://framagit.org/tyreunom/guile-rdf")
3896 (synopsis "Guile implementation of the RDF abstract and concrete syntaxes")
3897 (description "Guile RDF is an implementation of the RDF (Resource Description
3898Framework) format defined by the W3C for GNU Guile. RDF structures include
3899triples (facts with a subject, a predicate and an object), graphs which are
3900sets of triples, and datasets, which are collections of graphs.
3901
3902RDF specifications include the specification of concrete syntaxes and of
3903operations on graphs. This library implements some basic functionalities,
3904such as parsing and producing turtle and nquads syntax, as well as
3905manipulating graphs and datasets.")
3906 (license license:gpl3+)))
d1fa24af
JL
3907
3908(define-public guile-jsonld
3909 (package
3910 (name "guile-jsonld")
1bad456e 3911 (version "1.0.2")
d1fa24af
JL
3912 (source
3913 (origin
3914 (method git-fetch)
3915 (uri (git-reference
3916 (url "https://framagit.org/tyreunom/guile-jsonld")
3917 (commit version)))
3918 (file-name (git-file-name name version))
3919 (sha256
3920 (base32
1bad456e 3921 "1ryyvh71899z2inivqglb8d78zzp1sd0wv9a56kvcmrxf1966z6r"))))
d1fa24af
JL
3922 (build-system gnu-build-system)
3923 (arguments
3924 `(#:tests? #f)); require network
3925 (propagated-inputs
3926 `(("guile-gnutls" ,gnutls)
1bad456e 3927 ("guile-json" ,guile-json-4)
d1fa24af
JL
3928 ("guile-rdf" ,guile-rdf)))
3929 (inputs
3930 `(("guile" ,guile-3.0)))
3931 (native-inputs
3932 `(("automake" ,automake)
3933 ("autoconf" ,autoconf)
3934 ("pkg-config" ,pkg-config)
3935 ("texinfo" ,texinfo)))
3936 (home-page "https://framagit.org/tyreunom/guile-jsonld")
3937 (synopsis "Guile implementation of the JsonLD API specification")
3938 (description "Guile JsonLD is an implementation of the JsonLD (Json for
3939Linked Data) API defined by the W3C for GNU Guile. It allows you to express links
3940between data, in a way that is very similar to WikiData or RDF for instance.
3941An object can have relations (in the form of an IRI) that relates it to one or
3942more objects or strings, represented by a Json object or an IRI.")
3943 (license license:gpl3+)))
a684e6e2
MB
3944
3945(define-public guile-struct-pack
3946 (package
3947 (name "guile-struct-pack")
3948 (version "1.1.1")
3949 (source
3950 (origin
3951 (method git-fetch)
3952 (uri (git-reference
3953 (url "https://github.com/weinholt/struct-pack")
3954 (commit (string-append "v" version))))
3955 (file-name (git-file-name name version))
3956 (sha256
3957 (base32 "0hd72m821pahjphzyjn26i55542v8makr55xzjll2cycja4wsbc1"))))
3958 (build-system guile-build-system)
3959 (arguments
3960 `(#:compile-flags '("--r6rs" "-Wunbound-variable" "-Warity-mismatch")
3961 #:modules ((guix build guile-build-system)
3962 (guix build utils)
3963 (srfi srfi-26)
3964 (ice-9 ftw))
3965 #:phases (modify-phases %standard-phases
3966 (add-before 'build 'move-sls-files
3967 (lambda _
3968 ;; Move files under a struct/ directory to reflect the
3969 ;; module hierarchy.
3970 (define dst-folder "struct")
3971 (define (target file)
3972 (string-append dst-folder "/" file))
3973 (define files
3974 (scandir "." (negate (cut member <> '("." "..")))))
3975 (mkdir dst-folder)
3976 (for-each (lambda (file)
3977 (rename-file file (target file)))
3978 files)
3979 #t)))))
3980 (native-inputs
3981 `(("guile" ,guile-3.0)))
3982 (home-page "https://github.com/weinholt/struct-pack")
3983 (synopsis "R6RS library for working with packed byte structures")
3984 (description
3985 "This is an R6RS library for working with packed byte structures. It is
3986similar to struct in Python or pack and unpack in Perl.")
3987 (license license:expat)))
199da208
MB
3988
3989(define-public guile-machine-code
3990 (package
3991 (name "guile-machine-code")
3992 (version "2.1.0")
3993 (source
3994 (origin
3995 (method git-fetch)
3996 (uri (git-reference
3997 (url "https://github.com/weinholt/machine-code")
3998 (commit (string-append "v" version))))
3999 (file-name (git-file-name name version))
4000 (sha256
4001 (base32 "0wzj3caj2jypzyjqfkfqkvr3kkbjabsnhldv9kvnx9w9qnria5yd"))))
4002 (build-system guile-build-system)
4003 (arguments
4004 `(#:compile-flags '("--r6rs" "-Wunbound-variable" "-Warity-mismatch")
4005 #:modules ((guix build guile-build-system)
4006 (guix build utils)
4007 (srfi srfi-26)
4008 (ice-9 ftw))
4009 #:phases (modify-phases %standard-phases
4010 (add-before 'build 'move-sls-files
4011 (lambda _
4012 ;; Move files under a struct/ directory to reflect the
4013 ;; module hierarchy.
4014 (define dst-folder "machine-code")
4015 (define (target file)
4016 (string-append dst-folder "/" file))
4017 (define files
4018 (scandir "." (negate (cut member <> '("." "..")))))
4019 (mkdir dst-folder)
4020 (for-each (lambda (file)
4021 (rename-file file (target file)))
4022 files)
4023 #t)))))
4024 (native-inputs
4025 `(("guile" ,guile-3.0)))
4026 (propagated-inputs
4027 `(("guile-struct-pack" ,guile-struct-pack)))
4028 (home-page "https://github.com/weinholt/machine-code")
4029 (synopsis "Tools that relate to machine code and object formats")
4030 (description
4031 "This project is about the development of tools that relate to machine
4032code and object formats; for all architectures. Here you'll find libraries
4033for working with binary code: assembly, disassembly, instruction tables,
4034object formats and related areas.")
4035 (license license:expat)))
3826288f
MB
4036
4037(define-public guile-laesare
4038 (package
4039 (name "guile-laesare")
4040 (version "1.0.0")
4041 (source
4042 (origin
4043 (method git-fetch)
4044 (uri (git-reference
4045 (url "https://github.com/weinholt/laesare")
4046 (commit (string-append "v" version))))
4047 (file-name (git-file-name name version))
4048 (sha256
4049 (base32 "15q619gzw717r8r1ql23zfdaibpnp9qqs96032vdc3rj74msxc92"))))
4050 (build-system guile-build-system)
4051 (arguments
4052 `(#:compile-flags '("--r6rs" "-Wunbound-variable" "-Warity-mismatch")
4053 #:modules ((guix build guile-build-system)
4054 (guix build utils)
4055 (srfi srfi-26)
4056 (ice-9 ftw))
4057 #:phases (modify-phases %standard-phases
4058 (add-before 'build 'move-sls-files
4059 (lambda _
4060 ;; Move files under a laesare directory to reflect
4061 ;; the module hierarchy.
4062 (define dst-folder "laesare")
4063 (define (target file)
4064 (string-append dst-folder "/" file))
4065 (define files
4066 (scandir "." (negate (cut member <> '("." "..")))))
4067 (mkdir dst-folder)
4068 (for-each (lambda (file)
4069 (rename-file file (target file)))
4070 files)
4071 #t)))))
4072 (native-inputs
4073 `(("guile" ,guile-3.0)))
4074 (home-page "https://github.com/weinholt/laesare")
4075 (synopsis "R6RS Scheme library that provides a reader")
4076 (description
4077 "This is an R6RS Scheme library that provides a reader with some extra
4078features not found in the standard read procedure such as a compatible mode
4079with support for other RnRS standards and a tolerant mode that continues on
4080errors.")
4081 (license license:expat)))
465a951c
MO
4082
4083(define-public guile-avahi
d7f2b1e5
MO
4084 (let ((commit "6d43caf64f672a9694bf6c98bbf7a734f17a51e8")
4085 (revision "1"))
4086 (package
4087 (name "guile-avahi")
4088 (version (git-version "0.4.0" revision commit))
4089 (source (origin
4090 (method git-fetch)
4091 (uri (git-reference
4092 (url "git://git.sv.gnu.org/guile-avahi.git")
4093 (commit commit)))
4094 (file-name (git-file-name name version))
4095 (sha256
4096 (base32
4097 "0fvrf8x22yvc71180hd3xkhspg9yvadi0pbv8shzlsaxqncwy1m9"))
4098 (modules '((guix build utils)))))
4099 (build-system gnu-build-system)
4100 (arguments
4101 `(#:modules (((guix build guile-build-system)
4102 #:select (target-guile-effective-version))
4103 ,@%gnu-build-system-modules)
4104 #:imported-modules ((guix build guile-build-system)
4105 ,@%gnu-build-system-modules)
4106 #:make-flags
4107 '("GUILE_AUTO_COMPILE=0") ;to prevent guild warnings
4108 #:phases
4109 (modify-phases %standard-phases
4110 (add-before 'check 'fix-guile-avahi-file-name
4111 (lambda* (#:key outputs #:allow-other-keys)
4112 (with-directory-excursion "src"
4113 (invoke "make" "install"
4114 "-j" (number->string
4115 (parallel-job-count))))
4116 (let* ((out (assoc-ref outputs "out"))
4117 (files (find-files "modules" ".scm")))
4118 (substitute* files
4119 (("\"guile-avahi-v-0\"")
4120 (format #f "\"~a/lib/guile/~a/extensions/guile-avahi-v-0\""
4121 out (target-guile-effective-version))))
4122 #t))))))
4123 (inputs
4124 `(("guile" ,guile-3.0)
4125 ("avahi" ,avahi)))
4126 (native-inputs
4127 `(("autoconf" ,autoconf)
4128 ("automake" ,automake)
4129 ("libtool" ,libtool)
d7f2b1e5
MO
4130 ("pkg-config" ,pkg-config)
4131 ("texinfo" ,texinfo)))
4132 (synopsis "Guile bindings to Avahi")
4133 (description
4134 "This package provides bindings for Avahi. It allows programmers to
4135use functionalities of the Avahi client library from Guile Scheme programs.
4136Avahi itself is an implementation of multicast DNS (mDNS) and DNS Service
465a951c 4137Discovery (DNS-SD).")
d7f2b1e5
MO
4138 (home-page "https://www.nongnu.org/guile-avahi/")
4139 (license license:lgpl3+))))
a8c1eaba 4140
4141(define-public guile-mkdir-p
4142 (package
4143 (name "guile-mkdir-p")
4144 (version "1.0.1")
4145 (source
4146 (origin
4147 (method git-fetch)
4148 (uri (git-reference
4149 (url "https://code.divoplade.fr/mkdir-p.git")
4150 (commit (string-append "v" version))))
4151 (sha256
4152 (base32 "01k20rjcv6p0spmw8ls776aar6bfw0jxw46d2n12w0cb2p79xjv8"))
4153 (file-name (git-file-name name version))
4154 (snippet
4155 `(begin
4156 (with-output-to-file ".tarball-version"
4157 (lambda _ (format #t "~a~%" ,version)))
4158 #t))))
4159 (build-system gnu-build-system)
4160 (arguments `())
4161 (native-inputs
4162 `(("guile" ,guile-3.0)
4163 ("texinfo" ,texinfo)
4164 ("autoconf" ,autoconf)
4165 ("autoconf-archive" ,autoconf-archive)
4166 ("automake" ,automake)
4167 ("pkg-config" ,pkg-config)
fccc0127 4168 ("gettext" ,gettext-minimal)))
a8c1eaba 4169 (inputs `(("guile" ,guile-3.0)))
4170 (synopsis "Implementation of a recursive @code{mkdir} for Guile")
4171 (description
4172 "This package provides within the @code{(mkdir-p)} module the
4173@code{mkdir-p} function that tries to create the chain of directories
4174recursively. It also provides new versions of @code{open-output-file},
4175@code{call-with-output-file} and @code{with-output-to-file} to create the
4176directory of its argument if it does not exist.")
4177 (home-page "https://mkdir-p.divoplade.fr")
4178 (license license:asl2.0)))