* Purify the JRE.
svn path=/nixpkgs/trunk/; revision=7936
This commit is contained in:
parent
f69d866898
commit
e17d20b6d2
@ -1,19 +1,11 @@
|
|||||||
#! /bin/sh
|
source $stdenv/setup
|
||||||
|
|
||||||
source $stdenv/setup || exit 1
|
unzip $src || true
|
||||||
|
|
||||||
cp $src $version.bin || exit 1
|
ensureDir $out
|
||||||
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"
|
echo "Moving sources to the right location"
|
||||||
mv $version/* $out/ || exit 1
|
mv $version/* $out/
|
||||||
|
|
||||||
echo "Removing files at top level"
|
echo "Removing files at top level"
|
||||||
for file in $out/*
|
for file in $out/*
|
||||||
@ -23,3 +15,19 @@ do
|
|||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
rm -rf $out/docs
|
rm -rf $out/docs
|
||||||
|
|
||||||
|
# Set the dynamic linker.
|
||||||
|
rpath=
|
||||||
|
for i in $libraries; do
|
||||||
|
rpath=$rpath${rpath:+:}$i/lib
|
||||||
|
done
|
||||||
|
find $out -type f -perm +100 \
|
||||||
|
-exec patchelf --interpreter "$(cat $NIX_GCC/nix-support/dynamic-linker)" \
|
||||||
|
--set-rpath "$rpath" {} \;
|
||||||
|
|
||||||
|
# Unpack .pack files.
|
||||||
|
for i in $(find $out -name "*.pack"); do
|
||||||
|
echo "unpacking $i..."
|
||||||
|
$out/bin/unpack200 "$i" "$(dirname $i)/$(basename $i .pack).jar"
|
||||||
|
rm "$i"
|
||||||
|
done
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
{stdenv, fetchurl}:
|
{stdenv, fetchurl, unzip}:
|
||||||
|
|
||||||
if stdenv.system == "i686-linux"
|
if stdenv.system == "i686-linux"
|
||||||
then
|
then
|
||||||
(import ./jre-sun-linux.nix) {
|
(import ./jre-sun-linux.nix) {
|
||||||
inherit stdenv fetchurl;
|
inherit stdenv fetchurl unzip;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
false
|
false
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{stdenv, fetchurl}:
|
{stdenv, fetchurl, unzip}:
|
||||||
|
|
||||||
assert stdenv.system == "i686-linux";
|
assert stdenv.system == "i686-linux";
|
||||||
|
|
||||||
@ -10,6 +10,7 @@ assert stdenv.system == "i686-linux";
|
|||||||
url = http://jdl.sun.com/webapps/download/AutoDL?BundleId=10542;
|
url = http://jdl.sun.com/webapps/download/AutoDL?BundleId=10542;
|
||||||
md5 = "e2ad1c9e47f3e34d1efae059b9e2a2d9";
|
md5 = "e2ad1c9e47f3e34d1efae059b9e2a2d9";
|
||||||
};
|
};
|
||||||
|
buildInputs = [unzip];
|
||||||
})
|
})
|
||||||
|
|
||||||
// {mozillaPlugin = "/plugin/i386/ns7";}
|
// {mozillaPlugin = "/plugin/i386/ns7";}
|
||||||
|
@ -865,7 +865,7 @@ rec {
|
|||||||
};
|
};
|
||||||
|
|
||||||
jre = import ../development/interpreters/jre {
|
jre = import ../development/interpreters/jre {
|
||||||
inherit fetchurl stdenv;
|
inherit fetchurl stdenv unzip;
|
||||||
};
|
};
|
||||||
|
|
||||||
kaffe = import ../development/interpreters/kaffe {
|
kaffe = import ../development/interpreters/kaffe {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user