This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [ecj] Error compiling executable on i686-pc-linux-gnu


Mohan Embar writes:
 > Hi All,
 > 
 > I tried to build a Linux gcj and then do:
 > 
 > gcj --main=HelloJ5 -o HelloJ5 HelloJ5.java
 > 
 > A .class file gets generated in the current directory
 > (and this runs okay with gij), but instead of getting
 > an executable, I get:
 > 
 > /tmp/ccmCwrnA.jar:0: error: malformed .zip archive in CLASSPATH: /tmp/ccip4wgn.zip/
 > 
 > I'm not seeing either the .jar or .zip in /tmp.
 > 
 > Any ideas?

I remember this one, which was a hell of a job to find.

This was caused by a change to ecj1, which once used the syntax
-fzip-dependency=%U.zip and at some other time used the syntax 
-fzip-dependency %U.zip

Please find out which syntax the version of ecj1 that you are using
really wants, and we'll correct lang-specs.h accordingly.

Here's the diff:

Index: lang-specs.h
===================================================================
--- lang-specs.h        (revision 118935)
+++ lang-specs.h        (revision 118936)
@@ -44,8 +44,8 @@
       %{foutput-class-dir*} %{g*}                                      \
       %{fsource*} %{!fsource*:-fsource=1.5}                            \
       %{ftarget*} %{!femit-class-files|!ftarget*:-ftarget=1.5}         \
-      %{!findirect-dispatch:-fzip-dependency %U.zip}                   \
-      %{!fsyntax-only:-fzip-target %U.jar}}\n                          \
+      %{!findirect-dispatch:-fzip-dependency=%U.zip}                   \
+      %{!fsyntax-only:-fzip-target=%U.jar}}\n                          \
     %{.class|.zip|.jar|!fsyntax-only:jc1                               \
       %{.java|fsaw-java-file:%U.jar -fsource-filename=%i %<ffilelist-file} \
       %{.class|.zip|.jar|ffilelist-file|fcompile-resource*:%i}         \
Andrew.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]