2019-06-02 03:33:22 +02:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
|
|
|
, fetchurl
|
|
|
|
, findlib
|
|
|
|
, ocaml
|
|
|
|
, ocamlbuild
|
|
|
|
, topkg
|
|
|
|
}:
|
|
|
|
|
|
|
|
let
|
|
|
|
minimumSupportedOcamlVersion = "4.02.0";
|
|
|
|
in
|
|
|
|
assert lib.versionOlder minimumSupportedOcamlVersion ocaml.version;
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2021-01-21 01:24:35 +01:00
|
|
|
pname = "hmap";
|
2019-06-02 03:33:22 +02:00
|
|
|
version = "0.8.1";
|
|
|
|
name = "ocaml${ocaml.version}-${pname}-${version}";
|
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://erratique.ch/software/hmap/releases/${pname}-${version}.tbz";
|
|
|
|
sha256 = "10xyjy4ab87z7jnghy0wnla9wrmazgyhdwhr4hdmxxdn28dxn03a";
|
|
|
|
};
|
|
|
|
|
2022-02-22 10:59:04 +01:00
|
|
|
nativeBuildInputs = [ ocaml ocamlbuild findlib topkg ];
|
|
|
|
buildInputs = [ topkg ];
|
|
|
|
|
|
|
|
strictDeps = true;
|
2019-06-02 03:33:22 +02:00
|
|
|
|
|
|
|
inherit (topkg) installPhase;
|
|
|
|
|
|
|
|
buildPhase = "${topkg.run} build --tests true";
|
|
|
|
|
|
|
|
doCheck = true;
|
|
|
|
|
|
|
|
checkPhase = "${topkg.run} test";
|
|
|
|
|
|
|
|
meta = {
|
2021-01-21 01:24:35 +01:00
|
|
|
description = "Heterogeneous value maps for OCaml";
|
2019-06-02 03:33:22 +02:00
|
|
|
homepage = "https://erratique.ch/software/hmap";
|
2021-01-21 01:24:35 +01:00
|
|
|
license = lib.licenses.isc;
|
|
|
|
maintainers = [ lib.maintainers.pmahoney ];
|
2019-06-02 03:33:22 +02:00
|
|
|
};
|
|
|
|
}
|