guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

branch master updated: gnu: Add tr7.


From: guix-commits
Subject: branch master updated: gnu: Add tr7.
Date: Mon, 15 Apr 2024 06:33:45 -0400

This is an automated email from the git hooks/post-receive script.

ngz pushed a commit to branch master
in repository guix.

The following commit(s) were added to refs/heads/master by this push:
     new a8353e9d6b gnu: Add tr7.
a8353e9d6b is described below

commit a8353e9d6b34fd8d42d2e8f14ce844849fe9c293
Author: Artyom V. Poptsov <poptsov.artyom@gmail.com>
AuthorDate: Sat Apr 6 09:32:09 2024 +0300

    gnu: Add tr7.
    
    * gnu/packages/scheme.scm (tr7): New variable.
    
    Change-Id: I60e34f0f918ea7c9b36cea02358d69ab7bfad24b
    Signed-off-by: Nicolas Goaziou <mail@nicolasgoaziou.fr>
---
 gnu/packages/scheme.scm | 62 ++++++++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 61 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/scheme.scm b/gnu/packages/scheme.scm
index 070696d6ba..a91a2d693d 100644
--- a/gnu/packages/scheme.scm
+++ b/gnu/packages/scheme.scm
@@ -24,6 +24,7 @@
 ;;; Copyright © 2023 Juliana Sims <juli@incana.org>
 ;;; Copyright © 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com>
 ;;; Copyright © 2024 Skylar Hill <stellarskylark@posteo.net>
+;;; Copyright © 2024 Artyom V. Poptsov <poptsov.artyom@gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -44,7 +45,8 @@
   #:use-module (gnu packages)
   #:use-module ((guix licenses)
                 #:select (gpl2 gpl2+ lgpl2.0+ lgpl2.1 lgpl2.1+ lgpl3+ asl2.0
-                          bsd-3 cc-by-sa4.0 non-copyleft expat public-domain))
+                          bsd-0 bsd-3 cc-by-sa4.0 non-copyleft expat
+                          public-domain))
   #:use-module (guix gexp)
   #:use-module (guix packages)
   #:use-module (guix download)
@@ -855,6 +857,64 @@ can be added and values can be defined in the Scheme 
environment.  Being quite a
 small program, it is easy to comprehend, get to grips with, and use.")
     (license bsd-3)))                   ; there are no licence headers
 
+(define-public tr7
+  (package
+    (name "tr7")
+    (version "1.0.10")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://gitlab.com/jobol/tr7";)
+             (commit (string-append "v" version))))
+       (sha256
+        (base32 "0n77fkm5kcv2pmwbw5fl8r00aarw8da8gkd9d1ki5fn9kbl4fyk2"))
+       (file-name (git-file-name name version))))
+    (build-system gnu-build-system)
+    (outputs '("out" "doc"))
+    (arguments
+     (list
+      #:phases
+      #~(modify-phases %standard-phases
+          (replace 'configure
+            (lambda _
+              (substitute* "Makefile"
+                (("PREFIX = /usr/local")
+                 (string-append "PREFIX=" #$output))
+                (("ALL = \\$\\(LIBSTA\\) \\$\\(TR7I\\) tags")
+                 "ALL = $(LIBSTA) $(TR7I)"))))
+          (replace 'build
+            (lambda _
+              (setenv "CC" #$(cc-for-target))
+              (invoke "make")))
+          (replace 'check
+            (lambda* (#:key tests? #:allow-other-keys)
+              (when tests?
+                (invoke "make" "test"))))
+          (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))
+                (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)))))))
+    (home-page "https://gitlab.com/jobol/tr7";)
+    (synopsis "Embedded R7RS small Scheme interpreter")
+    (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.")
+    (license bsd-0)))
+
 (define-public stalin
   (let ((commit "ed1c9e339c352b7a6fee40bb2a47607c3466f0be"))
     ;; FIXME: The Stalin "source" contains C code generated by itself:



reply via email to

[Prev in Thread] Current Thread [Next in Thread]