diff --git a/pkgs/development/interpreters/j2re/builder.sh b/pkgs/development/interpreters/j2re/builder.sh index e14d911320b2..98d5156fabe8 100644 --- a/pkgs/development/interpreters/j2re/builder.sh +++ b/pkgs/development/interpreters/j2re/builder.sh @@ -1,13 +1,25 @@ +#! /bin/sh . $stdenv/setup || exit 1 -version=j2re1.4.2_03 cp $src $version.bin || exit 1 chmod u+x $version.bin || exit 1 alias more=cat +echo "Unpacking J2RE" yes yes | ./$version.bin || exit 1 mkdir $out || exit 1 + +echo "Moving sources to the right location" mv $version/* $out/ || exit 1 + +echo "Removing files at top level" +for file in $out/* +do + if test -f $file ; then + rm $file + fi +done +rm -rf $out/docs diff --git a/pkgs/development/interpreters/j2re/j2re-sun-linux.nix b/pkgs/development/interpreters/j2re/j2re-sun-linux.nix index 9958bb85c13b..7ff9a23b8445 100644 --- a/pkgs/development/interpreters/j2re/j2re-sun-linux.nix +++ b/pkgs/development/interpreters/j2re/j2re-sun-linux.nix @@ -2,14 +2,12 @@ assert stdenv.system == "i686-linux"; - -derivation { - name = "j2re-1.4.2"; - system = stdenv.system; +stdenv.mkDerivation { + name = "j2re-1.4.2"; + version = "j2re1.4.2_04"; builder = ./builder.sh; src = fetchurl { - url = http://java.sun.com/webapps/download/AutoDL?BundleId=9500; - md5 = "b4aae3fcda73d976bd6ae6349b36a90c"; + url = http://java.sun.com/webapps/download/AutoDL?BundleId=9562; + md5 = "57e31ffc32a2956e6140ceda8aa86e4e"; }; - stdenv = stdenv; }