I have a problem with building vaadin 6.5 from source on windows 7. I execute build with command
ant -Dignoreversion=1 package-jar compiling starts and after couple of minutes I encounter an error:
[jar]
Building jar: D:\vaadin-6.5.0_src\build\result\vaadin-6.5.1.dev-20110202\WebContent\WEB-INF\lib\vaadin-6.5.1.dev-20110202.jar
[java]
Updating manifest in JAR build/result/vaadin-6.5.1.dev-20110202/WebContent/WEB-INF/lib/vaadin-6.5.1.dev-20110202.jar
[java]
jar: java.io.IOException: Error in writing existing jar file
[java]
jar: at sun.tools.jar.Main.run(Main.java:217)
[java]
jar: at sun.tools.jar.Main.main(Main.java:1149)
[java]
The ‘jar’ command returned with exit value 1
BUILD FAILED
Compiling source 6.4 works fine, have a solution for this?
btw it is my first post and I have been working with vaadin for 2 weeks so hello to everyone
Sounds like
http://dev.vaadin.com/ticket/6045 . One guess is that is has something to do with the file being locked for some reason on Windows (this does not happen on other platforms).
OK, I circumvented compiler and I compiled source without problem on mac :smug:
Little update, with new jar one thing doesn’t work - embedded flash. I use in my app flash charts and in firefox don’t even upload flash file, in ie or chrome it uplods movie but it also doesn’t work correctly.
As I mentioned before I compiled it on mac with ant package-jar but running on windows. Original vadin 6.5 jar works fine, I recompiled widgetset and don’t know what else to do.
Can the problem be in that I compile on mac (maybe wrong target)?
and as I said before it works fine with original 6.5.0.jar but with jar compiled by me it doesn’t. Strange because I didn’t change anything corresponding to visual part of vaadin.
Shouldn’t you call
jar.close() in
com.vaadin.buildhelpers.GeneratePackageExports before creating the
ManifestWriter instance for overwriting the Jar file contents? I think
GeneratePackageExports opens the Jar file but never closes it, and
ManifestWriter tries to open it again (which obviously fails). After adding the above code to
GeneratePackageExports class, I was able to execute build process on my Windows 7 again.