METAGEN-45 Removed the second compilation. It should not be needed.
This commit is contained in:
parent
b3a2c67317
commit
cfc18b6cf8
|
@ -4,10 +4,11 @@
|
||||||
|
|
||||||
<groupId>org.hibernate</groupId>
|
<groupId>org.hibernate</groupId>
|
||||||
<artifactId>hibernate-jpamodelgen</artifactId>
|
<artifactId>hibernate-jpamodelgen</artifactId>
|
||||||
<version>1.1.0-SNAPSHOT</version>
|
<version>1.2.0-SNAPSHOT</version>
|
||||||
|
|
||||||
<name>Hibernate JPA 2 Metamodel Generator</name>
|
<name>Hibernate JPA 2 Metamodel Generator</name>
|
||||||
<description>Annotation Processor to generate JPA 2 static metamodel classes</description>
|
<description>Annotation Processor to generate JPA 2 static metamodel classes</description>
|
||||||
|
<url>http://www.hibernate.org/subprojects/jpamodelgen.html</url>
|
||||||
|
|
||||||
<inceptionYear>2009</inceptionYear>
|
<inceptionYear>2009</inceptionYear>
|
||||||
|
|
||||||
|
@ -59,7 +60,8 @@
|
||||||
</issueManagement>
|
</issueManagement>
|
||||||
|
|
||||||
<scm>
|
<scm>
|
||||||
<connection>scm:git:git://github.com/hibernate/git@github.com:hibernate/hibernate-metamodelgen.git</connection>
|
<connection>scm:git:git://github.com/hibernate/hibernate-metamodelgen.git</connection>
|
||||||
|
<developerConnection>scm:git:git@github.com:hibernate/hibernate-metamodelgen.git</developerConnection>
|
||||||
<url>http://github.com/hibernate/hibernate-metamodelgen</url>
|
<url>http://github.com/hibernate/hibernate-metamodelgen</url>
|
||||||
</scm>
|
</scm>
|
||||||
|
|
||||||
|
@ -272,7 +274,6 @@
|
||||||
<configuration>
|
<configuration>
|
||||||
<autoVersionSubmodules>true</autoVersionSubmodules>
|
<autoVersionSubmodules>true</autoVersionSubmodules>
|
||||||
<allowTimestampedSnapshots>true</allowTimestampedSnapshots>
|
<allowTimestampedSnapshots>true</allowTimestampedSnapshots>
|
||||||
<remoteTagging>true</remoteTagging>
|
|
||||||
<goals>package deploy javadoc:javadoc org.jboss.maven.plugins:maven-jdocbook-plugin:2.2.1:resources
|
<goals>package deploy javadoc:javadoc org.jboss.maven.plugins:maven-jdocbook-plugin:2.2.1:resources
|
||||||
org.jboss.maven.plugins:maven-jdocbook-plugin:2.2.1:generate assembly:assembly
|
org.jboss.maven.plugins:maven-jdocbook-plugin:2.2.1:generate assembly:assembly
|
||||||
</goals>
|
</goals>
|
||||||
|
|
|
@ -8,6 +8,12 @@
|
||||||
or @Embeddable, as well as entities mapped in /META-INF/orm.xml and mapping files specified in persistence.xml.
|
or @Embeddable, as well as entities mapped in /META-INF/orm.xml and mapping files specified in persistence.xml.
|
||||||
|
|
||||||
|
|
||||||
|
Latest stable version
|
||||||
|
-------------------
|
||||||
|
|
||||||
|
1.1.0.Final, 3.11.2010
|
||||||
|
|
||||||
|
|
||||||
System Requirements
|
System Requirements
|
||||||
-------------------
|
-------------------
|
||||||
|
|
||||||
|
@ -34,12 +40,3 @@
|
||||||
Source Code: http://github.com/hibernate/hibernate-metamodelgen
|
Source Code: http://github.com/hibernate/hibernate-metamodelgen
|
||||||
Issue Tracking: http://opensource.atlassian.com/projects/hibernate/browse/METAGEN
|
Issue Tracking: http://opensource.atlassian.com/projects/hibernate/browse/METAGEN
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -109,12 +109,8 @@ public class JPAMetaModelEntityProcessor extends AbstractProcessor {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean process(final Set<? extends TypeElement> annotations, final RoundEnvironment roundEnvironment) {
|
public boolean process(final Set<? extends TypeElement> annotations, final RoundEnvironment roundEnvironment) {
|
||||||
if ( roundEnvironment.processingOver() ) {
|
// see also METAGEN-45
|
||||||
if ( !context.isPersistenceUnitCompletelyXmlConfigured() ) {
|
if ( roundEnvironment.processingOver() || annotations.size() == 0) {
|
||||||
context.logMessage( Diagnostic.Kind.OTHER, "Last processing round." );
|
|
||||||
createMetaModelClasses();
|
|
||||||
context.logMessage( Diagnostic.Kind.OTHER, "Finished processing" );
|
|
||||||
}
|
|
||||||
return ALLOW_OTHER_PROCESSORS_TO_CLAIM_ANNOTATIONS;
|
return ALLOW_OTHER_PROCESSORS_TO_CLAIM_ANNOTATIONS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -134,6 +130,7 @@ public class JPAMetaModelEntityProcessor extends AbstractProcessor {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
createMetaModelClasses();
|
||||||
return ALLOW_OTHER_PROCESSORS_TO_CLAIM_ANNOTATIONS;
|
return ALLOW_OTHER_PROCESSORS_TO_CLAIM_ANNOTATIONS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -111,15 +111,6 @@ public abstract class CompilationTest {
|
||||||
sourceFiles
|
sourceFiles
|
||||||
);
|
);
|
||||||
|
|
||||||
// TODO - need to call the compiler twice. Once to compile the test classes and generate the java files
|
|
||||||
// of the generated metamodel. The second compile is for generated the class files of the metamodel.
|
|
||||||
// Note sure why this is not recursive the same way as on the command line
|
|
||||||
compileSources( options, compiler, diagnostics, fileManager, compilationUnits );
|
|
||||||
|
|
||||||
compilationUnits = fileManager.getJavaFileObjectsFromFiles(
|
|
||||||
getCompilationUnits( outBaseDir, packageName )
|
|
||||||
);
|
|
||||||
options.add( PROC_NONE ); // for the second compile skip the processor
|
|
||||||
compileSources( options, compiler, diagnostics, fileManager, compilationUnits );
|
compileSources( options, compiler, diagnostics, fileManager, compilationUnits );
|
||||||
compilationDiagnostics.addAll( diagnostics.getDiagnostics() );
|
compilationDiagnostics.addAll( diagnostics.getDiagnostics() );
|
||||||
fileManager.close();
|
fileManager.close();
|
||||||
|
|
Loading…
Reference in New Issue