Building the setup project

Justin Dearing <[email protected]> Thu, 29 Oct 2015 01:47:46 +0000
Newsgroups gmane.comp.java.tn5250j.devel
Message-ID <CABsCM1Pc5w4rmPfg9Pia37Je1b3o1Pc+eJC=oBvgr1-RP+Nsnw@mail.gmail.com>
--===============1966807176853439608==
Content-Type: multipart/alternative; boundary=001a113a9bb6f3303b0523347fbe

--001a113a9bb6f3303b0523347fbe
Content-Type: text/plain; charset=UTF-8

Hello,

I would like to add start menu icons to the setup project. However, I have
yet to get generate-installer to work. The current error message is

   [izpack] Oct 28, 2015 8:43:21 PM
com.izforge.izpack.core.container.PlatformProvider provide
   [izpack] INFO: Detected platform:
windows,version=10.0,arch=x64,symbolicName=null,javaVersion=1.8.0_66
   [izpack] Exception in thread "Thread-0"
com.izforge.izpack.api.exception.CompilerException:
C:\Users\Justin\Documents\tn5250j-code\tn5250j/dist/installer/install.xml:1:
the file version is different from the compiler version
   [izpack]     at
com.izforge.izpack.ant.IzpackAntRunnable.run(IzpackAntRunnable.java:79)
   [izpack]     at java.lang.Thread.run(Thread.java:745)
   [izpack] Caused by: com.izforge.izpack.api.exception.CompilerException:
C:\Users\Justin\Documents\tn5250j-code\tn5250j/dist/installer/install.xml:1:
the file version is different from the compiler version
   [izpack]     at
com.izforge.izpack.compiler.helper.AssertionHelper.parseError(AssertionHelper.java:61)
   [izpack]     at
com.izforge.izpack.compiler.resource.ResourceFinder.getXMLTree(ResourceFinder.java:188)
   [izpack]     at
com.izforge.izpack.compiler.CompilerConfig.executeCompiler(CompilerConfig.java:316)
   [izpack]     at
com.izforge.izpack.ant.IzpackAntRunnable.run(IzpackAntRunnable.java:75)
   [izpack]     ... 1 more


Here are the changes I made to get it to talk to my Izrepack install:

C:\Users\Justin\Documents\tn5250j-code\tn5250j>git diff
diff --git a/tn5250j/build.properties b/tn5250j/build.properties
index 7e9f7b8..736ec1d 100644
--- a/tn5250j/build.properties
+++ b/tn5250j/build.properties
@@ -20,7 +20,7 @@ Name=Tn5250j
 version=0.7.7-Snapshot
 year=2001-2015

-IzPack.dir=c:/IzPack/
+IzPack.dir=C:/Program Files/IzPack^M

 main.class=org.tn5250j.My5250

diff --git a/tn5250j/build.xml b/tn5250j/build.xml
index a4eef44..60d0326 100644
--- a/tn5250j/build.xml
+++ b/tn5250j/build.xml
@@ -301,9 +301,11 @@
   <!-- Creates an installer for tn5250j -->
   <target name="generate-installer" depends="dist" description="Creates
installer using IzPack">

+    <path id="build.classpath">
+        <fileset dir="${IzPack.dir}/lib" includes="*.jar"/>
+    </path>
     <!-- Allows us to use the IzPack Ant task -->
-    <taskdef name="izpack" classpath="${IzPack.dir}/lib/compiler.jar"
-             classname="com.izforge.izpack.ant.IzPackTask"/>
+    <taskdef name="izpack" classpathref="build.classpath"
classname="com.izforge.izpack.ant.IzPackTask"/>

     <!-- Copies the files to the dist directory -->
     <echo message="Copies the image of the distribution to ${dist.dir}"/>

Any ideas for next steps?

Justin Dearing

--001a113a9bb6f3303b0523347fbe
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Hello,<div><br></div><div>I would like to add start menu i=
cons to the setup project. However, I have yet to get generate-installer to=
 work. The current error message is</div><div><br></div><div><div>=C2=A0 =
=C2=A0[izpack] Oct 28, 2015 8:43:21 PM com.izforge.izpack.core.container.Pl=
atformProvider provide</div><div>=C2=A0 =C2=A0[izpack] INFO: Detected platf=
orm: windows,version=3D10.0,arch=3Dx64,symbolicName=3Dnull,javaVersion=3D1.=
8.0_66</div><div>=C2=A0 =C2=A0[izpack] Exception in thread &quot;Thread-0&q=
uot; com.izforge.izpack.api.exception.CompilerException: C:\Users\Justin\Do=
cuments\tn5250j-code\tn5250j/dist/installer/install.xml:1: the file version=
 is different from the compiler version</div><div>=C2=A0 =C2=A0[izpack] =C2=
