diff mbox series

[bug#49867,09/29] gnu: Add ocaml-eqaf.

Message ID 20210804071545.21181-9-pukkamustard@posteo.net
State Accepted
Headers show
Series gnu: Add ocaml-cohttp-lwt-unix. | expand

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git branch success View Git branch
cbaines/applying patch success View Laminar job
cbaines/issue success View issue

Commit Message

pukkamustard Aug. 4, 2021, 7:15 a.m. UTC
* gnu/packages/ocaml.scm (ocaml-eqaf): New variable.
---
 gnu/packages/ocaml.scm | 33 +++++++++++++++++++++++++++++++++
 1 file changed, 33 insertions(+)
diff mbox series

Patch

diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index c29a272214..04240b560b 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -7328,6 +7328,39 @@  establishing TCP and SSL/TLS connections from @code{ocaml-conduit} using
 @code{ocaml-lwt}.")
     (license license:isc)))
 
+(define-public ocaml-eqaf
+  (package
+    (name "ocaml-eqaf")
+    (version "0.7")
+    (home-page "https://github.com/mirage/eqaf")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url home-page)
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "06hsnnjax1kb3qsi3cj0nyyz8c2hj2gbw3h517gpjinpnwy2fr85"))))
+    (build-system dune-build-system)
+    (arguments
+     ;; Tests require ocaml-crowbar which depends on
+     ;; ocaml-afl-persistent. ocaml-afl-persistent uses a non-standard build system
+     ;; and I have not yet managed to build it with Guix. There is an on-going effort
+     ;; to port the build system to dune
+     ;; (https://github.com/stedolan/ocaml-afl-persistent/pull/7). With that it should
+     ;; be easy to add ocaml-afl-persistent and ocaml-crowbar and enable these tests.
+     `(#:tests? #f))
+    (propagated-inputs
+     ;; required to build the eqaf.cstruct library (see https://github.com/mirage/eqaf/pull/27)
+     `(("ocaml-bigarray-compat" ,ocaml-bigarray-compat)
+       ("ocaml-cstruct" ,ocaml-cstruct)))
+    (synopsis "OCaml library for constant-time equal function on string")
+    (description "This OCaml library provides an equal function on string in
+constant-time to avoid timing-attack with crypto stuff.")
+    (license license:expat)))
+
 (define-public js-of-ocaml
   (package
     (name "js-of-ocaml")