summary refs log tree commit diff
path: root/pkgs/development/tools/ocaml
diff options
context:
space:
mode:
authorVincent Laporte <Vincent.Laporte@gmail.com>2018-04-02 05:46:54 +0000
committerVincent Laporte <Vincent.Laporte@gmail.com>2018-04-03 05:55:59 +0000
commitd0072be8cdc6e92c1943928eedf2271b71aa716f (patch)
treef79158eaa5c6cc8e77ae813786a14149e861b72c /pkgs/development/tools/ocaml
parent2dc852022522059de740dc11ad7fd9cbf76e915c (diff)
downloadnixlib-d0072be8cdc6e92c1943928eedf2271b71aa716f.tar
nixlib-d0072be8cdc6e92c1943928eedf2271b71aa716f.tar.gz
nixlib-d0072be8cdc6e92c1943928eedf2271b71aa716f.tar.bz2
nixlib-d0072be8cdc6e92c1943928eedf2271b71aa716f.tar.lz
nixlib-d0072be8cdc6e92c1943928eedf2271b71aa716f.tar.xz
nixlib-d0072be8cdc6e92c1943928eedf2271b71aa716f.tar.zst
nixlib-d0072be8cdc6e92c1943928eedf2271b71aa716f.zip
ocamlPackages.ocamlify: fix build with OCaml 4.06
Diffstat (limited to 'pkgs/development/tools/ocaml')
-rw-r--r--pkgs/development/tools/ocaml/ocamlify/default.nix13
1 files changed, 10 insertions, 3 deletions
diff --git a/pkgs/development/tools/ocaml/ocamlify/default.nix b/pkgs/development/tools/ocaml/ocamlify/default.nix
index 2876464ab502..df480903d154 100644
--- a/pkgs/development/tools/ocaml/ocamlify/default.nix
+++ b/pkgs/development/tools/ocaml/ocamlify/default.nix
@@ -10,9 +10,16 @@ stdenv.mkDerivation {
 
   buildInputs = [ ocaml findlib ocamlbuild ];
 
-  configurePhase = "ocaml setup.ml -configure --prefix $out";
-  buildPhase     = "ocaml setup.ml -build";
-  installPhase   = "ocaml setup.ml -install";
+  configurePhase = ''
+    substituteInPlace src/ocamlify.ml --replace 'OCamlifyConfig.version' '"0.0.2"'
+  '';
+
+  buildPhase = "ocamlbuild src/ocamlify.native";
+
+  installPhase = ''
+    mkdir -p $out/bin
+    mv _build/src/ocamlify.native $out/bin/ocamlify
+  '';
 
   dontStrip = true;