Subject: [bug#60386] [PATCH] gnu: Add guile-proba.

From: Luis Felipe <[email-masked]>
Date: Mon, 06 Feb 2023 15:40:14 +0000

Hello again,

This is a new patch with guile-proba version 0.3.0, which solves the missing module import problem.

🤞

From 528f7d43933aa5e5a5528499b852ed274f33e406 Mon Sep 17 00:00:00 2001
From: Luis Felipe <[email-masked]>
Date: Wed, 28 Dec 2022 12:45:32 -0500
Subject: [PATCH] gnu: Add guile-proba.

* gnu/packages/check.scm (guile-proba): New variable.
---
 gnu/packages/check.scm | 63 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 63 insertions(+)

diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm
index aaa41777dc..c5b3b825e1 100644
--- a/gnu/packages/check.scm
+++ b/gnu/packages/check.scm
@@ -41,6 +41,7 @@
 ;;; Copyright © 2022 David Elsing <[email-masked]>
 ;;; Copyright © 2022 Sharlatan Hellseher <[email-masked]>
 ;;; Copyright © 2022 jgart <[email-masked]>
+;;; Copyright © 2023 Luis Felipe López Acevedo <[email-masked]>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -70,6 +71,8 @@ (define-module (gnu packages check)
   #:use-module (gnu packages gnome)
   #:use-module (gnu packages golang)
   #:use-module (gnu packages gtk)
+  #:use-module (gnu packages guile)
+  #:use-module (gnu packages guile-xyz)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
@@ -78,6 +81,7 @@ (define-module (gnu packages check)
   #:use-module (gnu packages python-web)
   #:use-module (gnu packages python-xyz)
   #:use-module (gnu packages python-science)
+  #:use-module (gnu packages texinfo)
   #:use-module (gnu packages time)
   #:use-module (gnu packages xml)
   #:use-module (guix utils)
@@ -90,6 +94,7 @@ (define-module (gnu packages check)
   #:use-module (guix build-system glib-or-gtk)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system go)
+  #:use-module (guix build-system guile)
   #:use-module (guix build-system meson)
   #:use-module (guix build-system pyproject)
   #:use-module (guix build-system python)
@@ -3455,3 +3460,61 @@ (define-public python-pytest-regressions
 tables by saving expected data in a data directory (courtesy of pytest-datadir)
 that can be used to verify that future runs produce the same data.")
     (license license:expat)))
+
+(define-public guile-proba
+  (package
+    (name "guile-proba")
+    (version "0.3.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://codeberg.org/luis-felipe/guile-proba")
+             (commit version)))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "1mjnrbb6gv5f95i1ihn75yh7ya445pcnj13cy34x2v58h9n2r80s"))))
+    (build-system guile-build-system)
+    (inputs (list bash-minimal))
+    (native-inputs (list guile-3.0 texinfo))
+    (propagated-inputs (list guile-config guile-lib))
+    (arguments
+     (list
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'build 'check
+            (lambda _
+              (invoke "guile" "proba.scm" "run" "tests")))
+          (add-after 'install 'install-wrapped-script
+            (lambda* (#:key outputs #:allow-other-keys)
+              (let* ((out (assoc-ref outputs "out"))
+                     (version (target-guile-effective-version))
+                     (scm (string-append "/share/guile/site/" version))
+                     (go (string-append "/lib/guile/" version "/site-ccache"))
+                     (bin-dir (string-append out "/bin"))
+                     (script (string-append bin-dir "/proba")))
+                (mkdir-p bin-dir)
+                (copy-file "proba.scm" script)
+                (chmod script #o555)
+                (wrap-program script
+                  `("GUILE_LOAD_PATH" prefix
+                    (,(string-append out scm)))
+                  `("GUILE_LOAD_COMPILED_PATH" prefix
+                    (,(string-append out go)))))))
+          (add-after 'install 'install-manual
+            (lambda* (#:key outputs #:allow-other-keys)
+              (let* ((out (assoc-ref outputs "out"))
+                     (info-dir (string-append out "/share/info")))
+                (mkdir-p info-dir)
+                (invoke "makeinfo" "manual/main.texi")
+                (install-file "guile-proba" info-dir)))))
+      #:not-compiled-file-regexp
+      "((bogus|bogus-tests|packages|tests)\\/.*.scm|(proba|manifest).scm)$"))
+    (home-page "https://luis-felipe.gitlab.io/guile-proba/")
+    (synopsis "Testing tools for GNU Guile projects with SRFI 64 test suites")
+    (description
+     "This software is a set of testing tools for GNU Guile projects
+with SRFI 64-based test suites.  It comes with a command-line interface
+to run test collections, and a library that includes a test runner and
+helpers for writing tests.")
+    (license license:public-domain)))

base-commit: fc5dc3e04789a15d80a7b35987adaefc1a94b97c
-- 
2.38.1