Jakob Fix wrote:
Jan,

On 28/11/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:

I think these steps should works
- compile the class (needs ant.jar on classpath)
- <taskdef>, e.g. <taskname classname="buildmagic.Apply" name="apply2"/>
- use the "new" task


Now I feel really stupid, but what the hell ... ok, I compiled the
class like this
  javac -classpath "./lib/ant.jar" Apply.java

which indeed created the Apply.class.  I moved it in the ant/lib
directory.

ok, so you have a file ant_home/lib/Apply.class

 Then I included this line in the build file:
  <taskdef name="apply2" classpath="${ant.library.dir}"
classname="buildmagic.Apply"/>

and you are declaring a need for a class buildmagic.Apply


1. Like any other java class, it needs to be in a proper package tree, e.g. /buildmagic/Apply
2. ant launcher only adds .jar classes in ant_home/lib.

so jar up the whole tree and stick it in.

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

Reply via email to