commit 365dee901658d1a58e8d734267af6b749b29720e parent fbd39b2ec9c7c410e2f7e263f4832687bb697743 Author: Yuval Langer <yuval.langer@gmail.com> Date: Thu, 5 Sep 2024 16:20:38 +0300 Use srfi/impl.scm to create srfi/srfi-253.scm and add a Guile module definition at the top of the file. Diffstat:
M | kakafarm/packages/guile-xyz.scm | | | 33 | +++++++++++++++++++++++++++------ |
1 file changed, 27 insertions(+), 6 deletions(-)
diff --git a/kakafarm/packages/guile-xyz.scm b/kakafarm/packages/guile-xyz.scm @@ -352,7 +352,7 @@ arguments.") (define-public guile-srfi-253 (let ((version "0.0.1") - (revision "1") + (revision "3") (commit "f72830bb9b8fd20b05145a7a0b78765ff9a571b0") (git-repository-url "https://github.com/scheme-requests-for-implementation/srfi-253")) @@ -375,13 +375,34 @@ arguments.") #:phases #~(modify-phases %standard-phases (add-after 'unpack 'move-create-and-delete-files (lambda _ - (substitute* "srfi/253.sld" - (("srfi 253") - "srfi srfi-253")) - (rename-file "srfi/253.sld" "srfi/srfi-253.scm") + (use-modules (ice-9 textual-ports)) + (let* ((impl (call-with-input-file "srfi/impl.scm" get-string-all))) + (with-output-to-file "srfi/srfi-253.scm" + (lambda () + (display "(define-module (srfi srfi-253) + #:export ( + case-lambda-checked + check-arg + define-checked + define-optionals-checked + lambda-checked + opt-lambda-checked + values-checked + )) +") + (display impl) + ))) + + (for-each (lambda (filename) (delete-file filename)) - '("existing-practice.scm" "test.scm"))))))) + '( + "existing-practice.scm" + "srfi/253.sld" + "srfi/253.sls" + "srfi/impl.scm" + "test.scm" + ))))))) (native-inputs (list gnu:packages:guile:guile-3.0)) (home-page git-repository-url) (synopsis "Data (Type-)Checking.")