ocamlPackages.ocp-indent: remove spurious dependency to opam and fix installPhase

This commit is contained in:
Vincent Laporte 2018-06-26 04:55:25 +00:00
parent ebc7d20190
commit 06db050abd
No known key found for this signature in database
GPG key ID: EBD582ADDDB1F81F
2 changed files with 6 additions and 12 deletions

View file

@ -1,4 +1,4 @@
{ stdenv, fetchzip, ocaml, findlib, ocpBuild, opam, cmdliner }:
{ stdenv, fetchzip, ocaml, findlib, ocpBuild, cmdliner }:
let inherit (stdenv.lib) getVersion versionAtLeast; in
@ -15,7 +15,7 @@ stdenv.mkDerivation {
sha256 = "0ynv2yhm7akpvqp72pdabhddwr352s1k85q8m1khsvspgg1mkiqz";
};
nativeBuildInputs = [ ocpBuild opam ];
nativeBuildInputs = [ ocpBuild ];
buildInputs = [ ocaml findlib cmdliner ];

View file

@ -1,4 +1,4 @@
{ stdenv, fetchzip, ocaml, findlib, ocpBuild, opam, cmdliner }:
{ stdenv, fetchzip, ocaml, findlib, jbuilder, ocpBuild, cmdliner }:
let inherit (stdenv.lib) getVersion versionAtLeast; in
@ -8,7 +8,7 @@ assert versionAtLeast (getVersion ocpBuild) "1.99.6-beta";
stdenv.mkDerivation rec {
name = "ocp-indent-${version}";
name = "ocaml${ocaml.version}-ocp-indent-${version}";
version = "1.6.1";
src = fetchzip {
@ -16,16 +16,10 @@ stdenv.mkDerivation rec {
sha256 = "0rcaa11mjqka032g94wgw9llqpflyk3ywr3lr6jyxbh1rjvnipnw";
};
nativeBuildInputs = [ ocpBuild opam ];
nativeBuildInputs = [ ocpBuild ];
buildInputs = [ ocaml findlib cmdliner ];
createFindlibDestdir = true;
preConfigure = "patchShebangs ./install.sh";
postInstall = ''
mv $out/lib/{ocp-indent,ocaml/${getVersion ocaml}/site-lib/}
'';
inherit (jbuilder) installPhase;
meta = with stdenv.lib; {
homepage = http://typerex.ocamlpro.com/ocp-indent.html;