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