ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Trevor Harmon <>
Subject javac task + sourcepathref + excluded files = impossible?
Date Tue, 10 Apr 2007 00:21:28 GMT
I have a list of source files that must be supplied to javac as well  
as several other tasks. It's a complex list with excludes, so I want  
to factor it out as a path reference to avoid future copy-and-paste  
bugs. But this doesn't seem to be possible!

My path reference is defined like this:

<path id="src.files">
   <fileset dir="src">
     <include name="**/*.java"/>
     <exclude name="some/directory/"/>
     <exclude name="some/directory/"/>

But when I call javac:


I get an error saying I didn't specify the srcdir attribute.

Okay, so I set srcdir to the same directory as my path reference, but  
then my excluded files don't get excluded! It seems the srcdir  
attribute overrides whatever is in the sourcepathref attribute.

Is that a bug? Or am I doing something wrong? Thanks,


P.S. I'm using Ant 1.7.0.

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

View raw message