You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Rum Pel <ru...@hotmail.com> on 2002/06/04 10:38:39 UTC

Re: GNU Java compiler

>
> > How do I make ant to use the GNU java compiler (gcj) instead
> > of javac?
>
> Read the documentation of <javac> especially the discussion of the
> build.compiler property.
>

gcj doesnt seem to compile sources recursively (ie., compiling the source
dependancies). javac does. I couldnt find any option to gcj for this
behaviour,
does anybody know how to do this?

thanks,
--rp.

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: GNU Java compiler

Posted by Rum Pel <ru...@hotmail.com>.
> > gcj doesnt seem to compile sources recursively (ie., compiling the
> > source dependancies). javac does. I couldnt find any option to gcj
> > for this behaviour, does anybody know how to do this?
>
> If I understand your question correctly, you may want to look at the
> (optional) <depend> task.
>

It is not about deleting outdated classes, but compiling all those outdated
classes at one go. Note that we do not specify all those outdated classes
explicitly, javac picks them up automatically for compilation. gcj doesnt.

I have three classes A, B, C and D. A depends on B and C. Running A creates
a new source E, on which D depends. So my build.xml is

<javac src="A.java" ... /> # this compiles A, B and C.
<java classname="A" .. /> # this creates D.
<javac src="*.java" .. />

With gcj, the first javac doesnt compile B and C and so the java task fails.
I can specify all the necessary sources in the first javac, but as the
number of
classes is large - I am looking for a better way of doing this, if it
exists.

thanks,
--rp.


> Diane
>
> =====
> (holtdl@yahoo.com)
>
>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: GNU Java compiler

Posted by Diane Holt <ho...@yahoo.com>.
--- Rum Pel <ru...@hotmail.com> wrote:
> gcj doesnt seem to compile sources recursively (ie., compiling the
> source dependancies). javac does. I couldnt find any option to gcj
> for this behaviour, does anybody know how to do this?

If I understand your question correctly, you may want to look at the
(optional) <depend> task.

Diane

=====
(holtdl@yahoo.com)



__________________________________________________
Do You Yahoo!?
Yahoo! - Official partner of 2002 FIFA World Cup
http://fifaworldcup.yahoo.com

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>