Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at netboot-syslinux-multiplatform 48 lines 962 B view raw
1{ lib 2, stdenv 3, cmdliner 4, fetchurl 5, findlib 6, ocaml 7, ocamlbuild 8, topkg 9}: 10 11if lib.versionOlder ocaml.version "4.14.0" 12then throw "cmarkit is not available for OCaml ${ocaml.version}" 13else 14 15stdenv.mkDerivation rec { 16 pname = "cmarkit"; 17 version = "0.2.0"; 18 19 src = fetchurl { 20 url = "https://erratique.ch/software/cmarkit/releases/cmarkit-${version}.tbz"; 21 hash = "sha256-86RuGB5pLbw/ThPGz9+qLaZRH7xvxbYrZWFLLIkc5Mk="; 22 }; 23 24 nativeBuildInputs = [ 25 ocaml 26 findlib 27 ocamlbuild 28 topkg 29 ]; 30 31 buildInputs = [ 32 topkg 33 cmdliner 34 ]; 35 36 strictDeps = true; 37 38 inherit (topkg) buildPhase installPhase; 39 40 meta = with lib; { 41 description = "CommonMark parser and renderer for OCaml"; 42 homepage = "https://erratique.ch/software/cmarkit"; 43 changelog = "https://github.com/dbuenzli/cmarkit/blob/v${version}/CHANGES.md"; 44 license = licenses.isc; 45 maintainers = [ maintainers.marsam ]; 46 inherit (ocaml.meta) platforms; 47 }; 48}