title: Why are Maven generated-sources not getting compiled?
body: <p>I have a plugin which generates sources under the <code>target/generated-sources/wrappers</code> directory. It's wired into the generate-sources phase like this:</p>
  
  <pre class="lang-xml prettyprint-override"><code>&lt;plugin&gt;
      &lt;groupId&gt;mygroupid&lt;/groupId&gt;
      &lt;artifactId&gt;myartifactid&lt;/artifactId&gt;
      &lt;executions&gt;
          &lt;execution&gt;
          &lt;phase&gt;generate-sources&lt;/phase&gt;
          &lt;goals&gt;
              &lt;goal&gt;xml2java&lt;/goal&gt;
          &lt;/goals&gt;
          &lt;/execution&gt;
      &lt;/executions&gt;
  &lt;/plugin&gt;
  </code></pre>
  
  <p>The problem is, when I use <code>mvn deploy</code> the <code>.class</code> files won't be placed in the jar. I see all the <code>.java</code> files there, but no <code>.class</code>.</p>
  
  <p>I read all the issues around this problem, but couldn't figure out how to solve the problem. I'm using Maven 3.0.x. </p>