2020-11-01 06:49:44 +00:00
|
|
|
{ lib, fetchurl, buildDunePackage, dune-configurator
|
2019-10-29 06:31:14 +00:00
|
|
|
, bigarray-compat, optint
|
2020-11-01 06:49:44 +00:00
|
|
|
, fmt, rresult
|
2019-10-29 06:31:14 +00:00
|
|
|
, alcotest
|
|
|
|
}:
|
2018-11-04 06:49:33 +00:00
|
|
|
|
2019-10-29 06:31:14 +00:00
|
|
|
buildDunePackage rec {
|
2020-11-01 06:49:44 +00:00
|
|
|
version = "0.2.1";
|
2019-10-29 06:31:14 +00:00
|
|
|
pname = "checkseum";
|
2018-11-04 06:49:33 +00:00
|
|
|
|
2020-11-01 06:49:44 +00:00
|
|
|
useDune2 = true;
|
|
|
|
|
2018-11-04 06:49:33 +00:00
|
|
|
src = fetchurl {
|
2019-10-29 06:31:14 +00:00
|
|
|
url = "https://github.com/mirage/checkseum/releases/download/v${version}/checkseum-v${version}.tbz";
|
2020-11-01 06:49:44 +00:00
|
|
|
sha256 = "1swb44c64pcs4dh9ka9lig6d398qwwkd3kkiajicww6qk7jbh3n5";
|
2018-11-04 06:49:33 +00:00
|
|
|
};
|
|
|
|
|
2020-11-01 06:49:44 +00:00
|
|
|
buildInputs = [ dune-configurator fmt rresult ];
|
2019-10-29 06:31:14 +00:00
|
|
|
propagatedBuildInputs = [ bigarray-compat optint ];
|
|
|
|
checkInputs = lib.optionals doCheck [ alcotest ];
|
2018-11-04 06:49:33 +00:00
|
|
|
|
2019-10-29 06:31:14 +00:00
|
|
|
doCheck = true;
|
2019-10-21 06:36:52 +01:00
|
|
|
|
2018-11-04 06:49:33 +00:00
|
|
|
meta = {
|
|
|
|
homepage = "https://github.com/mirage/checkseum";
|
|
|
|
description = "ADLER-32 and CRC32C Cyclic Redundancy Check";
|
2019-10-29 06:31:14 +00:00
|
|
|
license = lib.licenses.mit;
|
|
|
|
maintainers = [ lib.maintainers.vbgl ];
|
2018-11-04 06:49:33 +00:00
|
|
|
};
|
|
|
|
}
|