ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jesse Glick <jesse.gl...@sun.com>
Subject Re: Suggested change for <javac> classpaths
Date Tue, 19 Apr 2005 19:04:07 GMT
Richardson, Steph wrote:
> The javac task by default, adds the destination directory to the 
> classpath that is being used to compile [...]
> 
> This option would be very useful in projects where explicit
> dependencies between packages are manually specified, and would
> prevent the need for workarounds to this problem - such as convoluted
> tricks like compiling every package in a separate temp folder, or
> compileWithWalls or VerifyDesign from Ant-Contrib.

If you must compile using different classpaths (or other compiler 
options) within a single source root, and you can't break apart your 
sources physically into separate source roots, you can still do it: use 
explicit <src/> subelements, rather than sourcedir, and include a 
<selector>, e.g.

http://www.netbeans.org/source/browse/openide/build.xml?rev=1.187#do-lib-javac-nolocaldir

(Too complicated to serve as a very good example - sorry.)

If there are warnings/errors from the compiler, they will be hyperlinked 
to the proper sources, unlike the temp dir trick.

-J.

-- 
jesse.glick@sun.com   x22801   netbeans.org   ant.apache.org
if I had known it was harmless I would have killed it myself


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message