unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: "J. Sims via Guix-patches" via <guix-patches@gnu.org>
To: "62282@debbugs.gnu.org" <62282@debbugs.gnu.org>
Subject: [bug#62282] [PATCH] gnu: gerbil: Upgrade to 0.17.0.
Date: Thu, 30 Mar 2023 02:12:18 +0000	[thread overview]
Message-ID: <LSuRbFEjWmMm1qyxkuaXGo3gQfE0OmQpT61n_KZK0XgalSlLTjksQg6L23adZp6YQxeLmhWu4tHUYG3998qeF_w0d6u-BSrXjFPBtOOTniY=@protonmail.com> (raw)
In-Reply-To: <0121a7d5-ed7a-9272-1c67-4182d979dd0d@makinata.eu>

[-- Attachment #1: Type: text/plain, Size: 446 bytes --]

Hello,

> You should split these changes into separate commits.
> 
> Take a look at https://issues.guix.gnu.org/61845 or search the git history for “G-Expression”

I have done so and the new patches are attached here.

The first two patches have the same effect as the initial patch. The third patch enables a set of features that were not enabled before, but which it would be useful to make available to Guix users.

Thanks,
Juli

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-gerbil-Update-to-0.17.0.patch --]
[-- Type: text/x-patch; name=0001-gnu-gerbil-Update-to-0.17.0.patch, Size: 2411 bytes --]

From 494e5b344b550bbb09d726c7e7c139ee5d1c801d Mon Sep 17 00:00:00 2001
From: Juliana Sims <jtsims@protonmail.com>
Date: Tue, 28 Mar 2023 22:45:26 -0400
Subject: [PATCH 1/3] gnu: gerbil: Update to 0.17.0.

* gnu/package/scheme.scm (gerbil): Update to 0.17.0.
---
 gnu/packages/scheme.scm | 15 ++++++++++++---
 1 file changed, 12 insertions(+), 3 deletions(-)

diff --git a/gnu/packages/scheme.scm b/gnu/packages/scheme.scm
index e6a9ef1db0..e6f58aa403 100644
--- a/gnu/packages/scheme.scm
+++ b/gnu/packages/scheme.scm
@@ -21,6 +21,7 @@
 ;;; Copyright © 2022 jgart <jgart@dismail.de>
 ;;; Copyright © 2022 Robby Zambito <contact@robbyzambito.me>
 ;;; Copyright © 2023 Andrew Whatson <whatson@tailcall.au>
+;;; Copyright © 2023 Juliana Sims <jtsims@protonmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1113,7 +1114,7 @@ (define-public cl-airship-scheme
 (define-public gerbil
   (package
     (name "gerbil")
-    (version "0.16")
+    (version "0.17.0")
     (source
      (origin
        (method git-fetch)
@@ -1122,7 +1123,7 @@ (define-public gerbil
              (commit (string-append "v" version))))
        (file-name (git-file-name name version))
        (sha256
-        (base32 "0vng0kxpnwsg8jbjdpyn4sdww36jz7zfpfbzayg9sdpz6bjxjy0f"))))
+        (base32 "0c0nspm659ybgmqlppdv7sxzll4hwkvcp9qmcsip6d0kz0p8r9c3"))))
     (arguments
      `(#:phases
        (modify-phases %standard-phases
@@ -1172,6 +1173,14 @@ (define-public gerbil
                    "./tutorial/proxy/build-static.ss"
                    "./tutorial/proxy/build.ss")))
              #t))
+         (add-after 'configure 'create-gx-version.scm
+           (lambda _
+             (with-output-to-file (string-append
+                                   (getcwd)
+                                   "/gerbil/runtime/gx-version.scm")
+               (lambda _
+                 (write `(define (gerbil-version-string)
+                           ,(string-append "v" ,(version-major+minor version))))))))
          (replace
           'build
           (lambda*
@@ -1195,7 +1204,7 @@ (define-public gerbil
                (copy-recursively "../bin" bin)
                (copy-recursively "../lib" lib)))))))
     (native-inputs
-     (list coreutils util-linux))
+     (list coreutils gambit-c util-linux))
     (propagated-inputs
      (list gambit-c zlib openssl sqlite))
     (build-system gnu-build-system)
