[izpack-users] Specifying Required Packs and OSs
Hal Vaughan
hal at thresholddigital.com
Mon Jan 2 03:44:27 CET 2006
On Sunday 01 January 2006 04:52 pm, Klaus Bartz wrote:
> Hi Hal,
>
> Am 31.12.2005, 18:42 Uhr, schrieb Hal Vaughan <hal at thresholddigital.com>:
> > Have you had any problem with the packs for one OS being installed on the
> > other OS?
>
> No.
>
> > I'm testing on Linux and WinXp. I found if I specified one pack
> > as "windows" and the other as "linux" the test install on Linux gets
> > only the
> > "linux" pack, but the test install on Windows gets both packs. (And I'm
> > using the latest version of IzPack!)
>
> "linux" is not a valid name for the OS attribute of all elements like pack,
> file, fileset etc.
> The attribute OS is old and will be present for compatibility. There only
> the
> three values "windows" "unix" and "mac" are valid. The element OS is newer
> and
> you can specify the os in more detail. In addition to the family
> ("windows" "unix" and "mac") you can specify the OS name like "Windows XP".
> The name will be given by the VM using System.getProperty("os.name"). I
> doubt
> that "linux" will be a valid os.name property of a VM.
Okay. This is VERY helpful. I got the attributes and elements mixed up.
I'll take that into account.
...
> Using the OS attribute "linux" at the element <file> does also NOT work.
> It is the same behavior. I had offered that I can look into your pack
> declaration. If it is not an option for you, also OK. I think, my real
> pack declarations will only confuse you more. Therefore an example of an
> install.xml only for seeing how to declare OS dependency of packs:
Actually, I will probably post my install file. Basically, I was hoping
creating the install would be a one day thing. I spent from noon one day
until 5 am the next reviewing packages and trying to learn enough to make a
choice. The next day I was focused on using IzPack, and had to either finish
it and set it aside. Things were not working (I suspect there are some bugs
in the UserInput Panel and some serious bugs in the Search subclass, or
possibly the PathInput Panel, since it would not list default directories in
the UserInput or JDKPath Panels in some cases). It was basically getting to
the point where I had tried everything that seemed logical and it was not
working. So I had a few hours left and was trying everything I could. I
think, at this point, it is a mess.
However, the next project I had to do was supposed to take up to 2 weeks and
it worked out in a day, so now I have time to come back to this issue. I'll
take what you have said into account and see if it helps. The file (below)
is also a help for me.
As to my original question, I am concerned because I need to include
OpenOffice, which is a lot of data to download, so I don't want an internet
install to download both Linux and Windows versions. To handle this, I think
I'm going to just create 2 installers, one each for Linux and Windows.
Thanks!
Hal
> <installation version="1.0">
>
> <!-- The info section -->
> <info>
> <appname>InstallTest2</appname>
> <appversion>0.0.1 (build 2006.01.01)</appversion>
> <authors>
> <author email="" name="Klaus Bartz (developer)" />
> </authors>
> <url>http://www.izforge.com/izpack/</url>
> <javaversion>1.4</javaversion>
> </info>
>
> <!-- Flexible and in the screen proportions -->
> <guiprefs height="600" resizable="yes" width="800">
> <laf name="looks">
> <os family="unix" />
> </laf>
> </guiprefs>
>
> <!-- We include every langpack -->
> <locale>
> <langpack iso3="eng" />
> <langpack iso3="deu" />
> </locale>
> <!-- The panels in a classic order -->
> <panels>
> <panel classname="TargetPanel" />
> <panel classname="InstallPanel" />
> <panel classname="SimpleFinishPanel" />
> </panels>
> <!-- The packs section -->
> <packs>
> <!-- The core files -->
> <pack name="Core" required="yes">
> <description>The InstallTest core files.</description>
> <file src="core.txt" targetdir="$INSTALL_PATH" />
> </pack>
> <!-- The UNIX core files -->
> <pack name="UnixCore" required="yes" os="unix" >
> <description>The UNIX specific InstallTest core
> files.</description>
> <file src="UnixCore.txt" targetdir="$INSTALL_PATH" />
> </pack>
> <!-- The WINDOWS core files -->
> <pack name="WINCore" required="yes">
> <description>The Windows XP InstallTest core
> files.</description>
> <os family="windows" name="windows xp" />
> <file src="WindowsXPCore.txt" targetdir="$INSTALL_PATH" />
> </pack>
> <pack name="WINCore" required="yes" os="windows" >
> <description>The InstallTest core files for all Windows
> systems.</description>
> <file src="WindowsCore.txt" targetdir="$INSTALL_PATH" />
> </pack>
> <!-- The MAC core files -->
> <pack name="MACCore" required="yes" os="mac">
> <description>The InstallTest core files.</description>
> <file src="MacCore.txt" targetdir="$INSTALL_PATH" />
> </pack>
> </packs>
>
> </installation>
>
> > Right now I've had to step back. I am having so many problems with
> > IzPack I'm
> > not sure what to do. With my program I have to also install RealVNC and
> > OpenOffice. My program has to know where both are and it would look
> > damned
> > clumsy if I have a client install both of those THEN, when installing my
> > program, my installer asks, "Do you have OpenOffice installed?" and,
> > "What is
> > the path name?" So I really need to either install those programs along
> > with
> > mine, which I can do with the Process Panel by copying over the files as
> > packs, including parsing paths and such, so the Process Panel will run
> > batch
> > files that will do the install with response files that specify
> > directories
> > my client has picked for OOo and VNC.
>
> On Windows both programs are in the registry. You can look into the
> registry since IzPack 3.8 if the installer has read access in the registry.
> But this feature is only an undocumented add on of my
> RegistryInstallerListener.
> To use it implies knowledge of java and the possibility to extract the
> implicit
> rules from an other source. The class
> com.izforge.izpack.panels.CheckedHelloPanel
> can be used as example.
>
> > I have that working my own install program (which doesn't look as nice as
> > IzPack, doesn't do networked installs, and is not as easy to maintain).
> > However, to get it working in IzPack, I need to use the Search object in
> > the
> > UserInput panel, and no matter what I try, it is completely messed up.
> > I've
> > tried using it almost exactly like it was shown in the docs (changed path
> > names, but otherwise the same), and it does not work. Until I can get
> > something like this to work for me (so the user can either select an
> > install
>
> You know, I do not use UserInputPanel.
>
> > path for OOo and VNC *OR* tell me where they are), IzPack won't do what I
> > need. I've considered writing my own panels, but I'm not sure I fully
> > understand what I need to do that (I'm self taught, so I have a lot of
> > holes
> > in my background).
>
> You can only write own custom panels if you are firm with java. IzPack is
> not the best place to learn java...
> In chapter "Getting started" there is the paragraph
> "How to develop and debug IzPack using Eclipse"
> Do it. Never write a panel without the possibility to debug. The fastes
> way to learn something of the internals of IzPack is to step through an
> installation.
> For path panels look into
> com.izforge.izpack.panels.TargetPanel
> An other path panel really needs the methods isValidated() and
> panelActivate()
> rest is specific for the target panel. If you would see how to verify
> something,
> look into
> com.izforge.izpack.panels.JDKPathPanel
>
> > So, for now, I've had to set this aside until I can either get some
> > answers,
> > find a way to get everything on the UserInput Panel to work correctly, or
> > learn enough to write my own panel. I'm going to take time to think of
> > all
> > the issues I'm having, write them up as questions, and post them on the
> > list.
> > Then (I hope) when I'm ready to get back to the install part of my
> > program,
> > the answers should have been worked out.
> >
> > Thanks for the response. I'll be posting my install.xml file when I get
> > back
> > to this so I can ask for help on a number of topics.
> >
> > Hal
> > _______________________________________________
> > izpack-users mailing list
> > izpack-users at lists.berlios.de
> > http://lists.berlios.de/mailman/listinfo/izpack-users
> >
> >
> > __________ NOD32 1.1347 (20051230) Information __________
> >
> > Diese E-Mail wurde vom NOD32 Antivirus System geprüft
> > http://www.nod32.com
More information about the izpack-users
mailing list