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