summary refs log tree commit diff
path: root/pkgs/development/ocaml-modules/uuseg
diff options
context:
space:
mode:
authorsternenseemann <git@lukasepple.de>2016-11-03 03:03:04 +0100
committervbgl <vbgl@users.noreply.github.com>2016-11-11 08:30:37 +0100
commitca9ab3bfe1acb8177e1084008c4d92c0f9494e3d (patch)
tree2ee02133f1b7d6780e6b8861a157f03cee627be8 /pkgs/development/ocaml-modules/uuseg
parent8ac2c1feada537fa0229011e9307ce0a7703bc1f (diff)
downloadnixpkgs-ca9ab3bfe1acb8177e1084008c4d92c0f9494e3d.tar
nixpkgs-ca9ab3bfe1acb8177e1084008c4d92c0f9494e3d.tar.gz
nixpkgs-ca9ab3bfe1acb8177e1084008c4d92c0f9494e3d.tar.bz2
nixpkgs-ca9ab3bfe1acb8177e1084008c4d92c0f9494e3d.tar.lz
nixpkgs-ca9ab3bfe1acb8177e1084008c4d92c0f9494e3d.tar.xz
nixpkgs-ca9ab3bfe1acb8177e1084008c4d92c0f9494e3d.tar.zst
nixpkgs-ca9ab3bfe1acb8177e1084008c4d92c0f9494e3d.zip
ocaml-uuseg: 0.8.0 -> 0.9.0
This commit also refactors the expression.
Diffstat (limited to 'pkgs/development/ocaml-modules/uuseg')
-rw-r--r--pkgs/development/ocaml-modules/uuseg/default.nix14
1 files changed, 6 insertions, 8 deletions
diff --git a/pkgs/development/ocaml-modules/uuseg/default.nix b/pkgs/development/ocaml-modules/uuseg/default.nix
index 3c7a4ff5c58..92777129ca0 100644
--- a/pkgs/development/ocaml-modules/uuseg/default.nix
+++ b/pkgs/development/ocaml-modules/uuseg/default.nix
@@ -1,18 +1,16 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, opam, uucp, uutf, cmdliner }:
+{ stdenv, buildOcaml, fetchurl, ocaml, findlib, ocamlbuild, opam, uucp, uutf, cmdliner }:
 
 let
-  inherit (stdenv.lib) getVersion versionAtLeast;
-
   pname = "uuseg";
-  version = "0.8.0";
   webpage = "http://erratique.ch/software/${pname}";
 in
 
-assert versionAtLeast (getVersion ocaml) "4.01";
+buildOcaml rec {
 
-stdenv.mkDerivation {
+  minimumSupportedOcamlVersion = "4.01";
 
-  name = "ocaml-${pname}-${version}";
+  name = pname;
+  version = "0.9.0";
 
   src = fetchurl {
     url = "${webpage}/releases/${pname}-${version}.tbz";
@@ -34,7 +32,7 @@ stdenv.mkDerivation {
 
   installPhase = ''
     opam-installer --script --prefix=$out ${pname}.install | sh
-    ln -s $out/lib/${pname} $out/lib/ocaml/${getVersion ocaml}/site-lib/${pname}
+    ln -s $out/lib/${pname} $out/lib/ocaml/${ocaml.version}/site-lib/${pname}
   '';
 
   meta = with stdenv.lib; {