Hi. See below.

Peter Donald wrote:

At 06:43  15/9/00 -0500, you wrote:
>Hi,
>
>We have a fairly large Java source tree (500+ *.java files in a dozen
>packages/subpackages) which we would like to use Ant to build.
>
>
> after a minute
>of two, the build fails with an OutOfMemoryError.  We think javac simply
>has too many files to compile.
>
>Has this problem come up before?  Is there a good solution to this
>problem (other than the obvious hacks: split the project into two,
>increase the maximum memory size for javac)?

well I use jikes to compile projects with about 1400 files - so that would
definetly be an option :P. Otherwise you are left with splitting up the
build :( or perhaps you could make java task launch a new process and pass
flags to alow the JVM to use more memory


You could also not fork, and just give more memory to the JVM running Ant.  Use the -ms and -mx flags to the 'java' command in the ant script file, or set the $JAVACMD environment variable that that script uses, in your .antrc, to

  setenv JAVACMD "/my/path/to/java -ms128 -mx128"

-- 
David Bullock
Project Leader 
dbullock@lisa.com.au

"It's no use saying 'We are doing our best.'  You 
have got to succeed in doing what's necessary."  
    ...Winston Churchill


LISAsoft
http://www.lisa.com.au/

Adelaide                  Sydney
--------------------      ------------------------
38 Greenhill Rd           Level 3, 228 Pitt Street
Wayville S.A. 5034        Sydney NSW 2000
Australia                 Australia

PH  +61 8 8272 1555       PH  +61 2 9283 0877
FAX +61 8 8271 1199       FAX +61 2 9283 0866
--------------------      ------------------------