depot/third_party/nixpkgs/pkgs/development/ocaml-modules/cmarkit/default.nix
Default email 5c370c0b2a Project import generated by Copybara.
GitOrigin-RevId: 33d1e753c82ffc557b4a585c77de43d4c922ebb5
2024-05-15 17:35:15 +02:00

48 lines
943 B
Nix

{ lib
, stdenv
, cmdliner
, fetchurl
, findlib
, ocaml
, ocamlbuild
, topkg
}:
if lib.versionOlder ocaml.version "4.14.0"
then throw "cmarkit is not available for OCaml ${ocaml.version}"
else
stdenv.mkDerivation rec {
pname = "cmarkit";
version = "0.3.0";
src = fetchurl {
url = "https://erratique.ch/software/cmarkit/releases/cmarkit-${version}.tbz";
hash = "sha256-RouM5iU7VeTT0+4yhBgdEmxROeP/X31iqDjd1VI7z5c=";
};
nativeBuildInputs = [
ocaml
findlib
ocamlbuild
topkg
];
buildInputs = [
topkg
cmdliner
];
strictDeps = true;
inherit (topkg) buildPhase installPhase;
meta = with lib; {
description = "CommonMark parser and renderer for OCaml";
homepage = "https://erratique.ch/software/cmarkit";
changelog = "https://github.com/dbuenzli/cmarkit/blob/v${version}/CHANGES.md";
license = licenses.isc;
maintainers = [ ];
inherit (ocaml.meta) platforms;
};
}