[izpack-users] How does variable substitution work?

RAMOS lionel calimucho at gmail.com
Thu Jun 14 11:22:31 CEST 2007


Hi Klaus,

I will check this. I'm newbe in ant conception.
It's just to don't change all the tomcat5.5 when I want to change the tomcat
version.

Thanks for you're quick response,
cheers,
lionel

On 6/14/07, Bartz, Klaus <Klaus.Bartz at coi.de> wrote:
>
>  Hi lionel,
> variables are only used at installation time, not at packaging
> ("compile").
> <pack> and the targetdir of a <file> will be used at installation time,
> the source
> at packaging. The IzPack compiler uses the src path to catch the file and
> put it
> into the installation jar file. Therefore you cannot use an IzPack
> variable at that place.
>
> Ok, what todo? Use an ant build script where you can use ant replace or so
> before
> calling the IzPack ant task.
> Look into the build script of IzPack.
> %IZ_HOME%\src\build.xml
>
> Cheers
>
> Klaus
>
>
>  -----Original Message-----
> *From:* izpack-users-bounces at lists.berlios.de [mailto:
> izpack-users-bounces at lists.berlios.de] *On Behalf Of *RAMOS lionel
> *Sent:* Thursday, June 14, 2007 10:37 AM
> *To:* izpack-users at lists.berlios.de
> *Subject:* Re: [izpack-users] How does variable substitution work?
>
> Hi guys,
>
> I have moreover the same problem with the variable substitution but all in
> the install.xml
>
> I declare a variable
> <variable name="TomcatVersion" value="tomcat-5.5"/>
>
> and in <pack> tag I want to use like this:
>
> <file targetdir="$INSTALL_PATH" src="dnabi-install/${TomcatVersion}"/>
>
> But he don't replace the variable...
> Any tips? Because for me it's very usefull
>
> Thanks in advance,
> lionel
>
>
> On 6/14/07, Bartz, Klaus <Klaus.Bartz at coi.de> wrote:
> >
> > Hi Gernot,
> > variables will be not substituted by the contents of variables.
> > I see to ways to solve your problem.
> >
> > 1: write a custom action which does the substitution.
> >
> > 2: use
> > in install.xml
> > ...
> > <variable name="APPLICATIONS_SUB_PATH"
> >    value="/OpenOffice/orgPortable/App/openoffice/program/soffice.exe"/>
> > ...
> >
> > in your parsable file
> > <value>${APPLICATIONS_DEFAULT_ROOT}${APPLICATIONS_SUB_PATH}</value>
> >
> > Cheers
> >
> > Klaus
> >
> > > -----Original Message-----
> > > From: izpack-users-bounces at lists.berlios.de
> > > [mailto:izpack-users-bounces at lists.berlios.de] On Behalf Of
> > > Gernot Stenz
> > > Sent: Wednesday, June 13, 2007 6:44 PM
> > > To: izpack-users at lists.berlios.de
> > > Subject: [izpack-users] How does variable substitution work?
> > >
> > >
> > >
> > > Hello,
> > >
> > > I have yet another problem with my IzPack ( 3.10.0) installer:
> > >
> > > I need to set the path for an executable file. I do this
> > > using a variable and a <parsable>
> > > tag:
> > >
> > > <variable name="OOEXECUTABLE"
> > > value="$APPLICATIONS_DEFAULT_ROOT/OpenOfficeorgPortable/App/op
> > > enoffice/program/soffice.exe"/>
> > >
> > > <parsable type="xml"
> > > targetfile="$INSTALL_PATH/Editor-3.3rc5/res/vmodellexport.xml"/>
> > >
> > > and in said file I have the following:
> > >
> > > <value>$OOEXECUTABLE</value>
> > >
> > > However, after installation, the respective line in the file
> > > looks like this:
> > >
> > > <value>$APPLICATIONS_DEFAULT_ROOT/OpenOfficeorgPortable/App/op
> > > enoffice/program/soffice.exe</value>
> > >
> > > Why doesn't $APPLICATIONS_DEFAULT_ROOT get substituted?
> > >
> > > Thanks in advance, Gernot
> > >
> > > --
> > >     __o  Gernot Stenz
> > > e-mail:stenzg at informatik.tu-muenchen.de        /\
> > >    -\<,          WWW:  http://www4.in.tum.de/~stenzg
> > >      /\/--\
> > > _(_)/(_)_London - Paris: 3547
> > > km__________________________________/      \
> > >
> > > _______________________________________________
> > > izpack-users mailing list
> > > izpack-users at lists.berlios.de
> > > https://lists.berlios.de/mailman/listinfo/izpack-users
> > >
> > _______________________________________________
> > izpack-users mailing list
> > izpack-users at lists.berlios.de
> > https://lists.berlios.de/mailman/listinfo/izpack-users
> >
>
>
> _______________________________________________
> izpack-users mailing list
> izpack-users at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/izpack-users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.berlios.de/pipermail/izpack-users/attachments/20070614/b8cfb2fd/attachment.html 


More information about the izpack-users mailing list