[wpkg-users] Java struggle
Jurgen.Depicker at let.be
Wed Dec 4 11:49:59 CET 2013
I've been using your collection of scripts successfully for about a year now; enormous thanks for that.
Oracle recently changed the structure of the uninstall string though, which caused some troubles in my network :-) (java kept on being upgraded at every boot). I quickly solved the issue by modifying the install check as follows underneath; did you make the same modification or did you solve it differently?
<?xml version="1.0" encoding="UTF-8"?>
xmlns:packages="http://www.wpkg.org/packages" xmlns:wpkg="http://www.wpkg.org/wpkg" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.wpkg.org/packages ../xsd/packages.xsd" >
<!-- jre install with the msi ; for 32-bit and 64-bit hosts -->
<!-- modify settings.cmd (in javase folder) to reflect the new version:
eg, SET JAVA7_VERSION=1.7.0_45 at bottom of file ! -->
<!-- copy msi and cab from C:\Users\jde\AppData\LocalLow\Sun\Java after running the exe installer -->
<!-- rename msi to jre.msi !! -->
<!-- libreoffice depends on this -->
name='Java runtime environment'
<check type='uninstall' condition='exists' path='Java(TM) 7' />
<install cmd='"%SOFTWARE%\JavaSE\unattended.cmd"'> <!-- >NUL' > -->
<exit code='1603' />
<remove cmd='"%SOFTWARE%\JavaSE\unattended-uninstall.cmd"'/> <!-- >NUL' /> -->
<upgrade cmd='"%SOFTWARE%\JavaSE\unattended.cmd"'> <!-- >NUL' > -->
<exit code='1603' />
Kind regards, Jürgen
Van: Rainer Meier [mailto:r.meier at wpkg.org]
Verzonden: dinsdag 15 januari 2013 10:44
Aan: Jurgen Depicker
CC: wpkg-users at lists.wpkg.org
Onderwerp: Re: [wpkg-users] Java struggle
On 15.01.2013 10:20, jurgen.depicker at let.be wrote:
> Dear all,
> I'm a bit in stress and cannot weed out the page at
> http://wpkg.org/Javawhich is probably one of the most complex pages on
> the wiki :-). Does anyone have a more recent package description to
> upgrade both 32 and 64 bit hosts to the latest java release, that's to
> say jre7u11 according to http://www.oracle.com/technetwork/java/javase/downloads/jre7-downloads-1880261.html?
> There aren't any msi's there, and there's no package on the site
> without msi's for 64bit hosts.
> I'm pretty sure (hopeful) someone allready has a more up to date
> package description; if you mail it to me, I'll update the page on the wiki happily!
I am personally using a custom set of simple cmd scripts to handle Java installation. I have uploaded a snapshot of it here:
Using it is pretty simple:
First of all run the Windows exe installer and when the install window pops up grab the MSI files from %LocalAppData%Low folder (c:\users\<username>\AppData\LocalLow\Sun\Java).
Note: I found when installing from network there is (or was?) some bug that msiexec could not find the jre.msi file during JRE installation. So I had to rename the file to "jre.msi" so it works fine now.
Then place all the installer files in corresponding sub-folders like jre1.7.0_11_x64\jre.msi jre1.7.0_11_x86\jre.msi ...
Have a look at settings.cmd. Here you just need to define what is installed and/or uninstalled.
UNINSTALL_* parameters: The uninstall code uses WMI to clean all versions installed (also future ones hopefully).
INSTALL_* parameters: Select what you would like to install (JRE/JDK; version 6/7).
WEB_JAVA: Select whether or not you want to enable the java plugin in browsers (see Java control panel in latest 1.7.0_10 or newer which allows to disable Java Plugins globally).
INSTALL_32_AND_64_BIT: lets you select whether on 64-bit systems only 64-bit edition or 64-bit and 32-bit editions are installed in parallel.
JAVA*_VERSION: Adapt when new java versions are released
Paths to installers. Typically it's sufficient to adapt JAVA*_VERSION variables.
Please note that for JRE the MSI file is renamed to jre.msi (see above).
So to install new versions simply adapt settings.xml and place MSI files in correct location.
JRE.xml WPKG package is included as well (extremely basic version).
More information about the wpkg-users