diff options
Diffstat (limited to 'pkgs/development/compilers/ocaml/3.11.1.nix')
-rw-r--r-- | pkgs/development/compilers/ocaml/3.11.1.nix | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/pkgs/development/compilers/ocaml/3.11.1.nix b/pkgs/development/compilers/ocaml/3.11.1.nix index f5955c7c78c2..d7053d583c23 100644 --- a/pkgs/development/compilers/ocaml/3.11.1.nix +++ b/pkgs/development/compilers/ocaml/3.11.1.nix @@ -1,5 +1,10 @@ args: with args; +let + useX11 = (stdenv.system != "armv5tel-linux"); + useNativeCompilers = (stdenv.system != "armv5tel-linux"); + inherit (stdenv.lib) optionals optionalString; +in stdenv.mkDerivation (rec { name = "ocaml-3.11.1"; @@ -10,10 +15,10 @@ stdenv.mkDerivation (rec { }; prefixKey = "-prefix "; - configureFlags = ["-no-tk" "-x11lib" x11]; - buildFlags = "world bootstrap world.opt"; - buildInputs = [x11 ncurses]; - installTargets = "install installopt"; + configureFlags = ["-no-tk"] ++ optionals useX11 [ "-x11lib" x11 ]; + buildFlags = "world" + optionalString useNativeCompilers " bootstrap world.opt"; + buildInputs = [ncurses] ++ optionals useX11 [ x11 ]; + installTargets = "install" + optionalString useNativeCompilers " installopt"; patchPhase = '' CAT=$(type -tp cat) sed -e "s@/bin/cat@$CAT@" -i config/auto-aux/sharpbang |