But isn't this a bug Stefan!?!?!

You give us a solution that works around the bug (?), but don't explain why
when using <ant>/<antcall> (which reparses the build file, and thus
re-performs a lot of processing) the 'global' <taskdef>s are simply ignored.

Otherwise, all targets using a custom task/type have to use an idiom like:

<target name="taskdef" unless="taskdef.done">
  <taskdef ... />
  <typedef ... />
  <property name="taskdef.done" value="" />
</target>

<target name="do-something" depends="taskdef">
  ...
</target>

and never put a <taskdef>/<typedef> at global scope. --DD

-----Original Message-----
From: Stefan Bodewig [mailto:[EMAIL PROTECTED]] 
Sent: Monday, June 10, 2002 8:58 AM
To: [EMAIL PROTECTED]
Subject: Re: 1.5b2 and TaskDefs 'override' warnings

On Mon, 10 Jun 2002, Marc Gemis <[EMAIL PROTECTED]>
wrote:

> This was not the case in 1.4.1.

Yes, 1.4.1 wouldn't tell you that you were overriding an existing
taskdef at all.

> Or should I somehow change my build-file ?

Don't <taskdef> your task unless you need it.  Only <taskdef> it once
(i.e. don't <taskdef> it again in the part that gets called by
<ant*>).

Stefan

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to