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