On 11 March 2011 21:10, Scott Wilson <[email protected]> wrote:
> On 11 Mar 2011, at 20:25, Steve Lee wrote:
>
>> On 11 March 2011 19:43, Scott Wilson <[email protected]> wrote:
>>> This is a problem we've seen few times, and is specific to Ant 1.8+. It
>>> doesn't happen under Ant 1.7 for some reason.
>>>
>>> You can track it here: https://issues.apache.org/jira/browse/WOOKIE-152
> I suspect the offending line is:
>
> <src path="${wookie.features.dir}/${feature.shortname}/src" />
+1
I added comments to the ticket. Do you prefer to discuss here rather
than on ticket? I've repeated my thoughts below
> So I wonder if its reading this file twice, and adding these elements to the
> path each time. (I don't know why it wouldn't do that in Ant 1.7 too though.)
hmm - I don't think so
> Maybe it should use the srcdir attribute instead?
I tried and it makes no difference. The docs are really very clear for
javac path stuff, And I won't mention how clear it is for how the
nested ant basedir gets set :-)
Here are some observations that may help solve this
* The error seems to be the ant javac task fstating the generated
srcdir before calling the compiler
* The error is definitely in the conversion of a relative path in the
src sub element to an absolute one (doesn't happen if you prefix with
/)
* Using srcdir attribute makes no difference
* Using sourcepath="" has no effect
* To convert to abs path it prefixes with
/Users/stevelee/wookie/features/camera/ which is strange as the base
dir can be expected to be /Users/stevelee/wookie or
Users/stevelee/wookie/features/ as that is where those build files
live and cwd is the former. There seems no reason for the camera bit
at all.
* It's possible to hypothesise that ant 1.8 cwds for a subant task but
that still doesn't explain the camera bit.
* <project basedir= has no effect.
Finally I notice that wookie.features.dir is defined in the features
build file but that definition is ignored. Also the parent build uses
it but doesn't not define it. So perhaps its in an included file in
parent and inherited so local definition in child doesn't get used? Is
this what inherit all does?
* perhaps something is define the base dir to be
/Users/stevelee/wookie/features/camera/ but what?
Steve