sereby.aio/createjrepack.sh

36 lines
1.1 KiB
Bash
Raw Normal View History

#!/bin/bash
VERSION="7"
UPDATE="21"
BUILD="11"
TEMPDIR=$( mktemp -d )
pushd $TEMPDIR
wget http://javadl.sun.com/webapps/download/AutoDL?BundleId=76860 -O jre-${VERSION}u${UPDATE}-windows-i586.exe
wget http://javadl.sun.com/webapps/download/AutoDL?BundleId=76862 -O jre-${VERSION}u${UPDATE}-windows-x64.exe
mkdir JRE
WINEPREFIX=$TEMPDIR/prefix32 WINEARCH=win32 wine jre-${VERSION}u${UPDATE}-windows-i586.exe &
while [ ! -s $TEMPDIR/prefix32/drive_c/drive_c/users/${USER}/Application\ Data/Sun/Java/jre1.7.0_21/jre1.${VERSION}.0_${UPDATE}/*.msi ]
do
printf "."
done
pushd JRE
mkdir X86
cp -v $TEMPDIR/prefix32/drive_c/users/${USER}/Application\ Data/Sun/Java/jre1.${VERSION}.0_${UPDATE}/* X86
popd
killall wine
WINEPREFIX=$TEMPDIR/prefix64 WINEARCH=win64 wine jre-${VERSION}u${UPDATE}-windows-x64.exe &
while [ ! -s $TEMPDIR/prefix64/drive_c/users/${USER}/Application\ Data/Sun/Java/jre1.${VERSION}.0_${UPDATE}_x64/*.msi ]
do
printf "."
done
pushd JRE
mkdir X64
cp -v $TEMPDIR/prefix64/drive_c/users/${USER}/Application\ Data/Sun/Java/jre1.${VERSION}.0_${UPDATE}_x64/* X64
popd
killall wine