You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Eric Wood <EW...@llbean.com> on 2006/03/09 16:14:01 UTC
Issue overriding a target in build.xml that is importing other build files with the same target
I have a build.xml (A.xml) that defines:
<target name="deploy" depends="build" >
A.xml imports a build.xml file (B.xml) which does NOT have a deploy
target.
B.xml imports a build.xml file (C.xml) which does have a deploy target.
C.xml imports a build.xml file D.xml) which does have a deploy target.
So A.xml imports B.xml which imports C.xml which imports D.xml. A.xml,
C.xml and D.xml all have deploy targets.
When I execute A.xml with -debug I get the following output:
Already defined in main or a previous import, define deploy as
C.deploy
then the line
Already defined in main or a previous import, define deploy as
D.deploy
So far so good, then I get the following line in the debug output:
Build sequence for target(s) `deploy' is [init, clean-loop, clean,
_fetch, fetch, _compile, compile, _gatherReferences, gatherReferences,
_manifestClassPath, manifestClassPath, _manifest, manifest, _package,
package, build, deploy]
This is the dependency list for D.xml's deploy target. The build starts
to execute the targets in the depends="" and the build fails because
A.xml can't support the functionality that D.xml is expecting. That is
why I overrode the functionality in A.xml in the first place.
Any ideas why I am not executing my "deploy" in A.xml?
Eric
Re: Issue overriding a target in build.xml that is importing other build files with the same target
Posted by Dominique Devienne <dd...@gmail.com>.
> [...] So A.xml imports B.xml which imports C.xml which imports D.xml. A.xml,
> C.xml and D.xml all have deploy targets.
> [...]
> This is the dependency list for D.xml's deploy target. The build starts
> to execute the targets in the depends="" and the build fails because
> A.xml can't support the functionality that D.xml is expecting. That is
> why I overrode the functionality in A.xml in the first place.
>
> Any ideas why I am not executing my "deploy" in A.xml?
This sounds like a bug. I would advise you to at a minimum distill
your issue into a small testcase and submit a bug if you can still
reproduce it with this minimalist setup, and ideally submit a fix as
well ;-) --DD
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org