title: Maven java classes generated in "target" folder are not compiled
body: <p>I have a plugin which generates lots of java files (i.e FileA.java, FileB.java) under <code>target</code> folder. I'm using "exec-maven-plugin" to execute my plugin as follows</p>
  
  <pre><code>&lt;build&gt;
      &lt;plugins&gt;
          &lt;plugin&gt;
              &lt;groupId&gt;org.codehaus.mojo&lt;/groupId&gt;
              &lt;artifactId&gt;exec-maven-plugin&lt;/artifactId&gt;
              &lt;executions&gt;
                  &lt;execution&gt;
                      &lt;id&gt;generate-event-beans&lt;/id&gt;
                      &lt;phase&gt;generate-sources&lt;/phase&gt;
                      &lt;goals&gt;
                          &lt;goal&gt;java&lt;/goal&gt;
                      &lt;/goals&gt;
                      &lt;configuration&gt;
                          &lt;mainClass&gt;com.my.project.generate.GenerateJavaFiles&lt;/mainClass&gt;
                          &lt;classpathScope&gt;compile&lt;/classpathScope&gt;
                          &lt;arguments&gt;
                              &lt;argument&gt;${basedir}/src/main/resources&lt;/argument&gt;
                              &lt;argument&gt;${project.build.directory}/generated-sources/generated&lt;/argument&gt;
                          &lt;/arguments&gt;
                      &lt;/configuration&gt;
                  &lt;/execution&gt;
              &lt;/executions&gt;
          &lt;/plugin&gt;
  </code></pre>
  
  <p>
  </p>
  
  <p>I want to compile these java files created under <code>${project.build.directory}/generated-sources/generated</code> <strong>without adding them to source</strong> and package them in jar</p>