=A0 =C2=A0 at com.izforge.izpack.ant.IzpackAntRunnable.run(IzpackAntRunnabl=
e.java:79)</div><div>=C2=A0 =C2=A0[izpack] =C2=A0 =C2=A0 at java.lang.Threa=
d.run(Thread.java:745)</div><div>=C2=A0 =C2=A0[izpack] Caused by: com.izfor=
ge.izpack.api.exception.CompilerException: C:\Users\Justin\Documents\tn5250=
j-code\tn5250j/dist/installer/install.xml:1: the file version is different =
from the compiler version</div><div>=C2=A0 =C2=A0[izpack] =C2=A0 =C2=A0 at =
com.izforge.izpack.compiler.helper.AssertionHelper.parseError(AssertionHelp=
er.java:61)</div><div>=C2=A0 =C2=A0[izpack] =C2=A0 =C2=A0 at com.izforge.iz=
pack.compiler.resource.ResourceFinder.getXMLTree(ResourceFinder.java:188)</=
div><div>=C2=A0 =C2=A0[izpack] =C2=A0 =C2=A0 at com.izforge.izpack.compiler=
.CompilerConfig.executeCompiler(CompilerConfig.java:316)</div><div>=C2=A0 =
=C2=A0[izpack] =C2=A0 =C2=A0 at com.izforge.izpack.ant.IzpackAntRunnable.ru=
n(IzpackAntRunnable.java:75)</div><div>=C2=A0 =C2=A0[izpack] =C2=A0 =C2=A0 =
... 1 more</div></div><div><br></div><div><br></div><div>Here are the chang=
es I made to get it to talk to my Izrepack install:</div><div><br></div><di=
v><div>C:\Users\Justin\Documents\tn5250j-code\tn5250j&gt;git diff</div><div=
>diff --git a/tn5250j/build.properties b/tn5250j/build.properties</div><div=
>index 7e9f7b8..736ec1d 100644</div><div>--- a/tn5250j/build.properties</di=
v><div>+++ b/tn5250j/build.properties</div><div>@@ -20,7 +20,7 @@ Name=3DTn=
5250j</div><div>=C2=A0version=3D0.7.7-Snapshot</div><div>=C2=A0year=3D2001-=
2015</div><div><br></div><div>-IzPack.dir=3Dc:/IzPack/</div><div>+IzPack.di=
r=3DC:/Program Files/IzPack^M</div><div><br></div><div>=C2=A0main.class=3Do=
rg.tn5250j.My5250</div><div><br></div><div>diff --git a/tn5250j/build.xml b=
/tn5250j/build.xml</div><div>index a4eef44..60d0326 100644</div><div>--- a/=
tn5250j/build.xml</div><div>+++ b/tn5250j/build.xml</div><div>@@ -301,9 +30=
1,11 @@</div><div>=C2=A0 =C2=A0&lt;!-- Creates an installer for tn5250j --&=
gt;</div><div>=C2=A0 =C2=A0&lt;target name=3D&quot;generate-installer&quot;=
 depends=3D&quot;dist&quot; description=3D&quot;Creates installer using IzP=
ack&quot;&gt;</div><div><br></div><div>+ =C2=A0 =C2=A0&lt;path id=3D&quot;b=
uild.classpath&quot;&gt;</div><div>+ =C2=A0 =C2=A0 =C2=A0 =C2=A0&lt;fileset=
 dir=3D&quot;${IzPack.dir}/lib&quot; includes=3D&quot;*.jar&quot;/&gt;</div=
><div>+ =C2=A0 =C2=A0&lt;/path&gt;</div><div>=C2=A0 =C2=A0 =C2=A0&lt;!-- Al=
lows us to use the IzPack Ant task --&gt;</div><div>- =C2=A0 =C2=A0&lt;task=
def name=3D&quot;izpack&quot; classpath=3D&quot;${IzPack.dir}/lib/compiler.=
jar&quot;</div><div>- =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 classname=
=3D&quot;com.izforge.izpack.ant.IzPackTask&quot;/&gt;</div><div>+ =C2=A0 =
=C2=A0&lt;taskdef name=3D&quot;izpack&quot; classpathref=3D&quot;build.clas=
spath&quot; classname=3D&quot;com.izforge.izpack.ant.IzPackTask&quot;/&gt;<=
/div><div><br></div><div>=C2=A0 =C2=A0 =C2=A0&lt;!-- Copies the files to th=
e dist directory --&gt;</div><div>=C2=A0 =C2=A0 =C2=A0&lt;echo message=3D&q=
uot;Copies the image of the distribution to ${dist.dir}&quot;/&gt;</div></d=
iv><div><br></div><div>Any ideas for next steps?</div><div><br></div><div>J=
ustin Dearing</div></div>

--001a113a9bb6f3303b0523347fbe--


--===============1966807176853439608==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

------------------------------------------------------------------------------

--===============1966807176853439608==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Tn5250j-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tn5250j-develop

--===============1966807176853439608==--