2021-04-22 21:38:58 -07:00
|
|
|
{ lib, fetchurl, buildDunePackage, ounit, cstruct, dune-configurator, eqaf, bigarray-compat, pkg-config
|
2021-03-30 05:56:02 -07:00
|
|
|
, withFreestanding ? false
|
|
|
|
, ocaml-freestanding
|
|
|
|
}:
|
2020-04-13 04:20:48 -07:00
|
|
|
|
|
|
|
buildDunePackage rec {
|
2020-05-20 15:57:24 -07:00
|
|
|
minimumOCamlVersion = "4.08";
|
2020-04-13 04:20:48 -07:00
|
|
|
|
|
|
|
pname = "mirage-crypto";
|
2021-04-26 04:31:33 -07:00
|
|
|
version = "0.10.1";
|
2020-04-13 04:20:48 -07:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://github.com/mirage/mirage-crypto/releases/download/v${version}/mirage-crypto-v${version}.tbz";
|
2021-04-26 04:31:33 -07:00
|
|
|
sha256 = "028e2fc1f0a3e9b06603c6a253ecd043100099bc1c12c0567d8bc46d3781499c";
|
2020-04-13 04:20:48 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
useDune2 = true;
|
|
|
|
|
|
|
|
doCheck = true;
|
|
|
|
checkInputs = [ ounit ];
|
|
|
|
|
2020-05-20 15:57:24 -07:00
|
|
|
nativeBuildInputs = [ dune-configurator pkg-config ];
|
2021-03-30 05:56:02 -07:00
|
|
|
propagatedBuildInputs = [
|
2021-04-22 21:38:58 -07:00
|
|
|
cstruct eqaf bigarray-compat
|
2021-03-30 05:56:02 -07:00
|
|
|
] ++ lib.optionals withFreestanding [
|
|
|
|
ocaml-freestanding
|
|
|
|
];
|
2020-04-13 04:20:48 -07:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/mirage/mirage-crypto";
|
|
|
|
description = "Simple symmetric cryptography for the modern age";
|
2021-03-30 05:56:02 -07:00
|
|
|
license = [
|
|
|
|
licenses.isc # default license
|
|
|
|
licenses.bsd2 # mirage-crypto-rng-mirage
|
|
|
|
licenses.mit # mirage-crypto-ec
|
|
|
|
];
|
2020-04-13 04:20:48 -07:00
|
|
|
maintainers = with maintainers; [ sternenseemann ];
|
|
|
|
};
|
|
|
|
}
|