Unverified Commit b952554a authored by Fernando Rodrigues's avatar Fernando Rodrigues
Browse files

ocamlPackages.xenstore: drop cstruct dependency



Also begins fetching sources from git, instead of the release.

Signed-off-by: default avatarFernando Rodrigues <alpha@sigmasquadron.net>
parent 39b1c3e2
Loading
Loading
Loading
Loading
+16 −11
Original line number Diff line number Diff line
{ lib, buildDunePackage, fetchurl
, cstruct, ppx_cstruct, lwt, ounit2
{
  lib,
  buildDunePackage,
  fetchFromGitHub,
  lwt,
  ounit2,
}:

buildDunePackage rec {
  pname = "xenstore";
  version = "2.3.0";

  minimalOCamlVersion = "4.08";
  duneVersion = "3";

  src = fetchurl {
    url = "https://github.com/mirage/ocaml-xenstore/releases/download/v${version}/xenstore-${version}.tbz";
    hash = "sha256-1jxrvLLTwpd2fYPAoPbdRs7P1OaR8c9cW2VURF7Bs/Q=";
  src = fetchFromGitHub {
    owner = "mirage";
    repo = "ocaml-xenstore";
    rev = "v${version}";
    hash = "sha256-LaynsbCE/+2QfbQCOLZi8nw1rqmZtgrwAov9cSxYZw8=";
  };

  buildInputs = [ ppx_cstruct ];
  propagatedBuildInputs = [ cstruct lwt ];
  propagatedBuildInputs = [ lwt ];

  doCheck = true;
  checkInputs = [ ounit2 ];
@@ -23,7 +25,10 @@ buildDunePackage rec {
  meta = with lib; {
    description = "Xenstore protocol in pure OCaml";
    license = licenses.lgpl21Only;
    maintainers = [ maintainers.sternenseemann ];
    maintainers = with maintainers; [
      sternenseemann
      sigmasquadron
    ];
    homepage = "https://github.com/mirage/ocaml-xenstore";
  };
}