This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
RFC: Multiple Java Source Files - Combine Inputs By Default
- From: Ranjit Mathew <rmathew at gmail dot com>
- To: Per Bothner <per at bothner dot com>, GCJ <java at gcc dot gnu dot org>
- Date: Mon, 21 Jun 2004 12:10:52 +0530
- Subject: RFC: Multiple Java Source Files - Combine Inputs By Default
Hi,
Per enabled "compiling multiple files at once" support to jc1:
http://gcc.gnu.org/ml/java/2001-02/msg00058.html
However, for "normal" gcj invocations like:
gcj --main=Foo Foo.java Bar.java
this is not done unless one uses the "-o" option as well.
This is because:
------------------------- jvspec.c -------------------------
443 if ((saw_o && java_files_count + class_files_count +
zip_files_count > 1)
444 || (saw_C && java_files_count > 1)
445 || (indirect_files_count > 0
446 && java_files_count + class_files_count +
zip_files_count > 0))
447 combine_inputs = 1;
------------------------- jvspec.c -------------------------
This might seem trivial, but this causes different code
paths to be taken (and thus possibly different behaviour due
to bugs) depending on whether the user specified "-o" or
not. For an example, see:
http://gcc.gnu.org/ml/gcc-patches/2004-06/msg01589.html
I suggest that we remove the dependency on "-o" and always
combine input java sources/classes.
Per, is there any particular reason you added that extra
check (shown above)?
Ranjit.