about summary refs log tree commit diff
path: root/pkgs/development/ocaml-modules
diff options
context:
space:
mode:
authorSamuel Leathers <disasm@gmail.com>2019-08-24 00:08:59 -0400
committerGitHub <noreply@github.com>2019-08-24 00:08:59 -0400
commit93c70cf07e76fc08078914c8dea5c032fc10cfd8 (patch)
tree63e106d32327de53efce33fde367a1035f89e98f /pkgs/development/ocaml-modules
parent765a71f15025ce78024bae3dc4a92bd2be3a8fbf (diff)
parent162266b972cfc643721cdfa4b673aa48250fc7ce (diff)
downloadnixlib-93c70cf07e76fc08078914c8dea5c032fc10cfd8.tar
nixlib-93c70cf07e76fc08078914c8dea5c032fc10cfd8.tar.gz
nixlib-93c70cf07e76fc08078914c8dea5c032fc10cfd8.tar.bz2
nixlib-93c70cf07e76fc08078914c8dea5c032fc10cfd8.tar.lz
nixlib-93c70cf07e76fc08078914c8dea5c032fc10cfd8.tar.xz
nixlib-93c70cf07e76fc08078914c8dea5c032fc10cfd8.tar.zst
nixlib-93c70cf07e76fc08078914c8dea5c032fc10cfd8.zip
Merge pull request #67322 from vbgl/ocaml-otr-0.3.6
ocamlPackages.otr: 0.3.4 -> 0.3.6
Diffstat (limited to 'pkgs/development/ocaml-modules')
-rw-r--r--pkgs/development/ocaml-modules/otr/default.nix29
1 files changed, 8 insertions, 21 deletions
diff --git a/pkgs/development/ocaml-modules/otr/default.nix b/pkgs/development/ocaml-modules/otr/default.nix
index ac853c94094b..caa2d01a4418 100644
--- a/pkgs/development/ocaml-modules/otr/default.nix
+++ b/pkgs/development/ocaml-modules/otr/default.nix
@@ -1,35 +1,22 @@
-{ stdenv, fetchFromGitHub, ocaml, ocamlbuild, findlib, topkg
-, ppx_tools, ppx_sexp_conv, cstruct, ppx_cstruct, sexplib, rresult, nocrypto
-, astring
+{ lib, fetchFromGitHub, buildDunePackage
+, cstruct, sexplib0, rresult, nocrypto, astring
 }:
 
-if !stdenv.lib.versionAtLeast ocaml.version "4.03"
-then throw "otr is not available for OCaml ${ocaml.version}"
-else
-
-stdenv.mkDerivation rec {
-  name = "ocaml${ocaml.version}-otr-${version}";
-  version = "0.3.4";
+buildDunePackage rec {
+  pname = "otr";
+  version = "0.3.6";
 
   src = fetchFromGitHub {
     owner  = "hannesm";
     repo   = "ocaml-otr";
     rev    = "${version}";
-    sha256 = "0ixf0jvccmcbhk5mhzqakfzimvz200wkdkq3z2d0bdzyggslbdl4";
+    sha256 = "0iz6p85a0jxng9aq9blqsky173zaqfr6wlc5j48ad55lgwzlbih5";
   };
 
-  buildInputs = [ ocaml ocamlbuild findlib topkg ppx_tools ppx_sexp_conv ppx_cstruct ];
-  propagatedBuildInputs = [ cstruct sexplib rresult nocrypto astring ];
-
-  buildPhase = "${topkg.run} build --tests true";
-
-  inherit (topkg) installPhase;
+  propagatedBuildInputs = [ cstruct sexplib0 rresult nocrypto astring ];
 
   doCheck = true;
-  checkPhase = "${topkg.run} test";
-
-  meta = with stdenv.lib; {
-    inherit (ocaml.meta) platforms;
+  meta = with lib; {
     homepage = https://github.com/hannesm/ocaml-otr;
     description = "Off-the-record messaging protocol, purely in OCaml";
     license = licenses.bsd2;