depot/third_party/nixpkgs/pkgs/development/ocaml-modules/fmt/default.nix
Default email 889482aab3 Project import generated by Copybara.
GitOrigin-RevId: f2537a505d45c31fe5d9c27ea9829b6f4c4e6ac5
2022-06-26 12:26:21 +02:00

31 lines
910 B
Nix

{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, cmdliner, seq, stdlib-shims }:
if lib.versionOlder ocaml.version "4.05"
then throw "fmt is not available for OCaml ${ocaml.version}"
else
stdenv.mkDerivation rec {
version = "0.8.9";
pname = "ocaml${ocaml.version}-fmt";
src = fetchurl {
url = "https://erratique.ch/software/fmt/releases/fmt-${version}.tbz";
sha256 = "0gkkkj4x678vxdda4xaw2dd44qjacavsvn5nx8gydfwah6pjbkxk";
};
nativeBuildInputs = [ ocaml findlib ocamlbuild topkg ];
buildInputs = [ cmdliner topkg ];
propagatedBuildInputs = [ seq stdlib-shims ];
strictDeps = true;
inherit (topkg) buildPhase installPhase;
meta = with lib; {
homepage = "https://erratique.ch/software/fmt";
license = licenses.isc;
description = "OCaml Format pretty-printer combinators";
inherit (ocaml.meta) platforms;
maintainers = [ maintainers.vbgl ];
};
}