ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David" <>
Subject Suggestion: Specify the VM for javadoc
Date Fri, 05 Sep 2003 11:34:28 GMT
I would like to suggest the possibility of allowing to specify the VM or the
executable to be used for running <javadoc>. For running other java task
such us, <javac>, it possible to do that, but for <javadoc> it is not

Because <javadoc> fork the Virtual Machine, if you want to compile your file
for a given jdk version and also to document them using the latest javadoc
version using another jdk version, it would be better to specify JAVA_HOME
for your old jdk version, and then to specify the executable or the jdk
version for running the <javadoc>.

No if you want to compile your files for a given version (for the 1.3.1 for
example) and to generates the documentation using another jdk version (1.4.2
for example), you have to do the following:

1. fork the VM for the task <javac> then setting the attribute: executable
for the path of your jdk version.
2. Running the <javadoc> using the virtual machine used by ant (on my case
JAVA_HOME) points to jdk 1.4.2.

so, if you want to compile more than one time, you have to fork the VM every

A better aproach would be the oposite one:

1. Specify the executable for <javadoc> (that is not possible until now,
that is my suggestion)
2. Execute the <javac> using the virtual machine used by ant, now JAVA_HOME
points to the version 1.3.1.

but, <javadoc>, doesn't allow you to specify a different executable. This
solution would be nice, because <javadoc> ALWAYS fork the virtual machine,
so this alternative should be faster because you don't have to fork the
Virtual Machine for running <javac> every time.

Thanks in advance,


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message