Pulpcore build fails when 'pulpcore.java.language' set to '1.5'

6 views
Skip to first unread message

nouknouk

unread,
Apr 15, 2010, 5:02:22 PM4/15/10
to PulpCore
Hi,

I'm setting up a pulpcore dev. environment using pulpcore latest
package and NetBeans (but *not* netbeans pulcore plugin).

My project compiles well when in the build.xml file I set the java
language syntax to 1.4.
In buil.xml, line 74, I have:

<!-- Java language to use. May be 1.4 or 1.5. If the value is 1.5,
Retroweaver is used. -->
<property name="pulpcore.java.language" value="1.4" />


As soon as I set the version to 1.5 (and thus I'm using retroweaver),
the compilation fails with the following error:

Building jar: D:\documents\programmation\myProject\svn\applet\build
\applet\myJarName.jar
Copying 1 file to D:\documents\programmation\myProject\svn\applet\build
\applet
Processing 907 classes
D:\documents\programmation\myProject\svn\applet\build.xml:267:
java.util.zip.ZipException: duplicate entry: glyphs.png
at
java.util.zip.ZipOutputStream.putNextEntry(ZipOutputStream.java:175)
at
java.util.jar.JarOutputStream.putNextEntry(JarOutputStream.java:92)
at
net.sourceforge.retroweaver.RetroWeaver.weaveJarFile(RetroWeaver.java:
216)
at
net.sourceforge.retroweaver.ant.RetroWeaverTask.execute(RetroWeaverTask.java:
381)
at
org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
at sun.reflect.GeneratedMethodAccessor124.invoke(Unknown
Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:
25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:
106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:357)
at org.apache.tools.ant.Target.performTasks(Target.java:385)
at
org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
at org.apache.tools.ant.Project.executeTarget(Project.java:
1306)
at
org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:
41)
at org.apache.tools.ant.Project.executeTargets(Project.java:
1189)
at
org.apache.tools.ant.module.bridge.impl.BridgeImpl.run(BridgeImpl.java:
278)
at
org.apache.tools.ant.module.run.TargetExecutor.run(TargetExecutor.java:
498)
at
org.netbeans.core.execution.RunClassThread.run(RunClassThread.java:
151)
BUILD FAILED (total time: 2 seconds)

The highlighted line (267) of the error in build.xml is the following
line in the "-retroweave" target:
<retroweaver inputjar="${basedir}/${build}/in.jar" outputjar="$
{basedir}/${build}/in2.jar" />


The error seems to be the consturction of 'in2.jar' because in the
previously generated input file 'in.jar', I can find three times the
same file (glyphs.png) in the root of the archive. Why do I have
multiple times a resource file in the 'in.jar' file ? Shouldn't it be
stored in the external ZIP file ?

Any idea on how to solve the issue ?
Thanks in advance.

Nouk²

David Brackeen

unread,
Apr 15, 2010, 5:23:21 PM4/15/10
to pulp...@googlegroups.com
What version and what template are you using? Those line numbers don't match up with either existing build.xml
http://code.google.com/p/pulpcore/source/browse/templates/quick/build.xml?r=8c05ed50e94e6065fb4e1805c9f204fc75a746c0


--
You received this message because you are subscribed to the Google Groups "PulpCore" group.
To post to this group, send email to pulp...@googlegroups.com.
To unsubscribe from this group, send email to pulpcore+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/pulpcore?hl=en.


nouknouk

unread,
Apr 15, 2010, 6:09:30 PM4/15/10
to PulpCore
Ok, got it.

In fact, the issue came from the place where I decided to store the
'pulpcore-applet-debug-0.11' and other related JAR files.
In order to have them embedded in my project folder I stored them in a
directory 'lib' in the root of my project folder.
It seems the name 'lib' wasn't much appreciated by the build.xml file,
probably because it was considering the lib folder as the place of
'third party JAR files' which have to be embedded in the applet JAR.
Thus, I suppose the pulpcore lib was embedded two times in the JAR of
my built project.
I finally renamed the 'lib' folder by something else ('pulpcore-lib"
in my case), updated the build.xml and build.properties files, and it
is now ok.


So, now everything compiles well :-)


> What version and what template are you using? Those line numbers don't match

It was because my build.xml is customized a bit, in order to include
other external libs, namely:
- I added a pathelement in the classpath of the 'compile' target
- I added a zipfileset entry in the 'jar' target.

Anyway; thanks for your help.


Nouk²

Reply all
Reply to author
Forward
0 new messages