syscalls: 'define-as-needed' does not re-export local variables.
[jackhill/guix/guix.git] / gnu / packages / guile-xyz.scm
CommitLineData
0791437f
RW
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019 Ludovic Courtès <ludo@gnu.org>
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>
6;;; Copyright © 2016, 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
7;;; Copyright © 2016 Erik Edrosa <erik.edrosa@gmail.com>
f61f424d 8;;; Copyright © 2016, 2019 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>
a3246602 15;;; Copyright © 2017, 2018, 2019 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>
50771f5b 20;;; Copyright © 2018, 2019 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>
c99f32b9 24;;; Copyright © 2019 Amar Singh <nly@disroot.org>
0791437f
RW
25;;;
26;;; This file is part of GNU Guix.
27;;;
28;;; GNU Guix is free software; you can redistribute it and/or modify it
29;;; under the terms of the GNU General Public License as published by
30;;; the Free Software Foundation; either version 3 of the License, or (at
31;;; your option) any later version.
32;;;
33;;; GNU Guix is distributed in the hope that it will be useful, but
34;;; WITHOUT ANY WARRANTY; without even the implied warranty of
35;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
36;;; GNU General Public License for more details.
37;;;
38;;; You should have received a copy of the GNU General Public License
39;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
40
41(define-module (gnu packages guile-xyz)
42 #:use-module ((guix licenses) #:prefix license:)
43 #:use-module (gnu packages)
44 #:use-module (gnu packages aspell)
45 #:use-module (gnu packages autotools)
46 #:use-module (gnu packages base)
47 #:use-module (gnu packages bash)
48 #:use-module (gnu packages compression)
406ef442 49 #:use-module (gnu packages databases)
0791437f 50 #:use-module (gnu packages disk)
15218d4e 51 #:use-module (gnu packages emacs)
5531782d 52 #:use-module (gnu packages emacs-xyz)
0791437f
RW
53 #:use-module (gnu packages gawk)
54 #:use-module (gnu packages gettext)
55 #:use-module (gnu packages gl)
bdf2dd79 56 #:use-module (gnu packages glib)
5531782d 57 #:use-module (gnu packages gnome)
e8c2da41 58 #:use-module (gnu packages gnupg)
0791437f 59 #:use-module (gnu packages gperf)
bdf2dd79 60 #:use-module (gnu packages gtk)
0791437f
RW
61 #:use-module (gnu packages guile)
62 #:use-module (gnu packages hurd)
63 #:use-module (gnu packages image)
d1a3a8e1 64 #:use-module (gnu packages imagemagick)
0791437f
RW
65 #:use-module (gnu packages libffi)
66 #:use-module (gnu packages libunistring)
67 #:use-module (gnu packages linux)
68 #:use-module (gnu packages man)
69 #:use-module (gnu packages maths)
70 #:use-module (gnu packages multiprecision)
71 #:use-module (gnu packages ncurses)
72 #:use-module (gnu packages networking)
f0de9544 73 #:use-module (gnu packages noweb)
e8c2da41 74 #:use-module (gnu packages password-utils)
406ef442 75 #:use-module (gnu packages perl)
0791437f
RW
76 #:use-module (gnu packages pkg-config)
77 #:use-module (gnu packages python)
78 #:use-module (gnu packages readline)
79 #:use-module (gnu packages sdl)
80 #:use-module (gnu packages slang)
81 #:use-module (gnu packages sqlite)
f0de9544 82 #:use-module (gnu packages tex)
0791437f
RW
83 #:use-module (gnu packages texinfo)
84 #:use-module (gnu packages tls)
85 #:use-module (gnu packages version-control)
bdf2dd79 86 #:use-module (gnu packages webkit)
0791437f
RW
87 #:use-module (gnu packages xdisorg)
88 #:use-module (gnu packages xorg)
89 #:use-module (guix packages)
90 #:use-module (guix download)
91 #:use-module (guix git-download)
dec4b3aa 92 #:use-module (guix hg-download)
0791437f
RW
93 #:use-module (guix build-system gnu)
94 #:use-module (guix build-system guile)
95 #:use-module (guix utils)
96 #:use-module (ice-9 match)
97 #:use-module ((srfi srfi-1) #:select (alist-delete)))
98
99(define-public artanis
cd81199c 100 (let ((release "0.3.1")
fd9a6d83 101 (revision 0))
0791437f
RW
102 (package
103 (name "artanis")
104 (version (if (zero? revision)
105 release
106 (string-append release "-"
107 (number->string revision))))
108 (source (origin
109 (method url-fetch)
110 (uri (string-append "mirror://gnu/artanis/artanis-"
111 release ".tar.gz"))
112 (file-name (string-append name "-" version ".tar.gz"))
113 (sha256
114 (base32
cd81199c 115 "0hqr5m3mb558bdhkc2sadmd9cbrhp3y525wx7cwirgy6i0zmay68"))
0791437f
RW
116 (modules '((guix build utils)))
117 (snippet
118 '(begin
cd81199c 119 ;; Unbundle guile-redis and guile-json
0791437f
RW
120 (delete-file-recursively "artanis/third-party/json.scm")
121 (delete-file-recursively "artanis/third-party/json")
cd81199c 122 (delete-file-recursively "artanis/third-party/redis.scm")
123 (delete-file-recursively "artanis/third-party/redis")
0791437f 124 (substitute* '("artanis/artanis.scm"
cd81199c 125 "artanis/lpc.scm"
0791437f
RW
126 "artanis/oht.scm")
127 (("(#:use-module \\()artanis third-party (json\\))" _
128 use-module json)
129 (string-append use-module json)))
cd81199c 130 (substitute* '("artanis/lpc.scm"
131 "artanis/session.scm")
132 (("(#:use-module \\()artanis third-party (redis\\))" _
133 use-module redis)
134 (string-append use-module redis)))
0791437f
RW
135 (substitute* "artanis/oht.scm"
136 (("([[:punct:][:space:]]+)(->json-string)([[:punct:][:space:]]+)"
137 _ pre json-string post)
138 (string-append pre
139 "scm" json-string
140 post)))
141 (substitute* "artanis/artanis.scm"
142 (("[[:punct:][:space:]]+->json-string[[:punct:][:space:]]+")
143 ""))
144 #t))))
145 (build-system gnu-build-system)
cd81199c 146 ;; FIXME the bundled csv contains one more exported procedure
147 ;; (sxml->csv-string) than guile-csv. The author is maintainer of both
148 ;; projects.
0791437f
RW
149 ;; TODO: Add guile-dbi and guile-dbd optional dependencies.
150 (inputs `(("guile" ,guile-2.2)
91f55717 151 ("guile-json" ,guile-json-1)
cd81199c 152 ("guile-redis" ,guile-redis)))
0791437f
RW
153 (native-inputs `(("bash" ,bash) ;for the `source' builtin
154 ("pkgconfig" ,pkg-config)
155 ("util-linux" ,util-linux))) ;for the `script' command
156 (arguments
157 '(#:make-flags
158 ;; TODO: The documentation must be built with the `docs' target.
159 (let* ((out (assoc-ref %outputs "out"))
160 (scm (string-append out "/share/guile/site/2.2"))
161 (go (string-append out "/lib/guile/2.2/site-ccache")))
162 ;; Don't use (%site-dir) for site paths.
163 (list (string-append "MOD_PATH=" scm)
164 (string-append "MOD_COMPILED_PATH=" go)))
165 #:test-target "test"
166 #:phases
167 (modify-phases %standard-phases
fd9a6d83
CB
168 (add-after 'unpack 'patch-site-dir
169 (lambda* (#:key outputs #:allow-other-keys)
170 (substitute* "artanis/commands/help.scm"
171 (("\\(%site-dir\\)")
172 (string-append "\""
173 (assoc-ref outputs "out")
174 "/share/guile/site/2.2\"")))))
0791437f
RW
175 (add-before 'install 'substitute-root-dir
176 (lambda* (#:key outputs #:allow-other-keys)
177 (let ((out (assoc-ref outputs "out")))
178 (substitute* "Makefile" ;ignore the execution of bash.bashrc
179 ((" /etc/bash.bashrc") " /dev/null"))
180 (substitute* "Makefile" ;set the root of config files to OUT
181 ((" /etc") (string-append " " out "/etc")))
182 (mkdir-p (string-append out "/bin")) ;for the `art' executable
183 #t)))
184 (add-after 'install 'wrap-art
fd9a6d83 185 (lambda* (#:key inputs outputs #:allow-other-keys)
0791437f
RW
186 (let* ((out (assoc-ref outputs "out"))
187 (bin (string-append out "/bin"))
188 (scm (string-append out "/share/guile/site/2.2"))
189 (go (string-append out "/lib/guile/2.2/site-ccache")))
190 (wrap-program (string-append bin "/art")
fd9a6d83
CB
191 `("GUILE_LOAD_PATH" ":" prefix
192 (,scm ,(getenv "GUILE_LOAD_PATH")))
193 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
194 (,go ,(getenv "GUILE_LOAD_COMPILED_PATH"))))
0791437f
RW
195 #t))))))
196 (synopsis "Web application framework written in Guile")
197 (description "GNU Artanis is a web application framework written in Guile
198Scheme. A web application framework (WAF) is a software framework that is
199designed to support the development of dynamic websites, web applications, web
200services and web resources. The framework aims to alleviate the overhead
201associated with common activities performed in web development. Artanis
202provides several tools for web development: database access, templating
203frameworks, session management, URL-remapping for RESTful, page caching, and
204more.")
205 (home-page "https://www.gnu.org/software/artanis/")
206 (license (list license:gpl3+ license:lgpl3+))))) ;dual license
207
208;; There has not been any release yet.
209(define-public guildhall
210 (let ((commit "2fe2cc539f4b811bbcd69e58738db03eb5a2b778")
211 (revision "1"))
212 (package
213 (name "guildhall")
214 (version (string-append "0-" revision "." (string-take commit 9)))
215 (source (origin
216 (method git-fetch)
217 (uri (git-reference
218 (url "https://github.com/ijp/guildhall.git")
219 (commit commit)))
220 (file-name (string-append name "-" version "-checkout"))
221 (sha256
222 (base32
223 "115bym7bg66h3gs399yb2vkzc2ygriaqsn4zbrg8f054mgy8wzn1"))))
224 (build-system gnu-build-system)
225 (arguments
226 `(#:phases
227 (modify-phases %standard-phases
228 ;; Tests fail without this fix because they try to load the bash
229 ;; executable as a Scheme file. See bug report at
230 ;; https://github.com/ijp/guildhall/issues/22
231 (add-after 'unpack 'fix-bug-22
232 (lambda _
233 (substitute* "Makefile.am"
234 (("TESTS_ENVIRONMENT=.*")
235 "AM_TESTS_ENVIRONMENT=srcdir=$(abs_top_srcdir)/tests/
236TEST_EXTENSIONS = .scm
237SCM_LOG_COMPILER= $(top_builddir)/env $(GUILE)
238AM_SCM_LOG_FLAGS = --no-auto-compile -s")
239 ;; FIXME: one of the database tests fails for unknown
240 ;; reasons. It does not fail when run outside of Guix.
241 (("tests/database.scm") ""))
242 #t)))))
243 (inputs
244 `(("guile" ,guile-2.0)))
245 (native-inputs
246 `(("zip" ,zip) ; for tests
247 ("autoconf" ,autoconf)
248 ("automake" ,automake)
249 ("texinfo" ,texinfo)))
250 (synopsis "Package manager for Guile")
251 (description
252 "Guildhall is a package manager written for Guile Scheme. A guild is
253an association of independent craftspeople. A guildhall is where they meet.
254This Guildhall aims to make a virtual space for Guile wizards and journeyfolk
255to share code.
256
257On a practical level, Guildhall lets you share Scheme modules and programs
258over the internet, and install code that has been shared by others. Guildhall
259can handle dependencies, so when a program requires several libraries, and
260each of those has further dependencies, all of the prerequisites for the
261program can be installed in one go.")
262 (home-page "https://github.com/ijp/guildhall")
263 (license license:gpl3+))))
264
265(define-public guile-aspell
266 (package
267 (name "guile-aspell")
268 (version "0.4")
269 (source (origin
270 (method url-fetch)
271 (uri (string-append
272 "http://lonelycactus.com/tarball/guile_aspell-"
273 version ".tar.gz"))
274 (sha256
275 (base32
276 "0vpk5xj9m9qc702z3khmkwhgpb949qbsyz8kw2qycda6qnxk0077"))))
277 (build-system gnu-build-system)
278 (arguments
279 '(#:phases (modify-phases %standard-phases
280 (add-before 'configure 'set-guilesitedir
281 (lambda _
282 (substitute* "Makefile.in"
283 (("^guilesitedir =.*$")
284 "guilesitedir = \
285$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
286 #t))
287 (add-before 'build 'set-libaspell-file-name
288 (lambda* (#:key inputs #:allow-other-keys)
289 (let ((aspell (assoc-ref inputs "aspell")))
290 (substitute* "aspell.scm"
291 (("\"libaspell\\.so\"")
292 (string-append "\"" aspell
293 "/lib/libaspell\"")))
294 #t))))))
295 (native-inputs `(("pkg-config" ,pkg-config)))
296 (inputs `(("guile" ,guile-2.2)
297 ("aspell" ,aspell)))
298 (home-page "https://github.com/spk121/guile-aspell")
299 (synopsis "Spell-checking from Guile")
300 (description
301 "guile-aspell is a Guile Scheme library for comparing a string against a
302dictionary and suggesting spelling corrections.")
303 (license license:gpl3+)))
304
305(define-public guile-bash
306 ;; This project is currently retired. It was initially announced here:
307 ;; <https://lists.gnu.org/archive/html/guile-user/2015-02/msg00003.html>.
308 (let ((commit "1eabc563ca5692b3e08d84f1f0e6fd2283284469")
309 (revision "0"))
310 (package
311 (name "guile-bash")
312 (version (string-append "0.1.6-" revision "." (string-take commit 7)))
313 (home-page
314 "https://anonscm.debian.org/cgit/users/kaction-guest/retired/dev.guile-bash.git")
315 (source (origin
316 (method git-fetch)
317 (uri (git-reference
318 (commit commit)
319 (url home-page)))
320 (sha256
321 (base32
322 "097vny990wp2qpjij6a5a5gwc6fxzg5wk56inhy18iki5v6pif1p"))
323 (file-name (string-append name "-" version "-checkout"))))
324 (build-system gnu-build-system)
325 (arguments
326 '(#:configure-flags
327 ;; Add -I to match 'bash.pc' of Bash 4.4.
328 (list (string-append "CPPFLAGS=-I"
329 (assoc-ref %build-inputs "bash:include")
330 "/include/bash/include")
331
332 ;; The '.a' file is useless.
333 "--disable-static"
334
335 ;; Install 'lib/bash' as Bash 4.4 expects.
336 (string-append "--libdir=" (assoc-ref %outputs "out")
337 "/lib/bash"))))
338 (native-inputs `(("pkg-config" ,pkg-config)
339 ("autoconf" ,autoconf-wrapper)
340 ("automake" ,automake)
341 ("libtool" ,libtool)
342 ;; Gettext brings 'AC_LIB_LINKFLAGS_FROM_LIBS'.
343 ("gettext" ,gettext-minimal)
344
345 ;; Bash with loadable module support, for the test
346 ;; suite.
347 ("bash-full" ,bash)))
348 (inputs `(("guile" ,guile-2.0)
349 ("bash:include" ,bash "include")))
350 (synopsis "Extend Bash using Guile")
351 (description
352 "Guile-Bash provides a shared library and set of Guile modules,
353allowing you to extend Bash in Scheme. Scheme interfaces allow you to access
354the following aspects of Bash:
355
356@itemize
357@item aliases;
358@item setting and getting Bash variables;
359@item creating dynamic variables;
360@item creating Bash functions with a Scheme implementation;
361@item reader macro for output capturing;
362@item reader macro for evaluating raw Bash commands.
363@end itemize
364
365To enable it, run:
366
367@example
368enable -f ~/.guix-profile/lib/bash/libguile-bash.so scm
369@end example
370
371and then run @command{scm example.scm}.")
372 (license license:gpl3+))))
373
374(define-public guile-8sync
375 (package
376 (name "guile-8sync")
377 (version "0.4.2")
378 (source (origin
379 (method url-fetch)
380 (uri (string-append "mirror://gnu/8sync/8sync-" version
381 ".tar.gz"))
382 (sha256
383 (base32
384 "031wm13srak3wsnll7j2mbbi29g1pcm4swdb71ds9yn567pn20qw"))))
385 (build-system gnu-build-system)
386 (native-inputs `(("autoconf" ,autoconf)
387 ("automake" ,automake)
388 ("guile" ,guile-2.2)
389 ("pkg-config" ,pkg-config)
390 ("texinfo" ,texinfo)))
391 (arguments
392 `(#:phases (modify-phases %standard-phases
393 (add-before 'configure 'setenv
394 (lambda _
395 ;; quiet warnings
396 (setenv "GUILE_AUTO_COMPILE" "0")
397 #t)))))
398 (home-page "https://gnu.org/s/8sync/")
399 (synopsis "Asynchronous actor model library for Guile")
400 (description
401 "GNU 8sync (pronounced \"eight-sync\") is an asynchronous programming
402library for GNU Guile based on the actor model.
403
404Note that 8sync is only available for Guile 2.2.")
405 (license license:lgpl3+)))
406
407(define-public guile-daemon
408 (package
409 (name "guile-daemon")
410 (version "0.1.2")
411 (source (origin
412 (method url-fetch)
413 (uri (string-append "https://github.com/alezost/" name
414 "/releases/download/v" version
415 "/" name "-" version ".tar.gz"))
416 (sha256
417 (base32
418 "0hh6gq6b6phpxm0b1dkxyzj3f4sxdf7dji63609lzypa5v1ad2gv"))))
419 (build-system gnu-build-system)
420 (native-inputs
421 `(("pkg-config" ,pkg-config)))
422 (inputs
423 `(("guile" ,guile-2.2)))
424 (home-page "https://github.com/alezost/guile-daemon")
425 (synopsis "Evaluate code in a running Guile process")
426 (description
427 "Guile-Daemon is a small Guile program that loads your initial
428configuration file, and then reads and evaluates Guile expressions that
429you send to a FIFO file.")
430 (license license:gpl3+)))
431
432(define-public guile-dsv
433 (package
434 (name "guile-dsv")
435 (version "0.2.1")
436 (source (origin
437 (method git-fetch)
438 (uri (git-reference
439 (url "https://github.com/artyom-poptsov/guile-dsv")
440 (commit "bdc5267d007478abc20ea96d7c459b7dd9560b3d")))
441 (file-name (string-append name "-" version "-checkout"))
442 (sha256
443 (base32
444 "1irw6mz8998nwyhzrw9g94jcz60b9zljgqfmipaz1ybn8579qjx0"))))
445 (build-system gnu-build-system)
446 (native-inputs
447 `(("autoconf" ,autoconf)
448 ("automake" ,automake)
449 ("pkg-config" ,pkg-config)
450 ("texinfo" ,texinfo)))
451 (inputs `(("guile" ,guile-2.2)))
452 (propagated-inputs `(("guile-lib" ,guile-lib)))
453 (arguments
454 '(#:phases (modify-phases %standard-phases
455 (add-before 'configure 'set-guilesitedir
456 (lambda _
457 (substitute* "Makefile.in"
458 (("^guilesitedir =.*$")
459 "guilesitedir = \
460$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
461 (substitute* "modules/Makefile.in"
462 (("^guilesitedir =.*$")
463 "guilesitedir = \
464$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
465 (substitute* "modules/dsv/Makefile.in"
466 (("^guilesitedir =.*$")
467 "guilesitedir = \
468$(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
469 #t)))))
470 (home-page "https://github.com/artyom-poptsov/guile-dsv")
471 (synopsis "DSV module for Guile")
472 (description
473 "Guile-DSV is a GNU Guile module for working with the
474delimiter-separated values (DSV) data format. Guile-DSV supports the
475Unix-style DSV format and RFC 4180 format.")
476 (license license:gpl3+)))
477
478(define-public guile-fibers
479 (package
480 (name "guile-fibers")
481 (version "1.0.0")
482 (source (origin
483 (method url-fetch)
484 (uri (string-append "https://wingolog.org/pub/fibers/fibers-"
485 version ".tar.gz"))
486 (sha256
487 (base32
488 "0vjkg72ghgdgphzbjz9ig8al8271rq8974viknb2r1rg4lz92ld0"))))
489 (build-system gnu-build-system)
490 (arguments
491 '(#:phases (modify-phases %standard-phases
492 (add-after 'install 'mode-guile-objects
493 (lambda* (#:key outputs #:allow-other-keys)
494 ;; .go files are installed to "lib/guile/X.Y/cache".
495 ;; This phase moves them to "…/site-ccache".
496 (let* ((out (assoc-ref outputs "out"))
497 (lib (string-append out "/lib/guile"))
498 (old (car (find-files lib "^ccache$"
499 #:directories? #t)))
500 (new (string-append (dirname old)
501 "/site-ccache")))
502 (rename-file old new)
503 #t))))))
504 (native-inputs
505 `(("texinfo" ,texinfo)
506 ("pkg-config" ,pkg-config)))
507 (inputs
508 `(("guile" ,guile-2.2)))
509 (synopsis "Lightweight concurrency facility for Guile")
510 (description
511 "Fibers is a Guile library that implements a a lightweight concurrency
512facility, inspired by systems like Concurrent ML, Go, and Erlang. A fiber is
513like a \"goroutine\" from the Go language: a lightweight thread-like
514abstraction. Systems built with Fibers can scale up to millions of concurrent
515fibers, tens of thousands of concurrent socket connections, and many parallel
516cores. The Fibers library also provides Concurrent ML-like channels for
517communication between fibers.
518
519Note that Fibers makes use of some Guile 2.1/2.2-specific features and
520is not available for Guile 2.0.")
521 (home-page "https://github.com/wingo/fibers")
522 (license license:lgpl3+)))
523
524(define-public guile-syntax-highlight
525 (package
526 (name "guile-syntax-highlight")
527 (version "0.1")
528 (source (origin
529 (method url-fetch)
530 (uri (string-append "https://files.dthompson.us/"
531 "guile-syntax-highlight/"
532 "guile-syntax-highlight-"
533 version ".tar.gz"))
534 (sha256
535 (base32
536 "1p771kq15x83483m23bhah1sz6vkalg3drm7x279f4j1cxligkzi"))))
537 (build-system gnu-build-system)
538 (native-inputs
539 `(("pkg-config" ,pkg-config)))
540 (inputs
541 `(("guile" ,guile-2.2)))
542 (synopsis "General-purpose syntax highlighter for GNU Guile")
543 (description "Guile-syntax-highlight is a general-purpose syntax
544highlighting library for GNU Guile. It can parse code written in various
545programming languages into a simple s-expression that can be converted to
546HTML (via SXML) or any other format for rendering.")
547 (home-page "http://dthompson.us/projects/guile-syntax-highlight.html")
548 (license license:lgpl3+)))
549
550(define-public guile-sjson
551 (package
552 (name "guile-sjson")
553 (version "0.2.1")
554 (source (origin
555 (method url-fetch)
556 (uri (string-append "https://dustycloud.org/misc/sjson-" version
557 ".tar.gz"))
558 (sha256
559 (base32
560 "1mzmapln79vv10qxaggz9qwcdbag3jnrj19xx8bgkmxss8h03sv3"))))
561 (build-system gnu-build-system)
562 (native-inputs
563 `(("autoconf" ,autoconf)
564 ("automake" ,automake)
565 ("pkg-config" ,pkg-config)))
566 (inputs
567 `(("guile" ,guile-2.2)))
568 (home-page "https://gitlab.com/dustyweb/guile-sjson")
569 (synopsis "S-expression based json reader/writer for Guile")
570 (description "guile-sjson is a json reader/writer for Guile.
571It has a nice, simple s-expression based syntax.")
572 (license license:lgpl3+)))
573
61dafdc0
CB
574(define-public guile-squee
575 (let ((commit "a85902a92bf6f58a1d35fd974a01ade163deda8d")
576 (revision "0"))
577 (package
578 (name "guile-squee")
579 (version (string-append "0-" revision "." (string-take commit 7)))
580 (source (origin
581 (method git-fetch)
582 (uri (git-reference
583 (url "https://notabug.org/cwebber/guile-squee.git")
584 (commit commit)))
585 (file-name (git-file-name name version))
586 (sha256
587 (base32
588 "0p1lpsp4kx57j3ai1dkxilm4ziavzzx8wbbc42m3hpziq0a7qz5z"))))
589 (build-system guile-build-system)
590 (arguments
591 '(#:phases
592 (modify-phases %standard-phases
593 (add-after 'unpack 'patch
594 (lambda* (#:key inputs #:allow-other-keys)
595 (substitute* "squee.scm"
596 (("dynamic-link \"libpq\"")
597 (string-append
598 "dynamic-link \""
599 (assoc-ref inputs "postgresql") "/lib/libpq.so"
600 "\"")))
601 #t)))))
602 (inputs
603 `(("postgresql" ,postgresql)))
604 (native-inputs
605 `(("guile" ,guile-2.2)))
606 (home-page "https://notabug.org/cwebber/guile-squee")
607 (synopsis "Connect to PostgreSQL using Guile")
608 (description
609 "@code{squee} is a Guile library for connecting to PostgreSQL databases
610using Guile's foreign function interface.")
6fd72f70 611 (license license:lgpl3+))))
61dafdc0 612
0791437f
RW
613(define-public guile-colorized
614 (package
615 (name "guile-colorized")
616 (version "0.1")
1340ce28
TGR
617 (source
618 (origin
619 (method git-fetch)
620 (uri (git-reference
55f4282e 621 (url "https://gitlab.com/NalaGinrut/guile-colorized.git")
1340ce28
TGR
622 (commit (string-append "v" version))))
623 (file-name (git-file-name name version))
624 (sha256
625 (base32 "10mv8c63159r3qvwwdvsgnsvdg7nc2ghak85zapwqpv4ywrqp9zc"))))
0791437f
RW
626 (build-system guile-build-system)
627 (native-inputs
628 `(("guile" ,guile-2.2)))
55f4282e 629 (home-page "https://gitlab.com/NalaGinrut/guile-colorized")
0791437f
RW
630 (synopsis "Colorized REPL for Guile")
631 (description
632 "Guile-colorized provides you with a colorized REPL for GNU Guile.")
633 (license license:gpl3+)))
634
635(define-public guile-pfds
636 (package
637 (name "guile-pfds")
638 (version "0.3")
639 (home-page "https://github.com/ijp/pfds")
640 (source (origin
641 (method git-fetch)
642 (uri (git-reference
643 (url home-page)
644 (commit (string-append "v" version))))
645 (sha256
646 (base32
647 "19y33wg94pf0n98dkfqd1zbw93fgky4sawxsxl6s3vyqwl0yi5vh"))
648 (file-name (string-append name "-" version "-checkout"))))
649 (build-system guile-build-system)
650 (arguments
651 '(#:source-directory "src"
652 #:phases (modify-phases %standard-phases
653 (add-after 'unpack 'move-files-around
654 (lambda _
655 ;; Move files under a pfds/ directory to reflect the
656 ;; module hierarchy.
657 (mkdir-p "src/pfds")
658 (for-each (lambda (file)
659 (rename-file file
660 (string-append "src/pfds/"
661 file)))
662 '("bbtrees.sls"
663 "deques"
664 "deques.sls"
665 "dlists.sls"
666 "fingertrees.sls"
667 "hamts.sls"
668 "heaps.sls"
669 "private"
670 "psqs.sls"
671 "queues"
672 "queues.sls"
673 "sequences.sls"
674 "sets.sls"))
675
676 ;; In Guile <= 2.2.4, there's no way to tell 'guild
677 ;; compile' to accept the ".sls" extension. So...
678 (for-each (lambda (file)
679 (rename-file file
680 (string-append
681 (string-drop-right file 4)
682 ".scm")))
683 (find-files "." "\\.sls$"))
684 #t)))))
685 (native-inputs
686 `(("guile" ,guile-2.2)))
687 (synopsis "Purely functional data structures for Guile")
688 (description
689 "This package provides purely functional data structures written in R6RS
690Scheme and compiled for Guile. It has been tested with Racket, Guile 2,
691Vicare Scheme and IronScheme. Right now it contains:
692
693@itemize
694@item queues
695@item deques
696@item bbtrees
697@item sets
698@item dlists
699@item priority search queues (PSQs)
700@item finger trees
701@item sequences
702@item heaps
703@item hash array mapped tries (HAMTs).
704@end itemize\n")
705 (license license:bsd-3)))
706
707(define-public guile-aa-tree
708 (package
709 (name "guile-aa-tree")
710 (version "3.1.1")
711 (source (origin
712 (method url-fetch)
713 (uri (string-append "mirror://savannah/guile-aa-tree/guile-aa-tree-"
714 version ".tar.gz"))
715 (sha256
716 (base32
717 "0044c105r3q9vpl17pv3phl1b79kjm1llhkakqgiasixyav01blh"))))
718 (build-system guile-build-system)
719 (native-inputs `(("guile" ,guile-2.2)))
720 ;; https://savannah.nongnu.org/projects/guile-aa-tree
721 (home-page "https://qlfiles.net/guile-aa-tree/")
722 (synopsis "AA tree data structure for Guile")
723 (description
724 "This package provides an implementation of @dfn{AA trees}, a
725self-balancing binary tree data structure, for Guile. It ensure @math{O(log
726n)} worst case performance for core operations. The module provides
727non-mutating insert, delete, and search operations, with support for
728convenient nested tree operations.")
729 (license license:gpl3+)))
730
731(define-public guile-simple-zmq
732 (let ((commit "68bedb6679716214fb9d3472da57544526f7a618")
733 (revision "3"))
734 (package
735 (name "guile-simple-zmq")
736 (version (git-version "0.0.0" revision commit))
737 (source
738 (origin
739 (method git-fetch)
740 (uri (git-reference
741 (url "https://github.com/jerry40/guile-simple-zmq")
742 (commit commit)))
743 (sha256
744 (base32
745 "1ad3xg69qqviy1f6dnlw0ysmfdbmp1jq65rfqb8nfd8dsrq2syli"))
746 (file-name (git-file-name name version))))
747 (build-system guile-build-system)
748 (arguments
749 `(#:source-directory "src"
750 #:phases (modify-phases %standard-phases
751 (add-after 'unpack 'set-libzmq-file-name
752 (lambda* (#:key inputs #:allow-other-keys)
753 (substitute* "src/simple-zmq.scm"
754 (("\\(dynamic-link \"libzmq\"\\)")
755 (format #f "(dynamic-link \"~a/lib/libzmq.so\")"
756 (assoc-ref inputs "zeromq"))))
757 #t)))))
758 (native-inputs
759 `(("guile" ,guile-2.2)))
760 (inputs
761 `(("zeromq" ,zeromq)))
762 (home-page "https://github.com/jerry40/guile-simple-zmq")
763 (synopsis "Guile wrapper over ZeroMQ library")
764 (description
765 "This package provides a Guile programming interface to the ZeroMQ
766messaging library.")
767 (license license:gpl3+))))
768
769(define-public jupyter-guile-kernel
770 (let ((commit "a7db9245a886e104138474df46c3e88b95cff629")
771 (revision "1"))
772 (package
773 (name "jupyter-guile-kernel")
774 (version (git-version "0.0.0" revision commit))
775 (source
776 (origin
777 (method git-fetch)
778 (uri (git-reference
779 (url "https://github.com/jerry40/guile-kernel")
780 (commit commit)))
781 (sha256
782 (base32
783 "0aj04853bqm47ivfcmrgpb7w3wkis847kc7qrwsa5zcn9h38qh2f"))))
784 (build-system guile-build-system)
785 (arguments
786 '(#:phases (modify-phases %standard-phases
787 (add-after 'unpack 'set-openssl-file-name
788 (lambda* (#:key inputs #:allow-other-keys)
789 ;; Record the absolute file name of the 'openssl'
790 ;; command.
791 (substitute* "src/hmac.scm"
792 (("openssl")
793 (string-append (assoc-ref inputs "openssl")
794 "/bin/openssl")))
795 #t))
796
797 ;; XXX: The code uses 'include' to include its own source
798 ;; files, and "-L src" isn't enough in this case.
799 (add-before 'build 'chdir
800 (lambda _ (chdir "src") #t))
801 (add-after 'build 'chdir-back
802 (lambda _ (chdir "..") #t))
803
804 (add-after 'install 'install-kernel
805 (lambda* (#:key inputs outputs #:allow-other-keys)
806 (let* ((out (assoc-ref outputs "out"))
807 (json (assoc-ref inputs "guile-json"))
808 (zmq (assoc-ref inputs "guile-simple-zmq"))
809 (deps (list json zmq))
810 (dir (string-append
811 out "/share/jupyter/kernels/guile"))
812 (effective (target-guile-effective-version)))
813 ;; Install kernel.
814 (install-file "src/kernel.json" dir)
815
816 ;; Fix hard-coded file name in the kernel.
817 (substitute* (string-append dir "/kernel.json")
818 (("/home/.*/guile-jupyter-kernel.scm")
819 (string-append out "/share/guile/site/"
820 (target-guile-effective-version)
821 "/guile-jupyter-kernel.scm"))
822 (("\"guile\"")
823 (string-append "\"" (assoc-ref inputs "guile")
824 "/bin/guile\""))
825 (("-s")
826 ;; Add '-L' and '-C' flags so that the kernel
827 ;; finds its dependencies.
828 (let ((-L (map (lambda (item)
829 (string-append "\"" item
830 "/share/guile/site/"
831 effective "\""))
832 deps))
833 (-C (map (lambda (item)
834 (string-append "\"" item
835 "/lib/guile/"
836 effective
837 "/site-ccache\""))
838 deps)))
839 (string-append "--no-auto-compile\""
840 (string-join -L ", \"-L\", "
841 'prefix)
842 (string-join -C ", \"-C\", "
843 'prefix)
844 ", \"-s"))))
845 #t))))))
846 (inputs
847 `(("openssl" ,openssl)
848 ("guile" ,guile-2.2)
91f55717 849 ("guile-json" ,guile-json-1)
0791437f
RW
850 ("guile-simple-zmq" ,guile-simple-zmq)))
851 (synopsis "Guile kernel for the Jupyter Notebook")
852 (description
853 "This package provides a Guile 2.x kernel for the Jupyter Notebook. It
854allows users to interact with the Guile REPL through Jupyter.")
855 (home-page "https://github.com/jerry40/guile-kernel")
856 (license license:gpl3+))))
857
858(define-public guile-sparql
859 (package
860 (name "guile-sparql")
861 (version "0.0.7")
862 (source (origin
863 (method url-fetch)
864 (uri (string-append
865 "https://github.com/roelj/guile-sparql/releases/download/"
866 version "/guile-sparql-" version ".tar.gz"))
867 (sha256
868 (base32 "1drnvhsgl0gc5crmb16yyw1j98nkhwwcgssv9vgm36ng43nnzffd"))))
869 (build-system gnu-build-system)
870 (arguments `(#:tests? #f)) ; There are no tests.
871 (native-inputs
872 `(("pkg-config" ,pkg-config)))
873 (inputs
874 `(("guile" ,guile-2.2)))
875 (home-page "https://github.com/roelj/guile-sparql")
876 (synopsis "SPARQL module for Guile")
877 (description "This package provides the functionality to query a SPARQL
878endpoint. Additionally, it provides an interface to write SPARQL queries
879using S-expressions.")
880 (license license:gpl3+)))
881
882(define-public guile-debbugs
883 (package
884 (name "guile-debbugs")
885 (version "0.0.2")
886 (source (origin
887 (method url-fetch)
888 (uri (string-append "mirror://gnu/guile-debbugs/guile-debbugs-"
889 version ".tar.gz"))
890 (sha256
891 (base32
892 "16l8910p57im6s3j93xhdaqvgfy6ms5n97177mrch3y961z5hy0i"))
893 (modules '((guix build utils)))
894 (snippet
895 '(substitute* "Makefile.in"
896 (("^godir = (.*)/ccache" _ prefix)
897 (string-append "godir = " prefix "/site-ccache"))))))
898 (build-system gnu-build-system)
899 (native-inputs
900 `(("guile" ,guile-2.2)
901 ("pkg-config" ,pkg-config)))
902 (home-page "https://savannah.gnu.org/projects/guile-debbugs/")
903 (synopsis "Guile interface to the Debbugs bug tracking service")
904 (description
905 "This package provides a Guile library to communicate with a Debbugs bug
906tracker's SOAP service, such as @url{https://bugs.gnu.org}.")
907 (license license:gpl3+)))
908
909(define-public guile-email
50771f5b
AI
910 (package
911 (name "guile-email")
2c33a849 912 (version "0.2.1")
50771f5b
AI
913 (source
914 (origin
915 (method url-fetch)
916 (uri (string-append
db18d87a
AI
917 "https://guile-email.systemreboot.net/releases/guile-email-"
918 version ".tar.lz"))
50771f5b
AI
919 (sha256
920 (base32
2c33a849 921 "1ph3pb69hr3d8mj05fmbpf5rc67dlm8qnb35cc7cxz8ingvl7kv3"))))
50771f5b
AI
922 (build-system gnu-build-system)
923 (native-inputs
924 `(("pkg-config" ,pkg-config)
db18d87a 925 ("lzip" ,lzip)))
50771f5b
AI
926 (inputs
927 `(("guile" ,guile-2.2)))
db18d87a 928 (arguments
2c33a849 929 '(#:make-flags '("GUILE_AUTO_COMPILE=0"))) ; to prevent guild warnings
db18d87a 930 (home-page "https://guile-email.systemreboot.net")
50771f5b 931 (synopsis "Guile email parser")
db18d87a
AI
932 (description "guile-email is a collection of email utilities implemented
933in pure guile. It supports parsing MIME (Multipurpose Internet Mail
934Extensions) compliant email messages and reading emails from the mbox
935format.")
50771f5b 936 (license license:agpl3+)))
0791437f
RW
937
938(define-public guile-debbugs-next
014c3012
RW
939 (let ((commit "fb0ae064037a38a0d526e08b4ad24c52e205edb9")
940 (revision "2"))
0791437f
RW
941 (package (inherit guile-debbugs)
942 (name "guile-debbugs")
943 (version (git-version "0.0.3" revision commit))
944 (source (origin
945 (method git-fetch)
946 (uri (git-reference
947 (url "https://git.savannah.gnu.org/git/guile-debbugs.git")
948 (commit commit)))
949 (file-name (git-file-name name version))
950 (sha256
951 (base32
014c3012 952 "195sacx2xc1mzzfljj62nfpi8mxn0rc6dabxckizjksnhb5irfwy"))))
0791437f
RW
953 (build-system gnu-build-system)
954 (native-inputs
955 `(("pkg-config" ,pkg-config)
956 ("autoconf" ,autoconf)
957 ("automake" ,automake)
958 ("texinfo" ,texinfo)))
959 (inputs
960 `(("guile" ,guile-2.2)
961 ("guile-email" ,guile-email))))))
962
0791437f 963(define-public guile-newt
442a11f6
MO
964 (package
965 (name "guile-newt")
966 (version "0.0.1")
967 (source (origin
968 (method git-fetch)
969 (uri (git-reference
970 (url "https://gitlab.com/mothacehe/guile-newt")
971 (commit version)))
972 (file-name (git-file-name name version))
973 (sha256
974 (base32
975 "1w7qy4dw1f4bx622l6hw8mv49sf1ha8kch8j4nganyk8fj0wn695"))))
976 (build-system gnu-build-system)
977 (arguments
978 '(#:make-flags
979 '("GUILE_AUTO_COMPILE=0"))) ;to prevent guild warnings
980 (inputs
981 `(("guile" ,guile-2.2)
982 ("newt" ,newt)))
983 (native-inputs
984 `(("autoconf" ,autoconf)
985 ("automake" ,automake)
986 ("pkg-config" ,pkg-config)))
987 (synopsis "Guile bindings to Newt")
988 (description
989 "This package provides bindings for Newt, a programming library for
0791437f
RW
990color text mode, widget based user interfaces. The bindings are written in pure
991Scheme by using Guile’s foreign function interface.")
442a11f6
MO
992 (home-page "https://gitlab.com/mothacehe/guile-newt")
993 (license license:gpl3+)))
0791437f
RW
994
995(define-public guile-mastodon
996 (package
997 (name "guile-mastodon")
998 (version "0.0.1")
999 (source (origin
1000 (method git-fetch)
1001 (uri (git-reference
1002 (url "https://framagit.org/prouby/guile-mastodon.git")
1003 (commit (string-append "v" version))))
1004 (file-name (git-file-name name version))
1005 (sha256
1006 (base32
1007 "1vblf3d1bbwna3l09p2ap5y8ycvl549bz6whgk78imyfmn28ygry"))))
1008 (build-system gnu-build-system)
1009 (native-inputs
1010 `(("autoconf" ,autoconf)
1011 ("automake" ,automake)
1012 ("pkg-config" ,pkg-config)))
1013 (inputs
1014 `(("guile" ,guile-2.2)
1015 ("gnutls" ,gnutls)
91f55717 1016 ("guile-json" ,guile-json-1)))
0791437f
RW
1017 (home-page "https://framagit.org/prouby/guile-mastodon")
1018 (synopsis "Guile Mastodon REST API module")
1019 (description "This package provides Guile modules to access the
1020@uref{https://docs.joinmastodon.org/api/, REST API of Mastodon}, a federated
1021microblogging service.")
1022 (license license:gpl3+)))
1023
0791437f 1024(define-public guile-parted
dbcd503c
MO
1025 (package
1026 (name "guile-parted")
a3246602 1027 (version "0.0.2")
dbcd503c
MO
1028 (source (origin
1029 (method git-fetch)
1030 (uri (git-reference
1031 (url "https://gitlab.com/mothacehe/guile-parted")
1032 (commit version)))
1033 (file-name (git-file-name name version))
1034 (sha256
1035 (base32
a3246602 1036 "01qmv6xnbbq3wih0dl9bscvca2d7zx7bjiqf35y6dkaqsp8nvdxf"))))
dbcd503c
MO
1037 (build-system gnu-build-system)
1038 (arguments
1039 '(#:make-flags
1040 '("GUILE_AUTO_COMPILE=0"))) ;to prevent guild warnings
1041 (inputs
1042 `(("guile" ,guile-2.2)
1043 ("parted" ,parted)))
1044 (propagated-inputs
1045 `(("guile-bytestructures" ,guile-bytestructures)))
1046 (native-inputs
1047 `(("autoconf" ,autoconf)
1048 ("automake" ,automake)
1049 ("pkg-config" ,pkg-config)))
1050 (synopsis "Guile bindings to GNU Parted")
1051 (description
1052 "This package provides bindings for GNU Parted library, a C library
1053allowing disk partition tables creation and manipulation. The bindings are
0791437f 1054written in pure Scheme by using Guile's foreign function interface.")
dbcd503c
MO
1055 (home-page "https://gitlab.com/mothacehe/guile-parted")
1056 (license license:gpl3+)))
0791437f
RW
1057
1058(define-public guile-xosd
1059 (package
1060 (name "guile-xosd")
1061 (version "0.2.1")
1062 (source (origin
1063 (method url-fetch)
1064 (uri (string-append "https://github.com/alezost/" name
1065 "/releases/download/v" version
1066 "/" name "-" version ".tar.gz"))
1067 (sha256
1068 (base32
1069 "1ri5065c16kmgrf2pysn2ymxjqi5302lhpb07wkl1jr75ym8fn8p"))))
1070 (build-system gnu-build-system)
1071 (native-inputs
1072 `(("pkg-config" ,pkg-config)))
1073 (inputs
1074 `(("guile" ,guile-2.2)
1075 ("libx11" ,libx11)
1076 ("libxext" ,libxext)
1077 ("libxinerama" ,libxinerama)
1078 ("xosd" ,xosd)))
1079 (home-page "https://github.com/alezost/guile-xosd")
1080 (synopsis "XOSD bindings for Guile")
1081 (description
1082 "Guile-XOSD provides Guile bindings for @code{libxosd},
1083@uref{http://sourceforge.net/projects/libxosd/, the X On Screen Display
1084library}.")
1085 (license license:gpl3+)))
1086
1087(define-public guile-dbi
1088 (package
1089 (name "guile-dbi")
1090 (version "2.1.6")
1091 (source (origin
1092 (method url-fetch)
1093 (uri (string-append
1094 "http://download.gna.org/guile-dbi/guile-dbi-"
1095 version ".tar.gz"))
1096 (sha256
1097 (base32
1098 "116njrprhgrsv1qm904sp3b02rq01fx639r433d657gyhw3x159n"))))
1099 (build-system gnu-build-system)
1100 (arguments
1101 '(#:configure-flags
1102 (list (string-append
1103 "--with-guile-site-dir=" %output "/share/guile/site/2.2"))
1104 #:make-flags
406ef442
CB
1105 (list (string-append
1106 "LDFLAGS=-Wl,-rpath=" %output "/lib:"
1107 (assoc-ref %build-inputs "guile-dbd-sqlite3") "/lib" ":"
1108 (assoc-ref %build-inputs "guile-dbd-postgresql") "/lib"))
0791437f
RW
1109 #:phases
1110 (modify-phases %standard-phases
1111 (add-after 'install 'patch-extension-path
1112 (lambda* (#:key outputs #:allow-other-keys)
1113 (let* ((out (assoc-ref outputs "out"))
1114 (dbi.scm (string-append
1115 out "/share/guile/site/2.2/dbi/dbi.scm"))
1116 (ext (string-append out "/lib/libguile-dbi")))
1117 (substitute* dbi.scm (("libguile-dbi") ext))
1118 #t))))))
1119 (inputs
406ef442
CB
1120 `(("guile-dbd-sqlite3" ,guile-dbd-sqlite3)
1121 ("guile-dbd-postgresql" ,guile-dbd-postgresql))) ; only shared library, no scheme files
0791437f
RW
1122 (propagated-inputs
1123 `(("guile" ,guile-2.2)))
1124 (synopsis "Guile database abstraction layer")
1125 (home-page "http://home.gna.org/guile-dbi/guile-dbi.html")
1126 (description
1127 "guile-dbi is a library for Guile that provides a convenient interface to
1128SQL databases. Database programming with guile-dbi is generic in that the same
1129programming interface is presented regardless of which database system is used.
1130It currently supports MySQL, Postgres and SQLite3.")
1131 (license license:gpl2+)))
1132
1133(define guile-dbi-bootstrap
1134 (package
1135 (inherit guile-dbi)
1136 (name "guile-dbi-bootstrap")
1137 (inputs '())
1138 (arguments
1139 (substitute-keyword-arguments (package-arguments guile-dbi)
1140 ((#:make-flags _) '(list))))))
1141
1142(define-public guile-dbd-sqlite3
1143 (package
1144 (name "guile-dbd-sqlite3")
1145 (version "2.1.6")
1146 (source (origin
1147 (method url-fetch)
1148 (uri (string-append
1149 "http://download.gna.org/guile-dbi/guile-dbd-sqlite3-"
1150 version ".tar.gz"))
1151 (sha256
1152 (base32
1153 "0rg71jchxd2y8x496s8zmfmikr5g8zxi8zv2ar3f7a23pph92iw2"))))
1154 (build-system gnu-build-system)
1155 (native-inputs
1156 `(("pkg-config" ,pkg-config)
1157 ("guile-dbi-bootstrap" ,guile-dbi-bootstrap))) ; only required for headers
1158 (inputs
1159 `(("sqlite" ,sqlite)
1160 ("zlib" ,(@ (gnu packages compression) zlib))))
1161 (synopsis "Guile DBI driver for SQLite")
1162 (home-page "https://github.com/jkalbhenn/guile-dbd-sqlite3")
1163 (description
1164 "guile-dbi is a library for Guile that provides a convenient interface to
1165SQL databases. This package implements the interface for SQLite.")
1166 (license license:gpl2+)))
1167
406ef442
CB
1168(define-public guile-dbd-postgresql
1169 (let ((commit "e97589b6b018b206c901e4cc24db463407a4036b")
1170 (revision 0))
1171 (package
1172 (name "guile-dbd-postgresql")
1173 (version (string-append
1174 "2.1.6-" (number->string revision) "." (string-take commit 7)))
1175 (source
1176 (origin
1177 (method git-fetch)
1178 (uri (git-reference
1179 (url "https://github.com/opencog/guile-dbi.git")
1180 (commit commit)))
1181 (file-name (git-file-name name version))
1182 (sha256
1183 (base32 "0n1gv9a0kdys10a4qmnrwvg5sydwb03880asri4gqdchcj3fimni"))))
1184 (build-system gnu-build-system)
1185 (arguments
1186 '(#:phases
1187 (modify-phases %standard-phases
1188 (add-after 'unpack 'chdir
1189 (lambda _
1190 ;; The upstream Git repository contains all the code, so change
1191 ;; to the relevant directory.
1192 (chdir "guile-dbd-postgresql")
1193 #t))
1194 (add-after 'chdir 'patch-src/Makefile.am
1195 (lambda* (#:key inputs #:allow-other-keys)
1196 (substitute* "src/Makefile.am"
1197 (("/usr/include")
1198 (string-append (assoc-ref inputs "postgresql") "/include")))
1199 #t))
1200 (add-after 'patch-src/Makefile.am 'patch-src
1201 (lambda _
1202 (substitute* "src/guile-dbd-postgresql.c"
1203 (("postgresql/libpq-fe\\.h") "libpq-fe.h"))
1204 #t)))))
1205 (native-inputs
1206 `(("pkg-config" ,pkg-config)
1207 ("automake" ,automake)
1208 ("autoconf" ,autoconf)
1209 ("perl" ,perl)
1210 ("libtool" ,libtool)
1211 ("guile-dbi-bootstrap" ,guile-dbi-bootstrap)))
1212 (inputs
1213 `(("postgresql" ,postgresql)
1214 ("zlib" ,zlib)))
1215 (synopsis "Guile DBI driver for PostgreSQL")
1216 (home-page
1217 "https://github.com/opencog/guile-dbi/tree/master/guile-dbd-postgresql")
1218 (description
1219 "@code{guile-dbi} is a library for Guile that provides a convenient
1220interface to SQL databases. This package implements the interface for
1221PostgreSQL.")
1222 (license license:gpl2+))))
1223
0791437f
RW
1224(define-public guile-config
1225 (package
1226 (name "guile-config")
1227 (version "0.3")
1228 (source
1229 (origin
1230 (method git-fetch)
1231 (uri (git-reference
1232 (url "https://gitlab.com/a-sassmannshausen/guile-config")
1233 (commit "ce12de3f438c6b2b59c43ee21bcd58251835fdf3")))
1234 (file-name "guile-config-0.3-checkout")
1235 (sha256 (base32 "02zbpin0r9m2vxmr7mv68v3xdn247dcck56kbzjn0gj4c2rhih85"))))
1236 (build-system gnu-build-system)
1237 (native-inputs
1238 `(("autoconf" ,autoconf)
1239 ("automake" ,automake)
1240 ("pkg-config" ,pkg-config)
1241 ("texinfo" ,texinfo)))
1242 (inputs `(("guile" ,guile-2.2)))
1243 (synopsis
1244 "Guile application configuration parsing library.")
1245 (description
1246 "Guile Config is a library providing a declarative approach to
1247application configuration specification. The library provides clean
1248configuration declaration forms, and processors that take care of:
1249configuration file creation; configuration file parsing; command-line
1250parameter parsing using getopt-long; basic GNU command-line parameter
1251generation (--help, --usage, --version); automatic output generation for the
1252above command-line parameters.")
1253 (home-page
1254 "https://gitlab.com/a-sassmannshausen/guile-config")
1255 (license license:gpl3+)))
1256
1257(define-public guile-hall
1258 (package
1259 (name "guile-hall")
63bf0afd 1260 (version "0.2")
0791437f 1261 (source
feb11b08
RW
1262 (origin
1263 (method git-fetch)
1264 (uri (git-reference
1265 (url "https://gitlab.com/a-sassmannshausen/guile-hall")
1266 (commit (string-append "v" version))))
1267 (file-name (git-file-name name version))
1268 (sha256 (base32
1269 "1bkbqgj24xh5b65sw2m98iggpi67b72szx1dsiq3cpzlcxplmgaz"))))
0791437f
RW
1270 (build-system gnu-build-system)
1271 (arguments
63bf0afd
AS
1272 `(#:modules
1273 ((ice-9 match)
1274 (ice-9 ftw)
1275 ,@%gnu-build-system-modules)
1276 #:phases
1277 (modify-phases
1278 %standard-phases
1279 (add-after 'install 'hall-wrap-binaries
1280 (lambda* (#:key inputs outputs #:allow-other-keys)
1281 (let* ((compiled-dir
1282 (lambda (out version)
1283 (string-append
1284 out "/lib/guile/" version "/site-ccache")))
1285 (uncompiled-dir
1286 (lambda (out version)
1287 (string-append
1288 out "/share/guile/site"
1289 (if (string-null? version) "" "/") version)))
1290 (dep-path
1291 (lambda (env modules path)
1292 (list env ":" 'prefix
1293 (cons modules
1294 (map (lambda (input)
1295 (string-append
1296 (assoc-ref inputs input)
1297 path))
1298 ,''("guile-config"))))))
1299 (out (assoc-ref outputs "out"))
1300 (bin (string-append out "/bin/"))
1301 (site (uncompiled-dir out "")))
1302 (match (scandir site)
1303 (("." ".." version)
1304 (for-each
1305 (lambda (file)
1306 (wrap-program
1307 (string-append bin file)
1308 (dep-path
1309 "GUILE_LOAD_PATH"
1310 (uncompiled-dir out version)
1311 (uncompiled-dir "" version))
1312 (dep-path
1313 "GUILE_LOAD_COMPILED_PATH"
1314 (compiled-dir out version)
1315 (compiled-dir "" version))))
1316 ,''("hall"))
1317 #t))))))))
0791437f 1318 (native-inputs
63bf0afd
AS
1319 `(("autoconf" ,autoconf)
1320 ("automake" ,automake)
1321 ("pkg-config" ,pkg-config)
1322 ("texinfo" ,texinfo)))
0791437f
RW
1323 (inputs `(("guile" ,guile-2.2)))
1324 (propagated-inputs
3c3e6620 1325 `(("guile-config" ,guile-config)))
0791437f
RW
1326 (synopsis "Guile project tooling")
1327 (description
3c3e6620
RW
1328 "Hall is a command-line application and a set of Guile libraries that
1329allow you to quickly create and publish Guile projects. It allows you to
1330transparently support the GNU build system, manage a project hierarchy &
1331provides tight coupling to Guix.")
1332 (home-page "https://gitlab.com/a-sassmannshausen/guile-hall")
06085fac 1333 (license license:gpl3+)))
0791437f
RW
1334
1335(define-public guile-ics
1336 (package
1337 (name "guile-ics")
1338 (version "0.2.0")
1339 (source (origin
1340 (method git-fetch)
1341 (uri (git-reference
1342 (url "https://github.com/artyom-poptsov/guile-ics")
1343 (commit (string-append "v" version))))
1344 (file-name (string-append name "-" version "-checkout"))
1345 (sha256
1346 (base32
1347 "0qjjvadr7gibdq9jvwkmlkb4afsw9n2shfj9phpiadinxk3p4m2g"))))
1348 (build-system gnu-build-system)
1349 (native-inputs
1350 `(("autoconf" ,autoconf-wrapper)
1351 ("automake" ,automake)
1352 ("texinfo" ,texinfo)
1353 ;; Gettext brings 'AC_LIB_LINKFLAGS_FROM_LIBS'.
1354 ("gettext" ,gettext-minimal)
1355 ("pkg-config" ,pkg-config)))
1356 (inputs `(("guile" ,guile-2.2) ("which" ,which)))
1357 (propagated-inputs `(("guile-lib" ,guile-lib)))
1358 (home-page "https://github.com/artyom-poptsov/guile-ics")
1359 (synopsis "Guile parser library for the iCalendar format")
1360 (description
1361 "Guile-ICS is an iCalendar (RFC5545) format parser library written in
1362pure Scheme. The library can be used to read and write iCalendar data.
1363
1364The library is shipped with documentation in Info format and usage examples.")
1365 (license license:gpl3+)))
1366
1367(define-public guile-wisp
1368 (package
1369 (name "guile-wisp")
65610f73 1370 (version "1.0.2")
0791437f
RW
1371 (source (origin
1372 (method url-fetch)
1373 (uri (string-append "https://bitbucket.org/ArneBab/"
1374 "wisp/downloads/wisp-"
1375 version ".tar.gz"))
1376 (sha256
1377 (base32
65610f73 1378 "03pz7pj9jyallynhflp5s7qax8dj1fs8la434wrfgz7g1kgjnvf6"))))
0791437f
RW
1379 (build-system gnu-build-system)
1380 (arguments
1381 `(#:modules ((guix build gnu-build-system)
15218d4e 1382 ((guix build emacs-build-system) #:prefix emacs:)
0791437f 1383 (guix build utils)
15218d4e 1384 (guix build emacs-utils)
0791437f
RW
1385 (ice-9 rdelim)
1386 (ice-9 popen))
15218d4e
RW
1387 #:imported-modules (,@%gnu-build-system-modules
1388 (guix build emacs-build-system)
1389 (guix build emacs-utils))
0791437f
RW
1390 #:phases
1391 (modify-phases %standard-phases
1392 (add-before 'configure 'patch-/usr/bin/env
1393 (lambda _
1394 (substitute* "Makefile.in"
65610f73 1395 (("/usr/bin/env bash") (which "bash")))
0791437f
RW
1396 #t))
1397 ;; auto compilation breaks, but if we set HOME to /tmp,
1398 ;; that works ok
1399 (add-before 'check 'auto-compile-hacky-workaround
1400 (lambda _ (setenv "HOME" "/tmp") #t))
1401 (add-after 'install 'install-go-files
1402 (lambda* (#:key outputs inputs #:allow-other-keys)
1403 (let* ((out (assoc-ref outputs "out"))
1404 (effective (read-line
1405 (open-pipe* OPEN_READ
1406 "guile" "-c"
1407 "(display (effective-version))")))
1408 (module-dir (string-append out "/share/guile/site/"
1409 effective))
1410 (object-dir (string-append out "/lib/guile/" effective
1411 "/site-ccache"))
1412 (prefix (string-length module-dir)))
1413 ;; compile to the destination
1414 (for-each (lambda (file)
1415 (let* ((base (string-drop (string-drop-right file 4)
1416 prefix))
1417 (go (string-append object-dir base ".go")))
1418 (invoke "guild" "compile" "-L" module-dir
1419 file "-o" go)))
1420 (find-files module-dir "\\.scm$"))
15218d4e
RW
1421 #t)))
1422 (add-after 'install 'install-emacs-files
1423 (assoc-ref emacs:%standard-phases 'install))
1424 (add-after 'install-emacs-files 'compile-emacs-files
1425 (assoc-ref emacs:%standard-phases 'build))
1426 (add-after 'compile-emacs-files 'make-autoloads
1427 (assoc-ref emacs:%standard-phases 'make-autoloads)))))
17f90b67 1428 (home-page "https://www.draketo.de/english/wisp")
0791437f
RW
1429 (inputs
1430 `(("guile" ,guile-2.2)))
1431 (native-inputs
15218d4e
RW
1432 `(("emacs" ,emacs-minimal)
1433 ("python" ,python)
0791437f
RW
1434 ("pkg-config" ,pkg-config)))
1435 (synopsis "Whitespace to lisp syntax for Guile")
1436 (description "Wisp is a syntax for Guile which provides a Python-like
1437whitespace-significant language. It may be easier on the eyes for some
1438users and in some situations.")
1439 (license license:gpl3+)))
1440
1441(define-public guile-sly
1442 (package
1443 (name "guile-sly")
1444 (version "0.1")
1445 (source (origin
1446 (method url-fetch)
1447 (uri (string-append "https://files.dthompson.us/sly/sly-"
1448 version ".tar.gz"))
1449 (sha256
1450 (base32
1451 "1svzlbz2vripmyq2kjh0rig16bsrnbkwbsm558pjln9l65mcl4qq"))
1452 (modules '((guix build utils)))
1453 (snippet
1454 '(begin
1455 (substitute* "configure"
1456 (("_guile_required_version=\"2.0.11\"")
1457 "_guile_required_version=\"2\"")
1458 (("ac_subst_vars='")
1459 "ac_subst_vars='GUILE_EFFECTIVE_VERSION\n"))
1460 (substitute* (find-files "." "Makefile.in")
1461 (("moddir = .*$")
1462 (string-append
1463 "moddir = "
1464 "$(prefix)/share/guile/site/@GUILE_EFFECTIVE_VERSION@\n"))
1465 (("godir = .*$")
1466 (string-append
1467 "godir = "
1468 "$(prefix)/lib/guile/@GUILE_EFFECTIVE_VERSION@/site-ccache\n")))
1469 #t))))
1470 (build-system gnu-build-system)
1471 (arguments
1472 '(#:configure-flags
1473 (list (string-append "--with-libfreeimage-prefix="
1474 (assoc-ref %build-inputs "freeimage"))
1475 (string-append "--with-libgslcblas-prefix="
1476 (assoc-ref %build-inputs "gsl")))))
1477 (native-inputs
1478 `(("pkg-config" ,pkg-config)))
1479 (propagated-inputs
1480 `(("guile-sdl" ,guile-sdl)
1481 ("guile-opengl" ,guile-opengl)))
1482 (inputs
1483 `(("guile" ,guile-2.2)
1484 ("gsl" ,gsl)
1485 ("freeimage" ,freeimage)
1486 ("mesa" ,mesa)))
1487 (synopsis "2D/3D game engine for GNU Guile")
1488 (description "Sly is a 2D/3D game engine written in Guile Scheme. Sly
1489features a functional reactive programming interface and live coding
1490capabilities.")
1491 (home-page "https://dthompson.us/projects/sly.html")
1492 (license license:gpl3+)))
1493
1494(define-public g-wrap
1495 (package
1496 (name "g-wrap")
1497 (version "1.9.15")
1498 (source (origin
1499 (method url-fetch)
1500 (uri (string-append "mirror://savannah/g-wrap/g-wrap-"
1501 version ".tar.gz"))
1502 (sha256
1503 (base32
1504 "0ak0bha37dfpj9kmyw1r8fj8nva639aw5xr66wr5gd3l1rqf5xhg"))))
1505 (build-system gnu-build-system)
1506 (native-inputs
1507 `(("pkg-config" ,pkg-config)))
1508 (propagated-inputs
1509 `(("guile" ,guile-2.2)
1510 ("guile-lib" ,guile-lib)))
1511 (inputs
1512 `(("libffi" ,libffi)))
1513 (arguments
1514 `(#:configure-flags '("--disable-Werror")
1515 #:phases
1516 (modify-phases %standard-phases
1517 (add-before 'configure 'pre-configure
1518 (lambda* (#:key outputs #:allow-other-keys)
1519 (let ((out (assoc-ref outputs "out")))
1520 (substitute* (find-files "." "^Makefile.in$")
1521 (("guilemoduledir =.*guile/site" all)
1522 (string-append all "/@GUILE_EFFECTIVE_VERSION@")))
1523 #t))))))
1524 (synopsis "Generate C bindings for Guile")
1525 (description "G-Wrap is a tool and Guile library for generating function
1526wrappers for inter-language calls. It currently only supports generating Guile
1527wrappers for C functions. Given a definition of the types and prototypes for
1528a given C interface, G-Wrap will automatically generate the C code that
1529provides access to that interface and its types from the Scheme level.")
1530 (home-page "https://www.nongnu.org/g-wrap/index.html")
1531 (license license:lgpl2.1+)))
1532
1533(define-public guile-miniadapton
1534 (let ((commit "1b5749422304567c96ac5367f2221dda9eff5880")
1535 (revision "1"))
1536 (package
1537 (name "guile-miniadapton")
1538 (version (string-append "0-" revision "." (string-take commit 9)))
1539 (source (origin
1540 (method git-fetch)
1541 (uri (git-reference
1542 (url "https://github.com/fisherdj/miniAdapton.git")
1543 (commit commit)))
1544 (file-name (string-append name "-" version "-checkout"))
1545 (sha256
1546 (base32
1547 "09q51zkw2fypad5xixskfzw2cjhjgs5cswdp3i7cpp651rb3zndh"))))
1548 (build-system guile-build-system)
1549 (native-inputs
1550 `(("guile" ,guile-2.2)))
1551 (home-page "https://github.com/fisherdj/miniAdapton")
1552 (synopsis "Minimal implementation of incremental computation in Guile
1553Scheme")
1554 (description "This package provides a complete Scheme implementation of
1555miniAdapton, which implements the core functionality of the Adapton system for
1556incremental computation (also known as self-adjusting computation). Like
1557Adapton, miniAdapton allows programmers to safely combine mutation and
1558memoization. miniAdapton is built on top of an even simpler system,
1559microAdapton. Both miniAdapton and microAdapton are designed to be easy to
1560understand, extend, and port to host languages other than Scheme.")
1561 (license license:expat))))
1562
1563(define-public guile-reader
1564 (package
1565 (name "guile-reader")
1566 (version "0.6.2")
1567 (source (origin
1568 (method url-fetch)
1569 (uri (string-append "mirror://savannah/guile-reader/guile-reader-"
1570 version ".tar.gz"))
1571 (sha256
1572 (base32
1573 "0592s2s8ampqmqwilc4fvcild6rb9gy79di6vxv5kcdmv23abkgx"))))
1574 (build-system gnu-build-system)
1575 (native-inputs `(("pkgconfig" ,pkg-config)
1576 ("gperf" ,gperf-3.0)))
1577 (inputs `(("guile" ,guile-2.2)))
1578 (synopsis "Framework for building readers for GNU Guile")
1579 (description
1580 "Guile-Reader is a simple framework for building readers for GNU Guile.
1581
1582The idea is to make it easy to build procedures that extend Guile’s read
1583procedure. Readers supporting various syntax variants can easily be written,
1584possibly by re-using existing “token readers” of a standard Scheme
1585readers. For example, it is used to implement Skribilo’s R5RS-derived
1586document syntax.
1587
1588Guile-Reader’s approach is similar to Common Lisp’s “read table”, but
1589hopefully more powerful and flexible (for instance, one may instantiate as
1590many readers as needed).")
1591 (home-page "https://www.nongnu.org/guile-reader/")
1592 (license license:gpl3+)))
1593
0791437f
RW
1594(define-public guile-ncurses
1595 (package
1596 (name "guile-ncurses")
1597 (version "2.2")
1598 (source (origin
1599 (method url-fetch)
1600 (uri (string-append "mirror://gnu/guile-ncurses/guile-ncurses-"
1601 version ".tar.gz"))
1602 (sha256
1603 (base32
1604 "1wvggbr4xv8idh1hzd8caj4xfp4pln78a7w1wqzd4zgzwmnzxr2f"))))
1605 (build-system gnu-build-system)
1606 (inputs `(("ncurses" ,ncurses)
1607 ("guile" ,guile-2.2)))
1608 (native-inputs `(("pkg-config" ,pkg-config)))
1609 (arguments
1610 '(#:configure-flags (list "--with-ncursesw" ; Unicode support
1611 "--with-gnu-filesystem-hierarchy")
1612 #:phases
1613 (modify-phases %standard-phases
1614 (add-before 'build 'fix-libguile-ncurses-file-name
1615 (lambda* (#:key outputs #:allow-other-keys)
1616 (invoke "make" "install"
1617 "-C" "src/ncurses"
1618 "-j" (number->string
1619 (parallel-job-count)))
1620 (let* ((out (assoc-ref outputs "out"))
1621 (dir "src/ncurses")
1622 (files (find-files dir ".scm")))
1623 (substitute* files
1624 (("\"libguile-ncurses\"")
1625 (format #f "\"~a/lib/guile/2.2/libguile-ncurses\""
1626 out)))
1627 #t))))))
1628 (home-page "https://www.gnu.org/software/guile-ncurses/")
1629 (synopsis "Guile bindings to ncurses")
1630 (description
1631 "guile-ncurses provides Guile language bindings for the ncurses
1632library.")
1633 (license license:lgpl3+)))
1634
1635(define-public guile-ncurses/gpm
1636 (package
1637 (inherit guile-ncurses)
1638 (name "guile-ncurses-with-gpm")
1639 (inputs `(("ncurses" ,ncurses/gpm)
1640 ("guile" ,guile-2.2)))))
1641
1642(define-public guile-lib
1643 (package
1644 (name "guile-lib")
1645 (version "0.2.6.1")
1646 (source (origin
1647 (method url-fetch)
1648 (uri (string-append "mirror://savannah/guile-lib/guile-lib-"
1649 version ".tar.gz"))
1650 (sha256
1651 (base32
1652 "0aizxdif5dpch9cvs8zz5g8ds5s4xhfnwza2il5ji7fv2h7ks7bd"))))
1653 (build-system gnu-build-system)
1654 (arguments
1655 '(#:make-flags
1656 '("GUILE_AUTO_COMPILE=0") ; to prevent guild errors
1657 #:phases
1658 (modify-phases %standard-phases
1659 (add-before 'configure 'patch-module-dir
1660 (lambda _
1661 (substitute* "src/Makefile.in"
1662 (("^moddir = ([[:graph:]]+)")
1663 "moddir = $(datadir)/guile/site/@GUILE_EFFECTIVE_VERSION@\n")
1664 (("^godir = ([[:graph:]]+)")
1665 "godir = \
1666$(libdir)/guile/@GUILE_EFFECTIVE_VERSION@/site-ccache\n"))
1667 #t)))))
1668 (native-inputs `(("pkg-config" ,pkg-config)))
1669 (inputs `(("guile" ,guile-2.2)))
1670 (home-page "https://www.nongnu.org/guile-lib/")
1671 (synopsis "Collection of useful Guile Scheme modules")
1672 (description
1673 "Guile-Lib is intended as an accumulation place for pure-scheme Guile
1674modules, allowing for people to cooperate integrating their generic Guile
1675modules into a coherent library. Think \"a down-scaled, limited-scope CPAN
1676for Guile\".")
1677
1678 ;; The whole is under GPLv3+, but some modules are under laxer
1679 ;; distribution terms such as LGPL and public domain. See `COPYING' for
1680 ;; details.
1681 (license license:gpl3+)))
1682
1683(define-public guile2.0-lib
1684 (package
1685 (inherit guile-lib)
1686 (name "guile2.0-lib")
1687 (inputs `(("guile" ,guile-2.0)))))
1688
0791437f
RW
1689(define-public guile-minikanren
1690 (package
1691 (name "guile-minikanren")
1692 (version "20150424.e844d85")
1693 (source (origin
1694 (method git-fetch)
1695 (uri (git-reference
1696 (url "https://github.com/ijp/minikanren.git")
1697 (commit "e844d85512f8c055d3f96143ee506007389a25e3")))
1698 (file-name (string-append name "-" version "-checkout"))
1699 (sha256
1700 (base32
1701 "0r50jlpzi940jlmxyy3ddqqwmj5r12gb4bcv0ssini9v8km13xz6"))))
1702 (build-system guile-build-system)
1703 (native-inputs
1704 `(("guile" ,guile-2.2)))
1705 (home-page "https://github.com/ijp/minikanren")
1706 (synopsis "MiniKanren declarative logic system, packaged for Guile")
1707 (description
1708 "MiniKanren is a relational programming extension to the Scheme
1709programming Language, written as a smaller version of Kanren suitable for
1710pedagogical purposes. It is featured in the book, The Reasoned Schemer,
1711written by Dan Friedman, William Byrd, and Oleg Kiselyov.
1712
1713This is Ian Price's r6rs packaged version of miniKanren, which deviates
1714slightly from miniKanren mainline.
1715
1716See http://minikanren.org/ for more on miniKanren generally.")
1717 (license license:expat)))
1718
1719(define-public guile2.0-minikanren
1720 (package
1721 (inherit guile-minikanren)
1722 (name "guile2.0-minikanren")
1723 (native-inputs `(("guile" ,guile-2.0)))))
1724
0791437f
RW
1725(define-public guile-irregex
1726 (package
1727 (name "guile-irregex")
1728 (version "0.9.6")
1729 (source (origin
1730 (method url-fetch)
1731 (uri (string-append
1732 "http://synthcode.com/scheme/irregex/irregex-"
1733 version ".tar.gz"))
1734 (sha256
1735 (base32
1736 "1ia3m7dp3lcxa048q0gqbiwwsyvn99baw6xkhb4bhhzn4k7bwyqq"))))
1737 (build-system guile-build-system)
1738 (arguments
1739 '(#:phases (modify-phases %standard-phases
1740 (add-after 'unpack 'move-files-around
1741 (lambda _
1742 ;; Move the relevant source files to src/ and create the
1743 ;; rx/ directory to match the expected module hierarchy.
1744 (mkdir-p "src/rx/source")
1745 (rename-file "irregex-guile.scm"
1746 "src/rx/irregex.scm")
1747 (rename-file "irregex.scm"
1748 "src/rx/source/irregex.scm")
1749 ;; Not really reachable via guile's packaging system,
1750 ;; but nice to have around.
1751 (rename-file "irregex-utils.scm"
1752 "src/rx/source/irregex-utils.scm")
1753 #t)))
1754 #:source-directory "src"))
1755 (native-inputs
1756 `(("guile" ,guile-2.2)))
1757 (home-page "http://synthcode.com/scheme/irregex")
1758 (synopsis "S-expression based regular expressions")
1759 (description
1760 "Irregex is an s-expression based alternative to your classic
1761string-based regular expressions. It implements SRFI 115 and is deeply
1762inspired by the SCSH regular expression system.")
1763 (license license:bsd-3)))
1764
1765(define-public guile2.0-irregex
1766 (package
1767 (inherit guile-irregex)
1768 (name "guile2.0-irregex")
1769 (native-inputs `(("guile" ,guile-2.0)))))
1770
0791437f
RW
1771(define-public haunt
1772 (package
1773 (name "haunt")
1774 (version "0.2.4")
1775 (source (origin
1776 (method url-fetch)
1777 (uri (string-append "https://files.dthompson.us/haunt/haunt-"
1778 version ".tar.gz"))
1779 (sha256
1780 (base32
1781 "056z4znikk83nr5mr0x2ac3iinqbywa2bvb37mhr566a1q50isfc"))))
1782 (build-system gnu-build-system)
1783 (arguments
1784 `(#:modules ((ice-9 match) (ice-9 ftw)
1785 ,@%gnu-build-system-modules)
1786 #:tests? #f ; test suite is non-deterministic :(
1787 #:phases (modify-phases %standard-phases
1788 (add-after 'install 'wrap-haunt
1789 (lambda* (#:key inputs outputs #:allow-other-keys)
1790 ;; Wrap the 'haunt' command to refer to the right
1791 ;; modules.
1792 (let* ((out (assoc-ref outputs "out"))
1793 (bin (string-append out "/bin"))
1794 (site (string-append
1795 out "/share/guile/site"))
1796 (deps (list (assoc-ref inputs "guile-reader")
1797 (assoc-ref inputs "guile-commonmark"))))
1798 (match (scandir site)
1799 (("." ".." version)
1800 (let ((modules (string-append site "/" version))
1801 (compiled-modules (string-append
1802 out "/lib/guile/" version
1803 "/site-ccache")))
1804 (wrap-program (string-append bin "/haunt")
1805 `("GUILE_LOAD_PATH" ":" prefix
1806 (,modules
1807 ,@(map (lambda (dep)
1808 (string-append dep
1809 "/share/guile/site/"
1810 version))
1811 deps)))
1812 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
1813 (,compiled-modules
1814 ,@(map (lambda (dep)
1815 (string-append dep "/lib/guile/"
1816 version
1817 "/site-ccache"))
1818 deps))))
1819 #t)))))))))
1820 (native-inputs
1821 `(("pkg-config" ,pkg-config)
1822 ("texinfo" ,texinfo)))
1823 (inputs
1824 `(("guile" ,guile-2.2)))
1825 (propagated-inputs
1826 `(("guile-reader" ,guile-reader)
1827 ("guile-commonmark" ,guile-commonmark)))
1828 (synopsis "Functional static site generator")
1829 (description "Haunt is a static site generator written in Guile
1830Scheme. Haunt features a functional build system and an extensible
1831interface for reading articles in any format.")
1832 (home-page "http://haunt.dthompson.us")
1833 (license license:gpl3+)))
1834
1835(define-public guile2.0-haunt
1836 (package
1837 (inherit haunt)
1838 (name "guile2.0-haunt")
1839 (inputs `(("guile" ,guile-2.0)))))
1840
0791437f
RW
1841(define-public guile-redis
1842 (package
1843 (name "guile-redis")
f57bf15c 1844 (version "1.3.0")
0791437f
RW
1845 (home-page "https://github.com/aconchillo/guile-redis")
1846 (source (origin
1847 (method url-fetch)
1848 (uri (string-append home-page "/archive/" version ".tar.gz"))
1849 (sha256
1850 (base32
f57bf15c 1851 "1li70a2716my9q9zfq0qn2x5d1cir9k2vx0jm9glm464yaf1vj39"))))
0791437f
RW
1852 (build-system gnu-build-system)
1853 (native-inputs
1854 `(("autoconf" ,autoconf)
1855 ("automake" ,automake)
1856 ("pkg-config" ,pkg-config)
1857 ("guile" ,guile-2.2)))
1858 (synopsis "Redis client library for Guile")
1859 (description "Guile-redis provides a Scheme interface to the Redis
1860key-value cache and store.")
1861 (license license:lgpl3+)))
1862
1863(define-public guile2.0-redis
1864 (package
1865 (inherit guile-redis)
1866 (name "guile2.0-redis")
1867 (native-inputs `(("guile" ,guile-2.0)
1868 ,@(alist-delete "guile"
1869 (package-native-inputs guile-redis))))))
1870
0791437f
RW
1871(define-public guile-commonmark
1872 (package
1873 (name "guile-commonmark")
b552e307 1874 (version "0.1.2")
0791437f
RW
1875 (source (origin
1876 (method url-fetch)
1877 (uri (string-append "https://github.com/OrangeShark/" name
1878 "/releases/download/v" version
1879 "/" name "-" version ".tar.gz"))
1880 (sha256
1881 (base32
b552e307 1882 "17lrsdisa3kckh24q114vfmzdc4wkqa6ccwl4hdlrng5wpn1iman"))))
0791437f
RW
1883 (build-system gnu-build-system)
1884 (inputs
1885 `(("guile" ,guile-2.2)))
1886 (native-inputs
1887 `(("pkg-config" ,pkg-config)))
1888 (synopsis "CommonMark parser for Guile")
1889 (description
1890 "guile-commonmark is a library for parsing CommonMark, a fully specified
1891variant of Markdown. The library is written in Guile Scheme and is designed
1892to transform a CommonMark document to SXML. guile-commonmark tries to closely
1893follow the @uref{http://commonmark.org/, CommonMark spec}, the main difference
1894is no support for parsing block and inline level HTML.")
1895 (home-page "https://github.com/OrangeShark/guile-commonmark")
1896 (license license:lgpl3+)))
1897
1898(define-public guile2.0-commonmark
1899 (package
1900 (inherit guile-commonmark)
1901 (name "guile2.0-commonmark")
1902 (inputs `(("guile" ,guile-2.0)))))
1903
0791437f
RW
1904(define-public mcron
1905 (package
1906 (name "mcron")
f61f424d 1907 (version "1.1.2")
0791437f
RW
1908 (source (origin
1909 (method url-fetch)
1910 (uri (string-append "mirror://gnu/mcron/mcron-"
1911 version ".tar.gz"))
1912 (sha256
1913 (base32
f61f424d 1914 "069m3ri7nc8lgy3h9ka7gj3v3anqj69x9jw4l3cfq65nqkxsch4g"))))
0791437f
RW
1915 (build-system gnu-build-system)
1916 (arguments
1917 '(#:phases (modify-phases %standard-phases
0791437f
RW
1918 (add-before 'check 'adjust-tests
1919 (lambda _
1920 (substitute* "tests/job-specifier.scm"
1921 ;; (getpw) fails with "entry not found" in the build
1922 ;; environment, so pass an argument.
1923 (("\\(getpw\\)")
1924 "(getpwnam (getuid))")
1925 ;; The build environment lacks an entry for root in
1926 ;; /etc/passwd.
1927 (("\\(getpw 0\\)")
1928 "(getpwnam \"nobody\")")
1929
1930 ;; FIXME: Skip the 4 faulty tests (see above).
1931 (("\\(test-equal \"next-year\"" all)
1932 (string-append "(test-skip 4)\n" all)))
1933 #t)))))
f61f424d
EF
1934 (native-inputs `(("autoconf" ,autoconf)
1935 ("automake" ,automake)
1936 ("help2man" ,help2man)
1937 ("pkg-config" ,pkg-config)
1938 ("texinfo" ,texinfo)
0791437f 1939 ("tzdata" ,tzdata-for-tests)))
f61f424d 1940 (inputs `(("guile" ,guile-2.2)))
0791437f
RW
1941 (home-page "https://www.gnu.org/software/mcron/")
1942 (synopsis "Run jobs at scheduled times")
1943 (description
1944 "GNU Mcron is a complete replacement for Vixie cron. It is used to run
1945tasks on a schedule, such as every hour or every Monday. Mcron is written in
1946Guile, so its configuration can be written in Scheme; the original cron
1947format is also supported.")
1948 (license license:gpl3+)))
1949
1950(define-public mcron2
1951 ;; This was mthl's mcron development branch, and it became mcron 1.1.
1952 (deprecated-package "mcron2" mcron))
6bb5f88e
RW
1953
1954(define-public guile-picture-language
d1a3a8e1
RW
1955 (let ((commit "91d10c96708d732145006dd2802acc4de08b632e")
1956 (revision "1"))
6bb5f88e
RW
1957 (package
1958 (name "guile-picture-language")
d1a3a8e1 1959 (version (git-version "0.0.1" revision commit))
6bb5f88e
RW
1960 (source (origin
1961 (method git-fetch)
1962 (uri (git-reference
1963 (url "https://git.elephly.net/software/guile-picture-language.git")
1964 (commit commit)))
1965 (sha256
1966 (base32
d1a3a8e1
RW
1967 "1ydvw9dvssdvlvhh1dr8inyzy2x6m41qgp8hsivca1xysr4gc23a"))))
1968 (build-system gnu-build-system)
6bb5f88e
RW
1969 (inputs
1970 `(("guile" ,guile-2.2)))
d1a3a8e1
RW
1971 (native-inputs
1972 `(("autoconf" ,autoconf)
1973 ("automake" ,automake)
1974 ("imagemagick" ,imagemagick)
1975 ("pkg-config" ,pkg-config)
1976 ("texinfo" ,texinfo)))
6bb5f88e
RW
1977 (home-page "https://git.elephly.net/software/guile-picture-language.git")
1978 (synopsis "Picture language for Guile")
1979 (description
1980 "This package provides a simple SVG-based picture language for Guile.
1981The picture values can directly be displayed in Geiser.")
1982 (license license:lgpl3+))))
5531782d
RW
1983
1984(define-public guile-studio
1985 (let ((commit "e2da64f014942a73996286c4abe3c3b1f8bd220c")
1986 (revision "1"))
1987 (package
1988 (name "guile-studio")
1989 (version (git-version "0" revision commit))
1990 (source (origin
1991 (method git-fetch)
1992 (uri (git-reference
1993 (url "https://git.elephly.net/software/guile-studio.git")
1994 (commit commit)))
1995 (sha256
1996 (base32
1997 "10v3kw41bzd8c2a6vxgrwbvl216d0k8f5s9h6pm8hahpd03jl7lm"))))
1998 (build-system gnu-build-system)
1999 (arguments
2000 `(#:tests? #f ; there are none
2001 #:phases
2002 (modify-phases %standard-phases
2003 (delete 'configure)
2004 (replace 'build
2005 (lambda* (#:key source inputs outputs #:allow-other-keys)
2006 (let* ((out (assoc-ref outputs "out"))
2007 (bin (string-append out "/bin/"))
2008 (share (string-append out "/share/")))
2009 (mkdir-p share)
2010 (mkdir-p bin)
2011 (apply invoke "guile" "-s" "guile-studio-configure.scm"
2012 out
2013 (assoc-ref inputs "emacs")
2014 (assoc-ref inputs "guile-picture-language")
2015 (string-append (assoc-ref inputs "adwaita-icon-theme")
2016 "/share/icons/Adwaita/")
2017 (map cdr inputs))
2018 #t)))
2019 (delete 'install))))
2020 (inputs
2021 `(("guile" ,guile-2.2)
2022 ("guile-picture-language" ,guile-picture-language)
2023 ("emacs" ,emacs)
2024 ("emacs-geiser" ,emacs-geiser)
2025 ("emacs-company" ,emacs-company)
2026 ("emacs-flycheck" ,emacs-flycheck)
2027 ("emacs-smart-mode-line" ,emacs-smart-mode-line)
2028 ("emacs-paren-face" ,emacs-paren-face)
2029 ("adwaita-icon-theme" ,adwaita-icon-theme)))
2030 (home-page "https://gnu.org/software/guile")
2031 (synopsis "IDE for Guile")
2032 (description
2033 "This is Emacs with a few settings that make working with Guile easier
2034for people new to Emacs. Features include: CUA mode, Geiser, tool bar icons
2035to evaluate Guile buffers, support for Guile's very own picture language, code
2036completion, a simple mode line, etc.")
2037 (license license:gpl3+))))
9f8698ad
RW
2038
2039(define-public guile-stis-parser
2040 (let ((commit "6e85d37ffc333b722f4413a6c648263701eb75bd")
2041 (revision "1"))
2042 (package
2043 (name "guile-stis-parser")
2044 (version (git-version "0" revision commit))
2045 (source (origin
2046 (method git-fetch)
2047 (uri (git-reference
2048 (url "https://gitlab.com/tampe/stis-parser")
2049 (commit commit)))
29e76f07 2050 (file-name (git-file-name name version))
9f8698ad
RW
2051 (sha256
2052 (base32
2053 "0v4hvq7rlpbra1ni73lf8k6sdmjlflr50yi3p1f24g85h77pc7c0"))))
2054 (build-system gnu-build-system)
2055 (arguments
2056 `(#:parallel-build? #f ; not supported
2057 #:phases
2058 (modify-phases %standard-phases
2059 (add-after 'unpack 'chdir
2060 (lambda _ (chdir "modules") #t))
8318b3ed
RW
2061 (add-after 'chdir 'use-canonical-directory-for-go-files
2062 (lambda _
2063 (substitute* "Makefile.am"
2064 (("/ccache") "/site-ccache"))
2065 #t))
9f8698ad
RW
2066 (add-after 'chdir 'delete-broken-symlink
2067 (lambda _
2068 (delete-file "parser/stis-parser/lang/.#calc.scm")
2069 #t)))))
2070 (inputs
2071 `(("guile" ,guile-2.2)))
2072 (native-inputs
2073 `(("autoconf" ,autoconf)
2074 ("automake" ,automake)
2075 ("pkg-config" ,pkg-config)))
2076 (home-page "https://gitlab.com/tampe/stis-parser")
2077 (synopsis "Parser combinator framework")
2078 (description
2079 "This package provides a functional parser combinator library that
2080supports backtracking and a small logical framework. The idea is to build up
2081chunks that are memoized and there is no clear scanner/parser separation,
2082chunks can be expressions as well as simple tokens.")
2083 (license license:lgpl2.0+))))
12d73f9c
RW
2084
2085(define-public guile-persist
2086 (let ((commit "b14927b0368af51c024560aee5f55724aee35233")
2087 (revision "1"))
2088 (package
2089 (name "guile-persist")
2090 (version (git-version "0" revision commit))
2091 (source (origin
2092 (method git-fetch)
2093 (uri (git-reference
2094 (url "https://gitlab.com/tampe/guile-persist")
2095 (commit commit)))
2096 (file-name (git-file-name name version))
2097 (sha256
2098 (base32
85a411bc
LC
2099 "0z5nf377wh8yj6n3sx2ddn4bdx1qrqnw899dlqjhg0q69qzil522"))
2100 (modules '((guix build utils)))
2101 (snippet
2102 '(begin
2103 ;; Install .go files in the right place.
2104 (substitute* "Makefile.am"
2105 (("/ccache") "/site-ccache"))
2106 #t))))
12d73f9c
RW
2107 (build-system gnu-build-system)
2108 (arguments
2109 `(#:phases
2110 (modify-phases %standard-phases
2111 (add-after 'unpack 'patch-prefix
2112 (lambda* (#:key inputs outputs #:allow-other-keys)
2113 (substitute* "src/Makefile.am"
2114 (("/usr/local/lib/guile")
2115 (string-append (assoc-ref outputs "out") "/lib/guile"))
2116 (("/usr/local/include/guile")
2117 (string-append (assoc-ref inputs "guile") "/include/guile"))
2118 (("-L/usr/local/lib")
8f052528
RW
2119 (string-append "-L" (assoc-ref inputs "guile") "/lib"))
2120 ;; Use canonical directory for go files.
2121 (("/ccache") "/site-ccache"))
12d73f9c
RW
2122 #t))
2123 (add-after 'unpack 'patch-library-reference
2124 (lambda* (#:key outputs #:allow-other-keys)
2125 (let ((out (assoc-ref outputs "out")))
2126 (substitute* "persist/persistance.scm"
2127 (("\"libguile-persist\"")
2128 (format #f "\"~a/lib/guile/2.2/extensions/libguile-persist\"" out)))
2129 #t))))))
2130 (inputs
2131 `(("guile" ,guile-2.2)))
2132 (native-inputs
2133 `(("autoconf" ,autoconf)
2134 ("automake" ,automake)
2135 ("libtool" ,libtool)
2136 ("pkg-config" ,pkg-config)))
2137 (home-page "https://gitlab.com/tampe/guile-persist")
028053f2 2138 (synopsis "Persistence programming framework for Guile")
12d73f9c
RW
2139 (description
2140 "This is a serialization library for serializing objects like classes
2141and objects, closures and structs. This currently does not support
2142serializing continuations or delimited continuations.")
2143 (license license:lgpl2.0+))))
6d37301b
RW
2144
2145(define-public python-on-guile
5d5edb88
LC
2146 (let ((commit "00a51a23247f1edc4ae8eda72b30df5cd7d0015f")
2147 (revision "3"))
6d37301b
RW
2148 (package
2149 (name "python-on-guile")
2150 (version (git-version "0.1.0" revision commit))
2151 (source (origin
2152 (method git-fetch)
2153 (uri (git-reference
4088ae42 2154 (url "https://git.elephly.net/software/python-on-guile.git")
6d37301b
RW
2155 (commit commit)))
2156 (file-name (git-file-name name version))
2157 (sha256
2158 (base32
5d5edb88 2159 "03rpnqr08rqr3gay128g564rwk8w4jbj28ss6b46z1d4vjs4nk68"))))
6d37301b
RW
2160 (build-system gnu-build-system)
2161 (arguments
2162 `(#:parallel-build? #f ; not supported
83817158
LC
2163 #:make-flags '("GUILE_AUTO_COMPILE=0") ;to prevent guild warnings
2164
6d37301b
RW
2165 #:phases
2166 (modify-phases %standard-phases
2167 (add-after 'unpack 'chdir
83817158
LC
2168 (lambda _ (chdir "modules") #t))
2169 (add-after 'install 'wrap
2170 (lambda* (#:key outputs #:allow-other-keys)
2171 ;; Wrap the 'python' executable so it can find its
2172 ;; dependencies.
2173 (let ((out (assoc-ref outputs "out")))
2174 (wrap-program (string-append out "/bin/python")
2175 `("GUILE_LOAD_PATH" ":" prefix
2176 (,(getenv "GUILE_LOAD_PATH")))
2177 `("GUILE_LOAD_COMPILED_PATH" ":" prefix
2178 (,(getenv "GUILE_LOAD_COMPILED_PATH"))))
2179 #t))))))
6d37301b
RW
2180 (inputs
2181 `(("guile" ,guile-2.2)))
2182 (propagated-inputs
2183 `(("guile-persist" ,guile-persist)
2184 ("guile-readline" ,guile-readline)
2185 ("guile-stis-parser" ,guile-stis-parser)))
2186 (native-inputs
2187 `(("autoconf" ,autoconf)
2188 ("automake" ,automake)
2189 ("libtool" ,libtool)
2190 ("pkg-config" ,pkg-config)))
2191 (home-page "https://gitlab.com/python-on-guile/python-on-guile/")
2192 (synopsis "Python implementation in Guile")
2193 (description
2194 "This package allows you to compile a Guile Python file to any target
2195from @code{tree-il}.")
2196 (license license:lgpl2.0+))))
b97b4624
RW
2197
2198(define-public guile-file-names
2199 (package
2200 (name "guile-file-names")
481eca80 2201 (version "0.2")
b97b4624
RW
2202 (source (origin
2203 (method url-fetch)
2204 (uri (string-append "http://brandon.invergo.net/software/download/"
2205 "guile-file-names/guile-file-names-"
2206 version ".tar.gz"))
2207 (sha256
2208 (base32
481eca80 2209 "1kwx5hanl40960w2nhyga7ry4l6c3c57zdrihk4yajj87vn3pmi8"))))
b97b4624
RW
2210 (build-system gnu-build-system)
2211 (arguments
2212 `(#:phases
2213 (modify-phases %standard-phases
481eca80 2214 (add-after 'unpack 'fix-target-directory
b97b4624 2215 (lambda _
481eca80 2216 (substitute* "src/Makefile.in"
b97b4624
RW
2217 (("guilemoddir = \\$\\(GUILE_SITE\\)")
2218 "guilemoddir = $(datadir)/guile/site/$(GUILE_EFFECTIVE_VERSION)\n"))
2219 #t)))))
2220 (inputs
2221 `(("guile" ,guile-2.2)))
2222 (native-inputs
2223 `(("pkg-config" ,pkg-config)))
2224 (home-page "https://gitlab.com/brandoninvergo/guile-file-names")
2225 (synopsis "Manipulate file names")
2226 (description
2227 "The @code{(file-names)} module provides tools for manipulating file
2228names. The module was built on the idea that doing anything more than a
2229non-trivial modification of a file name string is a pain (making sure all
2230slashes are present and accounted for, resolving @code{.} and @code{..}, etc).
2231Inevitably, you have to break the string up into chunks and operate on that
2232list of components. This module takes care of that for you.")
2233 (license license:lgpl3+)))
bdf2dd79
JN
2234
2235(define-public guile-gi
bb6c8f20
RW
2236 (package
2237 (name "guile-gi")
6153fa0a 2238 (version "0.2.0")
bb6c8f20
RW
2239 (source (origin
2240 (method url-fetch)
2241 (uri (string-append "http://lonelycactus.com/tarball/guile_gi-"
2242 version ".tar.gz"))
2243 (sha256
2244 (base32
6153fa0a 2245 "1n4pbrmbrjkrx826a4m31ag5c35rgkj1sirqh4qalk7gg67cfb41"))))
bb6c8f20
RW
2246 (build-system gnu-build-system)
2247 (arguments
6153fa0a 2248 `(#:configure-flags '("--with-gnu-filesystem-hierarchy")))
bb6c8f20
RW
2249 (native-inputs
2250 `(("gettext" ,gnu-gettext)
6153fa0a 2251 ("glib:bin" ,glib "bin") ; for glib-compile-resources
bb6c8f20
RW
2252 ("libtool" ,libtool)
2253 ("pkg-config" ,pkg-config)))
2254 (propagated-inputs
2255 `(("glib" ,glib)
2256 ("gobject-introspection" ,gobject-introspection)
2257 ("gssettings-desktop-schemas" ,gsettings-desktop-schemas)
2258 ("gtk+" ,gtk+)
2259 ("guile-lib" ,guile-lib)
2260 ("webkitgtk" ,webkitgtk)))
2261 (inputs `(("guile" ,guile-2.2)))
2262 (home-page "https://github.com/spk121/guile-gi")
2263 (synopsis "GObject bindings for Guile")
2264 (description
2265 "Guile-GI is a library for Guile that allows using GObject-based
bdf2dd79
JN
2266libraries, such as GTK+3. Its README comes with the disclaimer: This is
2267pre-alpha code.")
bb6c8f20 2268 (license license:gpl3+)))
dec4b3aa
LC
2269
2270(define-public guile-srfi-159
2271 (let ((commit "1bd98abda2ae4ef8f36761a167903e55c6bda7bb")
2272 (revision "0"))
2273 (package
2274 (name "guile-srfi-159")
2275 (version (git-version "0" revision commit))
2276 (home-page "https://bitbucket.org/bjoli/guile-srfi-159")
2277 (source (origin
2278 (method hg-fetch)
2279 (uri (hg-reference (changeset commit)
2280 (url home-page)))
2281 (sha256
2282 (base32
2283 "1zw6cmcy7xdbfiz3nz9arqnn7l2daidaps6ixkcrc9b6k51fdv3p"))
2284 (file-name (git-file-name name version))))
2285 (build-system guile-build-system)
2286 (arguments
2287 ;; The *-impl.scm files are actually included from module files; they
2288 ;; should not be compiled separately, but they must be installed.
2289 '(#:not-compiled-file-regexp "-impl\\.scm$"))
2290 (inputs
2291 `(("guile" ,guile-2.2)))
2292 (synopsis "Formatting combinators for Guile")
2293 (description
2294 "The @code{(srfi-159)} module and its sub-modules implement the
2295formatting combinators specified by
2296@uref{https://srfi.schemers.org/srfi-159/srfi-159.html, SRFI-159}. These are
2297more expressive and flexible than the traditional @code{format} procedure.")
2298 (license license:bsd-3))))
f0de9544
JN
2299
2300(define-public emacsy
48eb71ae
JN
2301 (package
2302 (name "emacsy")
2303 (version "0.4.1")
2304 (source (origin
2305 (method url-fetch)
2306 (uri (string-append
2307 "https://download.savannah.nongnu.org/releases/"
2308 name "/" name "-" version ".tar.gz"))
2309 (sha256
2310 (base32
2311 "1cpb85dl1nibd34c2x2h7vfmjpkgh353p5b1w20v6cs6gmvgg4np"))))
2312 (build-system gnu-build-system)
2313 (native-inputs
2314 `(("autoconf" ,autoconf)
2315 ("automake" ,automake)
2316 ("bzip2" ,bzip2)
2317 ("guile" ,guile-2.2)
2318 ("gettext" ,gnu-gettext)
2319 ("libtool" ,libtool)
2320 ("perl" ,perl)
2321 ("pkg-config" ,pkg-config)
2322 ("texinfo" ,texinfo)
1aa026aa 2323 ("texlive" ,(texlive-union (list texlive-generic-epsf)))))
114f02ba 2324 (inputs
48eb71ae
JN
2325 `(("dbus-glib" ,dbus-glib)
2326 ("guile" ,guile-2.2)
2327 ("guile-lib" ,guile-lib)
2328 ("guile-readline" ,guile-readline)
48eb71ae 2329 ("freeglut" ,freeglut)
48eb71ae 2330 ("webkitgtk" ,webkitgtk)))
114f02ba
AS
2331 (propagated-inputs
2332 `(("glib-networking" ,glib-networking)
2333 ("gssettings-desktop-schemas" ,gsettings-desktop-schemas)))
48eb71ae 2334 (arguments
114f02ba
AS
2335 `(#:modules ((guix build gnu-build-system)
2336 (guix build utils)
2337 (ice-9 popen)
2338 (ice-9 rdelim)
2339 (ice-9 regex)
2340 (ice-9 ftw)
2341 (srfi srfi-26))
2342 #:phases
48eb71ae
JN
2343 (modify-phases %standard-phases
2344 (add-before 'configure 'setenv
2345 (lambda _
2346 (setenv "GUILE_AUTO_COMPILE" "0")
114f02ba
AS
2347 #t))
2348 (add-after 'install 'wrap-binaries
2349 (lambda* (#:key inputs outputs #:allow-other-keys)
2350 (let* ((out (assoc-ref outputs "out"))
2351 (effective (read-line
2352 (open-pipe* OPEN_READ
2353 "guile" "-c"
2354 "(display (effective-version))")))
2355 (deps (map (cut assoc-ref inputs <>)
2356 '("guile-lib" "guile-readline")))
2357 (scm-path (map (cut string-append <> "/share/guile/site/"
2358 effective) `(,out ,@deps)))
2359 (go-path (map (cut string-append <> "/lib/guile/" effective
2360 "/site-ccache/") `(,out ,@deps)))
2361 (examples (filter (cut string-match "emacsy" <>)
2362 (scandir (string-append out "/bin/"))))
2363 (progs (map (cut string-append out "/bin/" <>)
2364 examples)))
2365 (map (cut wrap-program <>
2366 `("GUILE_LOAD_PATH" ":" prefix ,scm-path)
2367 `("GUILE_LOAD_COMPILED_PATH" ":" prefix ,go-path))
2368 progs)
2369 #t))))))
48eb71ae
JN
2370 (home-page "https://savannah.nongnu.org/projects/emacsy")
2371 (synopsis "Embeddable GNU Emacs-like library using Guile")
2372 (description
2373 "Emacsy is an embeddable Emacs-like library that uses GNU Guile
f0de9544
JN
2374as extension language. Emacsy can give a C program an Emacsy feel with
2375keymaps, minibuffer, recordable macros, history, tab completion, major
2376and minor modes, etc., and can also be used as a pure Guile library. It
48eb71ae
JN
2377comes with a simple counter example using FreeGLUT and browser examples
2378in C using Gtk+-3 and WebKitGtk.")
2379 (license license:gpl3+)))
2135610c 2380
c99f32b9
AS
2381(define-public emacsy-minimal
2382 (let ((commit "f3bf0dbd803d7805b6ae8303253507ad13922293"))
2383 (package
2384 (inherit emacsy)
2385 (name "emacsy-minimal")
2386 (version (git-version "v0.4.1" "19" commit))
2387 (source (origin
2388 (method git-fetch)
2389 (uri (git-reference
2390 (url "https://git.savannah.gnu.org/git/emacsy.git")
2391 (commit commit)))
2392 (file-name (git-file-name name version))
2393 (sha256
2394 (base32
2395 "0ivy28km1p7nlrf63xx3hvrpxf5ld5amk1wcan3k7sqv1kq9mqdb"))))
2396 (build-system gnu-build-system)
2397 (inputs
2398 `(("guile" ,guile-2.2)
2399 ("guile-lib" ,guile-lib)
2400 ("guile-readline" ,guile-readline)))
2401 (propagated-inputs '())
2402 (arguments
2403 `(#:configure-flags '("--without-examples")
2404 #:phases
2405 (modify-phases %standard-phases
2406 (add-before 'configure 'setenv
2407 (lambda _
2408 (setenv "GUILE_AUTO_COMPILE" "0")
2409 #t))))))))
2410
2135610c
LC
2411(define-public guile-jpeg
2412 (let ((commit "6a1673578b297c2c1b28e44a76bd5c49e76a5046")
2413 (revision "0"))
2414 (package
2415 (name "guile-jpeg")
2416 (version (git-version "0.0" revision commit))
2417 (home-page "https://gitlab.com/wingo/guile-jpeg")
2418 (source (origin
2419 (method git-fetch)
2420 (uri (git-reference (url home-page)
2421 (commit commit)))
2422 (sha256
2423 (base32
2424 "05z9m408w3h6aqb5k3r3qa7khir0k10rxwvsrzhkcq1hr5vbmr4m"))
2425 (file-name (git-file-name name version))
2426 (modules '((guix build utils)))
2427 (snippet
2428 '(begin
2429 ;; Install .go files in the right place.
2430 (substitute* "Makefile.am"
2431 (("/ccache") "/site-ccache"))
2432 #t))))
2433 (build-system gnu-build-system)
2434 (native-inputs
2435 `(("autoconf" ,autoconf)
2436 ("automake" ,automake)
2437 ("pkg-config" ,pkg-config)
2438 ("guile" ,guile-2.2)))
2439 (synopsis "JPEG file parsing library for Guile")
2440 (description
2441 "Guile-JPEG is a Scheme library to parse JPEG image files and to
2442perform geometrical transforms on JPEG images.")
2443 (license license:gpl3+))))
e8c2da41
AS
2444
2445(define-public nomad
2446 (package
2447 (name "nomad")
2448 (version "0.1.1-alpha")
2449 (source (origin
2450 (method git-fetch)
2451 (uri (git-reference
2452 (url "https://git.savannah.gnu.org/git/nomad.git")
2453 (commit version)))
2454 (file-name (git-file-name name version))
2455 (sha256
2456 (base32
2457 "0abz07hl5dh802ciy71xzkvkhyryypq1i94wna40a2wndbd73f7z"))))
2458 (build-system gnu-build-system)
2459 (native-inputs
2460 `(("autoconf" ,autoconf)
2461 ("automake" ,automake)
2462 ("bash" ,bash)
2463 ("pkg-config" ,pkg-config)
2464 ("libtool" ,libtool)
2465 ("guile" ,guile-2.2)
2466 ("glib:bin" ,glib "bin")))
2467 (inputs
2468 `(("guile" ,guile-2.2)
2469 ("guile-lib" ,guile-lib)
2470 ("guile-gcrypt" ,guile-gcrypt)
2471 ("guile-readline" ,guile-readline)
2472 ("gnutls" ,gnutls)
2473 ("shroud" ,shroud)
2474 ("emacsy" ,emacsy-minimal)
2475 ("glib" ,glib)
2476 ("dbus-glib" ,dbus-glib)
2477 ("gtk+" ,gtk+)
2478 ("gtksourceview" ,gtksourceview)
2479 ("webkitgtk" ,webkitgtk)
2480 ("xorg-server" ,xorg-server)))
2481 (propagated-inputs
2482 `(("glib" ,glib)
2483 ("glib-networking" ,glib-networking)
2484 ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)))
2485 (arguments
2486 `(#:modules ((guix build gnu-build-system)
2487 (guix build utils)
2488 (ice-9 popen)
2489 (ice-9 rdelim)
2490 (srfi srfi-26))
2491 #:phases
2492 (modify-phases %standard-phases
2493 (add-before 'check 'start-xorg-server
2494 (lambda* (#:key inputs #:allow-other-keys)
2495 ;; The test suite requires a running X server.
2496 (system (format #f "~a/bin/Xvfb :1 &"
2497 (assoc-ref inputs "xorg-server")))
2498 (setenv "DISPLAY" ":1")
2499 #t))
2500 (add-after 'install 'wrap-binaries
2501 (lambda* (#:key inputs outputs #:allow-other-keys)
2502 (let* ((out (assoc-ref outputs "out"))
2503 (gio-deps (map (cut assoc-ref inputs <>) '("glib-networking"
2504 "glib")))
2505 (gio-mod-path (map (cut string-append <> "/lib/gio/modules")
2506 gio-deps))
2507 (effective (read-line (open-pipe*
2508 OPEN_READ
2509 "guile" "-c"
2510 "(display (effective-version))")))
2511 (deps (map (cut assoc-ref inputs <>)
2512 '("emacsy" "guile-lib" "guile-readline"
2513 "shroud")))
2514 (scm-path (map (cut string-append <>
2515 "/share/guile/site/" effective)
2516 `(,out ,@deps)))
2517 (go-path (map (cut string-append <>
2518 "/lib/guile/" effective "/site-ccache")
2519 `(,out ,@deps)))
2520 (progs (map (cut string-append out "/bin/" <>)
2521 '("nomad"))))
2522 (map (cut wrap-program <>
2523 `("GIO_EXTRA_MODULES" ":" prefix ,gio-mod-path)
2524 `("GUILE_LOAD_PATH" ":" prefix ,scm-path)
2525 `("GUILE_LOAD_COMPILED_PATH" ":"
2526 prefix ,go-path))
2527 progs)
2528 #t))))))
2529 (home-page "https://savannah.nongnu.org/projects/nomad/")
2530 (synopsis "Extensible Web Browser in Guile Scheme")
2531 (description "Nomad is an Emacs-like Web Browser built using Webkitgtk and
2532Emacsy. It has a small C layer and most browser features are fully
2533programmable in Guile. It has hooks, keymaps, and self documentation
2534features.")
2535 (license license:gpl3+)))
248965c9
RW
2536
2537(define-public guile-cv
2538 (package
2539 (name "guile-cv")
2540 (version "0.2.1")
2541 (source (origin
2542 (method url-fetch)
2543 (uri (string-append "mirror://gnu/guile-cv/guile-cv-"
2544 version ".tar.gz"))
2545 (sha256
2546 (base32
2547 "0qdf0s2h1xj5lbhnc1pfw69i3zg08pqy2y6869b92ydfis8r82j9"))))
2548 (build-system gnu-build-system)
2549 (arguments
2550 `(#:phases
2551 (modify-phases %standard-phases
2552 (add-after 'unpack 'prepare-build
2553 (lambda* (#:key inputs outputs #:allow-other-keys)
2554 (substitute* "configure"
2555 (("SITEDIR=\"\\$datadir/guile-cv\"")
2556 "SITEDIR=\"$datadir/guile/site/$GUILE_EFFECTIVE_VERSION\"")
2557 (("SITECCACHEDIR=\"\\$libdir/guile-cv/")
2558 "SITECCACHEDIR=\"$libdir/"))
2559 (substitute* "cv/init.scm"
2560 (("\\(dynamic-link \"libvigra_c\"\\)")
2561 (string-append "(dynamic-link \""
2562 (assoc-ref inputs "vigra-c")
2563 "/lib/libvigra_c\")"))
2564 (("\\(dynamic-link \"libguile-cv\"\\)")
2565 (format #f "~s"
2566 `(dynamic-link
2567 (format #f "~alibguile-cv"
2568 (if (getenv "GUILE_CV_UNINSTALLED")
2569 ""
2570 ,(format #f "~a/lib/"
2571 (assoc-ref outputs "out"))))))))
2572 (setenv "GUILE_CV_UNINSTALLED" "1")
2573 ;; Only needed to satisfy the configure script.
2574 (setenv "LD_LIBRARY_PATH"
2575 (string-append (assoc-ref inputs "vigra-c") "/lib"))
2576 #t)))))
2577 (inputs
2578 `(("vigra" ,vigra)
2579 ("vigra-c" ,vigra-c)
2580 ("guile" ,guile-2.2)))
2581 (native-inputs
2582 `(("texlive" ,(texlive-union (list texlive-booktabs
2583 texlive-lm
2584 texlive-siunitx
2585 texlive-standalone
2586 texlive-xcolor
2587 texlive-fonts-iwona)))
2588 ("pkg-config" ,pkg-config)))
2589 (propagated-inputs
2590 `(("guile-lib" ,guile-lib)))
2591 (home-page "https://www.gnu.org/software/guile-cv/")
2592 (synopsis "Computer vision library for Guile")
2593 (description "Guile-CV is a Computer Vision functional programming library
2594for the Guile Scheme language. It is based on Vigra (Vision with Generic
2595Algorithms), a C++ image processing and analysis library. Guile-CV contains
2596bindings to Vigra C (a C wrapper to most of the Vigra functionality) and is
2597enriched with pure Guile Scheme algorithms, all accessible through a nice,
2598clean and easy to use high level API.")
2599 (license license:gpl3+)))