diff options
author | Vincent Laporte <Vincent.Laporte@gmail.com> | 2017-01-24 21:09:20 +0000 |
---|---|---|
committer | Vincent Laporte <Vincent.Laporte@gmail.com> | 2017-01-25 06:55:59 +0000 |
commit | 453a3838f9eb96cee9c6234658d3d4ba34d1478a (patch) | |
tree | 54a21de93a06d783ae74d20cb7be2fd54a6d24d2 /pkgs/development/ocaml-modules/mtime | |
parent | c57715570a27ce89df57234e3ce7f1eb7c64cfe4 (diff) | |
download | nixpkgs-453a3838f9eb96cee9c6234658d3d4ba34d1478a.tar nixpkgs-453a3838f9eb96cee9c6234658d3d4ba34d1478a.tar.gz nixpkgs-453a3838f9eb96cee9c6234658d3d4ba34d1478a.tar.bz2 nixpkgs-453a3838f9eb96cee9c6234658d3d4ba34d1478a.tar.lz nixpkgs-453a3838f9eb96cee9c6234658d3d4ba34d1478a.tar.xz nixpkgs-453a3838f9eb96cee9c6234658d3d4ba34d1478a.tar.zst nixpkgs-453a3838f9eb96cee9c6234658d3d4ba34d1478a.zip |
ocamlPackages.mtime: init at 0.8.3
Mtime is an OCaml module to access monotonic wall-clock time. Homepage: http://erratique.ch/software/mtime
Diffstat (limited to 'pkgs/development/ocaml-modules/mtime')
-rw-r--r-- | pkgs/development/ocaml-modules/mtime/default.nix | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/pkgs/development/ocaml-modules/mtime/default.nix b/pkgs/development/ocaml-modules/mtime/default.nix new file mode 100644 index 00000000000..a26109bd4f9 --- /dev/null +++ b/pkgs/development/ocaml-modules/mtime/default.nix @@ -0,0 +1,29 @@ +{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, opam, js_of_ocaml +, jsooSupport ? !(stdenv.lib.versionAtLeast ocaml.version "4.04") +}: + +stdenv.mkDerivation { + name = "ocaml${ocaml.version}-mtime-0.8.3"; + + src = fetchurl { + url = http://erratique.ch/software/mtime/releases/mtime-0.8.3.tbz; + sha256 = "1hfx4ny2dkw6jf3jppz0640dafl5xgn8r2si9kpwzhmibal8qrah"; + }; + + unpackCmd = "tar xjf $src"; + + buildInputs = [ ocaml findlib ocamlbuild opam ] + ++ stdenv.lib.optional jsooSupport js_of_ocaml; + + buildPhase = "ocaml pkg/build.ml native=true native-dynlink=true jsoo=${if jsooSupport then "true" else "false"}"; + + installPhase = "opam-installer -i --prefix=$out --libdir=$OCAMLFIND_DESTDIR"; + + meta = { + description = "Monotonic wall-clock time for OCaml"; + homepage = http://erratique.ch/software/mtime; + inherit (ocaml.meta) platforms; + maintainers = [ stdenv.lib.maintainers.vbgl ]; + license = stdenv.lib.licenses.bsd3; + }; +} |