-- 
2.39.2


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #3: 0003-gnu-gerbil-Enable-all-features.patch --]
[-- Type: text/x-patch; name=0003-gnu-gerbil-Enable-all-features.patch, Size: 2661 bytes --]

From 569fabf7029200cbb3166af83b8fc89a6378468d Mon Sep 17 00:00:00 2001
From: Juliana Sims <jtsims@protonmail.com>
Date: Tue, 28 Mar 2023 23:56:07 -0400
Subject: [PATCH 3/3] gnu: gerbil: Enable all features.

* gnu/packages/scheme.scm (gerbil): Enable all features.
---
 gnu/packages/scheme.scm | 25 ++++++++++++++++++++++---
 1 file changed, 22 insertions(+), 3 deletions(-)

diff --git a/gnu/packages/scheme.scm b/gnu/packages/scheme.scm
index 8a510d840b..19ed5d0928 100644
--- a/gnu/packages/scheme.scm
+++ b/gnu/packages/scheme.scm
@@ -80,10 +80,12 @@ (define-module (gnu packages scheme)
   #:use-module (gnu packages netpbm)
   #:use-module (gnu packages pcre)
   #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages serialization)
   #:use-module (gnu packages sqlite)
   #:use-module (gnu packages tex)
   #:use-module (gnu packages texinfo)
   #:use-module (gnu packages tls)
+  #:use-module (gnu packages xml)
   #:use-module (gnu packages xorg)
   #:use-module (srfi srfi-1)
   #:use-module (ice-9 match))
@@ -1140,7 +1142,14 @@ (define-public gerbil
                            "--prefix"
                            #$output
                            "--with-gambit"
-                           #$gambit-c)))
+                           #$gambit-c
+                           "--enable-leveldb"
+                           "--enable-libxml"
+                           "--enable-libyaml"
+                           "--enable-lmdb"
+                           "--enable-mysql"
+                           "--enable-sqlite"
+                           "--enable-zlib")))
                (add-before 'patch-generated-file-shebangs 'fix-gxi-shebangs
                  (lambda _
                    ;; Some .ss files refer to gxi using /usr/bin/env gxi
@@ -1202,8 +1211,18 @@ (define-public gerbil
                      (copy-recursively "../bin" bin)
                      (copy-recursively "../lib" lib)))))
            #:tests? #f))
