treewide: replace make/build/configure/patchFlags with nix lists
This commit is contained in:
@@ -12,7 +12,7 @@ stdenv.mkDerivation (rec {
|
||||
|
||||
prefixKey = "-prefix ";
|
||||
configureFlags = ["-no-tk" "-x11lib" xlibsWrapper];
|
||||
buildFlags = "world bootstrap world.opt";
|
||||
buildFlags = [ "world" "bootstrap" "world.opt" ];
|
||||
buildInputs = [xlibsWrapper ncurses];
|
||||
installTargets = "install installopt";
|
||||
patchPhase = ''
|
||||
|
||||
@@ -7,10 +7,10 @@ let
|
||||
in
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
|
||||
|
||||
pname = "ocaml";
|
||||
version = "3.11.2";
|
||||
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://caml.inria.fr/pub/distrib/ocaml-3.11/${pname}-${version}.tar.bz2";
|
||||
sha256 = "86f3387a0d7e7c8be2a3c53af083a5a726e333686208d5ea0dd6bb5ac3f58143";
|
||||
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
|
||||
|
||||
prefixKey = "-prefix ";
|
||||
configureFlags = ["-no-tk"] ++ optionals useX11 [ "-x11lib" xlibsWrapper ];
|
||||
buildFlags = "world" + optionalString useNativeCompilers " bootstrap world.opt";
|
||||
buildFlags = [ "world" ] ++ optionals useNativeCompilers [ "bootstrap" "world.opt" ];
|
||||
buildInputs = [ncurses] ++ optionals useX11 [ xlibsWrapper ];
|
||||
installTargets = "install" + optionalString useNativeCompilers " installopt";
|
||||
prePatch = ''
|
||||
|
||||
@@ -7,10 +7,10 @@ let
|
||||
in
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
|
||||
|
||||
pname = "ocaml";
|
||||
version = "3.12.1";
|
||||
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://caml.inria.fr/pub/distrib/ocaml-3.12/${pname}-${version}.tar.bz2";
|
||||
sha256 = "13cmhkh7s6srnlvhg3s9qzh3a5dbk2m9qr35jzq922sylwymdkzd";
|
||||
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
|
||||
|
||||
prefixKey = "-prefix ";
|
||||
configureFlags = ["-no-tk"] ++ optionals useX11 [ "-x11lib" xlibsWrapper ];
|
||||
buildFlags = "world" + optionalString useNativeCompilers " bootstrap world.opt";
|
||||
buildFlags = [ "world" ] ++ optionals useNativeCompilers [ "bootstrap" "world.opt" ];
|
||||
buildInputs = [ncurses] ++ optionals useX11 [ xlibsWrapper ];
|
||||
installTargets = "install" + optionalString useNativeCompilers " installopt";
|
||||
patches = optionals stdenv.isDarwin [ ./3.12.1-darwin-fix-configure.patch ];
|
||||
|
||||
@@ -3,22 +3,22 @@
|
||||
let
|
||||
useX11 = !stdenv.isAarch32 && !stdenv.isMips;
|
||||
useNativeCompilers = !stdenv.isMips;
|
||||
inherit (stdenv.lib) optionals optionalString;
|
||||
inherit (stdenv.lib) optional optionals optionalString;
|
||||
in
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "ocaml";
|
||||
version = "4.00.1";
|
||||
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://caml.inria.fr/pub/distrib/ocaml-4.00/${pname}-${version}.tar.bz2";
|
||||
sha256 = "33c3f4acff51685f5bfd7c260f066645e767d4e865877bf1613c176a77799951";
|
||||
};
|
||||
|
||||
prefixKey = "-prefix ";
|
||||
configureFlags = ["-no-tk"] ++ optionals useX11 [ "-x11lib" xlibsWrapper ];
|
||||
buildFlags = "world" + optionalString useNativeCompilers " bootstrap world.opt";
|
||||
buildInputs = [ncurses] ++ optionals useX11 [ xlibsWrapper ];
|
||||
configureFlags = [ "-no-tk" ] ++ optionals useX11 [ "-x11lib" xlibsWrapper ];
|
||||
buildFlags = [ "world" ] ++ optionals useNativeCompilers [ "bootstrap" "world.opt" ];
|
||||
buildInputs = [ ncurses ] ++ optional useX11 xlibsWrapper;
|
||||
installTargets = "install" + optionalString useNativeCompilers " installopt";
|
||||
preConfigure = ''
|
||||
CAT=$(type -tp cat)
|
||||
|
||||
@@ -55,10 +55,10 @@ stdenv.mkDerivation (args // {
|
||||
++ optional flambdaSupport (flags "--enable-flambda" "-flambda")
|
||||
;
|
||||
|
||||
buildFlags = "world" + optionalString useNativeCompilers " bootstrap world.opt";
|
||||
buildFlags = [ "world" ] ++ optionals useNativeCompilers [ "bootstrap" "world.opt" ];
|
||||
buildInputs = optional (!stdenv.lib.versionAtLeast version "4.07") ncurses
|
||||
++ optionals useX11 [ libX11 xorgproto ];
|
||||
installTargets = "install" + optionalString useNativeCompilers " installopt";
|
||||
installTargets = [ "install" ] ++ optional useNativeCompilers "installopt";
|
||||
preConfigure = optionalString (!stdenv.lib.versionAtLeast version "4.04") ''
|
||||
CAT=$(type -tp cat)
|
||||
sed -e "s@/bin/cat@$CAT@" -i config/auto-aux/sharpbang
|
||||
|
||||
@@ -12,7 +12,7 @@ stdenv.mkDerivation ({
|
||||
|
||||
prefixKey = "-prefix ";
|
||||
configureFlags = ["-no-tk" "-x11lib" xlibsWrapper];
|
||||
buildFlags = "world bootstrap world.opt";
|
||||
buildFlags = [ "world" "bootstrap" "world.opt" ];
|
||||
buildInputs = [xlibsWrapper ncurses];
|
||||
installTargets = "install installopt";
|
||||
patchPhase = ''
|
||||
|
||||
Reference in New Issue
Block a user