[PATCH 01/39] gnu: Add ocaml-domain-name.

  • Done
  • quality assurance status badge
Details
3 participants
  • Julien Lepiller
  • Christopher Baines
  • Csepp
Owner
unassigned
Submitted by
Csepp
Severity
normal
Merged with
C
C
Csepp wrote on 9 Jan 2023 01:34
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-1-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

gnu/packages/ocaml.scm (ocaml-domain-name): New variable.
---
gnu/packages/ocaml.scm | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)

Toggle diff (43 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index c3a586f091..41485b3686 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -27,6 +27,7 @@
;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com>
;;; Copyright © 2022 Garek Dyszel <garekdyszel@disroot.org>
+;;; Copyright © 2023 Csepp <raingloom@riseup.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -3537,6 +3538,28 @@ (define-public ocaml-ocp-index
(license (list license:gpl3+
license:lgpl2.1+))))
+(define-public ocaml-domain-name
+ (package
+ (name "ocaml-domain-name")
+ (version "0.4.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/hannesm/domain-name/")
+ (commit (string-append "v" version))))
+ (file-name name)
+ (sha256
+ (base32
+ "1a669zz1pc7sqbi1c13jsnp8algcph2b8gr5fjrjhyh3p232770k"))))
+ (build-system dune-build-system)
+ (native-inputs (list ocaml-alcotest))
+ (home-page "https://github.com/hannesm/domain-name")
+ (synopsis "RFC 1035 Internet domain name data structure and parser")
+ (description
+ "Parses and constructs RFC compliant domain names. The invariants on the
+length of domain names are preserved throughout the module.")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 14/39] gnu: Add aliases for ocaml-cstruct and ocaml-lwt subpackages.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-14-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-lwt-ppx ocaml-cstruct-unix
ocaml-cstruct-sexp): New variables.
---
We've discussed aliases vs variants with Julien Lepiller and yeah, these are not ideal, but also it's unclear how variants could be used when the original packages already explicitly specify which subpackage they are building.
But, perfect is the enemy of the good. So I'm gonna leave these aliases in for now because I have a lot more MirageOS stuff to work on for my thesis project at uni.

gnu/packages/ocaml.scm | 11 +++++++++++
1 file changed, 11 insertions(+)

Toggle diff (31 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 53252aac03..ee4c1cf91a 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -2971,6 +2971,11 @@ (define-public ocaml-lwt
locks or other synchronization primitives.")
(license license:lgpl2.1)))
+;; TODO this alias is not ideal but ocaml-lwt already explicitly specifies a
+;; package argument and at least this way the importer doesn't try to
+;; re-import it.
+(define ocaml-lwt-ppx ocaml-lwt)
+
(define-public ocaml-lwt-dllist
(package
(name "ocaml-lwt-dllist")
@@ -4458,6 +4463,12 @@ (define-public ocaml4.07-cstruct
"0jj3whs8r3jc524i9bb67rffh7y7r157hjgvws0bkxijxpjzwkbk"))))
(properties '()))))
+;; TODO again, the "parent" package already has an explicit package argument,
+;; so a variant package doesn't make sense, at least these aliases help the
+;; importer out so it doesn't re-import things. At least hopefully.
+(define ocaml-cstruct-unix ocaml-cstruct)
+(define ocaml-cstruct-sexp ocaml-cstruct)
+
(define-public ocaml-hex
(package
(name "ocaml-hex")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 15/39] gnu: Add ocaml-ppx-cstruct.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-15-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-ppx-cstruct): New variable.
---
gnu/packages/ocaml.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)

