[PATCH 0/5] gnu: ocaml-eio: Update to 0.12.

  • Open
  • quality assurance status badge
Details
2 participants
  • Benjamin
  • jgart
Owner
unassigned
Submitted by
Benjamin
Severity
normal
B
B
Benjamin wrote on 14 Jul 13:44 +0200
(address . guix-patches@gnu.org)(name . Benjamin)(address . benjamin@uvy.fr)
cover.1720956786.git.benjamin@uvy.fr
Hello, this series of patches update eio to version 0.12.

It is not possible to update to the latest version 1.1 because it
depends on ocaml 5.1 [1]


Benjamin (5):
gnu: ocaml-mdx: Update to 2.4.1.
gnu: Add ocaml-thread-table.
gnu: Add ocaml-domain-schims.
gnu: Add ocaml-domain-local-await.
gnu: ocaml-eio: Update to 0.12.

gnu/packages/ocaml.scm | 150 +++++++++++++++++++++++++++++------------
1 file changed, 106 insertions(+), 44 deletions(-)


base-commit: fb11149feaa177a95e1f0d640e4f03881257e83e
--
2.45.2
B
B
Benjamin wrote on 14 Jul 13:49 +0200
[PATCH 3/5] gnu: Add ocaml-domain-schims.
(address . 72107@debbugs.gnu.org)(name . Benjamin)(address . benjamin@uvy.fr)
aa4668c8003a4954a9b62a997a6d232d9524beca.1720956786.git.benjamin@uvy.fr
* gnu/packages/ocaml.scm (ocaml-domain-schims): New variable.

Change-Id: Ifbf8ade84658862a187f165a1bf7abe17ee1ecb7
---
gnu/packages/ocaml.scm | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)

Toggle diff (37 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index a6fb5af138..fdeec8f2a1 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3156,6 +3156,30 @@ (define-public ocaml-thread-table
for associating thread specific state with threads within a domain.")
(license license:isc)))
+(define-public ocaml-domain-schims
+ (package
+ (name "ocaml-domain-schims")
+ (version "0.1.0")
+ (home-page "https://gitlab.com/gasche/domain-shims")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256 (base32
+ "0mxvzhxgcrvv0l99i4blag52v7g1knycwsh1xv9vkmh0rpwb147z"))))
+ (build-system dune-build-system)
+ (arguments `(#:package "domain_shims"))
+ (native-inputs (list))
+ (synopsis "A self-contained implementation of the Domain module for OCaml 4.")
+ (description "Domain is a new module of the OCaml 5 standard library that exposes
+the Multicore OCaml runtime's ability to run OCaml computations in parallel.
+With domain-shims, you can compile run code that was written for
+OCaml 5 using the Domain module under OCaml 4")
+ (license license:expat)))
+
(define ocaml-eio
(package
(name "ocaml-eio")
--
2.45.2
B
B
Benjamin wrote on 14 Jul 13:49 +0200
[PATCH 1/5] gnu: ocaml-mdx: Update to 2.4.1.
(address . 72107@debbugs.gnu.org)(name . Benjamin)(address . benjamin@uvy.fr)
4b223400cd4730c925ade5f6796757230176c0cc.1720956786.git.benjamin@uvy.fr
* gnu/packages/ocaml.scm (ocaml-mdx): Update to 2.4.1.
[propagated-inputs]: Remove ocaml-odoc and ocaml-odoc-parser; add ocaml-camlp-streams,
ocaml-csexp, and ocaml-cppo.
[native-inputs]: Remove ocaml-cppo; add ocaml-odoc.

Change-Id: I319fc32d958efe0ca5db6d6c4fef9dbf0de97fd1
---
gnu/packages/ocaml.scm | 23 ++++++++++++-----------
1 file changed, 12 insertions(+), 11 deletions(-)

Toggle diff (52 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 1204c78883..fa84ea73a5 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8445,7 +8445,7 @@ (define-public ocaml-version
(define-public ocaml-mdx
(package
(name "ocaml-mdx")
- (version "2.1.0")
+ (version "2.4.1")
(source (origin
(method git-fetch)
(uri (git-reference
@@ -8454,7 +8454,7 @@ (define-public ocaml-mdx
(file-name (git-file-name name version))
(sha256
(base32
- "1w1givvhwv9jzj9zbg4mmlpb35sqi75w83r99p2z50bdr69fdf57"))))
+ "14v4iv0xypvl60y9vsg5rs8xbwxagmz0zr8sxrzchd6xij0nlplv"))))
(build-system dune-build-system)
(arguments
`(#:phases
@@ -8473,17 +8473,18 @@ (define-public ocaml-mdx
(substitute* "test/bin/mdx-test/expect/padding/test-case.md"
(("egrep") "grep -E")))))))
(propagated-inputs
- (list ocaml-fmt
- ocaml-astring
- ocaml-logs
- ocaml-cmdliner
+ (list ocaml-result
+ ocaml-camlp-streams
+ ocaml-version
ocaml-re
- ocaml-result
- ocaml-odoc
- ocaml-odoc-parser
- ocaml-version))
+ ocaml-cmdliner
+ ocaml-logs
+ ocaml-astring
+ ocaml-csexp
+ ocaml-cppo
+ ocaml-fmt))
(native-inputs
- (list ocaml-cppo ocaml-lwt ocaml-alcotest))
+ (list ocaml-odoc ocaml-alcotest ocaml-lwt))
(home-page
"https://github.com/realworldocaml/mdx")
(synopsis
--
2.45.2
B
B
Benjamin wrote on 14 Jul 13:49 +0200
[PATCH 4/5] gnu: Add ocaml-domain-local-await.
(address . 72107@debbugs.gnu.org)(name . Benjamin)(address . benjamin@uvy.fr)
a7b7a151b30bef7438e7e8c5671e5f99da910780.1720956786.git.benjamin@uvy.fr
* gnu/packages/ocaml.scm (ocaml-domain-local-await): New variable.

Change-Id: I8ae010390f4aacfaa4c82f4ec18cbf5480595120
---
gnu/packages/ocaml.scm | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)

