summary refs log tree commit diff
path: root/gnu/packages/ocaml.scm
diff options
context:
space:
mode:
authorJulien Lepiller <julien@lepiller.eu>2019-02-01 17:35:10 +0100
committerJulien Lepiller <julien@lepiller.eu>2019-02-05 22:33:31 +0100
commita0584d6c9758456930e243e7e16dd2472d51ddf5 (patch)
treef5ca4baa7da66dfc7f9effdeb4cd5893147bea49 /gnu/packages/ocaml.scm
parente6f08ec93a0c33406f9b4a006b1e5153d0788d67 (diff)
downloadguix-a0584d6c9758456930e243e7e16dd2472d51ddf5.tar.gz
gnu: Add ocaml-bin-prot.
* gnu/packages/ocaml.scm (ocaml-bin-prot): New variable.
Diffstat (limited to 'gnu/packages/ocaml.scm')
-rw-r--r--gnu/packages/ocaml.scm34
1 files changed, 34 insertions, 0 deletions
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 1fcf119de0..7887058349 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -5354,3 +5354,37 @@ variant types.")
     (description "Extensions to printf-style format-strings for user-defined
 string conversion.")
     (license license:asl2.0)))
+
+(define-public ocaml-bin-prot
+  (package
+    (name "ocaml-bin-prot")
+    (version "0.11.0")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
+                                  (version-major+minor version)
+                                  "/files/bin_prot-v" version ".tar.gz"))
+              (sha256
+               (base32
+                "1rsd91gx36prj4whi76nsiz1bzpgal9nzyw3pxdz1alv4ilk2il6"))))
+    (build-system dune-build-system)
+    (inputs
+      `(("ocaml-base" ,ocaml-base)
+        ("ocaml-ppx-compare" ,ocaml-ppx-compare)
+        ("ocaml-ppx-custom-printf" ,ocaml-ppx-custom-printf)
+        ("ocaml-ppx-fields-conv" ,ocaml-ppx-fields-conv)
+        ("ocaml-ppx-sexp-conv" ,ocaml-ppx-sexp-conv)
+        ("ocaml-ppx-variants-conv" ,ocaml-ppx-variants-conv)
+        ("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree)))
+    (properties `((upstream-name . "bin_prot")))
+    (home-page "https://github.com/janestreet/bin_prot")
+    (synopsis "Binary protocol generator")
+    (description "This library contains functionality for reading and writing
+OCaml-values in a type-safe binary protocol.  It is extremely efficient,
+typically supporting type-safe marshalling and unmarshalling of even highly
+structured values at speeds sufficient to saturate a gigabit connection.  The
+protocol is also heavily optimized for size, making it ideal for long-term
+storage of large amounts of data.")
+    (license (list
+               license:asl2.0
+               license:bsd-3))))