aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher R. Nelson <christopher.nelson@languidnights.com>2024-01-22 07:54:48 -0500
committerChristopher R. Nelson <christopher.nelson@languidnights.com>2024-01-22 07:54:48 -0500
commit35fb2f2a04d1ed1594c596c22c283af702a6a8ef (patch)
tree2c4a0d0c101cc440bcc493d12a6c7fff85e55d33
parenta855ea3efd669b7a96c942223f913ca75fb0519f (diff)
guile-reading-heap: a heap of reading material
-rw-r--r--crn/packages/guile-xyz.scm108
1 files changed, 108 insertions, 0 deletions
diff --git a/crn/packages/guile-xyz.scm b/crn/packages/guile-xyz.scm
new file mode 100644
index 0000000..ee5f160
--- /dev/null
+++ b/crn/packages/guile-xyz.scm
@@ -0,0 +1,108 @@
+(define-module (crn packages guile-xyz)
+ #:use-module (crn packages)
+ #:use-module (gnu packages autotools)
+ #:use-module (gnu packages guile)
+ #:use-module (gnu packages guile-xyz)
+ #:use-module (gnu packages networking)
+ #:use-module (gnu packages pkg-config)
+ #:use-module (gnu packages texinfo)
+ #:use-module (guix build-system gnu)
+ #:use-module (guix git-download)
+ #:use-module (guix gexp)
+ #:use-module (guix packages)
+ #:use-module ((guix licenses) #:prefix licenses:))
+
+(define-public guile-reading-heap
+ (package
+ (name "guile-reading-heap")
+ (version "0.1")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "git://languidnights.com/reading-heap")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1zk8q003wzp00yc8lwadm45fc4vg44qiaa2qj5rr6x0vi35f8qj7"))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:modules
+ ((ice-9 match)
+ (ice-9 ftw)
+ ,@%gnu-build-system-modules)
+ #:phases
+ (modify-phases
+ %standard-phases
+ (add-after
+ 'install
+ 'hall-wrap-binaries
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (let* ((compiled-dir
+ (lambda (out version)
+ (string-append
+ out
+ "/lib/guile/"
+ version
+ "/site-ccache")))
+ (uncompiled-dir
+ (lambda (out version)
+ (string-append
+ out
+ "/share/guile/site"
+ (if (string-null? version) "" "/")
+ version)))
+ (dep-path
+ (lambda (env modules path)
+ (list env
+ ":"
+ 'prefix
+ (cons modules
+ (map (lambda (input)
+ (string-append
+ (assoc-ref inputs input)
+ path))
+ ,''("guile-config"
+ "guile-json"
+ "guile-simple-zmq"))))))
+ (out (assoc-ref outputs "out"))
+ (bin (string-append out "/bin/"))
+ (site (uncompiled-dir out "")))
+ (match (scandir site)
+ (("." ".." version)
+ (for-each
+ (lambda (file)
+ (wrap-program
+ (string-append bin file)
+ (dep-path
+ "GUILE_LOAD_PATH"
+ (uncompiled-dir out version)
+ (uncompiled-dir "" version))
+ (dep-path
+ "GUILE_LOAD_COMPILED_PATH"
+ (compiled-dir out version)
+ (compiled-dir "" version))))
+ ,''("rh-server" "rh-client"))
+ #t))))))))
+ (native-inputs
+ (list autoconf
+ automake
+ guile-hall
+ pkg-config
+ texinfo))
+ (inputs
+ (list guile-3.0
+ guile-config
+ guile-json-4
+ guile-simple-zmq
+ zeromq))
+ (synopsis
+ "An application for managing your reading list.")
+ (description
+ "Reading-Heap is a client-server application that manages a reading
+ list in a priority queue, so you always know what the next thing you
+should read is, without having to devote your own brain power to sorting
+them.")
+ (home-page
+ "https://projects.languidnights.com/reading-heap/")
+ (license licenses:agpl3+)))