forked from phoedos/pmd
Add config to create multi-release jar
This commit is contained in:
@ -16,6 +16,9 @@
|
||||
<maven.compiler.source>1.${java.version}</maven.compiler.source>
|
||||
<maven.compiler.target>1.${java.version}</maven.compiler.target>
|
||||
|
||||
<build.mr.java8.output>${project.build.directory}/classes-java8</build.mr.java8.output>
|
||||
|
||||
|
||||
<openjfx.version>11</openjfx.version>
|
||||
</properties>
|
||||
|
||||
@ -61,6 +64,57 @@
|
||||
</rulesets>
|
||||
</configuration>
|
||||
</plugin>
|
||||
|
||||
<!-- Unpack Java 8 specific code into the root output dir -->
|
||||
<!-- Code specific to higher versions is unpacked into META-INF/versions/n -->
|
||||
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-dependency-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>Unpack java 8 specific deps</id>
|
||||
<phase>generate-sources</phase>
|
||||
<goals>
|
||||
<goal>unpack</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<artifact>org.controlsfx:controlsfx:8.40.13</artifact>
|
||||
<outputDirectory>${project.build.outputDirectory}</outputDirectory>
|
||||
<includes>**/*</includes>
|
||||
<excludes>MANIFEST.MF</excludes>
|
||||
</configuration>
|
||||
</execution>
|
||||
|
||||
<execution>
|
||||
<id>Unpack java 9 specific deps</id>
|
||||
<phase>generate-resources</phase>
|
||||
<goals>
|
||||
<goal>unpack</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<artifact>org.controlsfx:controlsfx:9.0.0</artifact>
|
||||
<outputDirectory>${project.build.outputDirectory}/META-INF/versions/9</outputDirectory>
|
||||
<includes>**/*</includes>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-jar-plugin</artifactId>
|
||||
<configuration>
|
||||
<archive>
|
||||
<manifestEntries>
|
||||
<!-- Important for it to work on JRE 9+ -->
|
||||
<Multi-Release>true</Multi-Release>
|
||||
<Main-Class>net.sourceforge.pmd.util.fxdesigner.DesignerStarter</Main-Class>
|
||||
</manifestEntries>
|
||||
</archive>
|
||||
<finalName>pmd-ui</finalName>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
@ -115,9 +169,12 @@
|
||||
<version>0.9.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<!-- That one is "provided" because several versions are unpacked into versioned dirs -->
|
||||
<!-- to create a multi-release jar. -->
|
||||
<groupId>org.controlsfx</groupId>
|
||||
<artifactId>controlsfx</artifactId>
|
||||
<version>8.40.13</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-beanutils</groupId>
|
||||
|
Reference in New Issue
Block a user