From d6dfd173f93c8cb48e250627ac967cfca10385e1 Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Sat, 21 Nov 2020 09:01:01 +0100 Subject: [PATCH] =?UTF-8?q?ocamlPackages.rpclib:=207.0.0=20=E2=86=92=208.0?= =?UTF-8?q?.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ppx_deriving_rpc/default.nix | 11 ++++++---- .../ocaml-modules/rpclib/default.nix | 22 ++++++++++--------- pkgs/top-level/ocaml-packages.nix | 4 +--- 3 files changed, 20 insertions(+), 17 deletions(-) diff --git a/pkgs/development/ocaml-modules/ppx_deriving_rpc/default.nix b/pkgs/development/ocaml-modules/ppx_deriving_rpc/default.nix index 92d73e540f48..b7d1986c30d4 100644 --- a/pkgs/development/ocaml-modules/ppx_deriving_rpc/default.nix +++ b/pkgs/development/ocaml-modules/ppx_deriving_rpc/default.nix @@ -1,13 +1,16 @@ -{ lib, buildDunePackage, rpclib, ppxlib, ppx_deriving }: +{ lib, buildDunePackage, rpclib, alcotest, ppxlib, ppx_deriving, yojson }: buildDunePackage rec { pname = "ppx_deriving_rpc"; - inherit (rpclib) version src; + inherit (rpclib) version useDune2 src; - buildInputs = [ ppxlib ]; + minimumOCamlVersion = "4.08"; - propagatedBuildInputs = [ rpclib ppx_deriving ]; + propagatedBuildInputs = [ ppxlib rpclib ppx_deriving ]; + + checkInputs = [ alcotest yojson ]; + doCheck = true; meta = with lib; { homepage = "https://github.com/mirage/ocaml-rpc"; diff --git a/pkgs/development/ocaml-modules/rpclib/default.nix b/pkgs/development/ocaml-modules/rpclib/default.nix index 9216a489248b..53b559257bec 100644 --- a/pkgs/development/ocaml-modules/rpclib/default.nix +++ b/pkgs/development/ocaml-modules/rpclib/default.nix @@ -1,20 +1,22 @@ -{ lib, fetchFromGitHub, buildDunePackage, alcotest, cmdliner, rresult, result, xmlm, yojson }: +{ lib, fetchurl, buildDunePackage +, alcotest +, base64, cmdliner, rresult, xmlm, yojson +}: buildDunePackage rec { pname = "rpclib"; - version = "7.0.0"; + version = "8.0.0"; - minimumOCamlVersion = "4.04"; + useDune2 = true; - src = fetchFromGitHub { - owner = "mirage"; - repo = "ocaml-rpc"; - rev = "v${version}"; - sha256 = "0d8nb272mjxkq5ddn65cy9gjpa8yvd0v3jv3wp5xfh9gj29wd2jj"; + src = fetchurl { + url = "https://github.com/mirage/ocaml-rpc/releases/download/v${version}/rpclib-v${version}.tbz"; + sha256 = "1kqbixk4d9y15ns566fiyzid5jszkamm1kv7iks71invv33v7krz"; }; - buildInputs = [ alcotest cmdliner yojson ]; - propagatedBuildInputs = [ rresult result xmlm ]; + buildInputs = [ cmdliner yojson ]; + propagatedBuildInputs = [ base64 rresult xmlm ]; + checkInputs = [ alcotest ]; doCheck = true; diff --git a/pkgs/top-level/ocaml-packages.nix b/pkgs/top-level/ocaml-packages.nix index 5e4f350099a6..316666ca6d8d 100644 --- a/pkgs/top-level/ocaml-packages.nix +++ b/pkgs/top-level/ocaml-packages.nix @@ -878,9 +878,7 @@ let ppx_deriving_protobuf = callPackage ../development/ocaml-modules/ppx_deriving_protobuf {}; - ppx_deriving_rpc = callPackage ../development/ocaml-modules/ppx_deriving_rpc { - ppxlib = ppxlib.override { legacy = true; }; - }; + ppx_deriving_rpc = callPackage ../development/ocaml-modules/ppx_deriving_rpc { }; ppx_deriving_yojson = callPackage ../development/ocaml-modules/ppx_deriving_yojson {};