ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rich Wagner" <>
Subject <java>'s "jvm" attribute should imply "fork=true"...
Date Fri, 06 Jun 2003 17:09:45 GMT

I recently had an Ant build file which included a <java> task which needed 
to use a specific JVM.  So I included the appropriate "jvm" attribute, but 
did NOT include any "fork" attribute.  But (without going into the details) 
things weren't working right, and when we coded what appeared to be an 
equivalent "java.exe" command line invocation, things were fine...

Well, after much confusion and head-scratching, we realized what the problem 
was, and it's best stated by the "<java>" task documentation:

        "jvm" attribute ... Ignored if fork is disabled.

Sure enough, when I added 'fork="true" ' to my <java> tasks, everything was 

Now, before I added the "fork" attribute, I didn't disable "fork" 
explicitly: the default value for the "fork" attribute is just "false".  So 
an IMPLICIT default value for one attribute overrode my EXPLICIT value for 
the "jvm" attribute ?!?  Hmmm, pretty questionable behavior for the <java> 
task, no ?

Thoughts ?  Should I try to convince the Ant developers that this qualifies 
as a bug that should be fixed ?

Rich Wagner

Add photos to your e-mail with MSN 8. Get 2 months FREE*.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message