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