2020-03-08 15:58:54 +00:00
|
|
|
{ lib, fetchurl, ocaml, buildDunePackage }:
|
|
|
|
|
|
|
|
if lib.versionAtLeast ocaml.version "4.08"
|
|
|
|
then throw "earley is not available for OCaml ${ocaml.version}"
|
|
|
|
else
|
2018-05-19 22:01:40 +01:00
|
|
|
|
2019-05-21 21:17:57 +01:00
|
|
|
buildDunePackage rec {
|
|
|
|
version = "2.0.0";
|
|
|
|
pname = "earley";
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://github.com/rlepigre/ocaml-earley/releases/download/${version}/earley-${version}.tbz";
|
|
|
|
sha256 = "1kjr0wh3lji7f493kf48rphxnlv3sygj5a8rmx9z3xkpbd7aqyyw";
|
2018-05-19 22:01:40 +01:00
|
|
|
};
|
|
|
|
|
2019-05-21 21:17:57 +01:00
|
|
|
minimumOCamlVersion = "4.03";
|
2018-05-19 22:01:40 +01:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Parser combinators based on Earley Algorithm";
|
2019-05-21 21:17:57 +01:00
|
|
|
license = lib.licenses.cecill-b;
|
|
|
|
maintainers = [ lib.maintainers.vbgl ];
|
|
|
|
homepage = "https://github.com/rlepigre/ocaml-earley";
|
2018-05-19 22:01:40 +01:00
|
|
|
};
|
|
|
|
}
|