From 0a4da64cadc1d2b4166ed50559acf07e51e6d425 Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Wed, 10 May 2017 06:35:58 +0000 Subject: [PATCH] ocamlPackages.octavius: init at 0.2.0 Octavius is a library to parse the ocamldoc comment syntax. --- .../ocaml-modules/octavius/default.nix | 26 +++++++++++++++++++ pkgs/top-level/ocaml-packages.nix | 2 ++ 2 files changed, 28 insertions(+) create mode 100644 pkgs/development/ocaml-modules/octavius/default.nix diff --git a/pkgs/development/ocaml-modules/octavius/default.nix b/pkgs/development/ocaml-modules/octavius/default.nix new file mode 100644 index 000000000000..f1668160df19 --- /dev/null +++ b/pkgs/development/ocaml-modules/octavius/default.nix @@ -0,0 +1,26 @@ +{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, opam }: + +if !stdenv.lib.versionAtLeast ocaml.version "4.03" +then throw "octavius is not available for OCaml ${ocaml.version}" else + +stdenv.mkDerivation { + name = "ocaml${ocaml.version}-octavius-0.2.0"; + src = fetchurl { + url = http://github.com/ocaml-doc/octavius/releases/download/v0.2.0/octavius-0.2.0.tbz; + sha256 = "02milzzlr4xk5aymg2fjz27f528d5pyscqvld3q0dm41zcpkz5ml"; + }; + + unpackCmd = "tar xjf $src"; + + buildInputs = [ ocaml findlib ocamlbuild topkg opam ]; + + inherit (topkg) buildPhase installPhase; + + meta = { + description = "Ocamldoc comment syntax parser"; + homepage = https://github.com/ocaml-doc/octavius; + license = stdenv.lib.licenses.isc; + maintainers = [ stdenv.lib.maintainers.vbgl ]; + inherit (ocaml.meta) platforms; + }; +} diff --git a/pkgs/top-level/ocaml-packages.nix b/pkgs/top-level/ocaml-packages.nix index d330de0f267f..3a185bc0a10b 100644 --- a/pkgs/top-level/ocaml-packages.nix +++ b/pkgs/top-level/ocaml-packages.nix @@ -395,6 +395,8 @@ let ocsigen-toolkit = callPackage ../development/ocaml-modules/ocsigen-toolkit { }; + octavius = callPackage ../development/ocaml-modules/octavius { }; + ojquery = callPackage ../development/ocaml-modules/ojquery { }; omd = callPackage ../development/ocaml-modules/omd { };