Ing. Federico Bortolomiol
System Engineer
M B M Italia S.r.l.
Via Pellizzo 14/A - 35128 Padova
Email f.bort...@mbm.it
Phone +39.049.9080741 Fax +39.049.2106668I think is just your registry specs encoding…
I have the following natives:
<!-- The native libraries to add -->
<natives>
<native type="izpack" name="ShellLink.dll"/>
<native type="izpack" name="ShellLink_x64.dll"/>
<native type="izpack" name="WinSetupAPI.dll"/>
<native type="izpack" name="WinSetupAPI_x64.dll"/>
<native type="3rdparty" name="COIOSHelper.dll" stage="both">
<os family="windows"/>
</native>
<native type="3rdparty" name="COIOSHelper_x64.dll" stage="both">
<os family="windows"/>
</native>
</natives>
With the attached registry specs that works fine on Windows x86 and x64 (do notice the encoding of it set for UTF-8):
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!--
ATTENTION!!! do not edit with an editor which do not handle UTF-8 in a right manner!!
Storing with a wrong editor can crash this file!
Registry definition file for IzPack Installation.
$Id$
-->
<izpack:registry version="5.0"
xmlns:izpack="http://izpack.org/schema/registry"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://izpack.org/schema/registry http://izpack.org/schema/5.0/izpack-registry-5.0.xsd">
<pack name="UninstallStuff">
<!-- Special "pack", if not defined an uninstall key will be generated automatically -->
<!-- The variable $UNINSTALL_NAME can be only used if CheckedHelloPanel will be used
because there the variable will be declared. With that variabel it is possible
to install more as one instances of the product on one machine each with an
unique uninstall key. -->
<value name="DisplayName"
keypath="SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\$APP_NAME $APP_VER"
root="HKLM"
string="$APP_NAME" />
<value name="DisplayVersion"
keypath="SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\$APP_NAME $APP_VER"
root="HKLM"
string="$APP_VER (r${buildNumber})" />
<value name="UninstallString"
keypath="SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\$APP_NAME $APP_VER"
root="HKLM"
string=""$JAVA_HOME\bin\javaw.exe" -jar "$INSTALL_PATH\uninstaller\uninstaller.jar" -f -x" />
<value name="DisplayIcon"
keypath="SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\$APP_NAME $APP_VER"
root="HKLM"
string="$INSTALL_PATH\Uninstaller\uninstaller.ico" />
<value name="HelpLink"
keypath="SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\$APP_NAME $APP_VER"
root="HKLM"
string="$APP_URL" />
<value name="ServiceName"
keypath="SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\$APP_NAME $APP_VER"
root="HKLM"
string="${console.serviceName}" />
<value name="InstallPath"
keypath="SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\$APP_NAME $APP_VER"
root="HKLM"
string="$INSTALL_PATH" />
<value name="Publisher"
keypath="SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\$APP_NAME $APP_VER"
root="HKLM"
string="My Comp Software Inc." />
</pack>
</izpack:registry>
I’m still on izPack 5.0.0-beta11 but my use-case is different from yours. I do not use a second pack.
Most likely your pack name must match a defined package inside your intall.xml instead of OtherStuff.
ie:
<packs>
<pack name="GlassFish Server" required="yes" preselected="yes" hidden="true">
<description>
GlassFish Server is the world's first implementation of the Java
Platform, Enterprise Edition (Java EE) 6 specification which delivers
a flexible, lightweight, and production-ready Java EE 6 application
server.
For more details please see
</description>
<fileset dir="" targetdir="$INSTALL_PATH">
<include name="glassfish/**" />
<include name="drivers/*.jar" />
<include name="Uninstaller/*.ico" />
</fileset>
</pack>
…
</packs>
Then I would expect your RegistrySpecs.xml to have something like:
<pack name="GlassFish Server">
<value name="Name"
keypath="SOFTWARE\XXX\yyy"
root="HKLM"
string="$UNINSTALL_NAME" />
<value name="Version"
keypath="SOFTWARE\XXX\yyy"
root="HKLM"
string="$APP_VER" />
</pack>
Again, this is just my guess as I haven’t looked over izPack’s code nor have I tried this. I deducted this from the older outdated documentation at:
http://izpack.org/documentation/custom-actions.html#extended-uninstall-key
Which states that UninstallerStuff is a build in package (the generated uninstaller).
See also the newer documentation at:
http://docs.codehaus.org/pages/viewpage.action?pageId=142803064#id-(CustomActions)-CustomActionTypes
I suggest you look over izPack’s code and post back with your solution.
~ Thank you,
Paul Bors
Hi Federico,
this was made because only the registry entries for installed packs should by set. An exception is the virtual pack “UninstallStuff” which will be always assumed as defined and installed.
Cheers
Klaus