Toggle diff (37 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index fdeec8f2a1..0660c3d3d4 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3180,6 +3180,30 @@ (define-public ocaml-domain-schims
OCaml 5 using the Domain module under OCaml 4")
(license license:expat)))
+(define-public ocaml-domain-local-await
+ (package
+ (name "ocaml-domain-local-await")
+ (version "1.0.1")
+ (home-page "https://github.com/ocaml-multicore/domain-local-await")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256 (base32
+ "0h60sxzd9p14ilpg004d47y3zd89pswffr0wvqa9cykpn8qgdfcm"))))
+ (build-system dune-build-system)
+ (arguments `(#:package "domain-local-await"))
+ (propagated-inputs (list ocaml-thread-table))
+ (native-inputs (list ocaml-odoc ocaml-domain-schims ocaml-version ocaml-mdx ocaml-alcotest))
+ (synopsis "A scheduler independent blocking mechanism")
+ (description "Ocaml library implementing a scheduler independent blocking
+mechanism. It provides a low level mechanism intended for writing higher level
+libraries that need to block in a scheduler friendly manner.")
+ (license license:isc)))
+
(define ocaml-eio
(package
(name "ocaml-eio")
--
2.45.2
B
B
Benjamin wrote on 14 Jul 13:49 +0200
[PATCH 2/5] gnu: Add ocaml-thread-table.
(address . 72107@debbugs.gnu.org)(name . Benjamin)(address . benjamin@uvy.fr)
62b3c0488e059e026271c2ef4c88fa8aa3e5d00f.1720956786.git.benjamin@uvy.fr
* gnu/packages/ocaml.scm (ocaml-thread-table): New variable.

Change-Id: If0175f44e6959befc539a399bd8bdebdcb41ba1b
---
gnu/packages/ocaml.scm | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)

Toggle diff (36 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index fa84ea73a5..a6fb5af138 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3133,6 +3133,29 @@ (define-public ocaml-hmap
to which allows adding and looking up bindings in a type safe manner.")
(license license:isc)))
+(define-public ocaml-thread-table
+ (package
+ (name "ocaml-thread-table")
+ (version "1.0.0")
+ (home-page "https://github.com/ocaml-multicore/thread-table")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256 (base32
+ "05sla96m4lbfrnrjczj4xl1zbcwypir6krp4y16x50hz24ai12pc"))))
+ (build-system dune-build-system)
+ (arguments `(#:package "thread-table"))
+ (native-inputs (list ocaml-odoc ocaml-alcotest))
+ (synopsis "A lock-free thread-safe integer keyed hash table")
+ (description "Ocaml library implementing a minimalist lock-free thread-safe
+integer keyed hash table with zero synchronization overhead on lookups designed
+for associating thread specific state with threads within a domain.")
+ (license license:isc)))
+
(define ocaml-eio
(package
(name "ocaml-eio")
--
2.45.2
B
B
Benjamin wrote on 14 Jul 13:49 +0200
[PATCH 5/5] gnu: ocaml-eio: Update to 0.12.
(address . 72107@debbugs.gnu.org)(name . Benjamin)(address . benjamin@uvy.fr)
02f027b2684ce91e2e980e5083609e44d4f366de.1720956786.git.benjamin@uvy.fr
* gnu/packages/ocaml.scm (ocaml-eio): Update to 0.12.
[propagated-inputs]: Remove ocaml-lwt, ocaml-logs, and ocaml-odoc; add
ocaml-domain-local-await.
[native-inputs]: Remove ocaml-astring and ocaml-alcotest; add ocaml-odoc.
* gnu/packages/ocaml.scm (ocaml-eio-luv): Remove ocaml-eio-luv.
* gnu/packages/ocaml.scm (ocaml-eio-main): Update to 0.12.

Change-Id: I0445cb1d181deacda827516c9b42104aa77bcad0
---
gnu/packages/ocaml.scm | 56 +++++++++++++++++-------------------------
1 file changed, 23 insertions(+), 33 deletions(-)

Toggle diff (111 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 0660c3d3d4..01f5d57faf 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3207,7 +3207,7 @@ (define-public ocaml-domain-local-await
(define ocaml-eio
(package
(name "ocaml-eio")
- (version "0.8.1")
+ (version "0.12")
(home-page "https://github.com/ocaml-multicore/eio")
(source
(origin
@@ -3217,24 +3217,21 @@ (define ocaml-eio
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256 (base32
- "02q9i5wbb2497vd4ypc9d9p4zi3lmx0rsv8faiy7h8dnnzbjjf4z"))))
+ "1havn2h3c0748mj8ic7jn32kswb7sigavnbvxdqf37qn7cx91ilr"))))
(build-system dune-build-system)
(arguments `(#:package "eio"))
(propagated-inputs (list ocaml-bigstringaf
ocaml-cstruct
- ocaml-lwt
+ ocaml-domain-local-await
ocaml-lwt-dllist
- ocaml-logs
ocaml-optint
ocaml-psq
ocaml-fmt
ocaml-hmap
- ocaml-mtime
- ocaml-odoc))
- (native-inputs (list ocaml-astring
- ocaml-crowbar
- ocaml-alcotest
- ocaml-mdx))
+ ocaml-mtime))
+ (native-inputs (list ocaml-odoc
+ ocaml-mdx
+ ocaml-crowbar))
(synopsis "Effect-based direct-style IO API for OCaml")
(description "This package provides an effect-based IO API for multicore
OCaml with fibers.")
@@ -3243,20 +3240,6 @@ (define ocaml-eio
(define-public ocaml5.0-eio
(package-with-ocaml5.0 ocaml-eio))
-(define ocaml-eio-luv
- (package
- (inherit ocaml-eio)
- (name "ocaml-eio-luv")
- (arguments `(#:package "eio_luv"))
- (propagated-inputs (list ocaml-eio ocaml-luv))
- (native-inputs (list ocaml-mdx))
- (synopsis "Libuv-based backend for Ocaml Eio")
- (description "@code{Eio_luv} provides a cross-platform backend for
-@code{Ocaml Eio}'s APIs using luv (libuv)")))
-
-(define-public ocaml5.0-eio-luv
- (package-with-ocaml5.0 ocaml-eio-luv))
-
(define-public ocaml-unionfind
(package
(name "ocaml-unionfind")
@@ -3320,16 +3303,24 @@ (define ocaml-eio-linux
(package
(inherit ocaml-eio)
(name "ocaml-eio-linux")
- (arguments `(#:package "eio_linux"))
+ (arguments `(
+ #:package "eio_linux"
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'build 'fix-test-path
+ (lambda* (#:key outputs #:allow-other-keys)
+ (substitute* "lib_eio_linux/tests/spawn.md"
+ (("/usr/bin/env") (which "env"))))))))
(propagated-inputs
- (list ocaml-eio
- ocaml-uring
+ (list ocaml-uring
+ ocaml-fmt
ocaml-logs
- ocaml-fmt))
+ ocaml-eio))
(native-inputs
- (list ocaml-mdx
- ocaml-alcotest
- ocaml-mdx))
+ (list ocaml-odoc
+ ocaml-cmdliner
+ ocaml-mdx
+ ocaml-alcotest))
(synopsis "Linux backend for ocaml-eio")
(description "@code{Eio_linux} provides a Linux io-uring backend for
@code{Ocaml Eio} APIs, plus a low-level API that can be used directly
@@ -3347,10 +3338,9 @@ (define ocaml-eio-main
#:tests? #f))
(propagated-inputs
(list ocaml-eio
- ocaml-eio-luv
ocaml-eio-linux))
(native-inputs
- (list ocaml-mdx))
+ (list ocaml-odoc))
(synopsis "Eio backend selector")
(description "@code{Eio_main} selects an appropriate backend (e.g.
@samp{eio_linux} or @samp{eio_luv}), depending on your platform.")))
--
2.45.2
J
Re: [PATCH 0/5] gnu: ocaml-eio: Update to 0.12.
(address . 72107@debbugs.gnu.org)(name . Benjamin)(address . benjamin@uvy.fr)
87frrvzox3.fsf@dismail.de
Hi,

Thanks for your contribution.

See the issues detected by qa here:


Could you send v2?
--
all the best,
jgart
?
Your comment

Commenting via the web interface is currently disabled.

To comment on this conversation send an email to 72107@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 72107
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch