[PATCHES] Add guile's implementation for scheme-lsp-server

  • Open
  • quality assurance status badge
Details
2 participants
  • Abhishek Cherath
  • goodoldpaul
Owner
unassigned
Submitted by
goodoldpaul
Severity
normal
G
G
G
Giacomo Leidi wrote on 23 Dec 2022 21:46
[PATCH 2/2] gnu: Add guile-scheme-lsp-server.
(address . 60286@debbugs.gnu.org)(name . Giacomo Leidi)(address . goodoldpaul@autistici.org)
20221223204630.1833-2-goodoldpaul@autistici.org
* gnu/packages/scheme-xyz.scm (guile-scheme-lsp-server): New variable.
---
gnu/packages/scheme-xyz.scm | 85 +++++++++++++++++++++++++++++++++++++
1 file changed, 85 insertions(+)

Toggle diff (102 lines)
diff --git a/gnu/packages/scheme-xyz.scm b/gnu/packages/scheme-xyz.scm
index 819c5cdf9e..513953b0f4 100644
--- a/gnu/packages/scheme-xyz.scm
+++ b/gnu/packages/scheme-xyz.scm
@@ -18,6 +18,7 @@
(define-module (gnu packages scheme-xyz)
#:use-module (gnu packages autotools)
+ #:use-module (gnu packages bash)
#:use-module (gnu packages guile)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages texinfo)
@@ -65,3 +66,87 @@ (define-public guile-scheme-json-rpc
This package delivers Guile's bytecode for @code{scheme-json-rpc}.")
(home-page "https://codeberg.org/rgherdt/scheme-json-rpc")
(license license:expat)))
+
+(define (scheme-lsp-server-origin name version hash)
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://codeberg.org/rgherdt/scheme-lsp-server.git")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ hash))))
+
+(define-public guile-scheme-lsp-server
+ (package
+ (name "guile-scheme-lsp-server")
+ (version "0.2.2")
+ (source
+ (scheme-lsp-server-origin
+ name
+ version
+ "0lb359gw00w149h5yq2brfrcpybdwdj6ndbl7k1ms88l653r5l2g"))
+ (build-system gnu-build-system)
+ (arguments
+ (list #:modules `((ice-9 match)
+ (ice-9 ftw)
+ ,@%gnu-build-system-modules)
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-after 'unpack 'move-to-guile-directory
+ (lambda _
+ (chdir "./guile")))
+ (add-after 'install 'wrap-entrypoint
+ (lambda _
+ (let* ((bin (string-append #$output "/bin"))
+ (site (string-append #$output
+ "/share/guile/site"))
+ (deps (list #$guile-scheme-json-rpc)))
+ (match (scandir site)
+ (("." ".." version)
+ (let ((modules (string-append site "/"
+ version))
+ (compiled-modules (string-append #$output
+ "/lib/guile/"
+ version
+ "/site-ccache")))
+ (wrap-program (string-append bin
+ "/guile-lsp-server")
+ `("GUILE_LOAD_PATH" ":"
+ prefix
+ (,modules
+ ,@(map (lambda (dep)
+ (string-append
+ dep
+ "/share/guile/site/"
+ version))
+ deps)))
+ `("GUILE_LOAD_COMPILED_PATH"
+ ":" prefix
+ (,compiled-modules
+ ,@(map (lambda (dep)
+ (string-append
+ dep
+ "/lib/guile/"
+ version
+ "/site-ccache"))
+ deps))))
+ #t)))))))))
+ (native-inputs (list autoconf automake pkg-config))
+ (inputs
+ ;; Depend on the latest Guile to avoid bytecode compatibility issues when
+ ;; using modules built against the latest version.
+ (list bash-minimal
+ guile-3.0-latest))
+ (propagated-inputs (list guile-scheme-json-rpc))
+ (synopsis "LSP (Language Server Protocol) server for Scheme")
+ (description
+ "@code{guile-lsp-server} is an implementation for Guile of the LSP
+specification. This software aims to support several Scheme implementations.
+To achieve this, the code is designed to contain as much logic as possible in
+R7RS Scheme, separating implementation-specific code in different modules.
+
+This package delivers Guile's implementation for @code{scheme-lsp-server}.")
+ (home-page "https://codeberg.org/rgherdt/scheme-lsp-server")
+ (license license:expat)))
--
2.38.1
G
G
Giacomo Leidi wrote on 23 Dec 2022 21:46
[PATCH 1/2] gnu: Add guile-scheme-json-rpc.
(address . 60286@debbugs.gnu.org)(name . Giacomo Leidi)(address . goodoldpaul@autistici.org)
20221223204630.1833-1-goodoldpaul@autistici.org
* gnu/packages/scheme-xyz.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
---
gnu/local.mk | 1 +
gnu/packages/scheme-xyz.scm | 67 +++++++++++++++++++++++++++++++++++++
2 files changed, 68 insertions(+)
create mode 100644 gnu/packages/scheme-xyz.scm

Toggle diff (89 lines)
diff --git a/gnu/local.mk b/gnu/local.mk
index 45d05de02d..868903a0e7 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -548,6 +548,7 @@ GNU_SYSTEM_MODULES = \
%D%/packages/sawfish.scm \
%D%/packages/scanner.scm \
%D%/packages/scheme.scm \
+ %D%/packages/scheme-xyz.scm \
%D%/packages/spreadsheet.scm \
%D%/packages/screen.scm \
%D%/packages/scribus.scm \
diff --git a/gnu/packages/scheme-xyz.scm b/gnu/packages/scheme-xyz.scm
new file mode 100644
index 0000000000..819c5cdf9e
--- /dev/null
+++ b/gnu/packages/scheme-xyz.scm
@@ -0,0 +1,67 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2022 Giacomo Leidi <goodoldpaul@autistici.org>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages scheme-xyz)
+ #:use-module (gnu packages autotools)
+ #:use-module (gnu packages guile)
+ #:use-module (gnu packages pkg-config)
+ #:use-module (gnu packages texinfo)
+ #:use-module (guix gexp)
+ #:use-module (guix git-download)
+ #:use-module ((guix licenses) #:prefix license:)
+ #:use-module (guix packages)
+ #:use-module (guix build-system gnu))
+
+(define (scheme-json-rpc-origin name version hash)
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://codeberg.org/rgherdt/scheme-json-rpc.git")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ hash))))
+
+(define-public guile-scheme-json-rpc
+ (package
+ (name "guile-scheme-json-rpc")
+ (version "0.2.11")
+ (source
+ (scheme-json-rpc-origin
+ name
+ version
+ "0w4m8xx8yyj0rv0q57mjr8ja87l7yikscj33i3ck26wg7230ppa5"))
+ (build-system gnu-build-system)
+ (arguments
+ (list #:phases #~(modify-phases %standard-phases
+ (add-after 'unpack 'move-to-guile-directory
+ (lambda _
+ (chdir "./guile"))))))
+ (native-inputs (list autoconf automake pkg-config texinfo guile-3.0-latest))
+ (synopsis "Implementation of the JSON-RPC for Scheme")
+ (description
+ "@code{scheme-json-rpc} allows calling procedures
+on remote servers by exchanging JSON objects. It implements the
+@url{jsonrpc specifications, https://www.jsonrpc.org/specification}.
+The low-level API strives to be R7RS compliant, relying on some SRFI's
+when needed. So far it was only tested under CHICKEN 5 and Guile 3.
+
+This package delivers Guile's bytecode for @code{scheme-json-rpc}.")
+ (home-page "https://codeberg.org/rgherdt/scheme-json-rpc")
+ (license license:expat)))

base-commit: 1b29fccff2334fb5d6e979a290233a452969e39b
--
2.38.1
A
A
Abhishek Cherath wrote on 31 Dec 2022 17:23
[PATCHES] Add guile's implementation for scheme-lsp-server
(address . 60286@debbugs.gnu.org)
24291997-B08A-4644-B0BF-25F759EE6A13@quic.us
Ha! I hadn't seen this and submitted #60444

Does the json-rpc package need autoconf automake and TeX? I got it to work with guile-3, guile-json-3 as inputs and pkg-config as a native input. (Actually now that I think about it I guess guile-json isn't needed)

Also why would guile be a native input for json-rpc? Should just be an input right?

Thanks,
Abhishek.
Attachment: file
G
G
goodoldpaul wrote on 2 Jan 02:52 +0100
(address . 60286@debbugs.gnu.org)
f15587251ce3f7e90f53612bc6b09711@autistici.org
Dear Abhishek,
thank you for the heads up! I fixed my patches with your suggestions and
I'm sending an updated patchset.

giacomo
G
G
Giacomo Leidi wrote on 2 Jan 03:00 +0100
[PATCHv2 1/2] gnu: Add guile-scheme-json-rpc.
(address . 60286@debbugs.gnu.org)(name . Giacomo Leidi)(address . goodoldpaul@autistici.org)
20230102020024.27498-1-goodoldpaul@autistici.org
* gnu/packages/scheme-xyz.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
---
gnu/local.mk | 1 +
gnu/packages/scheme-xyz.scm | 68 +++++++++++++++++++++++++++++++++++++
2 files changed, 69 insertions(+)
create mode 100644 gnu/packages/scheme-xyz.scm

Toggle diff (90 lines)
diff --git a/gnu/local.mk b/gnu/local.mk
index f0b1b3fd15..5a285eb629 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -548,6 +548,7 @@ GNU_SYSTEM_MODULES = \
%D%/packages/sawfish.scm \
%D%/packages/scanner.scm \
%D%/packages/scheme.scm \
+ %D%/packages/scheme-xyz.scm \
%D%/packages/spreadsheet.scm \
%D%/packages/screen.scm \
%D%/packages/scribus.scm \
diff --git a/gnu/packages/scheme-xyz.scm b/gnu/packages/scheme-xyz.scm
new file mode 100644
index 0000000000..91ba1e7f5b
--- /dev/null
+++ b/gnu/packages/scheme-xyz.scm
@@ -0,0 +1,68 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2022 Giacomo Leidi <goodoldpaul@autistici.org>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages scheme-xyz)
+ #:use-module (gnu packages autotools)
+ #:use-module (gnu packages guile)
+ #:use-module (gnu packages pkg-config)
+ #:use-module (gnu packages texinfo)
+ #:use-module (guix gexp)
+ #:use-module (guix git-download)
+ #:use-module ((guix licenses) #:prefix license:)
+ #:use-module (guix packages)
+ #:use-module (guix build-system gnu))
+
+(define (scheme-json-rpc-origin name version hash)
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://codeberg.org/rgherdt/scheme-json-rpc.git")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ hash))))
+
+(define-public guile-scheme-json-rpc
+ (package
+ (name "guile-scheme-json-rpc")
+ (version "0.2.11")
+ (source
+ (scheme-json-rpc-origin
+ name
+ version
+ "0w4m8xx8yyj0rv0q57mjr8ja87l7yikscj33i3ck26wg7230ppa5"))
+ (build-system gnu-build-system)
+ (arguments
+ (list #:phases #~(modify-phases %standard-phases
+ (add-after 'unpack 'move-to-guile-directory
+ (lambda _
+ (chdir "./guile"))))))
+ (native-inputs (list pkg-config))
+ (inputs (list guile-3.0-latest))
+ (synopsis "Implementation of the JSON-RPC for Scheme")
+ (description
+ "@code{scheme-json-rpc} allows calling procedures
+on remote servers by exchanging JSON objects. It implements the
+@url{jsonrpc specifications, https://www.jsonrpc.org/specification}.
+The low-level API strives to be R7RS compliant, relying on some SRFI's
+when needed. So far it was only tested under CHICKEN 5 and Guile 3.
+
+This package delivers Guile's bytecode for @code{scheme-json-rpc}.")
+ (home-page "https://codeberg.org/rgherdt/scheme-json-rpc")
+ (license license:expat)))

base-commit: d7a9d72bb02a2a3b1a99183655bf878547116032
--
2.38.1
G
G
Giacomo Leidi wrote on 2 Jan 03:00 +0100
[PATCHv2 2/2] gnu: Add guile-scheme-lsp-server.
(address . 60286@debbugs.gnu.org)(name . Giacomo Leidi)(address . goodoldpaul@autistici.org)
20230102020024.27498-2-goodoldpaul@autistici.org
* gnu/packages/scheme-xyz.scm (guile-scheme-lsp-server): New variable.
---
gnu/packages/scheme-xyz.scm | 85 +++++++++++++++++++++++++++++++++++++
1 file changed, 85 insertions(+)

Toggle diff (102 lines)
diff --git a/gnu/packages/scheme-xyz.scm b/gnu/packages/scheme-xyz.scm
index 91ba1e7f5b..3947bf4f92 100644
--- a/gnu/packages/scheme-xyz.scm
+++ b/gnu/packages/scheme-xyz.scm
@@ -18,6 +18,7 @@
(define-module (gnu packages scheme-xyz)
#:use-module (gnu packages autotools)
+ #:use-module (gnu packages bash)
#:use-module (gnu packages guile)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages texinfo)
@@ -66,3 +67,87 @@ (define-public guile-scheme-json-rpc
This package delivers Guile's bytecode for @code{scheme-json-rpc}.")
(home-page "https://codeberg.org/rgherdt/scheme-json-rpc")
(license license:expat)))
+
+(define (scheme-lsp-server-origin name version hash)
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://codeberg.org/rgherdt/scheme-lsp-server.git")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ hash))))
+
+(define-public guile-scheme-lsp-server
+ (package
+ (name "guile-scheme-lsp-server")
+ (version "0.2.2")
+ (source
+ (scheme-lsp-server-origin
+ name
+ version
+ "0lb359gw00w149h5yq2brfrcpybdwdj6ndbl7k1ms88l653r5l2g"))
+ (build-system gnu-build-system)
+ (arguments
+ (list #:modules `((ice-9 match)
+ (ice-9 ftw)
+ ,@%gnu-build-system-modules)
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-after 'unpack 'move-to-guile-directory
+ (lambda _
+ (chdir "./guile")))
+ (add-after 'install 'wrap-entrypoint
+ (lambda _
+ (let* ((bin (string-append #$output "/bin"))
+ (site (string-append #$output
+ "/share/guile/site"))
+ (deps (list #$guile-scheme-json-rpc)))
+ (match (scandir site)
+ (("." ".." version)
+ (let ((modules (string-append site "/"
+ version))
+ (compiled-modules (string-append #$output
+ "/lib/guile/"
+ version
+ "/site-ccache")))
+ (wrap-program (string-append bin
+ "/guile-lsp-server")
+ `("GUILE_LOAD_PATH" ":"
+ prefix
+ (,modules
+ ,@(map (lambda (dep)
+ (string-append
+ dep
+ "/share/guile/site/"
+ version))
+ deps)))
+ `("GUILE_LOAD_COMPILED_PATH"
+ ":" prefix
+ (,compiled-modules
+ ,@(map (lambda (dep)
+ (string-append
+ dep
+ "/lib/guile/"
+ version
+ "/site-ccache"))
+ deps))))
+ #t)))))))))
+ (native-inputs (list pkg-config))
+ (inputs
+ ;; Depend on the latest Guile to avoid bytecode compatibility issues when
+ ;; using modules built against the latest version.
+ (list bash-minimal
+ guile-3.0-latest))
+ (propagated-inputs (list guile-scheme-json-rpc))
+ (synopsis "LSP (Language Server Protocol) server for Scheme")
+ (description
+ "@code{guile-lsp-server} is an implementation for Guile of the LSP
+specification. This software aims to support several Scheme implementations.
+To achieve this, the code is designed to contain as much logic as possible in
+R7RS Scheme, separating implementation-specific code in different modules.
+
+This package delivers Guile's implementation for @code{scheme-lsp-server}.")
+ (home-page "https://codeberg.org/rgherdt/scheme-lsp-server")
+ (license license:expat)))
--
2.38.1
G
G
goodoldpaul wrote on 12 Apr 22:43 +0200
Re: [PATCHES] Add guile's implementation for scheme-lsp-server
(address . 60286@debbugs.gnu.org)
44013bc23722fa720268916df79b962c@autistici.org
Dear Guixers,

this is a friendly ping :) I'm sending an updated patchset.

Thank you for your time and efforts,

Giacomo
G
G
Giacomo Leidi wrote on 12 Apr 22:44 +0200
[v3 2/2] gnu: Add guile-scheme-lsp-server.
(address . 60286@debbugs.gnu.org)(name . Giacomo Leidi)(address . goodoldpaul@autistici.org)
20230412204402.14774-2-goodoldpaul@autistici.org
* gnu/packages/scheme-xyz.scm (guile-scheme-lsp-server): New variable.
---
gnu/packages/scheme-xyz.scm | 85 +++++++++++++++++++++++++++++++++++++
1 file changed, 85 insertions(+)

Toggle diff (102 lines)
diff --git a/gnu/packages/scheme-xyz.scm b/gnu/packages/scheme-xyz.scm
index 91ba1e7f5b..3947bf4f92 100644
--- a/gnu/packages/scheme-xyz.scm
+++ b/gnu/packages/scheme-xyz.scm
@@ -18,6 +18,7 @@
(define-module (gnu packages scheme-xyz)
#:use-module (gnu packages autotools)
+ #:use-module (gnu packages bash)
#:use-module (gnu packages guile)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages texinfo)
@@ -66,3 +67,87 @@ (define-public guile-scheme-json-rpc
This package delivers Guile's bytecode for @code{scheme-json-rpc}.")
(home-page "https://codeberg.org/rgherdt/scheme-json-rpc")
(license license:expat)))
+
+(define (scheme-lsp-server-origin name version hash)
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://codeberg.org/rgherdt/scheme-lsp-server.git")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ hash))))
+
+(define-public guile-scheme-lsp-server
+ (package
+ (name "guile-scheme-lsp-server")
+ (version "0.2.2")
+ (source
+ (scheme-lsp-server-origin
+ name
+ version
+ "0lb359gw00w149h5yq2brfrcpybdwdj6ndbl7k1ms88l653r5l2g"))
+ (build-system gnu-build-system)
+ (arguments
+ (list #:modules `((ice-9 match)
+ (ice-9 ftw)
+ ,@%gnu-build-system-modules)
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-after 'unpack 'move-to-guile-directory
+ (lambda _
+ (chdir "./guile")))
+ (add-after 'install 'wrap-entrypoint
+ (lambda _
+ (let* ((bin (string-append #$output "/bin"))
+ (site (string-append #$output
+ "/share/guile/site"))
+ (deps (list #$guile-scheme-json-rpc)))
+ (match (scandir site)
+ (("." ".." version)
+ (let ((modules (string-append site "/"
+ version))
+ (compiled-modules (string-append #$output
+ "/lib/guile/"
+ version
+ "/site-ccache")))
+ (wrap-program (string-append bin
+ "/guile-lsp-server")
+ `("GUILE_LOAD_PATH" ":"
+ prefix
+ (,modules
+ ,@(map (lambda (dep)
+ (string-append
+ dep
+ "/share/guile/site/"
+ version))
+ deps)))
+ `("GUILE_LOAD_COMPILED_PATH"
+ ":" prefix
+ (,compiled-modules
+ ,@(map (lambda (dep)
+ (string-append
+ dep
+ "/lib/guile/"
+ version
+ "/site-ccache"))
+ deps))))
+ #t)))))))))
+ (native-inputs (list pkg-config))
+ (inputs
+ ;; Depend on the latest Guile to avoid bytecode compatibility issues when
+ ;; using modules built against the latest version.
+ (list bash-minimal
+ guile-3.0-latest))
+ (propagated-inputs (list guile-scheme-json-rpc))
+ (synopsis "LSP (Language Server Protocol) server for Scheme")
+ (description
+ "@code{guile-lsp-server} is an implementation for Guile of the LSP
+specification. This software aims to support several Scheme implementations.
+To achieve this, the code is designed to contain as much logic as possible in
+R7RS Scheme, separating implementation-specific code in different modules.
+
+This package delivers Guile's implementation for @code{scheme-lsp-server}.")
+ (home-page "https://codeberg.org/rgherdt/scheme-lsp-server")
+ (license license:expat)))
--
2.39.2
G
G
Giacomo Leidi wrote on 12 Apr 22:44 +0200
[v3 1/2] gnu: Add guile-scheme-json-rpc.
(address . 60286@debbugs.gnu.org)(name . Giacomo Leidi)(address . goodoldpaul@autistici.org)
20230412204402.14774-1-goodoldpaul@autistici.org
* gnu/packages/scheme-xyz.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
---
gnu/local.mk | 1 +
gnu/packages/scheme-xyz.scm | 68 +++++++++++++++++++++++++++++++++++++
2 files changed, 69 insertions(+)
create mode 100644 gnu/packages/scheme-xyz.scm

Toggle diff (90 lines)
diff --git a/gnu/local.mk b/gnu/local.mk
index 8088e8170b..7f6cfc4158 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -556,6 +556,7 @@ GNU_SYSTEM_MODULES = \
%D%/packages/sawfish.scm \
%D%/packages/scanner.scm \
%D%/packages/scheme.scm \
+ %D%/packages/scheme-xyz.scm \
%D%/packages/spreadsheet.scm \
%D%/packages/screen.scm \
%D%/packages/scribus.scm \
diff --git a/gnu/packages/scheme-xyz.scm b/gnu/packages/scheme-xyz.scm
new file mode 100644
index 0000000000..91ba1e7f5b
--- /dev/null
+++ b/gnu/packages/scheme-xyz.scm
@@ -0,0 +1,68 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2022 Giacomo Leidi <goodoldpaul@autistici.org>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages scheme-xyz)
+ #:use-module (gnu packages autotools)
+ #:use-module (gnu packages guile)
+ #:use-module (gnu packages pkg-config)
+ #:use-module (gnu packages texinfo)
+ #:use-module (guix gexp)
+ #:use-module (guix git-download)
+ #:use-module ((guix licenses) #:prefix license:)
+ #:use-module (guix packages)
+ #:use-module (guix build-system gnu))
+
+(define (scheme-json-rpc-origin name version hash)
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://codeberg.org/rgherdt/scheme-json-rpc.git")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ hash))))
+
+(define-public guile-scheme-json-rpc
+ (package
+ (name "guile-scheme-json-rpc")
+ (version "0.2.11")
+ (source
+ (scheme-json-rpc-origin
+ name
+ version
+ "0w4m8xx8yyj0rv0q57mjr8ja87l7yikscj33i3ck26wg7230ppa5"))
+ (build-system gnu-build-system)
+ (arguments
+ (list #:phases #~(modify-phases %standard-phases
+ (add-after 'unpack 'move-to-guile-directory
+ (lambda _
+ (chdir "./guile"))))))
+ (native-inputs (list pkg-config))
+ (inputs (list guile-3.0-latest))
+ (synopsis "Implementation of the JSON-RPC for Scheme")
+ (description
+ "@code{scheme-json-rpc} allows calling procedures
+on remote servers by exchanging JSON objects. It implements the
+@url{jsonrpc specifications, https://www.jsonrpc.org/specification}.
+The low-level API strives to be R7RS compliant, relying on some SRFI's
+when needed. So far it was only tested under CHICKEN 5 and Guile 3.
+
+This package delivers Guile's bytecode for @code{scheme-json-rpc}.")
+ (home-page "https://codeberg.org/rgherdt/scheme-json-rpc")
+ (license license:expat)))

base-commit: dd3e5e71104a2bcbad80e52e062a144ea96b8c6a
--
2.39.2
?