title: Run Ant task from Maven
body: <p>I'm using Ant to build a custom jar library, which then I'm using in Maven as dependency.</p>
  
  <pre>
  &lt;dependency&gt;
      &lt;groupId>test-lib&lt;/groupId&gt;
      &lt;artifactId>test-lib&lt;/artifactId&gt;
      &lt;version&gt;1.0.0system&lt;/scope&gt;
      &lt;systemPath&gt;${basedir}/src/main/webapp/WEB-INF/lib/test-lib-1.0.0.jar&lt;/systemPath&gt;
  &lt;/dependency&gt;
  </pre>
  
  <p>So, basically what I do now is:</p>
  
  <p>1) run ant to build custom library (test-lib-1.0.0.jar)<br>
  2) run: mvn compile, to compile my project using custom library among others.  </p>
  
  <p>Is there an option for me to do all this (packaing custom jar &amp; compiling project) from
  Maven?
  I've found maven run plugin, and here are my settings:  </p>
  
  <pre>
  &lt;plugin>
      &lt;artifactId>maven-antrun-plugin&lt;/artifactId>
      &lt;version>1.4
      &lt;executions>
          &lt;execution>
              &lt;phase>?????what to put here?????/phase>
              &lt;configuration>
                  &lt;tasks>
                      &lt;ant antfile="${basedir}/build.xml">
                          &lt;target name="prepare-test-lib" />
                      &lt;/ant>
                  &lt;/tasks>
              &lt;/configuration>
              &lt;goals>
                  &lt;goal>run&lt;/goal>
              &lt;/goals>
          &lt;/execution>
      &lt;/executions>
  &lt;/plugin>
  </pre>
  
  <p>But, when running: <code>mvn compile</code> it complains about missing artifact: <code>test-lib-1.0.0.jar</code>.
  I've used compile, generate-resouces,... in <code>&lt;phase/&gt;</code> tag, but nothing seems to work.</p>
  
  <p>Is it possible to solve this somehow using this plugin?</p>