我有 jaxb2-maven-plugin 版本 1.5 和 axistools-maven-plugin 版本 1.4 当我执行 maven 生成源时,我收到一个错误.. 任何帮助都会非常有用。
[INFO]
[INFO] --- jaxb2-maven-plugin:1.5:xjc (default) @ TouchStoneCore ---
[INFO] Generating source...
[INFO] parsing a schema...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.456s
[INFO] Finished at: Wed Jun 26 15:40:58 PDT 2013
[INFO] Final Memory: 28M/351M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:jaxb2-maven-plugin:1.5:xjc (default) on project TouchStoneCore: Execution default of goal org.codehaus.mojo:jaxb2-maven-plugin:1.5:xjc failed: An API incompatibility was encountered while executing org.codehaus.mojo:jaxb2-maven-plugin:1.5:xjc: java.lang.NoSuchMethodError: org.apache.xerces.impl.xs.XMLSchemaLoader.loadGrammar([Lorg/apache/xerces/xni/parser/XMLInputSource;)V
[ERROR] -----------------------------------------------------
[ERROR] realm = plugin>org.codehaus.mojo:jaxb2-maven-plugin:1.5
[ERROR] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
[ERROR] urls[0] = file:/C:/M2/repository/org/codehaus/mojo/jaxb2-maven-plugin/1.5/jaxb2-maven-plugin-1.5.jar
[ERROR] urls[1] = file:/C:/M2/repository/org/codehaus/plexus/plexus-interpolation/1.1/plexus-interpolation-1.1.jar
[ERROR] urls[2] = file:/C:/M2/repository/com/sun/xml/bind/jaxb-xjc/2.1.13/jaxb-xjc-2.1.13.jar
[ERROR] urls[3] = file:/C:/M2/repository/com/sun/xml/bind/jaxb-impl/2.1.13/jaxb-impl-2.1.13.jar
[ERROR] urls[4] = file:/C:/M2/repository/javax/xml/bind/jaxb-api/2.1/jaxb-api-2.1.jar
[ERROR] urls[5] = file:/C:/M2/repository/javax/xml/stream/stax-api/1.0-2/stax-api-1.0-2.jar
[ERROR] urls[6] = file:/C:/M2/repository/javax/activation/activation/1.1/activation-1.1.jar
[ERROR] urls[7] = file:/C:/M2/repository/org/codehaus/plexus/plexus-compiler-api/1.9.1/plexus-compiler-api-1.9.1.jar
[ERROR] urls[8] = file:/C:/M2/repository/org/codehaus/plexus/plexus-utils/3.0.4/plexus-utils-3.0.4.jar
[ERROR] urls[9] = file:/C:/M2/repository/org/sonatype/plexus/plexus-build-api/0.0.7/plexus-build-api-0.0.7.jar
[ERROR] Number of foreign imports: 1
[ERROR] import: Entry[import from realm ClassRealm[maven.api, parent: null]]