-    (native-inputs (list coreutils gambit-c util-linux))
-    (propagated-inputs (list gambit-c openssl sqlite zlib))
+    (native-inputs (list coreutils
+                         gambit-c
+                         util-linux))
+    (propagated-inputs (list gambit-c
+                             leveldb
+                             libxml2
+                             libyaml
+                             lmdb
+                             mysql
+                             openssl
+                             sqlite
+                             zlib))
     (build-system gnu-build-system)
     (synopsis "Meta-dialect of Scheme with post-modern features")
     (description
-- 
2.39.2


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #4: 0002-gnu-gerbil-Use-G-expressions.patch --]
[-- Type: text/x-patch; name=0002-gnu-gerbil-Use-G-expressions.patch, Size: 9785 bytes --]

From 3ea0527aab1924ff3eb49f7714400ae88e2dfd65 Mon Sep 17 00:00:00 2001
From: Juliana Sims <jtsims@protonmail.com>
Date: Tue, 28 Mar 2023 23:05:15 -0400
Subject: [PATCH 2/3] gnu: gerbil: Use G-expressions.

* gnu/packages/scheme.scm (gerbil)[source, arguments]: Reindent.
[arguments]: Rewrite using G-expressions. Do not return #t from custom
phases. Use #:tests? instead of deleting the check phase.
---
 gnu/packages/scheme.scm | 182 ++++++++++++++++++++--------------------
 1 file changed, 90 insertions(+), 92 deletions(-)

diff --git a/gnu/packages/scheme.scm b/gnu/packages/scheme.scm
index e6f58aa403..8a510d840b 100644
--- a/gnu/packages/scheme.scm
+++ b/gnu/packages/scheme.scm
@@ -1115,101 +1115,99 @@ (define-public gerbil
   (package
     (name "gerbil")
     (version "0.17.0")
-    (source
-     (origin
-       (method git-fetch)
-       (uri (git-reference
-             (url "https://github.com/vyzo/gerbil")
-             (commit (string-append "v" version))))
-       (file-name (git-file-name name version))
-       (sha256
-        (base32 "0c0nspm659ybgmqlppdv7sxzll4hwkvcp9qmcsip6d0kz0p8r9c3"))))
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/vyzo/gerbil")
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "0c0nspm659ybgmqlppdv7sxzll4hwkvcp9qmcsip6d0kz0p8r9c3"))))
     (arguments
-     `(#:phases
-       (modify-phases %standard-phases
-         (delete 'bootstrap)
-         (add-before 'configure 'chdir
-           (lambda _
-             (chdir "src")
-             #t))
-         (replace 'configure
-           (lambda* (#:key outputs inputs #:allow-other-keys)
-             (invoke "chmod" "755" "-R" ".")
-             ;; Otherwise fails when editing an r--r--r-- file.
-             (invoke "gsi-script" "configure"
-                     "--prefix" (assoc-ref outputs "out")
-                     "--with-gambit" (assoc-ref inputs "gambit-c"))))
-         (add-before 'patch-generated-file-shebangs 'fix-gxi-shebangs
-           (lambda _
-             ;; Some .ss files refer to gxi using /usr/bin/env gxi
-             ;; and 'patch-generated-file-shebangs can't fix that
-             ;; because gxi has not been compiled yet.
-             ;; We know where gxi is going to end up so we
-             ;; Doctor Who our fix here before the problem
-             ;; happens towards the end of the build.sh script.
-             (let ((abs-srcdir (getcwd)))
-               (for-each
-                (lambda (f)
-                   (substitute* f
-                     (("#!/usr/bin/env gxi")
-                      (string-append "#!" abs-srcdir "/../bin/gxi"))))
-                 '("./gerbil/gxc"
-                   "./lang/build.ss"
-                   "./misc/http-perf/build.ss"
-                   "./misc/rpc-perf/build.ss"
-                   "./misc/scripts/docsnarf.ss"
-                   "./misc/scripts/docstub.ss"
-                   "./misc/scripts/docsyms.ss"
-                   "./r7rs-large/build.ss"
-                   "./release.ss"
-                   "./std/build.ss"
-                   "./std/run-tests.ss"
-                   "./std/web/fastcgi-test.ss"
-                   "./std/web/rack-test.ss"
-                   "./tools/build.ss"
-                   "./tutorial/httpd/build.ss"
-                   "./tutorial/kvstore/build.ss"
-                   "./tutorial/lang/build.ss"
-                   "./tutorial/proxy/build-static.ss"
-                   "./tutorial/proxy/build.ss")))
-             #t))
-         (add-after 'configure 'create-gx-version.scm
-           (lambda _
-             (with-output-to-file (string-append
-                                   (getcwd)
-                                   "/gerbil/runtime/gx-version.scm")
-               (lambda _
-                 (write `(define (gerbil-version-string)
-                           ,(string-append "v" ,(version-major+minor version))))))))
-         (replace
-          'build
-          (lambda*
-           (#:key inputs #:allow-other-keys)
-           (setenv "HOME" (getcwd))
-             (invoke
-              ;; The build script needs a tty or it'll crash on an ioctl
-              ;; trying to find the width of the terminal it's running on.
-              ;; Calling in script prevents that.
-              "script"
-              "-qefc"
-              "./build.sh")))
-         (delete 'check)
-         (replace 'install
-           (lambda* (#:key outputs #:allow-other-keys)
-             (let* ((out (assoc-ref outputs "out"))
-                    (bin (string-append out "/bin"))
-                    (lib (string-append out "/lib")))
-               (mkdir-p bin)
-               (mkdir-p lib)
-               (copy-recursively "../bin" bin)
-               (copy-recursively "../lib" lib)))))))
-    (native-inputs
-     (list coreutils gambit-c util-linux))
-    (propagated-inputs
-     (list gambit-c zlib openssl sqlite))
+     (list #:phases
+           #~(modify-phases %standard-phases
+               (delete 'bootstrap)
+               (add-before 'configure 'chdir
+                 (lambda _
+                   (chdir "src")))
+               (replace 'configure
+                 (lambda _
+                   (invoke "chmod" "755" "-R" ".")
+                   ;; Otherwise fails when editing an r--r--r-- file.
+                   (invoke "gsi-script"
+                           "configure"
+                           "--prefix"
+                           #$output
+                           "--with-gambit"
+                           #$gambit-c)))
+               (add-before 'patch-generated-file-shebangs 'fix-gxi-shebangs
+                 (lambda _
+                   ;; Some .ss files refer to gxi using /usr/bin/env gxi
+                   ;; and 'patch-generated-file-shebangs can't fix that
+                   ;; because gxi has not been compiled yet.
+                   ;; We know where gxi is going to end up so we
+                   ;; Doctor Who our fix here before the problem
+                   ;; happens towards the end of the build.sh script.
+                   (let ((abs-srcdir (getcwd)))
+                     (for-each (lambda (f)
+                                 (substitute* f
+                                   (("#!/usr/bin/env gxi")
+                                    (string-append "#!" abs-srcdir
+                                                   "/../bin/gxi"))))
+                               '("./gerbil/gxc" "./lang/build.ss"
+                                 "./misc/http-perf/build.ss"
+                                 "./misc/rpc-perf/build.ss"
+                                 "./misc/scripts/docsnarf.ss"
+                                 "./misc/scripts/docstub.ss"
+                                 "./misc/scripts/docsyms.ss"
+                                 "./r7rs-large/build.ss"
+                                 "./release.ss"
+                                 "./std/build.ss"
+                                 "./std/run-tests.ss"
+                                 "./std/web/fastcgi-test.ss"
+                                 "./std/web/rack-test.ss"
+                                 "./tools/build.ss"
+                                 "./tutorial/httpd/build.ss"
+                                 "./tutorial/kvstore/build.ss"
+                                 "./tutorial/lang/build.ss"
+                                 "./tutorial/proxy/build-static.ss"
+                                 "./tutorial/proxy/build.ss")))))
+               (add-after 'configure 'create-gx-version.scm
+                 (lambda _
+                   (with-output-to-file (string-append (getcwd)
+                                                       "/gerbil/runtime/gx-version.scm")
+                     (lambda _
+                       (write `(define (gerbil-version-string)
+                                 ,(string-append "v"
+                                                 #$(version-major+minor
+                                                    version))))))))
+               (replace 'build
+                 (lambda _
+                   (setenv "HOME"
+                           (getcwd))
+                   (invoke
+                    ;; The build script needs a tty or it'll crash on an ioctl
+                    ;; trying to find the width of the terminal it's running on.
+                    ;; Calling in script prevents that.
+                    "script"
+                    "-qefc"
+                    "./build.sh")))
+               (replace 'install
+                 (lambda _
+                   (let* ((bin (string-append #$output "/bin"))
+                          (lib (string-append #$output "/lib")))
+                     (mkdir-p bin)
+                     (mkdir-p lib)
+                     (copy-recursively "../bin" bin)
+                     (copy-recursively "../lib" lib)))))
+           #:tests? #f))
+    (native-inputs (list coreutils gambit-c util-linux))
+    (propagated-inputs (list gambit-c openssl sqlite zlib))
     (build-system gnu-build-system)
     (synopsis "Meta-dialect of Scheme with post-modern features")
-    (description "Gerbil is an opinionated dialect of Scheme designed for Systems
+    (description
+     "Gerbil is an opinionated dialect of Scheme designed for Systems
 Programming, with a state of the art macro and module system on top of the Gambit
 runtime.  The macro system is based on quote-syntax, and provides the full meta-syntactic
 tower with a native implementation of syntax-case.  It also provides a full-blown module
-- 
2.39.2


  reply	other threads:[~2023-03-30  2:13 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-19 23:06 [bug#62282] [PATCH] gnu: gerbil: Upgrade to 0.17.0 J. Sims via Guix-patches via
2023-03-21 13:57 ` Bruno Victal
2023-03-30  2:12   ` J. Sims via Guix-patches via [this message]
2023-04-08 22:01     ` bug#62282: " Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='LSuRbFEjWmMm1qyxkuaXGo3gQfE0OmQpT61n_KZK0XgalSlLTjksQg6L23adZp6YQxeLmhWu4tHUYG3998qeF_w0d6u-BSrXjFPBtOOTniY=@protonmail.com' \
    --to=guix-patches@gnu.org \
    --cc=62282@debbugs.gnu.org \
    --cc=jtsims@protonmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).