guix-patches
[Top][All Lists]
Advanced

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

[bug#53882] [PATCH v2 04/25] gnu: Add ocaml-spawn.


From: zimoun
Subject: [bug#53882] [PATCH v2 04/25] gnu: Add ocaml-spawn.
Date: Fri, 8 Apr 2022 15:22:44 +0200

From: Julien Lepiller <julien@lepiller.eu>

* gnu/packages/ocaml.scm (ocaml-spawn): New variable.
(ocaml4.07-spawn): Inherit from it.
---
 gnu/packages/ocaml.scm | 55 ++++++++++++++++++++++++++++--------------
 1 file changed, 37 insertions(+), 18 deletions(-)

diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index cb461bf257..6690fab76d 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -6446,10 +6446,10 @@ (define-public ocaml4.07-configurator
 @end itemize")
     (license license:asl2.0)))
 
-(define-public ocaml4.07-spawn
+(define-public ocaml-spawn
   (package
-    (name "ocaml4.07-spawn")
-    (version "0.13.0")
+    (name "ocaml-spawn")
+    (version "0.15.0")
     (source (origin
               (method git-fetch)
               (uri (git-reference
@@ -6458,22 +6458,12 @@ (define-public ocaml4.07-spawn
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "1w003k1kw1lmyiqlk58gkxx8rac7dchiqlz6ah7aj7bh49b36ppf"))))
+                "1fjr91psas5zmk1hxvxh0dchhn0pkyzlr4gg232f5g9vdgissi0p"))))
     (build-system dune-build-system)
-    (arguments
-     `(#:phases
-       (modify-phases %standard-phases
-         (add-before 'check 'fix-tests
-           (lambda _
-             (substitute* "test/tests.ml"
-               (("/bin/pwd") (which "pwd"))
-               (("/bin/echo") (which "echo")))
-             #t)))
-       #:ocaml ,ocaml-4.07
-       #:findlib ,ocaml4.07-findlib
-       #:dune ,ocaml4.07-dune))
-    (native-inputs
-     `(("ocaml-ppx-expect" ,(package-with-ocaml4.07 ocaml-ppx-expect))))
+    (propagated-inputs (list ocaml-odoc))
+    (native-inputs (list ocaml-ppx-expect))
+    (properties
+     `((ocaml4.07-variant . ,(delay ocaml4.07-spawn))))
     (home-page "https://github.com/janestreet/spawn";)
     (synopsis "Spawning sub-processes")
     (description
@@ -6495,6 +6485,35 @@ (define-public ocaml4.07-spawn
 @end itemize")
     (license license:asl2.0)))
 
+(define-public ocaml4.07-spawn
+  (package-with-ocaml4.07
+    (package
+      (inherit ocaml-spawn)
+      (version "0.13.0")
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                       (url "https://github.com/janestreet/spawn";)
+                       (commit (string-append "v" version))))
+                (file-name (git-file-name "ocaml4.07-spawn" version))
+                (sha256
+                 (base32
+                  "1w003k1kw1lmyiqlk58gkxx8rac7dchiqlz6ah7aj7bh49b36ppf"))))
+      (arguments
+       `(#:phases
+         (modify-phases %standard-phases
+           (add-before 'check 'fix-tests
+             (lambda _
+               (substitute* "test/tests.ml"
+                 (("/bin/pwd") (which "pwd"))
+                 (("/bin/echo") (which "echo")))
+               #t)))
+         #:ocaml ,ocaml-4.07
+         #:findlib ,ocaml4.07-findlib
+         #:dune ,ocaml4.07-dune))
+      (propagated-inputs '())
+      (properties '()))))
+
 (define-public ocaml4.07-core
   (package
     (name "ocaml4.07-core")
-- 
2.34.0






reply via email to

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