Error downloading jce_policy-6.zip on 0.2.8 tag
stuartf opened this issue · comments
When running the 0.2.8 tag (currently the latest) I get the following error, it looks like Oracle might have changed up their site so the scraping for the jce_policy-6.zip path is broken.
[x] Downloading jce_policy-6.zip : --2013-06-19 15:18:27-- http://jce_policy-6.zip/
Resolving jce_policy-6.zip (jce_policy-6.zip)... failed: Name or service not known.
wget: unable to resolve host address `jce_policy-6.zip'
16129's retcode: 4
failed
When I edit the script to include a hard link to the Oracle site "http://download.oracle.com/otn-pub/java/jce_policy/6/" the script will continue, but fails to build: Log: http://pastebin.com/MfBj7q5e
Same.
+1
same here
Boboss74 fix still fail when building the packages. According to the log:
binsize=$(wc -c jdk-6u45-linux-i586.bin | awk '{print $1}'); \
zipstart=$(unzip -ql jdk-6u45-linux-i586.bin 2>&1 >/dev/null | sed -n -e 's/.* \([0-9][0-9]*\) extra bytes.*/\1/p'); \
tail -c $(expr $binsize - $zipstart) jdk-6u45-linux-i586.bin > tmp-jdk.zip
expr: syntax error
tail: jdk-6u45-linux-i586.bin: invalid number of bytes
make: *** [unpack-i586-stamp] Error 1
dpkg-buildpackage: error: debian/rules build gave error exit status 2
11308's retcode: 2
it seems that dpkg-buildpackage is failing because either $binzise or $zipstart is invalid.
Package building is failing because the jdk-6u45-linux-i586.bin downloaded is not the correct file; it is an HTML file that says that login failed.
Oracle put all the older JDK versions behind a developer account login. This script cannot work for java6. If you want java6 I suggest using this method: https://launchpad.net/~webupd8team/+archive/java
Workaround:
First, goto the oracle website and download the following three files manually:
/var/local/oab/pkg/jce_policy-6.zip
/var/local/oab/pkg/jdk-6u45-linux-i586.bin
/var/local/oab/pkg/jdk-6u45-linux-x64.bin
Note: These urls are currently working:
http://www.oracle.com/technetwork/java/javase/downloads/jce-6-download-429243.html
Next, patch oab-java.sh so that it will not attempt to download because we have already manually downloaded the files and placed them in /var/local/oab/pkg/.
--- oab-java6.orig/oab-java.sh 2013-07-15 02:31:17.406791738 +0200
+++ oab-java6/oab-java.sh 2013-07-15 02:28:18.998791874 +0200
@@ -499,8 +499,8 @@
COOKIES="oraclelicensejdk-${JAVA_VER}u${JAVA_UPD}-oth-JPR=accept-securebackup-cookie;gpw_e24=http://edelivery.oracle.com"
ncecho " [x] Downloading ${JAVA_BIN} : ${DOWNLOAD_SIZE} "
- wget --no-check-certificate --header="Cookie: ${COOKIES}" -c "${DOWNLOAD_URL}" -O ${WORK_PATH}/pkg/${JAVA_BIN} >> "$log" 2>&1 &
- pid=$!;progress_loop $pid
+# wget --no-check-certificate --header="Cookie: ${COOKIES}" -c "${DOWNLOAD_URL}" -O ${WORK_PATH}/pkg/${JAVA_BIN} >> "$log" 2>&1 &
+# pid=$!;progress_loop $pid
ncecho " [x] Symlinking ${JAVA_BIN} "
ln -s ${WORK_PATH}/pkg/${JAVA_BIN} ${WORK_PATH}/src/${JAVA_BIN} >> "$log" 2>&1 &
@@ -527,8 +527,8 @@
DOWNLOAD_SIZE=`grep ${JCE_POLICY} /tmp/oab-download-jce.html | cut -d'{' -f2 | cut -d',' -f2 | cut -d'"' -f4`
ncecho " [x] Downloading ${JCE_POLICY} : ${DOWNLOAD_SIZE} "
-wget --no-check-certificate --header="Cookie: ${COOKIES}" -c "${DOWNLOAD_URL}" -O ${WORK_PATH}/pkg/${JCE_POLICY} >> "$log" 2>&1 &
-pid=$!;progress_loop $pid
+#wget --no-check-certificate --header="Cookie: ${COOKIES}" -c "${DOWNLOAD_URL}" -O ${WORK_PATH}/pkg/${JCE_POLICY} >> "$log" 2>&1 &
+#pid=$!;progress_loop $pid
ncecho " [x] Symlinking ${JCE_POLICY} "
ln -s ${WORK_PATH}/pkg/${JCE_POLICY} ${WORK_PATH}/src/${JCE_POLICY} >> "$log" 2>&1 &`
Merged pull-requuest #111.