diff options
Diffstat (limited to 'pkgs/development/ocaml-modules/zmq')
-rw-r--r-- | pkgs/development/ocaml-modules/zmq/default.nix | 15 | ||||
-rw-r--r-- | pkgs/development/ocaml-modules/zmq/lwt.nix | 12 |
2 files changed, 9 insertions, 18 deletions
diff --git a/pkgs/development/ocaml-modules/zmq/default.nix b/pkgs/development/ocaml-modules/zmq/default.nix index a792877e0590a..fe6a17e876b60 100644 --- a/pkgs/development/ocaml-modules/zmq/default.nix +++ b/pkgs/development/ocaml-modules/zmq/default.nix @@ -1,8 +1,9 @@ -{ stdenv, fetchFromGitHub, ocaml, findlib, dune, czmq, stdint }: +{ stdenv, fetchFromGitHub, buildDunePackage, czmq, stdint }: -stdenv.mkDerivation rec { - name = "ocaml${ocaml.version}-zmq-${version}"; +buildDunePackage rec { + pname = "zmq"; version = "20180726"; + src = fetchFromGitHub { owner = "issuu"; repo = "ocaml-zmq"; @@ -14,19 +15,13 @@ stdenv.mkDerivation rec { ./ocaml-zmq-issue43.patch ]; - buildInputs = [ ocaml findlib dune czmq ]; - + buildInputs = [ czmq ]; propagatedBuildInputs = [ stdint ]; - buildPhase = "dune build -p zmq"; - - inherit (dune) installPhase; - meta = with stdenv.lib; { description = "ZeroMQ bindings for OCaml"; license = licenses.mit; maintainers = with maintainers; [ akavel ]; inherit (src.meta) homepage; - inherit (ocaml.meta) platforms; }; } diff --git a/pkgs/development/ocaml-modules/zmq/lwt.nix b/pkgs/development/ocaml-modules/zmq/lwt.nix index 80c934b44d64d..65595992e2c1e 100644 --- a/pkgs/development/ocaml-modules/zmq/lwt.nix +++ b/pkgs/development/ocaml-modules/zmq/lwt.nix @@ -1,12 +1,8 @@ -{ stdenv, ocaml, findlib, dune, zmq, ocaml_lwt }: +{ stdenv, buildDunePackage, zmq, ocaml_lwt }: -stdenv.mkDerivation rec { - name = "ocaml${ocaml.version}-zmq-lwt-${version}"; - inherit (zmq) version src installPhase meta; - - buildInputs = [ ocaml findlib dune ]; +buildDunePackage rec { + pname = "zmq-lwt"; + inherit (zmq) version src meta; propagatedBuildInputs = [ zmq ocaml_lwt ]; - - buildPhase = "dune build -p zmq-lwt"; } |