Toggle diff (35 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index ee4c1cf91a..72cb000fd9 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -4469,6 +4469,28 @@ (define-public ocaml4.07-cstruct
(define ocaml-cstruct-unix ocaml-cstruct)
(define ocaml-cstruct-sexp ocaml-cstruct)
+(define-public ocaml-ppx-cstruct
+ (package
+ (inherit ocaml-cstruct)
+ (name "ocaml-ppx-cstruct")
+ (properties `((upstream-name . "ppx_cstruct")))
+ (arguments '(#:package "ppx_cstruct"
+ ;; TODO doesn't find test deps for some reason?
+ ;; I have no clue why.
+ #:tests? #f))
+ (propagated-inputs
+ (modify-inputs
+ (package-propagated-inputs ocaml-cstruct)
+ (append ocaml-cstruct
+ ocaml-ppxlib
+ ocaml-sexplib)))
+ (native-inputs
+ (modify-inputs
+ (package-propagated-inputs ocaml-cstruct)
+ (append ocaml-cstruct-sexp
+ ocaml-findlib
+ ocaml-ppx-sexp-conv)))))
+
(define-public ocaml-hex
(package
(name "ocaml-hex")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 16/39] gnu: Add ocaml-mirage-profile-unix.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-16-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-profile-unix): New variable.
---
gnu/packages/ocaml.scm | 37 +++++++++++++++++++++++++++++++++++++
1 file changed, 37 insertions(+)

Toggle diff (50 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 72cb000fd9..62fb00dd37 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3853,6 +3853,43 @@ (define-public ocaml-mirage-unix
handles the main loop and timers.")
(license license:isc)))
+(define-public ocaml-mirage-profile-unix
+ (package
+ (name "ocaml-mirage-profile-unix")
+ (version "0.9.1")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://github.com/mirage/mirage-profile/releases/download/v0.9.1/mirage-profile-v0.9.1.tbz")
+ (sha256
+ (base32
+ "0lh3591ad4v7nxpd410b75idmgdq668mqdilvkg4avrwqw1wzdib"))))
+ (build-system dune-build-system)
+ (arguments
+ '(#:package "mirage-profile-unix"
+ #:tests? #f ;; depends on ocaml-mirage-profile which would form a loop
+ #:phases
+ (modify-phases %standard-phases
+ ;; TODO is there a way to do this with dune build flags?
+ (add-after 'unpack 'disable-xen
+ (lambda _
+ ;; this way it is not detected as a build target
+ (rename-file "xen" "_xen"))))))
+ (propagated-inputs (list ocaml-cstruct ocaml-ocplib-endian ocaml-lwt
+ ocaml-mtime ocaml-ppx-cstruct))
+ (native-inputs (list ocaml-ppx-cstruct))
+ (home-page "https://github.com/mirage/mirage-profile")
+ (synopsis "Collects Ocaml/Lwt profiling information in CTF format")
+ (description
+ "Used to trace execution of OCaml/Lwt programs (such as Mirage
+unikernels) at the level of Lwt threads. The traces can be viewed using
+JavaScript or GTK viewers provided by mirage-trace-viewer or processed by
+tools supporting the Common Trace Format.
+When compiled against a normal version of Lwt, OCaml's cross-module inlining
+will optimise these calls away, meaning there should be no overhead in the
+non-profiling case.")
+ (license license:bsd-2)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 17/39] gnu: Add ocaml-mirage-profile.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-17-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-profile): New variable.
---
gnu/packages/ocaml.scm | 14 ++++++++++++++
1 file changed, 14 insertions(+)

Toggle diff (27 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 62fb00dd37..33bc997dc5 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3890,6 +3890,20 @@ (define-public ocaml-mirage-profile-unix
non-profiling case.")
(license license:bsd-2)))
+(define-public ocaml-mirage-profile
+ (package
+ (inherit ocaml-mirage-profile-unix)
+ (name "ocaml-mirage-profile")
+ (arguments '(#:package "mirage-profile"
+ ;; TODO cyclic dependency with mirage-profile
+ ;; It could be broken using package variants, if not for
+ ;; propagated inputs leading to version conflicts.
+ #:tests? #f))
+ (propagated-inputs
+ (modify-inputs
+ (package-propagated-inputs ocaml-mirage-profile-unix)
+ (append ocaml-mirage-profile-unix)))))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 18/39] gnu: Add ocaml-mirage-clock.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-18-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-clock): New variable.
---
gnu/packages/ocaml.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)

Toggle diff (35 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 33bc997dc5..70129a5b6b 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3833,6 +3833,28 @@ (define-public ocaml-mirage-time
"Defines the signature for time-related operations for MirageOS.")
(license license:isc)))
+(define-public ocaml-mirage-clock
+ (package
+ (name "ocaml-mirage-clock")
+ (version "4.2.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://github.com/mirage/mirage-clock/releases/download/v4.2.0/mirage-clock-4.2.0.tbz")
+ (sha256
+ (base32
+ "0iwqi2381fbi3jlcw424dbhjs4fpisw7qpqzfjx7jg72bdfx25zs"))))
+ (build-system dune-build-system)
+ (home-page "https://github.com/mirage/mirage-clock")
+ (synopsis "Libraries and module types for portable clocks")
+ (description
+ "This library implements portable support for an operating system
+timesource that is compatible with the MirageOS library interfaces. It
+implements an @code{MCLOCK} module that represents a monotonic timesource
+since an arbitrary point, and @code{PCLOCK} which counts time since the Unix
+epoch.")
+ (license license:isc)))
+
(define-public ocaml-mirage-unix
(package
(name "ocaml-mirage-unix")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 19/39] gnu: Add ocaml-ptime.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-19-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-ptime): New variable.
---
gnu/packages/ocaml.scm | 32 ++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)

Toggle diff (45 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 70129a5b6b..52692b40bf 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3855,6 +3855,38 @@ (define-public ocaml-mirage-clock
epoch.")
(license license:isc)))
+(define-public ocaml-ptime
+ (package
+ (name "ocaml-ptime")
+ ;; TODO 1.1.0 has some issues, so for now we are stuck with 0.8.5
+ (version "0.8.5")
+ (source
+ (origin
+ (method url-fetch)
+ (uri "https://erratique.ch/software/ptime/releases/ptime-0.8.5.tbz")
+ (sha256
+ (base32
+ "1fxq57xy1ajzfdnvv5zfm7ap2nf49znw5f9gbi4kb9vds942ij27"))))
+ (build-system ocaml-build-system)
+ (arguments
+ `(#:build-flags (list "build" "--with-js_of_ocaml" "true" "--tests" "true")
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'configure))))
+ (propagated-inputs
+ (list ocaml-result js-of-ocaml))
+ (native-inputs
+ (list ocaml-findlib ocamlbuild ocaml-topkg opam))
+ (home-page "https://erratique.ch/software/ptime")
+ (synopsis "POSIX time for OCaml")
+ (description
+ "Ptime offers platform independent POSIX time support in pure OCaml. It
+provides a type to represent a well-defined range of POSIX timestamps with
+picosecond precision, conversion with date-time values, conversion with RFC
+3339 timestamps and pretty printing to a human-readable, locale-independent
+representation.")
+ (license license:isc)))
+
(define-public ocaml-mirage-unix
(package
(name "ocaml-mirage-unix")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 20/39] gnu: Add ocaml-mirage-logs.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-20-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-logs): New variable.
---
gnu/packages/ocaml.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)

Toggle diff (41 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 52692b40bf..f703b04760 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3958,6 +3958,34 @@ (define-public ocaml-mirage-profile
(package-propagated-inputs ocaml-mirage-profile-unix)
(append ocaml-mirage-profile-unix)))))
+
+(define-public ocaml-mirage-logs
+ (package
+ (name "ocaml-mirage-logs")
+ (version "1.2.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://github.com/mirage/mirage-logs/releases/download/v1.2.0/mirage-logs-v1.2.0.tbz")
+ (sha256
+ (base32
+ "0h0amzjxy067jljscib7fvw5q8k0adqa8m86affha9hq5jsh07a1"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-logs ocaml-ptime ocaml-mirage-clock
+ ocaml-mirage-profile
+ ocaml-lwt))
+ (native-inputs (list ocaml-alcotest))
+ (home-page "https://github.com/mirage/mirage-logs")
+ (synopsis
+ "Reporter for the Logs library that writes to stderr with timestamps")
+ (description
+ "Uses a Mirage @code{CLOCK} to write timestamped log messages. It can
+also log only important messages to the console, while writing all received
+messages to a ring buffer which is displayed if an exception occurs. If
+tracing is enabled (via mirage-profile), it also writes each log message to
+the trace buffer.")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 21/39] gnu: Add ocaml-sexp-pretty.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-21-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-sexp-pretty): New variable.
---
gnu/packages/ocaml.scm | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)

Toggle diff (34 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index f703b04760..16d54f3230 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -6163,6 +6163,27 @@ (define-public ocaml4.07-sexplib
"0ksx62zsxhz8xmdrsn41n2hbc2qbyh3bxxc6946xisvgwh42h3q3"))
(properties '()))))
+(define-public ocaml-sexp-pretty
+ (package
+ (name "ocaml-sexp-pretty")
+ (version "0.15.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://ocaml.janestreet.com/ocaml-core/v0.15/files/sexp_pretty-v0.15.0.tar.gz")
+ (sha256
+ (base32
+ "1wax07zgvjcmrdnc2g89h6sbp5cirk65l5ibf00h57dzq8xn9s4r"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-base ocaml-ppx-base ocaml-sexplib ocaml-re))
+ (properties `((upstream-name . "sexp_pretty")))
+ (home-page "https://github.com/janestreet/sexp_pretty")
+ (synopsis "S-expression pretty-printer")
+ (description
+ "Library for pretty-printing s-expressions, using better indentation
+rules than the default pretty printer in Sexplib.")
+ (license license:expat)))
+
(define-public ocaml-base
(package
(name "ocaml-base")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 22/39] gnu: Add ocaml-expect-test-helpers-core.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-22-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-expect-test-helpers-core): New variable.
---
gnu/packages/ocaml.scm | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)

Toggle diff (39 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 16d54f3230..fb3332a5dd 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -2638,6 +2638,32 @@ (define-public ocaml4.07-alcotest
`(#:package "alcotest"))
(properties '()))))
+(define-public ocaml-expect-test-helpers-core
+ (package
+ (name "ocaml-expect-test-helpers-core")
+ (version "0.15.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://ocaml.janestreet.com/ocaml-core/v0.15/files/expect_test_helpers_core-v0.15.0.tar.gz")
+ (sha256
+ (base32
+ "0llnzx90qp1yydx4rg3fgd29wqfi92jrsvw1pp434gi5cj2p6akz"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-base
+ ocaml-base-quickcheck
+ ocaml-core
+ ocaml-ppx-jane
+ ocaml-sexp-pretty
+ ocaml-stdio
+ ocaml-re))
+ (properties `((upstream-name . "expect_test_helpers_core")))
+ (home-page "https://github.com/janestreet/expect_test_helpers_core")
+ (synopsis "Helpers for writing expectation tests")
+ (description
+ "Helper functions for writing expect tests.")
+ (license license:expat)))
+
(define-public ocaml-ppx-tools
(package
(name "ocaml-ppx-tools")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 23/39] gnu: Add ocaml-intrinsics.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-23-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-intrinsics): New variable.
---
gnu/packages/ocaml.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)

Toggle diff (41 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index fb3332a5dd..b82c3b4cd0 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -9209,6 +9209,34 @@ (define-public ocaml-bigstringaf
these missing pieces.")
(license license:bsd-3)))
+(define-public ocaml-intrinsics
+ (package
+ (name "ocaml-intrinsics")
+ (version "0.15.2")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/janestreet/ocaml_intrinsics")
+ (commit (string-append "v" version))))
+ (file-name name)
+ (sha256
+ (base32 "1mazr1ka2zlm2s8bw5i555cnhi1bmr9yxvpn29d3v4m8lsnfm73z"))))
+ (build-system dune-build-system)
+ ;; TODO figure out how to get around this error:
+ ;; No rule found for alias test/runtime-deps-of-tests
+ (arguments '(#:tests? #f))
+ (propagated-inputs (list dune-configurator))
+ (native-inputs (list ocaml-expect-test-helpers-core ocaml-core))
+ (properties `((upstream-name . "ocaml_intrinsics")))
+ (home-page "https://github.com/janestreet/ocaml_intrinsics")
+ (synopsis "AMD64 intrinsics with emulated fallbacks")
+ (description
+ "Provides an OCaml interface to operations that have dedicated hardware
+instructions on some micro-architectures, with default implementations using C
+stubs for all targets.")
+ (license license:expat)))
+
(define-public ocaml-trie
(package
(name "ocaml-trie")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 26/39] gnu: Add ocaml-async-unix.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-26-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-async-unix): New variable.
---
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 cbfaf40da7..fa56c687d0 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8387,6 +8387,30 @@ (define-public ocaml-async-kernel
JavaScript using @code{Async_js}.")
(license license:expat)))
+(define-public ocaml-async-unix
+ (package
+ (name "ocaml-async-unix")
+ (version "0.15.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://ocaml.janestreet.com/ocaml-core/v0.15/files/async_unix-v0.15.0.tar.gz")
+ (sha256
+ (base32
+ "1i9vrflp5df5d31q01643l412wrwizisb0qak1mfszqrqikrv4a9"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-async-kernel ocaml-core ocaml-core-kernel
+ ocaml-core-unix ocaml-ppx-jane))
+ (properties `((upstream-name . "async_unix")))
+ (home-page "https://github.com/janestreet/async_unix")
+ (synopsis "Monadic concurrency library")
+ (description
+ "Unix-related dependencies for things like system calls and
+threads. Using these, it hooks the Async_kernel scheduler up to either epoll
+or select, depending on availability, and manages a thread pool that blocking
+system calls run in.")
+ (license license:expat)))
+
(define-public ocaml-timezone
(package
(name "ocaml-timezone")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 29/39] gnu: Add ocaml-protocol-version-header.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-29-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-protocol-version-header): New variable.
---
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 9f05552c15..64d7c8065a 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -6846,6 +6846,29 @@ (define-public ocaml4.07-bin-prot
license:asl2.0
license:bsd-3)))))
+(define-public ocaml-protocol-version-header
+ (package
+ (name "ocaml-protocol-version-header")
+ (version "0.15.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://ocaml.janestreet.com/ocaml-core/v0.15/files/protocol_version_header-v0.15.0.tar.gz")
+ (sha256
+ (base32
+ "1izks6hxqd4gjxmwiv5ng52js8jbccl5hmyrvdqznjycp9ky9i6h"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-core ocaml-ppx-jane))
+ (properties `((upstream-name . "protocol_version_header")))
+ (home-page "https://github.com/janestreet/protocol_version_header")
+ (synopsis "Protocol versioning")
+ (description
+ "This library offers a lightweight way for applications protocols to
+version themselves. The more protocols that add themselves to
+@code{Known_protocol}, the nicer error messages we will get when connecting to
+a service while using the wrong protocol.")
+ (license license:expat)))
+
(define-public ocaml-octavius
(package
(name "ocaml-octavius")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 24/39] gnu: Add ocaml-core-unix.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-24-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-core-unix): New variable.
---
gnu/packages/ocaml.scm | 30 ++++++++++++++++++++++++++++++
1 file changed, 30 insertions(+)

Toggle diff (43 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index b82c3b4cd0..44ef688154 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8335,6 +8335,36 @@ (define-public ocaml4.07-core-kernel
;; MLton and sjs
license:expat)))))
+(define-public ocaml-core-unix
+ (package
+ (name "ocaml-core-unix")
+ (version "0.15.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://ocaml.janestreet.com/ocaml-core/v0.15/files/core_unix-v0.15.0.tar.gz")
+ (sha256
+ (base32
+ "0bd0bn959p6q3k1zh8bh7qdri8bhpph720bkij2q16h2sb0d5y8a"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-core
+ ocaml-core-kernel
+ ocaml-expect-test-helpers-core
+ ocaml-jane-street-headers
+ ocaml-jst-config
+ ocaml-intrinsics
+ ocaml-ppx-jane
+ ocaml-sexplib
+ ocaml-timezone
+ ocaml-spawn))
+ (properties `((upstream-name . "core_unix")))
+ (home-page "https://github.com/janestreet/core_unix")
+ (synopsis "Unix-specific portions of Core")
+ (description
+ "Unix-specific extensions to some of the modules defined in core and
+core_kernel.")
+ (license license:expat)))
+
(define-public ocaml-timezone
(package
(name "ocaml-timezone")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 25/39] gnu: Add ocaml-async-kernel.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-25-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-async-kernel): New variable.
---
gnu/packages/ocaml.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)

Toggle diff (35 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 44ef688154..cbfaf40da7 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8365,6 +8365,28 @@ (define-public ocaml-core-unix
core_kernel.")
(license license:expat)))
+(define-public ocaml-async-kernel
+ (package
+ (name "ocaml-async-kernel")
+ (version "0.15.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://ocaml.janestreet.com/ocaml-core/v0.15/files/async_kernel-v0.15.0.tar.gz")
+ (sha256
+ (base32
+ "15n65wqyzqnvk66dq1rgzdl68ixfp1ri02zib7p2gcdh9c0kwx9h"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-core ocaml-core-kernel ocaml-ppx-jane))
+ (properties `((upstream-name . "async_kernel")))
+ (home-page "https://github.com/janestreet/async_kernel")
+ (synopsis "Monadic concurrency library")
+ (description
+ "Contains @code{Async}'s core data structures, like
+@code{Deferred}. @code{Async_kernel} is portable, and so can be used in
+JavaScript using @code{Async_js}.")
+ (license license:expat)))
+
(define-public ocaml-timezone
(package
(name "ocaml-timezone")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 27/39] gnu: Add ocaml-textutils-kernel.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-27-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-textutils-kernel): New variable.
---
gnu/packages/ocaml.scm | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)

Toggle diff (34 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index fa56c687d0..73cae7fd52 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8411,6 +8411,27 @@ (define-public ocaml-async-unix
system calls run in.")
(license license:expat)))
+(define-public ocaml-textutils-kernel
+ (package
+ (name "ocaml-textutils-kernel")
+ (version "0.15.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://ocaml.janestreet.com/ocaml-core/v0.15/files/textutils_kernel-v0.15.0.tar.gz")
+ (sha256
+ (base32
+ "0dzsazmwnjq11z533wq3a319drlgrjgxr28y2j40h2i4qdfr3b5c"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-core ocaml-ppx-jane ocaml-uutf))
+ (properties `((upstream-name . "textutils_kernel")))
+ (home-page "https://github.com/janestreet/textutils_kernel")
+ (synopsis "Text output utilities")
+ (description
+ "The subset of textutils using only core_kernel and working in
+javascript.")
+ (license license:expat)))
+
(define-public ocaml-timezone
(package
(name "ocaml-timezone")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 28/39] gnu: Add ocaml-textutils.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-28-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-textutils): New variable.
---
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 73cae7fd52..9f05552c15 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8432,6 +8432,30 @@ (define-public ocaml-textutils-kernel
javascript.")
(license license:expat)))
+(define-public ocaml-textutils
+ (package
+ (name "ocaml-textutils")
+ (version "0.15.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://ocaml.janestreet.com/ocaml-core/v0.15/files/textutils-v0.15.0.tar.gz")
+ (sha256
+ (base32
+ "1pr2vhvmiqcdipwd21vif24p2zzv6kbhvcmzkzb7qwhqmnv8ydn0"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-core
+ ocaml-core-kernel
+ ocaml-core-unix
+ ocaml-ppx-jane
+ ocaml-textutils-kernel
+ ocaml-uutf))
+ (home-page "https://github.com/janestreet/textutils")
+ (synopsis "Text output utilities")
+ (description
+ "Utilities for working with terminal output, such as color printing.")
+ (license license:expat)))
+
(define-public ocaml-timezone
(package
(name "ocaml-timezone")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 30/39] gnu: Add ocaml-async-rpc-kernel.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-30-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-async-rpc-kernel): New variable.
---
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 64d7c8065a..d2c41a2fdf 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8434,6 +8434,29 @@ (define-public ocaml-async-unix
system calls run in.")
(license license:expat)))
+(define-public ocaml-async-rpc-kernel
+ (package
+ (name "ocaml-async-rpc-kernel")
+ (version "0.15.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://ocaml.janestreet.com/ocaml-core/v0.15/files/async_rpc_kernel-v0.15.0.tar.gz")
+ (sha256
+ (base32
+ "07aq9fz1cqyfy3sarwrdh0rzw57b4balmagdqwsfs1c2rjffk4d7"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-async-kernel ocaml-core ocaml-ppx-jane
+ ocaml-protocol-version-header))
+ (properties `((upstream-name . "async_rpc_kernel")))
+ (home-page "https://github.com/janestreet/async_rpc_kernel")
+ (synopsis "Platform-independent core of Async RPC library")
+ (description
+ "Library for building RPC-style protocols. This library is the portable
+part of the Unix-oriented Async_rpc library, and is actively used in
+JavaScript.")
+ (license license:expat)))
+
(define-public ocaml-textutils-kernel
(package
(name "ocaml-textutils-kernel")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 32/39] gnu: Add ocaml-shared-memory-ring.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-32-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-shared-memory-ring): New variable.
---
gnu/packages/ocaml.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)

Toggle diff (41 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index c94beb408c..11da7bd7c7 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3023,6 +3023,34 @@ (define-public ocaml-lwt-dllist
doubly-linked list with Lwt iterators.")
(license license:expat)))
+
+(define-public ocaml-shared-memory-ring
+ (package
+ (name "ocaml-shared-memory-ring")
+ (version "3.1.1")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/shared-memory-ring")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "12cpbia39aifnd8rxpsra0lhssqj5qw0zygb5fd8kg58zy2clmrr"))))
+ (build-system dune-build-system)
+ (arguments '(#:package "shared-memory-ring"))
+ (propagated-inputs (list ocaml-cstruct ocaml-ppx-cstruct ocaml-lwt-dllist
+ ocaml-mirage-profile))
+ (native-inputs (list ocaml-ounit))
+ (home-page "https://github.com/mirage/shared-memory-ring")
+ (synopsis "Xen-style shared memory rings")
+ (description
+ "Libraries for creating shared memory producer/consumer rings. The rings
+follow the Xen ABI and may be used to create or implement Xen virtual
+devices.")
+ (license license:isc)))
+
(define-public ocaml-luv
(package
(name "ocaml-luv")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 33/39] gnu: Alias ocaml-shared-memory-ring-lwt to ocaml-shared-memory-ring.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-33-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-shared-memory-ring-lwt): New variable.
---
gnu/packages/ocaml.scm | 9 +++++++++
1 file changed, 9 insertions(+)

Toggle diff (22 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 11da7bd7c7..645ff3961f 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3051,6 +3051,15 @@ (define-public ocaml-shared-memory-ring
devices.")
(license license:isc)))
+(define-public ocaml-shared-memory-ring-lwt
+ (package
+ (inherit ocaml-shared-memory-ring)
+ (name "ocaml-shared-memory-ring-lwt")
+ (arguments '(#:package "shared-memory-ring-lwt"))
+ (propagated-inputs
+ (modify-inputs (package-propagated-inputs ocaml-shared-memory-ring)
+ (append ocaml-shared-memory-ring)))))
+
(define-public ocaml-luv
(package
(name "ocaml-luv")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 31/39] gnu: Add ocaml-async.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-31-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-async): New variable.
---
gnu/packages/ocaml.scm | 32 ++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)

Toggle diff (45 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index d2c41a2fdf..c94beb408c 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8457,6 +8457,38 @@ (define-public ocaml-async-rpc-kernel
JavaScript.")
(license license:expat)))
+(define-public ocaml-async
+ (package
+ (name "ocaml-async")
+ (version "0.15.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://ocaml.janestreet.com/ocaml-core/v0.15/files/async-v0.15.0.tar.gz")
+ (sha256
+ (base32
+ "1afnls0m4izzp933h606k0vj43krfsy4ypnybsidq7pd9cfb4fqd"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-async-kernel
+ ocaml-async-rpc-kernel
+ ocaml-async-unix
+ ocaml-core
+ ocaml-core-kernel
+ ocaml-core-unix
+ ocaml-ppx-jane
+ ocaml-ppx-log
+ ocaml-textutils))
+ ;; TODO one test dependency is deprecated, the other is nowhere to be found
+ (arguments '(#:tests? #f))
+ ;; (native-inputs (list ocaml-netkit-sockets ocaml-qtest-deprecated))
+ (home-page "https://github.com/janestreet/async")
+ (synopsis "Asynchronous execution library")
+ (description
+ "Library for asynchronous programming, i.e., programming where some part
+of the program must wait for things that happen at times determined by some
+external entity (like a human or another program).")
+ (license license:expat)))
+
(define-public ocaml-textutils-kernel
(package
(name "ocaml-textutils-kernel")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 34/39] gnu: Add ocaml-xenstore.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-34-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-xenstore): New variable.
---
gnu/packages/ocaml.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)

Toggle diff (41 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 645ff3961f..b2867ac366 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3060,6 +3060,34 @@ (define-public ocaml-shared-memory-ring-lwt
(modify-inputs (package-propagated-inputs ocaml-shared-memory-ring)
(append ocaml-shared-memory-ring)))))
+(define-public ocaml-xenstore
+ (package
+ (name "ocaml-xenstore")
+ (version "2.2.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://github.com/mirage/ocaml-xenstore/releases/download/v2.2.0/xenstore-2.2.0.tbz")
+ (sha256
+ (base32
+ "0b8qqg7a2bcwfbva042l5kiivpwc1pa8bvwic1fy87bkvsvfmjfl"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-cstruct ocaml-ppx-cstruct ocaml-lwt))
+ (native-inputs (list ocaml-ounit2))
+ (home-page "https://github.com/mirage/ocaml-xenstore")
+ (synopsis "Xenstore protocol in pure OCaml")
+ (description
+ "Repository contents:
+@itemize
+@item client library, a merge of the Mirage and XCP ones
+@item server library
+@item server instance which runs under Unix with libxc
+@item server instance which runs on mirage.
+@end itemize
+The client and the server libraries have sets of unit-tests.")
+ ;; Has a linking exception, see LICENSE.md.
+ (license license:lgpl2.1)))
+
(define-public ocaml-luv
(package
(name "ocaml-luv")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 35/39] gnu: Add ocaml-io-page.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-35-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-io-page): New variable.
---
gnu/packages/ocaml.scm | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)

Toggle diff (34 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index b2867ac366..f63aa138d2 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3088,6 +3088,27 @@ (define-public ocaml-xenstore
;; Has a linking exception, see LICENSE.md.
(license license:lgpl2.1)))
+(define-public ocaml-io-page
+ (package
+ (name "ocaml-io-page")
+ (version "3.0.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://github.com/mirage/io-page/releases/download/v3.0.0/io-page-3.0.0.tbz")
+ (sha256
+ (base32
+ "1vl6ywzp48180bmdnk1zprwz0amz5sxrijwhh08acsq5v5scldhf"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-cstruct))
+ (native-inputs (list pkg-config ocaml-ounit))
+ (home-page "https://github.com/mirage/io-page")
+ (synopsis "Support for efficient handling of I/O memory pages")
+ (description
+ "IO pages are page-aligned, and wrapped in the @code{Cstruct} library to
+avoid copying the data contained within the page.")
+ (license license:isc)))
+
(define-public ocaml-luv
(package
(name "ocaml-luv")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 36/39] gnu: Add ocaml-bheap.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-36-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-bheap): New variable.
---
gnu/packages/ocaml.scm | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)

Toggle diff (33 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index f63aa138d2..b3a4e5e01d 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3109,6 +3109,26 @@ (define-public ocaml-io-page
avoid copying the data contained within the page.")
(license license:isc)))
+(define-public ocaml-bheap
+ (package
+ (name "ocaml-bheap")
+ (version "2.0.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://github.com/backtracking/bheap/releases/download/2.0.0/bheap-2.0.0.tbz")
+ (sha256
+ (base32
+ "0dpnpla20lgiicrxl2432m2fcr6y68msw3pnjxqb11xw6yrdfhsz"))))
+ (build-system dune-build-system)
+ (native-inputs (list ocaml-stdlib-shims))
+ (home-page "https://github.com/backtracking/bheap")
+ (synopsis "Priority queues")
+ (description
+ "Traditional implementation of priority queues using a binary heap
+encoded in a resizable array.")
+ (license license:lgpl2.1)))
+
(define-public ocaml-luv
(package
(name "ocaml-luv")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 37/39] gnu: Add ocaml-mirage-xen.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-37-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-xen): New variable.
---
gnu/packages/ocaml.scm | 33 +++++++++++++++++++++++++++++++++
1 file changed, 33 insertions(+)

Toggle diff (46 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index b3a4e5e01d..d6279d6d7d 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3088,6 +3088,39 @@ (define-public ocaml-xenstore
;; Has a linking exception, see LICENSE.md.
(license license:lgpl2.1)))
+(define-public ocaml-mirage-xen
+ (package
+ (name "ocaml-mirage-xen")
+ (version "8.0.1")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/mirage-xen")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1qydg92dbw8hj4b809apj0f51cjgmamq3zdf34a4wyn5jv85yzyx"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-cstruct
+ ocaml-lwt
+ ocaml-shared-memory-ring-lwt
+ ocaml-xenstore
+ ocaml-lwt-dllist
+ ;;ocaml-mirage-profile dependency cycle
+ ocaml-io-page
+ ocaml-mirage-runtime
+ ocaml-logs
+ ocaml-fmt
+ ocaml-bheap
+ ocaml-duration))
+ (home-page "https://github.com/mirage/mirage-xen")
+ (synopsis "Xen core platform libraries for MirageOS")
+ (description "MirageOS OS library for Xen targets, which handles the main
+loop and timers. It also provides the low level C startup code and C stubs
+required by the OCaml code.")
+ (license license:isc)))
+
(define-public ocaml-io-page
(package
(name "ocaml-io-page")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 38/39] gnu: Add ocaml-parse-argv.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-38-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-parse-argv): New variable.
---
gnu/packages/ocaml.scm | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)

Toggle diff (33 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index d6279d6d7d..0b90578c4b 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3852,6 +3852,26 @@ (define-public ocaml-emile
according RFC2047.")
(license license:expat)))
+(define-public ocaml-parse-argv
+ (package
+ (name "ocaml-parse-argv")
+ (version "0.2.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://github.com/mirage/parse-argv/releases/download/v0.2.0/parse-argv-v0.2.0.tbz")
+ (sha256
+ (base32
+ "06dl04fcmwpkydzni2fzwrhk0bqypd55mgxfax9v82x65xrgj5gw"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-astring))
+ (native-inputs (list ocaml-ounit))
+ (home-page "https://github.com/mirage/parse-argv")
+ (synopsis "Process strings into sets of command-line arguments")
+ (description
+ "Small implementation of a simple argv parser.")
+ (license license:isc)))
+
(define-public ocaml-functoria-runtime
(package
(name "ocaml-functoria-runtime")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 01:35
[PATCH 39/39] gnu: Add ocaml-mirage-bootvar-unix.
(address . guix-patches@gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230109003529.23375-39-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-bootvar-unix): New variable.
---
gnu/packages/ocaml.scm | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)

Toggle diff (31 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 0b90578c4b..8251082afc 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3975,6 +3975,24 @@ (define-public ocaml-mirage
a fully-standalone, specialised unikernel.")
(license license:isc)))
+(define-public ocaml-mirage-bootvar-unix
+ (package
+ (name "ocaml-mirage-bootvar-unix")
+ (version "0.1.0")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://github.com/mirage/mirage-bootvar-unix/releases/download/0.1.0/mirage-bootvar-unix-0.1.0.tbz")
+ (sha256
+ (base32
+ "0r92s6y7nxg0ci330a7p0hii4if51iq0sixn20cnm5j4a2clprbf"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-lwt ocaml-parse-argv))
+ (home-page "https://github.com/mirage/mirage-bootvar-unix")
+ (synopsis "Unix implementation of MirageOS Bootvar interface")
+ (description "Library for passing boot parameters from Solo5 to MirageOS.")
+ (license license:isc)))
+
(define-public ocaml-duration
(package
(name "ocaml-duration")
--
2.38.1
C
C
Csepp wrote on 9 Jan 2023 14:51
merging accidental multiple submission
(address . control@debbugs.gnu.org)
86eds3hjvn.fsf@riseup.net
merge 60671 60672 60673 60674 60675 60676 60677 60678 60679 60680 60681 60682 60683
thanks

Sorry, and thanks nckx for helping me sort this out!
C
C
Christopher Baines wrote on 7 Feb 2023 08:54
tag 60674 moreinfo
(address . control@debbugs.gnu.org)
87cz6lykon.fsf@cbaines.net
tags 60674 + moreinfo
quit
C
C
Christopher Baines wrote on 7 Feb 2023 08:57
Re: [bug#60673] [PATCH 01/39] gnu: Add ocaml-domain-name.
(name . Csepp)(address . raingloom@riseup.net)
874jrxdhxi.fsf@cbaines.net
Hey,

While I think the builds look OK for this series, there are quite a few
formatting issues raised by the linter (this can be seen on [1] and [2]).


Could you run the linter on the packages you've added here, address the
issues it raises and send an updated series?

Thanks,

Chris
-----BEGIN PGP SIGNATURE-----

iQKlBAEBCgCPFiEEPonu50WOcg2XVOCyXiijOwuE9XcFAmPiBPlfFIAAAAAALgAo
aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF
ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcRHG1haWxAY2Jh
aW5lcy5uZXQACgkQXiijOwuE9XemNw//Yyogb3RNcvqQrZEQ6rsNixU7V8PRkpZT
60HG5x7tbvy2wAyW5VoO5dn/175HyZns3Wr6Us1lU7Qz4YF1SNoJysiGmVnCuu4X
sAHdtf9PkEQIhVe+G+3aSzs0jIc0bUpRqBQiUcKSBxAJEkdnY+TdEAmfOQvyWKQz
fX23WfEpG+8GMNExgmB22bz0rczSk2p9oahQt74YEmhHIodxC4ZBxeGzpN5iEC89
OjRFjfTbnsjLZQRHW0ZQNe3dfXmkZS+NYn7DpoF3++inNpbRBJIhWzkF2T7JeQca
2+cQpMN3i61I6nd5kaypDlbo0C1DrKpWZzTU8lXKD2iXwYwKhU3hFuvxJOsEMWKO
7kKEDqIhyu1vC5bahzw+CYlUEZrGNwxJrRFF8/xLI2LVflZvsawm4LH25v3q31Sy
+mufCu0aDJaS4J3GFpI3t+uAGKhaZr+WqeCxgVt0zKiYN4R4XGUUfEwbsh0eB3N0
oOEMXku9mJ6lx+v528Qp/ibW3/WRVWH2dQIYg1kgH9NrtQae1kb70V5d6vMLEe3R
aFAl16vlp3b0WGVXuTezWv3blB83LSuV1/pUvdvokWoE7Z8KZk73kOnhuvz2PCku
kPgpukulRqA0a9mmpFIKv9p98VZ8k8F3+gqMdCPVk0ReRPgwwCPKgomRZFQCB4HC
S9ZPwIsXoCU=
=uyIT
-----END PGP SIGNATURE-----

C
C
Csepp wrote on 8 Feb 2023 02:37
(name . Christopher Baines)(address . mail@cbaines.net)
87wn4t2aik.fsf@riseup.net
Christopher Baines <mail@cbaines.net> writes:

Toggle quote (19 lines)
> [[PGP Signed Part:Undecided]]
> Hey,
>
> While I think the builds look OK for this series, there are quite a few
> formatting issues raised by the linter (this can be seen on [1] and [2]).
>
> 1: https://qa.guix.gnu.org/issue/60674
> 2:
> https://data.qa.guix.gnu.org/compare?base_commit=238f965c331990459a69cbc713ca951ad40e6044&target_commit=3b5485b9cdaebda127dc040ad67a287f39e33519
>
> Could you run the linter on the packages you've added here, address the
> issues it raises and send an updated series?
>
> Thanks,
>
> Chris
>
> [[End of PGP Signed Part]]

Those are all URL constants, can't really do much about them other than slice
them up with string-append, which I'm not sure really helps with
readability or ease of editing. They were not an issue while I was
editing the code and gnu/packages/ocaml.scm already has a lot of lines
that whitespace-mode highlights as too long, so I thought it wouldn't
matter much and my time would be better spent elsewhere.
The real fix IMHO would be to convert them into git-fetch origins, which
would also make it possible to use git related package transforms. This
is on my TODO list.
Or at least the OPAM importer should be changed to do the URL splitting.
C
C
Christopher Baines wrote on 8 Feb 2023 08:32
(name . Csepp)(address . raingloom@riseup.net)
875ycc8v82.fsf@cbaines.net
Csepp <raingloom@riseup.net> writes:

Toggle quote (28 lines)
> Christopher Baines <mail@cbaines.net> writes:
>
>> [[PGP Signed Part:Undecided]]
>> Hey,
>>
>> While I think the builds look OK for this series, there are quite a few
>> formatting issues raised by the linter (this can be seen on [1] and [2]).
>>
>> 1: https://qa.guix.gnu.org/issue/60674
>> 2:
>> https://data.qa.guix.gnu.org/compare?base_commit=238f965c331990459a69cbc713ca951ad40e6044&target_commit=3b5485b9cdaebda127dc040ad67a287f39e33519
>>
>> Could you run the linter on the packages you've added here, address the
>> issues it raises and send an updated series?
>>
>> Thanks,
>>
>> Chris
>>
>> [[End of PGP Signed Part]]
>
> Those are all URL constants, can't really do much about them other than slice
> them up with string-append, which I'm not sure really helps with
> readability or ease of editing. They were not an issue while I was
> editing the code and gnu/packages/ocaml.scm already has a lot of lines
> that whitespace-mode highlights as too long, so I thought it wouldn't
> matter much and my time would be better spent elsewhere.

You're right that there are quite a few other instances of lines that
are too long in that module, but I don't think that's a reason not to
add more. I think splitting the long URL strings with string-append is a
good approach and can help with readability.
-----BEGIN PGP SIGNATURE-----

iQKlBAEBCgCPFiEEPonu50WOcg2XVOCyXiijOwuE9XcFAmPjUO1fFIAAAAAALgAo
aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF
ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcRHG1haWxAY2Jh
aW5lcy5uZXQACgkQXiijOwuE9XeNng//QEGLBpjKu9K+4epn0c3gYLpHC0shKrIC
fpgtFwe7pvAz2+vXKziNhkEU2EU++muR8ELHSyOaCum3lR3neGX3TiYhWXI9h0qp
yBCYnhM1GLLzbie43ntklU3FdL59P5XuLM8B7HL5Pkdm5wk/DXc0q4wcQz/r/dfs
9oCKeUgGz8xukGv/sTlhw2zR42/nCootTepFcgqBAhKQ7HX8I9ATgzWkbjVFADGD
JorGAgYqDcTJ5+CmMGU8ygGYR2RpjCqpCBajZ3fG8oTNzG5YgaT+yoNJ1HNQKmA0
kJs/DaQvZsn7ZmL1iSlsT61L8xDD1zXtMkuF5ny3Q3IujhLlDYZJ5QjbSxsKYPu9
qQkwaK4QAwbih0N97ofmmoFWzlWzhv2ElEv+Tu6gfXt3u8Vljg9LOEKKhanhKPzM
94kkeZ1hjHGl1QS4hNIThbWIIZEPxR5+x9lOw9YIOV72a1zZj62mnxkq6ox5MOJ3
9c2y4LgdNmbg7dOIWYwV9/tWCFcw03TQ8InuKu1mwyp7nxPEAxh4Mf9EpCMLax4z
dcge6OM4iEdKe97uurICRE1SEwa480mDk4o4j70TLZ/VWGIkCLD67KDDPwbXqBLd
wHwF2BoSDjovtQUnN3vkZoMNeBIuKotbX3sXyRshzlqco9y+odBBlNOT5/YJRpGO
ZdpXq9zWvio=
=TUka
-----END PGP SIGNATURE-----

C
(address . 60673@debbugs.gnu.org)
20230215220028.18575-1-raingloom@riseup.net
Updated version of the packages needed to build the hello world unikernel.
Lint warnings taken care of, the few that remain are false positives related
to upgrades to versions that are not actually newer.
C
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-2-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

gnu/packages/ocaml.scm (ocaml-domain-name): New variable.
---
gnu/packages/ocaml.scm | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)

Toggle diff (43 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 0cc92c3e85..75f112f0ac 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -27,6 +27,7 @@
;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com>
;;; Copyright © 2022 Garek Dyszel <garekdyszel@disroot.org>
+;;; Copyright © 2023 Csepp <raingloom@riseup.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -3529,6 +3530,28 @@ (define-public ocaml-ocp-index
(license (list license:gpl3+
license:lgpl2.1+))))
+(define-public ocaml-domain-name
+ (package
+ (name "ocaml-domain-name")
+ (version "0.4.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/hannesm/domain-name/")
+ (commit (string-append "v" version))))
+ (file-name name)
+ (sha256
+ (base32
+ "1a669zz1pc7sqbi1c13jsnp8algcph2b8gr5fjrjhyh3p232770k"))))
+ (build-system dune-build-system)
+ (native-inputs (list ocaml-alcotest))
+ (home-page "https://github.com/hannesm/domain-name")
+ (synopsis "RFC 1035 Internet domain name data structure and parser")
+ (description
+ "Parses and constructs RFC compliant domain names. The invariants on the
+length of domain names are preserved throughout the module.")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 02/39] gnu: Add ocaml-macaddr.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-3-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-macaddr): New variable.
---
gnu/packages/ocaml.scm | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)

Toggle diff (42 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 75f112f0ac..7fb32ade5a 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3552,6 +3552,35 @@ (define-public ocaml-domain-name
length of domain names are preserved throughout the module.")
(license license:isc)))
+(define-public ocaml-macaddr
+ (package
+ (name "ocaml-macaddr")
+ (version "5.3.1")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/ocaml-ipaddr/")
+ (commit (string-append "v" version))))
+ (file-name name)
+ (sha256
+ (base32
+ "1zgwx0ms3l4k4dzwnkrwq4zzqjrddjsvqn66mbd0rm6aq1ib019d"))))
+ (build-system dune-build-system)
+ (arguments '(#:package "macaddr"))
+ (propagated-inputs (list ocaml-cstruct ocaml-domain-name))
+ (native-inputs (list ocaml-ounit2 ocaml-ppx-sexp-conv))
+ (home-page "https://github.com/mirage/ocaml-ipaddr")
+ (synopsis "OCaml library for manipulation of MAC address representations")
+ (description
+ "Features:
+@itemize
+@item MAC-48 (Ethernet) address support
+@item @code{Macaddr} is a @code{Map.OrderedType}
+@item All types have sexplib serializers/deserializers optionally via the
+@code{Macaddr_sexp} library
+@end itemize")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 03/39] gnu: Add ocaml-ipaddr.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-4-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-ipaddr): New variable.
---
gnu/packages/ocaml.scm | 13 +++++++++++++
1 file changed, 13 insertions(+)

Toggle diff (26 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 7fb32ade5a..e3e63c26b4 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3581,6 +3581,19 @@ (define-public ocaml-macaddr
@end itemize")
(license license:isc)))
+(define-public ocaml-ipaddr
+ ;; same repo and versions as ocaml-macaddr
+ (package
+ (inherit ocaml-macaddr)
+ (name "ocaml-ipaddr")
+ (arguments '(#:package "ipaddr"))
+ (propagated-inputs (list ocaml-macaddr ocaml-domain-name))
+ (synopsis
+ "Library for manipulation of IP (and MAC) address representations")
+ (description
+ "IP address types with serialization, supporting a wide range of RFCs.")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 04/39] gnu: Add ocaml-opam-monorepo.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-5-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-opam-monorepo): New variable.
---
gnu/packages/ocaml.scm | 33 +++++++++++++++++++++++++++++++++
1 file changed, 33 insertions(+)

Toggle diff (46 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index e3e63c26b4..d9b0d74c80 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -976,6 +976,39 @@ (define-public opam
;; The 'LICENSE' file waives some requirements compared to LGPLv3.
(license license:lgpl3)))
+(define-public ocaml-opam-monorepo
+ (package
+ (name "ocaml-opam-monorepo")
+ (version "0.3.5")
+ (source (origin
+ (method git-fetch)
+ (uri
+ (git-reference
+ (url "https://github.com/tarides/opam-monorepo/")
+ (commit version)))
+ (file-name name)
+ (sha256
+ (base32
+ "09lq788b1sai4v1nxd16b00pw0m55plcwrx3f9v5a90gpxg0a6sc"))))
+ (build-system dune-build-system)
+ (arguments
+ ;; TODO
+ ;; Too many tests require a fully initialized opam, disabling them would
+ ;; be a huge pain. "Mocking" opam init is difficult because it requires
+ ;; networking access.
+ '(#:tests? #f))
+ ;; TODO: not entirely clear if these should be native, test cross-building
+ (native-inputs (list ocaml-odoc
+ pkg-config))
+ ;; (propagated-inputs lablgtk3) optional and is currently failing to build
+ (home-page "https://github.com/tarides/opam-monorepo")
+ (synopsis "Assemble and manage fully vendored Dune repositories")
+ (description
+ "The opam monorepo plugin provides a convenient interface to bridge the
+opam package manager with having a local copy of all the source code required
+to build a project using the dune build tool.")
+ (license license:isc)))
+
(define-public ocaml-camlp-streams
(package
(name "ocaml-camlp-streams")
--
2.39.1
C
[PATCH v2 05/39] gnu: Add ocaml-pecu.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-6-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-pecu): New variable.
---
gnu/packages/ocaml.scm | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)

Toggle diff (34 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index d9b0d74c80..17230b5023 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3627,6 +3627,27 @@ (define-public ocaml-ipaddr
"IP address types with serialization, supporting a wide range of RFCs.")
(license license:isc)))
+(define-public ocaml-pecu
+ (package
+ (name "ocaml-pecu")
+ (version "0.6")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://github.com/mirage/pecu/releases/download/v0.6/pecu-v0.6.tbz")
+ (sha256
+ (base32
+ "1iz5jj9lyl1pah8dfni4wv0qml0ir5zknv4zhw7v50sc8kdbglm9"))))
+ (build-system dune-build-system)
+ (native-inputs (list ocaml-fmt ocaml-alcotest ocaml-crowbar ocaml-astring))
+ (home-page "https://github.com/mirage/pecu")
+ (synopsis "Encoder/Decoder of Quoted-Printable (RFC2045 & RFC2047)")
+ (description
+ "This package provides a non-blocking encoder/decoder of Quoted-Printable
+according to RFC2045 and RFC2047 (about encoded-word). Useful to translate
+contents of emails.")
+ (license license:expat)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 06/39] gnu: Add ocaml-emile.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-7-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-emile): New variable.
---
gnu/packages/ocaml.scm | 27 +++++++++++++++++++++++++++
1 file changed, 27 insertions(+)

Toggle diff (40 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 17230b5023..f6371983d3 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3648,6 +3648,33 @@ (define-public ocaml-pecu
contents of emails.")
(license license:expat)))
+(define-public ocaml-emile
+ (package
+ (name "ocaml-emile")
+ (version "1.1")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://github.com/mirage/emile/releases/download/v1.1/emile-v1.1.tbz")
+ (sha256
+ (base32
+ "0r1141makr0b900aby1gn0fccjv1qcqgyxib3bzq8fxmjqwjan8p"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-angstrom
+ ocaml-ipaddr
+ ocaml-base64
+ ocaml-pecu
+ ocaml-bigstringaf
+ ocaml-uutf))
+ (native-inputs (list ocaml-alcotest))
+ (home-page "https://github.com/mirage/emile")
+ (synopsis "Parser of email address according RFC822")
+ (description
+ "This package provides a parser of email address according RFC822, RFC2822,
+RFC5321 and RFC6532. It handles UTF-8 email addresses and encoded-word
+according RFC2047.")
+ (license license:expat)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 11/39] gnu: Add ocaml-duration.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-12-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-duration): New variable.
---
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 d89b538d31..263ad9d200 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3778,6 +3778,30 @@ (define-public ocaml-mirage
a fully-standalone, specialised unikernel.")
(license license:isc)))
+(define-public ocaml-duration
+ (package
+ (name "ocaml-duration")
+ (version "0.2.1")
+ (source (origin
+ (method git-fetch)
+ (uri
+ (git-reference
+ (url "https://github.com/hannesm/duration/")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0vvxi0ipxmdz1k4h501brvccniwf3wpc32djbccyyrzraiz7qkff"))))
+ (build-system dune-build-system)
+ (native-inputs (list ocaml-alcotest))
+ (home-page "https://github.com/hannesm/duration")
+ (synopsis "Conversions to various time units")
+ (description
+ "This package provides a duration is represented in nanoseconds as an
+unsigned 64 bit integer. This has a range of up to 584 years. Functions
+provided check the input and raise on negative or out of bound input.")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 07/39] gnu: Add ocaml-functoria-runtime
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-8-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-functoria-runtime): New variable.
---
gnu/packages/ocaml.scm | 35 +++++++++++++++++++++++++++++++++++
1 file changed, 35 insertions(+)

Toggle diff (48 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index f6371983d3..3ad0ccbb76 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3675,6 +3675,41 @@ (define-public ocaml-emile
according RFC2047.")
(license license:expat)))
+(define-public ocaml-functoria-runtime
+ (package
+ (name "ocaml-functoria-runtime")
+ (version "4.3.3")
+ (source
+ (origin
+ (method git-fetch)
+ (uri
+ (git-reference
+ (url "https://github.com/mirage/mirage/")
+ (commit (string-append "v" version))))
+ ;; TODO this origin is used by multiple packages, so what should the name
+ ;; field say?
+ (file-name (git-file-name "mirage" version))
+ (sha256
+ (base32
+ "09mqbffrhnklbc50gaflkwb3h1xysqqiwb84a9q1phjl038pic6r"))))
+ (build-system dune-build-system)
+ (arguments
+ '(#:package "functoria-runtime"
+ ;; TODO
+ ;; again, requires opam for tests, which needs network access.
+ ;; most other tests seem to pass.
+ #:tests? #f))
+ (propagated-inputs
+ (list ocaml-cmdliner ocaml-fmt ocaml-logs ocaml-bos ocaml-ipaddr
+ ocaml-emile ocaml-uri))
+ (native-inputs
+ (list ocaml-alcotest))
+ (home-page "https://github.com/mirage/mirage")
+ (synopsis "Runtime support library for functoria-generated code")
+ (description
+ "This is the runtime support library for code generated by functoria.")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 13/39] gnu: Add ocaml-mirage-time.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-14-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-time): New variable.
---
gnu/packages/ocaml.scm | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)

Toggle diff (33 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index f2ff6b6e15..affd0c194a 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3802,6 +3802,26 @@ (define-public ocaml-duration
provided check the input and raise on negative or out of bound input.")
(license license:isc)))
+(define-public ocaml-mirage-time
+ (package
+ (name "ocaml-mirage-time")
+ (version "3.0.0")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append
+ "https://github.com/mirage/mirage-time/releases/download/v"
+ version "/mirage-time-v3.0.0.tbz"))
+ (sha256
+ (base32
+ "0z5xkhlgyhm22wyhwpf9r0rn4125cc3cxj6ccavyiiz2b2dr8h0d"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-lwt ocaml-duration))
+ (home-page "https://github.com/mirage/mirage-time")
+ (synopsis "Time operations for MirageOS")
+ (description
+ "Defines the signature for time-related operations for MirageOS.")
+ (license license:isc)))
+
(define-public ocaml-mirage-unix
(package
(name "ocaml-mirage-unix")
--
2.39.1
C
[PATCH v2 09/39] gnu: Add ocaml-functoria.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-10-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-functoria): New variable.
---
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 532a6b4d3d..bf57dc153a 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3731,6 +3731,29 @@ (define-public ocaml-mirage-runtime
applications built with MirageOS")
(license license:isc)))
+(define-public ocaml-functoria
+ (package
+ (inherit ocaml-functoria-runtime)
+ (name "ocaml-functoria")
+ (build-system dune-build-system)
+ (arguments
+ '(#:package "functoria"
+ ;; TODO again, wants opam, other tests seem to pass
+ ;; look for a way to disable tests that want network access
+ #:tests? #f))
+ (propagated-inputs (list ocaml-cmdliner ocaml-rresult ocaml-result
+ ocaml-astring ocaml-fmt ocaml-logs ocaml-bos
+ ocaml-fpath ocaml-emile ocaml-uri))
+ (native-inputs (list ocaml-alcotest ocaml-functoria-runtime))
+ (home-page "https://github.com/mirage/mirage")
+ (synopsis
+ "DSL to organize functor applications")
+ (description
+ "DSL to describe a set of modules and functors, their types and
+how to apply them in order to produce a complete application. The main use
+case is mirage.")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 14/39] gnu: Add aliases for ocaml-cstruct and ocaml-lwt subpackages.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-15-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-lwt-ppx ocaml-cstruct-unix
ocaml-cstruct-sexp): New variables.
---
gnu/packages/ocaml.scm | 11 +++++++++++
1 file changed, 11 insertions(+)

Toggle diff (31 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index affd0c194a..552759a171 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -2963,6 +2963,11 @@ (define-public ocaml-lwt
locks or other synchronization primitives.")
(license license:lgpl2.1)))
+;; TODO this alias is not ideal but ocaml-lwt already explicitly specifies a
+;; package argument and at least this way the importer doesn't try to
+;; re-import it.
+(define ocaml-lwt-ppx ocaml-lwt)
+
(define-public ocaml-lwt-dllist
(package
(name "ocaml-lwt-dllist")
@@ -4453,6 +4458,12 @@ (define-public ocaml4.07-cstruct
"0jj3whs8r3jc524i9bb67rffh7y7r157hjgvws0bkxijxpjzwkbk"))))
(properties '()))))
+;; TODO again, the "parent" package already has an explicit package argument,
+;; so a variant package doesn't make sense, at least these aliases help the
+;; importer out so it doesn't re-import things. At least hopefully.
+(define ocaml-cstruct-unix ocaml-cstruct)
+(define ocaml-cstruct-sexp ocaml-cstruct)
+
(define-public ocaml-hex
(package
(name "ocaml-hex")
--
2.39.1
C
[PATCH v2 10/39] gnu: Add ocaml-mirage.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-11-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage): New variable.
---
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 bf57dc153a..d89b538d31 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3754,6 +3754,30 @@ (define-public ocaml-functoria
case is mirage.")
(license license:isc)))
+(define-public ocaml-mirage
+ (package
+ (inherit ocaml-functoria-runtime)
+ (name "ocaml-mirage")
+ (build-system dune-build-system)
+ (arguments
+ '(#:package "mirage"
+ ;; TODO again, wants opam, other tests seem to pass
+ ;; look for a way to disable tests that want network access
+ #:tests? #f))
+ (propagated-inputs
+ (list ocaml-astring ocaml-bos ocaml-functoria ocaml-ipaddr ocaml-logs
+ ocaml-mirage-runtime ocaml-opam-monorepo))
+ (native-inputs (list ocaml-alcotest ocaml-fmt))
+ (home-page "https://github.com/mirage/mirage")
+ (synopsis
+ "The MirageOS library operating system")
+ (description
+ "Library operating system that constructs unikernels for secure,
+high-performance network applications across a variety of cloud computing and
+mobile platforms. Code can be developed on a normal OS and then compiled into
+a fully-standalone, specialised unikernel.")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 15/39] gnu: Add ocaml-ppx-cstruct.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-16-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-ppx-cstruct): New variable.
---
gnu/packages/ocaml.scm | 16 ++++++++++++++++
1 file changed, 16 insertions(+)

Toggle diff (29 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 552759a171..dfd194faaf 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -4464,6 +4464,22 @@ (define-public ocaml4.07-cstruct
(define ocaml-cstruct-unix ocaml-cstruct)
(define ocaml-cstruct-sexp ocaml-cstruct)
+(define-public ocaml-ppx-cstruct
+ (package
+ (inherit ocaml-cstruct)
+ (name "ocaml-ppx-cstruct")
+ (properties `((upstream-name . "ppx_cstruct")))
+ (arguments
+ '(#:package "ppx_cstruct"
+ ;; TODO doesn't find test deps for some reason?
+ ;; I have no clue why.
+ #:tests? #f))
+ (propagated-inputs (modify-inputs (package-propagated-inputs ocaml-cstruct)
+ (append ocaml-cstruct ocaml-ppxlib ocaml-sexplib)))
+ (native-inputs (modify-inputs (package-propagated-inputs ocaml-cstruct)
+ (append ocaml-cstruct-sexp ocaml-findlib
+ ocaml-ppx-sexp-conv)))))
+
(define-public ocaml-hex
(package
(name "ocaml-hex")
--
2.39.1
C
[PATCH v2 16/39] gnu: Add ocaml-mirage-profile-unix.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-17-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-profile-unix): New variable.
---
gnu/packages/ocaml.scm | 38 ++++++++++++++++++++++++++++++++++++++
1 file changed, 38 insertions(+)

Toggle diff (51 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index dfd194faaf..665bf943da 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3848,6 +3848,44 @@ (define-public ocaml-mirage-unix
handles the main loop and timers.")
(license license:isc)))
+(define-public ocaml-mirage-profile-unix
+ (package
+ (name "ocaml-mirage-profile-unix")
+ (version "0.9.1")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/mirage-profile/")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "11p3ai8g993algds9mbg4xf3is0agqah127r69fb7rm35dryzq95"))))
+ (build-system dune-build-system)
+ (arguments
+ '(#:package "mirage-profile-unix"
+ #:tests? #f ;depends on ocaml-mirage-profile which would form a loop
+ #:phases (modify-phases %standard-phases
+ ;; TODO is there a way to do this with dune build flags?
+ (add-after 'unpack 'disable-xen
+ (lambda _
+ ;; this way it is not detected as a build target
+ (rename-file "xen" "_xen"))))))
+ (propagated-inputs (list ocaml-cstruct ocaml-ocplib-endian ocaml-lwt
+ ocaml-mtime ocaml-ppx-cstruct))
+ (native-inputs (list ocaml-ppx-cstruct))
+ (home-page "https://github.com/mirage/mirage-profile")
+ (synopsis "Collects Ocaml/Lwt profiling information in CTF format")
+ (description
+ "Used to trace execution of OCaml/Lwt programs (such as Mirage
+unikernels) at the level of Lwt threads. The traces can be viewed using
+JavaScript or GTK viewers provided by mirage-trace-viewer or processed by
+tools supporting the Common Trace Format.
+When compiled against a normal version of Lwt, OCaml's cross-module inlining
+will optimise these calls away, meaning there should be no overhead in the
+non-profiling case.")
+ (license license:bsd-2)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 17/39] gnu: Add ocaml-mirage-profile.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-18-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-profile): New variable.
---
gnu/packages/ocaml.scm | 14 ++++++++++++++
1 file changed, 14 insertions(+)

Toggle diff (27 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 665bf943da..fd40f7b75c 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3886,6 +3886,20 @@ (define-public ocaml-mirage-profile-unix
non-profiling case.")
(license license:bsd-2)))
+(define-public ocaml-mirage-profile
+ (package
+ (inherit ocaml-mirage-profile-unix)
+ (name "ocaml-mirage-profile")
+ (arguments
+ '(#:package "mirage-profile"
+ ;; TODO cyclic dependency with mirage-profile
+ ;; It could be broken using package variants, if not for
+ ;; propagated inputs leading to version conflicts.
+ #:tests? #f))
+ (propagated-inputs (modify-inputs (package-propagated-inputs
+ ocaml-mirage-profile-unix)
+ (append ocaml-mirage-profile-unix)))))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 12/39] gnu: Add ocaml-mirage-unix.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-13-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-unix): New variable.
---
gnu/packages/ocaml.scm | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)

Toggle diff (34 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 263ad9d200..f2ff6b6e15 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3802,6 +3802,27 @@ (define-public ocaml-duration
provided check the input and raise on negative or out of bound input.")
(license license:isc)))
+(define-public ocaml-mirage-unix
+ (package
+ (name "ocaml-mirage-unix")
+ (version "5.0.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append
+ "https://github.com/mirage/mirage-unix/releases/download/v"
+ version "/mirage-unix-5.0.1.tbz"))
+ (sha256
+ (base32
+ "1y44hvsd5lxqbazwkv9n6cn936lpn8l7v82wf55w4183fp70nnjk"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-lwt ocaml-duration ocaml-mirage-runtime))
+ (home-page "https://github.com/mirage/mirage-unix")
+ (synopsis "Unix core platform libraries for MirageOS")
+ (description
+ "This package provides the MirageOS `OS` library for Unix targets, which
+handles the main loop and timers.")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 08/39] gnu: Add ocaml-mirage-runtime.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-9-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-runtime): New variable.
---
gnu/packages/ocaml.scm | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)

Toggle diff (34 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 3ad0ccbb76..532a6b4d3d 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3710,6 +3710,27 @@ (define-public ocaml-functoria-runtime
"This is the runtime support library for code generated by functoria.")
(license license:isc)))
+(define-public ocaml-mirage-runtime
+ (package
+ (inherit ocaml-functoria-runtime)
+ (name "ocaml-mirage-runtime")
+ (build-system dune-build-system)
+ (arguments
+ '(#:package "mirage-runtime"
+ ;; TODO again, wants opam, other tests seem to pass
+ ;; look for a way to disable tests that want network access
+ #:tests? #f))
+ (propagated-inputs (list ocaml-ipaddr ocaml-functoria-runtime ocaml-fmt
+ ocaml-logs ocaml-lwt))
+ (native-inputs (list ocaml-alcotest))
+ (home-page "https://github.com/mirage/mirage")
+ (synopsis
+ "The base MirageOS runtime library, part of every MirageOS unikernel")
+ (description
+ "This package provides a bundle of useful runtime functions for
+applications built with MirageOS")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 18/39] gnu: Add ocaml-mirage-clock.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-19-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-clock): New variable.
---
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 fd40f7b75c..48676f0fbf 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3827,6 +3827,30 @@ (define-public ocaml-mirage-time
"Defines the signature for time-related operations for MirageOS.")
(license license:isc)))
+(define-public ocaml-mirage-clock
+ (package
+ (name "ocaml-mirage-clock")
+ (version "4.2.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/mirage-clock")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0rkara9i3dvnzrb8jl2vkx8hgamvxnksin67wmhbv9d4i758amjy"))))
+ (build-system dune-build-system)
+ (home-page "https://github.com/mirage/mirage-clock")
+ (synopsis "Libraries and module types for portable clocks")
+ (description
+ "This library implements portable support for an operating system
+timesource that is compatible with the MirageOS library interfaces. It
+implements an @code{MCLOCK} module that represents a monotonic timesource
+since an arbitrary point, and @code{PCLOCK} which counts time since the Unix
+epoch.")
+ (license license:isc)))
+
(define-public ocaml-mirage-unix
(package
(name "ocaml-mirage-unix")
--
2.39.1
C
[PATCH v2 19/39] gnu: Add ocaml-ptime.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-20-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-ptime): New variable.
---
gnu/packages/ocaml.scm | 30 ++++++++++++++++++++++++++++++
1 file changed, 30 insertions(+)

Toggle diff (43 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 48676f0fbf..b4b81b9a41 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3851,6 +3851,36 @@ (define-public ocaml-mirage-clock
epoch.")
(license license:isc)))
+(define-public ocaml-ptime
+ (package
+ (name "ocaml-ptime")
+ ;; TODO 1.1.0 has some issues, so for now we are stuck with 0.8.5
+ (version "0.8.5")
+ (source (origin
+ (method url-fetch)
+ (uri
+ "https://erratique.ch/software/ptime/releases/ptime-0.8.5.tbz")
+ (sha256
+ (base32
+ "1fxq57xy1ajzfdnvv5zfm7ap2nf49znw5f9gbi4kb9vds942ij27"))))
+ (build-system ocaml-build-system)
+ (arguments
+ `(#:build-flags (list "build" "--with-js_of_ocaml" "true" "--tests"
+ "true")
+ #:phases (modify-phases %standard-phases
+ (delete 'configure))))
+ (propagated-inputs (list ocaml-result js-of-ocaml))
+ (native-inputs (list ocaml-findlib ocamlbuild ocaml-topkg opam))
+ (home-page "https://erratique.ch/software/ptime")
+ (synopsis "POSIX time for OCaml")
+ (description
+ "Ptime offers platform independent POSIX time support in pure OCaml. It
+provides a type to represent a well-defined range of POSIX timestamps with
+picosecond precision, conversion with date-time values, conversion with RFC
+3339 timestamps and pretty printing to a human-readable, locale-independent
+representation.")
+ (license license:isc)))
+
(define-public ocaml-mirage-unix
(package
(name "ocaml-mirage-unix")
--
2.39.1
C
[PATCH v2 20/39] gnu: Add ocaml-mirage-logs.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-21-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-logs): New variable.
---
gnu/packages/ocaml.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)

Toggle diff (41 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index b4b81b9a41..d6ecc92605 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3954,6 +3954,34 @@ (define-public ocaml-mirage-profile
ocaml-mirage-profile-unix)
(append ocaml-mirage-profile-unix)))))
+(define-public ocaml-mirage-logs
+ (package
+ (name "ocaml-mirage-logs")
+ (version "1.2.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/mirage-logs/")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1wv2hz1dj38jzc8nabin9p8im43ghy8f3crv7rf9szyyzyrdanp2"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-logs ocaml-ptime ocaml-mirage-clock
+ ocaml-mirage-profile ocaml-lwt))
+ (native-inputs (list ocaml-alcotest))
+ (home-page "https://github.com/mirage/mirage-logs")
+ (synopsis
+ "Reporter for the Logs library that writes to stderr with timestamps")
+ (description
+ "Uses a Mirage @code{CLOCK} to write timestamped log messages. It can
+also log only important messages to the console, while writing all received
+messages to a ring buffer which is displayed if an exception occurs. If
+tracing is enabled (via mirage-profile), it also writes each log message to
+the trace buffer.")
+ (license license:isc)))
+
(define-public ocaml-ocurl
(package
(name "ocaml-ocurl")
--
2.39.1
C
[PATCH v2 21/39] gnu: Add ocaml-sexp-pretty.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-22-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-sexp-pretty): New variable.
---
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 d6ecc92605..c00a8a8af3 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -6150,6 +6150,29 @@ (define-public ocaml4.07-sexplib
"0ksx62zsxhz8xmdrsn41n2hbc2qbyh3bxxc6946xisvgwh42h3q3"))
(properties '()))))
+(define-public ocaml-sexp-pretty
+ (package
+ (name "ocaml-sexp-pretty")
+ (version "0.15.1")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/janestreet/sexp_pretty")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "08z9jpvgag5f029ns0a06lcdymg00vwi232xsy1rdv82zvc0x4ah"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-base ocaml-ppx-base ocaml-sexplib ocaml-re))
+ (properties `((upstream-name . "sexp_pretty")))
+ (home-page "https://github.com/janestreet/sexp_pretty")
+ (synopsis "S-expression pretty-printer")
+ (description
+ "Library for pretty-printing s-expressions, using better indentation
+rules than the default pretty printer in Sexplib.")
+ (license license:expat)))
+
(define-public ocaml-base
(package
(name "ocaml-base")
--
2.39.1
C
[PATCH v2 22/39] gnu: Add ocaml-expect-test-helpers-core.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-23-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-expect-test-helpers-core): New variable.
---
gnu/packages/ocaml.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)

Toggle diff (41 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index c00a8a8af3..671e8bc355 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -2636,6 +2636,34 @@ (define-public ocaml4.07-alcotest
`(#:package "alcotest"))
(properties '()))))
+(define-public ocaml-expect-test-helpers-core
+ (package
+ (name "ocaml-expect-test-helpers-core")
+ (version "0.15.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url
+ "https://github.com/janestreet/expect_test_helpers_core")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0bxs3g0zzym8agfcbpg5lmrh6hcb86z861bq40xhhfwqf4pzdbfa"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-base
+ ocaml-base-quickcheck
+ ocaml-core
+ ocaml-ppx-jane
+ ocaml-sexp-pretty
+ ocaml-stdio
+ ocaml-re))
+ (properties `((upstream-name . "expect_test_helpers_core")))
+ (home-page "https://github.com/janestreet/expect_test_helpers_core")
+ (synopsis "Helpers for writing expectation tests")
+ (description "Helper functions for writing expect tests.")
+ (license license:expat)))
+
(define-public ocaml-ppx-tools
(package
(name "ocaml-ppx-tools")
--
2.39.1
C
[PATCH v2 23/39] gnu: Add ocaml-intrinsics.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-24-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-intrinsics): New variable.
---
gnu/packages/ocaml.scm | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)

Toggle diff (42 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 671e8bc355..cb3d5594eb 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -9221,6 +9221,35 @@ (define-public ocaml-bigstringaf
these missing pieces.")
(license license:bsd-3)))
+(define-public ocaml-intrinsics
+ (package
+ (name "ocaml-intrinsics")
+ (version "0.15.2")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/janestreet/ocaml_intrinsics")
+ (commit (string-append "v" version))))
+ (file-name name)
+ (sha256
+ (base32
+ "1mazr1ka2zlm2s8bw5i555cnhi1bmr9yxvpn29d3v4m8lsnfm73z"))))
+ (build-system dune-build-system)
+ ;; TODO figure out how to get around this error:
+ ;; No rule found for alias test/runtime-deps-of-tests
+ (arguments
+ '(#:tests? #f))
+ (propagated-inputs (list dune-configurator))
+ (native-inputs (list ocaml-expect-test-helpers-core ocaml-core))
+ (properties `((upstream-name . "ocaml_intrinsics")))
+ (home-page "https://github.com/janestreet/ocaml_intrinsics")
+ (synopsis "AMD64 intrinsics with emulated fallbacks")
+ (description
+ "Provides an OCaml interface to operations that have dedicated hardware
+instructions on some micro-architectures, with default implementations using C
+stubs for all targets.")
+ (license license:expat)))
+
(define-public ocaml-trie
(package
(name "ocaml-trie")
--
2.39.1
C
[PATCH v2 28/39] gnu: Add ocaml-textutils.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-29-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-textutils): New variable.
---
gnu/packages/ocaml.scm | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)

Toggle diff (39 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 789aaf48f9..8e313d74bb 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8464,6 +8464,32 @@ (define-public ocaml-textutils-kernel
javascript.")
(license license:expat)))
+(define-public ocaml-textutils
+ (package
+ (name "ocaml-textutils")
+ (version "0.15.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/janestreet/textutils")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1wass49h645wql9b7nck2iqlkf4648dkxvlvxixr7z80zcnb5rxr"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-core
+ ocaml-core-kernel
+ ocaml-core-unix
+ ocaml-ppx-jane
+ ocaml-textutils-kernel
+ ocaml-uutf))
+ (home-page "https://github.com/janestreet/textutils")
+ (synopsis "Text output utilities")
+ (description
+ "Utilities for working with terminal output, such as color printing.")
+ (license license:expat)))
+
(define-public ocaml-timezone
(package
(name "ocaml-timezone")
--
2.39.1
C
[PATCH v2 24/39] gnu: Add ocaml-core-unix.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-25-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-core-unix): New variable.
---
gnu/packages/ocaml.scm | 32 ++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)

Toggle diff (45 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index cb3d5594eb..157ef250cd 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8359,6 +8359,38 @@ (define-public ocaml4.07-core-kernel
;; MLton and sjs
license:expat)))))
+(define-public ocaml-core-unix
+ (package
+ (name "ocaml-core-unix")
+ (version "0.15.2")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/janestreet/core_unix")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0h6lqaxpp4r06a63k8yr0g9y7wc8r35v2xzqgvkiiq1ypa48zzgm"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-core
+ ocaml-core-kernel
+ ocaml-expect-test-helpers-core
+ ocaml-jane-street-headers
+ ocaml-jst-config
+ ocaml-intrinsics
+ ocaml-ppx-jane
+ ocaml-sexplib
+ ocaml-timezone
+ ocaml-spawn))
+ (properties `((upstream-name . "core_unix")))
+ (home-page "https://github.com/janestreet/core_unix")
+ (synopsis "Unix-specific portions of Core")
+ (description
+ "Unix-specific extensions to some of the modules defined in core and
+core_kernel.")
+ (license license:expat)))
+
(define-public ocaml-timezone
(package
(name "ocaml-timezone")
--
2.39.1
C
[PATCH v2 25/39] gnu: Add ocaml-async-kernel.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-26-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-async-kernel): New variable.
---
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 157ef250cd..ea7967e72d 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8391,6 +8391,30 @@ (define-public ocaml-core-unix
core_kernel.")
(license license:expat)))
+(define-public ocaml-async-kernel
+ (package
+ (name "ocaml-async-kernel")
+ (version "0.15.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/janestreet/async_kernel")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "01if6c8l2h64v7sk56xr8acnmj6g9whxcjrzzzvczspq88hq2bfh"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-core ocaml-core-kernel ocaml-ppx-jane))
+ (properties `((upstream-name . "async_kernel")))
+ (home-page "https://github.com/janestreet/async_kernel")
+ (synopsis "Monadic concurrency library")
+ (description
+ "Contains @code{Async}'s core data structures, like
+@code{Deferred}. @code{Async_kernel} is portable, and so can be used in
+JavaScript using @code{Async_js}.")
+ (license license:expat)))
+
(define-public ocaml-timezone
(package
(name "ocaml-timezone")
--
2.39.1
C
[PATCH v2 26/39] gnu: Add ocaml-async-unix.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-27-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-async-unix): New variable.
---
gnu/packages/ocaml.scm | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)

Toggle diff (39 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index ea7967e72d..ed70c1e08a 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8415,6 +8415,32 @@ (define-public ocaml-async-kernel
JavaScript using @code{Async_js}.")
(license license:expat)))
+(define-public ocaml-async-unix
+ (package
+ (name "ocaml-async-unix")
+ (version "0.15.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/janestreet/async_unix")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0z4fgpn93iw0abd7l9kac28qgzgc5qr2x0s1n2zh49lsdn02n6ys"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-async-kernel ocaml-core ocaml-core-kernel
+ ocaml-core-unix ocaml-ppx-jane))
+ (properties `((upstream-name . "async_unix")))
+ (home-page "https://github.com/janestreet/async_unix")
+ (synopsis "Monadic concurrency library")
+ (description
+ "Unix-related dependencies for things like system calls and
+threads. Using these, it hooks the Async_kernel scheduler up to either epoll
+or select, depending on availability, and manages a thread pool that blocking
+system calls run in.")
+ (license license:expat)))
+
(define-public ocaml-timezone
(package
(name "ocaml-timezone")
--
2.39.1
C
[PATCH v2 31/39] gnu: Add ocaml-async.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-32-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-async): New variable.
---
gnu/packages/ocaml.scm | 35 +++++++++++++++++++++++++++++++++++
1 file changed, 35 insertions(+)

Toggle diff (48 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index cda38dc381..852c9f6f6f 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8492,6 +8492,41 @@ (define-public ocaml-async-rpc-kernel
JavaScript.")
(license license:expat)))
+(define-public ocaml-async
+ (package
+ (name "ocaml-async")
+ (version "0.15.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/janestreet/async")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0pykmnsil754jsnr8gss91ykyjvivngx4ii0ih3nsg1x2jl9xmy2"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-async-kernel
+ ocaml-async-rpc-kernel
+ ocaml-async-unix
+ ocaml-core
+ ocaml-core-kernel
+ ocaml-core-unix
+ ocaml-ppx-jane
+ ocaml-ppx-log
+ ocaml-textutils))
+ ;; TODO one test dependency is deprecated, the other is nowhere to be found
+ (arguments
+ '(#:tests? #f))
+ ;; (native-inputs (list ocaml-netkit-sockets ocaml-qtest-deprecated))
+ (home-page "https://github.com/janestreet/async")
+ (synopsis "Asynchronous execution library")
+ (description
+ "Library for asynchronous programming, i.e., programming where some part
+of the program must wait for things that happen at times determined by some
+external entity (like a human or another program).")
+ (license license:expat)))
+
(define-public ocaml-textutils-kernel
(package
(name "ocaml-textutils-kernel")
--
2.39.1
C
[PATCH v2 27/39] gnu: Add ocaml-textutils-kernel.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-28-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-textutils-kernel): New variable.
---
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 ed70c1e08a..789aaf48f9 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8441,6 +8441,29 @@ (define-public ocaml-async-unix
system calls run in.")
(license license:expat)))
+(define-public ocaml-textutils-kernel
+ (package
+ (name "ocaml-textutils-kernel")
+ (version "0.15.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/janestreet/textutils_kernel")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "068g11d98wsb5a6ds0p5xybdmx5nx9bxa0k11dmh3l57kn4c169x"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-core ocaml-ppx-jane ocaml-uutf))
+ (properties `((upstream-name . "textutils_kernel")))
+ (home-page "https://github.com/janestreet/textutils_kernel")
+ (synopsis "Text output utilities")
+ (description
+ "The subset of textutils using only core_kernel and working in
+javascript.")
+ (license license:expat)))
+
(define-public ocaml-timezone
(package
(name "ocaml-timezone")
--
2.39.1
C
[PATCH v2 32/39] gnu: Add ocaml-shared-memory-ring.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-33-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-shared-memory-ring): New variable.
---
gnu/packages/ocaml.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)

Toggle diff (41 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 852c9f6f6f..8d9d2c50c6 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3017,6 +3017,34 @@ (define-public ocaml-lwt-dllist
doubly-linked list with Lwt iterators.")
(license license:expat)))
+
+(define-public ocaml-shared-memory-ring
+ (package
+ (name "ocaml-shared-memory-ring")
+ (version "3.1.1")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/shared-memory-ring")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "12cpbia39aifnd8rxpsra0lhssqj5qw0zygb5fd8kg58zy2clmrr"))))
+ (build-system dune-build-system)
+ (arguments
+ '(#:package "shared-memory-ring"))
+ (propagated-inputs (list ocaml-cstruct ocaml-ppx-cstruct ocaml-lwt-dllist
+ ocaml-mirage-profile))
+ (native-inputs (list ocaml-ounit))
+ (home-page "https://github.com/mirage/shared-memory-ring")
+ (synopsis "Xen-style shared memory rings")
+ (description
+ "Libraries for creating shared memory producer/consumer rings. The rings
+follow the Xen ABI and may be used to create or implement Xen virtual
+devices.")
+ (license license:isc)))
+
(define-public ocaml-luv
(package
(name "ocaml-luv")
--
2.39.1
C
[PATCH v2 33/39] gnu: Add ocaml-shared-memory-ring-lwt.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-34-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-shared-memory-ring-lwt): New variable.
---
gnu/packages/ocaml.scm | 10 ++++++++++
1 file changed, 10 insertions(+)

Toggle diff (23 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 8d9d2c50c6..f3911261a8 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3045,6 +3045,16 @@ (define-public ocaml-shared-memory-ring
devices.")
(license license:isc)))
+(define-public ocaml-shared-memory-ring-lwt
+ (package
+ (inherit ocaml-shared-memory-ring)
+ (name "ocaml-shared-memory-ring-lwt")
+ (arguments
+ '(#:package "shared-memory-ring-lwt"))
+ (propagated-inputs (modify-inputs (package-propagated-inputs
+ ocaml-shared-memory-ring)
+ (append ocaml-shared-memory-ring)))))
+
(define-public ocaml-luv
(package
(name "ocaml-luv")
--
2.39.1
C
[PATCH v2 29/39] gnu: Add ocaml-protocol-version-header.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-30-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-protocol-version-header): New variable.
---
gnu/packages/ocaml.scm | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)

Toggle diff (39 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 8e313d74bb..86c22f500c 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -6867,6 +6867,32 @@ (define-public ocaml4.07-bin-prot
license:asl2.0
license:bsd-3)))))
+(define-public ocaml-protocol-version-header
+ (package
+ (name "ocaml-protocol-version-header")
+ (version "0.15.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url
+ "https://github.com/janestreet/protocol_version_header")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0s638cwf1357gg754rc4306654hhrhzqaqm2lp3yv5vj3ml8p4qy"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-core ocaml-ppx-jane))
+ (properties `((upstream-name . "protocol_version_header")))
+ (home-page "https://github.com/janestreet/protocol_version_header")
+ (synopsis "Protocol versioning")
+ (description
+ "This library offers a lightweight way for applications protocols to
+version themselves. The more protocols that add themselves to
+@code{Known_protocol}, the nicer error messages we will get when connecting to
+a service while using the wrong protocol.")
+ (license license:expat)))
+
(define-public ocaml-octavius
(package
(name "ocaml-octavius")
--
2.39.1
C
[PATCH v2 30/39] gnu: Add ocaml-async-rpc-kernel.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-31-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-async-rpc-kernel): New variable.
---
gnu/packages/ocaml.scm | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)

Toggle diff (38 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 86c22f500c..cda38dc381 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -8467,6 +8467,31 @@ (define-public ocaml-async-unix
system calls run in.")
(license license:expat)))
+(define-public ocaml-async-rpc-kernel
+ (package
+ (name "ocaml-async-rpc-kernel")
+ (version "0.15.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/janestreet/async_rpc_kernel")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1b5rp5yam03ir4f1sixpzjg1zdqmkb7lvnaa82kac4fzk80gfrfr"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-async-kernel ocaml-core ocaml-ppx-jane
+ ocaml-protocol-version-header))
+ (properties `((upstream-name . "async_rpc_kernel")))
+ (home-page "https://github.com/janestreet/async_rpc_kernel")
+ (synopsis "Platform-independent core of Async RPC library")
+ (description
+ "Library for building RPC-style protocols. This library is the portable
+part of the Unix-oriented Async_rpc library, and is actively used in
+JavaScript.")
+ (license license:expat)))
+
(define-public ocaml-textutils-kernel
(package
(name "ocaml-textutils-kernel")
--
2.39.1
C
[PATCH v2 34/39] gnu: Add ocaml-xenstore.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-35-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-xenstore): New variable.
---
gnu/packages/ocaml.scm | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)

Toggle diff (42 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index f3911261a8..e4ab3977a0 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3055,6 +3055,35 @@ (define-public ocaml-shared-memory-ring-lwt
ocaml-shared-memory-ring)
(append ocaml-shared-memory-ring)))))
+(define-public ocaml-xenstore
+ (package
+ (name "ocaml-xenstore")
+ (version "2.2.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/ocaml-xenstore")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1acld5gxmvnhl5iyyy5ancpm7fv9d6ns1x32krcmb62p2czd00ky"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-cstruct ocaml-ppx-cstruct ocaml-lwt))
+ (native-inputs (list ocaml-ounit2))
+ (home-page "https://github.com/mirage/ocaml-xenstore")
+ (synopsis "Xenstore protocol in pure OCaml")
+ (description "Repository contents:
+@itemize
+@item client library, a merge of the Mirage and XCP ones
+@item server library
+@item server instance which runs under Unix with libxc
+@item server instance which runs on mirage.
+@end itemize
+The client and the server libraries have sets of unit-tests.")
+ ;; Has a linking exception, see LICENSE.md.
+ (license license:lgpl2.1)))
+
(define-public ocaml-luv
(package
(name "ocaml-luv")
--
2.39.1
C
[PATCH v2 35/39] gnu: Add ocaml-io-page.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-36-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-io-page): New variable.
---
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 e4ab3977a0..737f2cd8e8 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3084,6 +3084,29 @@ (define-public ocaml-xenstore
;; Has a linking exception, see LICENSE.md.
(license license:lgpl2.1)))
+(define-public ocaml-io-page
+ (package
+ (name "ocaml-io-page")
+ (version "3.0.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/io-page")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0lmvm1whdw5s7rvi7jnjzicrp2j919dkjl856jwyjlq38f7qn0zm"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-cstruct))
+ (native-inputs (list pkg-config ocaml-ounit))
+ (home-page "https://github.com/mirage/io-page")
+ (synopsis "Support for efficient handling of I/O memory pages")
+ (description
+ "IO pages are page-aligned, and wrapped in the @code{Cstruct} library to
+avoid copying the data contained within the page.")
+ (license license:isc)))
+
(define-public ocaml-luv
(package
(name "ocaml-luv")
--
2.39.1
C
[PATCH v2 36/39] gnu: Add ocaml-bheap.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-37-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-bheap): New variable.
---
gnu/packages/ocaml.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)

Toggle diff (35 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 737f2cd8e8..0aca8a1c83 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3107,6 +3107,28 @@ (define-public ocaml-io-page
avoid copying the data contained within the page.")
(license license:isc)))
+(define-public ocaml-bheap
+ (package
+ (name "ocaml-bheap")
+ (version "2.0.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/backtracking/bheap")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0b8md5zl4yz7j62jz0bf7lwyl0pyqkxqx36ghkgkbkxb4zzggfj1"))))
+ (build-system dune-build-system)
+ (native-inputs (list ocaml-stdlib-shims))
+ (home-page "https://github.com/backtracking/bheap")
+ (synopsis "Priority queues")
+ (description
+ "Traditional implementation of priority queues using a binary heap
+encoded in a resizable array.")
+ (license license:lgpl2.1)))
+
(define-public ocaml-luv
(package
(name "ocaml-luv")
--
2.39.1
C
[PATCH v2 37/39] gnu: Add ocaml-mirage-xen.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-38-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-xen): New variable.
---
gnu/packages/ocaml.scm | 34 ++++++++++++++++++++++++++++++++++
1 file changed, 34 insertions(+)

Toggle diff (47 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 0aca8a1c83..be088cf60d 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3084,6 +3084,40 @@ (define-public ocaml-xenstore
;; Has a linking exception, see LICENSE.md.
(license license:lgpl2.1)))
+(define-public ocaml-mirage-xen
+ (package
+ (name "ocaml-mirage-xen")
+ (version "8.0.1")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/mirage-xen")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1qydg92dbw8hj4b809apj0f51cjgmamq3zdf34a4wyn5jv85yzyx"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-cstruct
+ ocaml-lwt
+ ocaml-shared-memory-ring-lwt
+ ocaml-xenstore
+ ocaml-lwt-dllist
+ ;; ocaml-mirage-profile dependency cycle
+ ocaml-io-page
+ ocaml-mirage-runtime
+ ocaml-logs
+ ocaml-fmt
+ ocaml-bheap
+ ocaml-duration))
+ (home-page "https://github.com/mirage/mirage-xen")
+ (synopsis "Xen core platform libraries for MirageOS")
+ (description
+ "MirageOS OS library for Xen targets, which handles the main
+loop and timers. It also provides the low level C startup code and C stubs
+required by the OCaml code.")
+ (license license:isc)))
+
(define-public ocaml-io-page
(package
(name "ocaml-io-page")
--
2.39.1
C
[PATCH v2 38/39] gnu: Add ocaml-parse-argv.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-39-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-parse-argv): New variable.
---
gnu/packages/ocaml.scm | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)

Toggle diff (34 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index be088cf60d..545d15974a 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3854,6 +3854,27 @@ (define-public ocaml-emile
according RFC2047.")
(license license:expat)))
+(define-public ocaml-parse-argv
+ (package
+ (name "ocaml-parse-argv")
+ (version "0.2.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/parse-argv")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "16n18zik6vkfnhv8jaigr90fwp1ykg23p61aqchym0jil4i4yq01"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-astring))
+ (native-inputs (list ocaml-ounit))
+ (home-page "https://github.com/mirage/parse-argv")
+ (synopsis "Process strings into sets of command-line arguments")
+ (description "Small implementation of a simple argv parser.")
+ (license license:isc)))
+
(define-public ocaml-functoria-runtime
(package
(name "ocaml-functoria-runtime")
--
2.39.1
C
[PATCH v2 39/39] gnu: Add ocaml-mirage-bootvar-unix.
(address . 60673@debbugs.gnu.org)(name . raingloom)(address . raingloom@riseup.net)
20230215220028.18575-40-raingloom@riseup.net
From: raingloom <raingloom@riseup.net>

* gnu/packages/ocaml.scm (ocaml-mirage-bootvar-unix): New variable.
---
gnu/packages/ocaml.scm | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)

Toggle diff (33 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 545d15974a..374eeeb57f 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -3978,6 +3978,26 @@ (define-public ocaml-mirage
a fully-standalone, specialised unikernel.")
(license license:isc)))
+(define-public ocaml-mirage-bootvar-unix
+ (package
+ (name "ocaml-mirage-bootvar-unix")
+ (version "0.1.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/mirage-bootvar-unix")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1vi13q0z5ffv5hf4q5lfvkia6j2s5520px0s2x4dbjgd52icizrz"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-lwt ocaml-parse-argv))
+ (home-page "https://github.com/mirage/mirage-bootvar-unix")
+ (synopsis "Unix implementation of MirageOS Bootvar interface")
+ (description "Library for passing boot parameters from Solo5 to MirageOS.")
+ (license license:isc)))
+
(define-public ocaml-duration
(package
(name "ocaml-duration")
--
2.39.1
C
Re: [bug#60673] [PATCH 01/39] gnu: Add ocaml-domain-name.
(name . Christopher Baines)(address . mail@cbaines.net)
87sff5t84l.fsf@riseup.net
Christopher Baines <mail@cbaines.net> writes:

Toggle quote (39 lines)
> [[PGP Signed Part:Undecided]]
>
> Csepp <raingloom@riseup.net> writes:
>
>> Christopher Baines <mail@cbaines.net> writes:
>>
>>> [[PGP Signed Part:Undecided]]
>>> Hey,
>>>
>>> While I think the builds look OK for this series, there are quite a few
>>> formatting issues raised by the linter (this can be seen on [1] and [2]).
>>>
>>> 1: https://qa.guix.gnu.org/issue/60674
>>> 2:
>>> https://data.qa.guix.gnu.org/compare?base_commit=238f965c331990459a69cbc713ca951ad40e6044&target_commit=3b5485b9cdaebda127dc040ad67a287f39e33519
>>>
>>> Could you run the linter on the packages you've added here, address the
>>> issues it raises and send an updated series?
>>>
>>> Thanks,
>>>
>>> Chris
>>>
>>> [[End of PGP Signed Part]]
>>
>> Those are all URL constants, can't really do much about them other than slice
>> them up with string-append, which I'm not sure really helps with
>> readability or ease of editing. They were not an issue while I was
>> editing the code and gnu/packages/ocaml.scm already has a lot of lines
>> that whitespace-mode highlights as too long, so I thought it wouldn't
>> matter much and my time would be better spent elsewhere.
>
> You're right that there are quite a few other instances of lines that
> are too long in that module, but I don't think that's a reason not to
> add more. I think splitting the long URL strings with string-append is a
> good approach and can help with readability.
>
> [[End of PGP Signed Part]]

Alright, got around to sending the updated patch series. Hopefully I
got the send-email arguments right.
J
J
Julien Lepiller wrote on 17 Feb 2023 07:41
B6DDEC9E-8436-4564-8583-A47000388E14@lepiller.eu
https://qa.guix.gnu.org/issue/60673has picked it up at least :). We still need to wait for a few builds.

Le 17 février 2023 02:03:46 GMT+01:00, Csepp <raingloom@riseup.net> a écrit :
Toggle quote (47 lines)
>
>Christopher Baines <mail@cbaines.net> writes:
>
>> [[PGP Signed Part:Undecided]]
>>
>> Csepp <raingloom@riseup.net> writes:
>>
>>> Christopher Baines <mail@cbaines.net> writes:
>>>
>>>> [[PGP Signed Part:Undecided]]
>>>> Hey,
>>>>
>>>> While I think the builds look OK for this series, there are quite a few
>>>> formatting issues raised by the linter (this can be seen on [1] and [2]).
>>>>
>>>> 1: https://qa.guix.gnu.org/issue/60674
>>>> 2:
>>>> https://data.qa.guix.gnu.org/compare?base_commit=238f965c331990459a69cbc713ca951ad40e6044&target_commit=3b5485b9cdaebda127dc040ad67a287f39e33519
>>>>
>>>> Could you run the linter on the packages you've added here, address the
>>>> issues it raises and send an updated series?
>>>>
>>>> Thanks,
>>>>
>>>> Chris
>>>>
>>>> [[End of PGP Signed Part]]
>>>
>>> Those are all URL constants, can't really do much about them other than slice
>>> them up with string-append, which I'm not sure really helps with
>>> readability or ease of editing. They were not an issue while I was
>>> editing the code and gnu/packages/ocaml.scm already has a lot of lines
>>> that whitespace-mode highlights as too long, so I thought it wouldn't
>>> matter much and my time would be better spent elsewhere.
>>
>> You're right that there are quite a few other instances of lines that
>> are too long in that module, but I don't think that's a reason not to
>> add more. I think splitting the long URL strings with string-append is a
>> good approach and can help with readability.
>>
>> [[End of PGP Signed Part]]
>
>Alright, got around to sending the updated patch series. Hopefully I
>got the send-email arguments right.
>
>
>
C
C
Christopher Baines wrote on 17 Feb 2023 16:50
(address . raingloom@riseup.net)
873574mgrg.fsf@cbaines.net
Julien Lepiller <julien@lepiller.eu> writes:

Toggle quote (3 lines)
> https://qa.guix.gnu.org/issue/60673has picked it up at least :). We
> still need to wait for a few builds.

Everything looks to have built on x86_64-linux and aarch64-linux, plus
there are no introduced lint warnings now (for the checkers the data
service runs at least), so I've gone ahead and pushed these patches to
master as 48724a66422e02995e62e2f707dcd9087d43bee5.

Thanks,

Chris
-----BEGIN PGP SIGNATURE-----

iQKlBAEBCgCPFiEEPonu50WOcg2XVOCyXiijOwuE9XcFAmPvoqNfFIAAAAAALgAo
aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF
ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcRHG1haWxAY2Jh
aW5lcy5uZXQACgkQXiijOwuE9Xf6FQ//e5elecmw4od0ECnK0GRC0HofnXJSJlGD
hkxuCBWZo+AIVPq3GRHDfbVwrl3BV/yH4PaV2d3pD47ihHGr5y3BQgmLYdMyTucd
beOl3vSLwGZxkAHNit6vkL+JNOyL/eTgi7ki/NN3bZMtmOYu0+5mlDmCrhDsvfuM
zgt4uHf25gNkN6iswDNODuVeoi77vATPxu17TwDEeGPmj2/tpJb32FGbkHJgg4FJ
aVpVjvCM6mjNmaU2l8BESq3FIRJpppiCx66QCBKL/DO8quAMSC/15zhAyr6t+R2t
eca4EjFYIOQcv54uofGtPPl8du7jAG2ZokM9zzJ/qBWxZz6m77k9D4s4vJt4K5xD
ssGD4HLOMB/OpsFyrxtch2GmICt5Of35QY8JDrDxOdQE0ZhVZlt1FzFu+0gLZPXt
69UmsPi6sshXfw1FmjQL6Ek3PCzj6KLm875DLUVaMfGdniYoxvGRe5HL71TpvZOj
sqiX1L64QZnmLkQFkR45URDnEdFZ+dyj0vScLO6dYQWmVzRtf3L28LReDuOGS7pT
0RWp9EPh4OJl/MCG0lYSgjO5satUw8B1w2R30wO89NTDaMWWrSxT6T+cCPw6fSBu
oZh7o2ZEvQoTH5ZI7e/9AkmWpn9plylSYgDuFBhytQ/wFHj1trdEI+faFTtUondu
3UQKlqcOkv0=
=6Tl0
-----END PGP SIGNATURE-----

?
Your comment

This issue is archived.

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

To respond to this issue using the mumi CLI, first switch to it
mumi current 60673
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