我正在尝试使用Retrotranslator Maven插件来促进JDK1.4之前的环境的开发。我有一个名为xyz-core的maven模块,其中包含br.com.company.xyz.core.backport包,我想将其用作通用的后端程序包。
问题是:插件找不到包。如果我将该包复制到此项目,它可以工作。但我需要在单独的工件上使用backport包,因为它将在许多其他项目中使用。
这是pom:
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>br.com.company.xyz</groupId>
<artifactId>xyz-parent</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
<artifactId>xyz-test</artifactId>
<dependencies>
<dependency>
<groupId>br.com.company.xyz</groupId>
<artifactId>xyz-core</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>retrotranslator-maven-plugin</artifactId>
<version>1.0-alpha-4</version>
<configuration>
<classifier>ME</classifier>
<target>1.1</target>
<verbose>true</verbose>
<verify>true</verify>
<verifyClasspath>
<element>${basedir}/lib/rt.jar</element>
</verifyClasspath>
<backport>br.com.company.xyz.core.backport</backport>
</configuration>
<executions>
<execution>
<goals>
<goal>translate-project</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>