aboutsummaryrefslogtreecommitdiffstats
path: root/mcgoron/guix
diff options
context:
space:
mode:
authorGravatar Peter McGoron 2026-03-09 10:29:49 -0400
committerGravatar Peter McGoron 2026-03-09 10:29:49 -0400
commit0a7d37ee062320878371ba172eb961d3d8748def (patch)
treee960726915a42b2373c9a451b97938a858bfd5f6 /mcgoron/guix
parentcyclone and libck (diff)
fix path, add tr7 stdlib
Diffstat (limited to 'mcgoron/guix')
-rw-r--r--mcgoron/guix/scheme-packages.scm53
1 files changed, 39 insertions, 14 deletions
diff --git a/mcgoron/guix/scheme-packages.scm b/mcgoron/guix/scheme-packages.scm
index 9b7ff04..5838d2f 100644
--- a/mcgoron/guix/scheme-packages.scm
+++ b/mcgoron/guix/scheme-packages.scm
@@ -183,7 +183,7 @@
(use-modules (guix build utils))
(let* ((bin (assoc-ref %outputs "out"))
(impl (string-append
- (assoc-ref %build-inputs ,package-name)
+ (assoc-ref %build-inputs ,(package-name imported-package))
,binary-name))
(sh (string-append
(assoc-ref %build-inputs "bash-minimal")
@@ -488,19 +488,51 @@
;;;; TR7
;;;;;;;;;;;
+;;; XXX: Currently importing tr7 requires the fragile (tr7 tr7-with-path) combo.
+(define-public tr7-lib-dir "share/tr7")
+(define current-tr7-hash
+ "1326s9zxznh400rzz07sxnc11f82qhy45cj8xawg41z50jlqg5y9")
+
+(define-public tr7-stdlib
+ (package
+ (name "tr7-stdlib")
+ (version "2.0.16")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://gitlab.com/jobol/tr7")
+ (commit (string-append "v" version))))
+ (sha256 (base32 current-tr7-hash))
+ (file-name (git-file-name name version))))
+ (build-system copy-build-system)
+ (arguments `(#:install-plan '(("tr7libs" ,tr7-lib-dir))))
+ (home-page "https://gitlab.com/jobol/tr7")
+ (synopsis "Embedded R7RS small Scheme interpreter (standard libraries)")
+ (description
+ "TR7 is a lightweight Scheme interpreter that implements the revision
+R7RS small of scheme programming language.
+
+It is meant to be used as an embedded scripting interpreter for other
+programs. A lot of functionality in TR7 is included conditionally, to allow
+developers freedom in balancing features and footprint.
+
+This package installs the libraries that come with tr7 such that they are
+accessable by tr7-with-path.")
+ (license bsd-0)))
+
(define-public tr7
;; Current guix TR7 is a major version out of date
(package
(name "tr7")
- (version "2.0.12")
+ (version "2.0.16")
(source
(origin
(method git-fetch)
(uri (git-reference
(url "https://gitlab.com/jobol/tr7")
(commit (string-append "v" version))))
- (sha256
- (base32 "0q4lqhqbmac54nh7lykhkc0wbzra9y0x9bdzy7jvp66mj8m8ix66"))
+ (sha256 (base32 current-tr7-hash))
(file-name (git-file-name name version))))
(build-system gnu-build-system)
(outputs '("out" "doc"))
@@ -526,16 +558,11 @@
(replace 'install
(lambda _
(let* ((share (string-append #$output "/share"))
- (doc (string-append #$output:doc "/share/doc/"))
(bin (string-append #$output "/bin"))
- (lib (string-append #$output "/lib/"))
- (tr7 (string-append share "/tr7"))
- (libs (string-append tr7 "/libs")))
- (for-each mkdir-p (list tr7 libs bin lib doc))
+ (lib (string-append #$output "/lib/")))
+ (for-each mkdir-p (list lib bin))
(copy-file "tr7i" (string-append bin "/tr7i"))
- (copy-file "libtr7.a" (string-append lib "/libtr7.a"))
- #;(copy-file "r7rs.pdf" (string-append doc "/r7rs.pdf"))
- (copy-recursively "tr7libs" libs)))))))
+ (copy-file "libtr7.a" (string-append lib "/libtr7.a"))))))))
(home-page "https://gitlab.com/jobol/tr7")
(synopsis "Embedded R7RS small Scheme interpreter")
(description
@@ -547,8 +574,6 @@ programs. A lot of functionality in TR7 is included conditionally, to allow
developers freedom in balancing features and footprint.")
(license bsd-0)))
-(define-public tr7-lib-dir "share/tr7")
-
(define-public tr7-build-system
(default-copying-build-system 'tr7
"Copy Scheme libraries into TR7 directory"