* In the JDK packages, don't return false if the platform is

unsupported.  This gives a type error ("value is a boolean while 
  an attribute set was expected").

svn path=/nixpkgs/trunk/; revision=8576
This commit is contained in:
Eelco Dolstra 2007-04-16 10:07:06 +00:00
parent e317c7de41
commit 0005a37b8d
3 changed files with 10 additions and 8 deletions

View File

@ -6,4 +6,4 @@ if stdenv.system == "i686-linux"
inherit stdenv fetchurl; inherit stdenv fetchurl;
} }
else else
false abort "the Java 2 SDK is not supported on this platform"

View File

@ -7,4 +7,4 @@ else if args.stdenv.system == "powerpc-linux" then
(import ./jdk5-ibm-powerpc-linux.nix) args (import ./jdk5-ibm-powerpc-linux.nix) args
else else
false abort "the JDK is not supported on this platform"

View File

@ -753,21 +753,23 @@ rec {
inherit fetchurl stdenv ghc; inherit fetchurl stdenv ghc;
}; };
j2sdk14x = import ../development/compilers/jdk/default-1.4.nix { j2sdk14x =
assert system == "i686-linux";
import ../development/compilers/jdk/default-1.4.nix {
inherit fetchurl stdenv; inherit fetchurl stdenv;
}; };
jdk = jdkdistro true false; jdk = jdkdistro true false;
jre = jdkdistro false false; jre = jdkdistro false false;
jdkPlugin = jdkdistro true true; jdkPlugin = jdkdistro true true;
jrePlugin = jdkdistro false true; jrePlugin = jdkdistro false true;
jdkdistro = installjdk : pluginSupport: jdkdistro = installjdk: pluginSupport:
if stdenv.isDarwin then if stdenv.isDarwin then
"/System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Home" "/System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Home"
else else
assert system == "i686-linux" || system == "x86_64-linux" || system == "powerpc-linux";
import ../development/compilers/jdk { import ../development/compilers/jdk {
inherit fetchurl stdenv unzip installjdk xlibs pluginSupport; inherit fetchurl stdenv unzip installjdk xlibs pluginSupport;
libstdcpp5 = gcc33.gcc; libstdcpp5 = gcc33.gcc;