2021-10-06 05:10:37 +00:00
|
|
|
{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, uchar, uutf, cmdliner }:
|
2014-07-09 07:42:26 +00:00
|
|
|
let
|
|
|
|
pname = "uunf";
|
2019-04-22 08:14:28 +00:00
|
|
|
webpage = "https://erratique.ch/software/${pname}";
|
2021-10-06 05:10:37 +00:00
|
|
|
version = "14.0.0";
|
2014-07-09 07:42:26 +00:00
|
|
|
in
|
2014-09-21 10:02:55 +00:00
|
|
|
|
2021-10-06 05:10:37 +00:00
|
|
|
if !lib.versionAtLeast ocaml.version "4.03"
|
|
|
|
then throw "${pname} is not available for OCaml ${ocaml.version}"
|
|
|
|
else
|
2014-09-21 10:02:55 +00:00
|
|
|
|
2020-08-14 05:42:07 +00:00
|
|
|
stdenv.mkDerivation {
|
2021-10-06 05:10:37 +00:00
|
|
|
name = "ocaml${ocaml.version}-${pname}-${version}";
|
2020-08-14 05:42:07 +00:00
|
|
|
inherit version;
|
2014-07-09 07:42:26 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "${webpage}/releases/${pname}-${version}.tbz";
|
2021-10-06 05:10:37 +00:00
|
|
|
sha256 = "sha256:17wv0nm3vvwcbzb1b09akw8jblmigyhbfmh1sy9lkb5756ni94a2";
|
2014-07-09 07:42:26 +00:00
|
|
|
};
|
|
|
|
|
2021-10-06 05:10:37 +00:00
|
|
|
buildInputs = [ ocaml findlib ocamlbuild topkg uutf cmdliner ];
|
2016-12-04 10:33:02 +00:00
|
|
|
|
|
|
|
propagatedBuildInputs = [ uchar ];
|
2014-07-09 07:42:26 +00:00
|
|
|
|
2016-12-04 10:33:02 +00:00
|
|
|
inherit (topkg) buildPhase installPhase;
|
2014-07-09 07:42:26 +00:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2014-07-09 07:42:26 +00:00
|
|
|
description = "An OCaml module for normalizing Unicode text";
|
2019-09-08 23:38:31 +00:00
|
|
|
homepage = webpage;
|
2021-10-06 05:10:37 +00:00
|
|
|
inherit (ocaml.meta) platforms;
|
2014-09-21 10:02:55 +00:00
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = [ maintainers.vbgl ];
|
2014-07-09 07:42:26 +00:00
|
|
|
};
|
|
|
|
}
|