This is an automated email from the ASF dual-hosted git repository.
skygo pushed a commit to branch master
in repository
https://gitbox.apache.org/repos/asf/netbeans-mavenutils-nbm-maven-plugin.git
The following commit(s) were added to refs/heads/master by this push:
new fa9e7ae update build to new release parameter to build on uptodate
jdk pack200 will work for jdk 8
fa9e7ae is described below
commit fa9e7ae7f0841f6d8de46538be3f6362d38233fc
Author: Eric Barboni <[email protected]>
AuthorDate: Mon Feb 22 16:12:56 2021 +0100
update build to new release parameter to build on uptodate jdk pack200 will
work for jdk 8
* remove pack200 from nbm-maven-plugin
* alter pom and build instead of removing pack200
* Intercept Linkage Error
---
pom.xml | 43 +++++++++++++++++++---
.../apache/netbeans/nbm/CreateClusterAppMojo.java | 14 +++----
2 files changed, 45 insertions(+), 12 deletions(-)
diff --git a/pom.xml b/pom.xml
index f1febfc..b2ddefb 100644
--- a/pom.xml
+++ b/pom.xml
@@ -57,6 +57,18 @@ under the License.
<tag>HEAD</tag>
</scm>
<build>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <version>3.8.1</version>
+ </plugin>
+ <plugin>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <version>3.2.0</version>
+ </plugin>
+ </plugins>
+ </pluginManagement>
<plugins>
<plugin>
<!-- TODO need to override parent version value... I suppose
this will eventually end up in mojo parent pom, check regularly -->
@@ -203,10 +215,10 @@ under the License.
<link>http://junit.sourceforge.net/javadoc/</link>
<link>http://logging.apache.org/log4j/1.2/apidocs/</link>
<!-- unreachable site
<link>http://jakarta.apache.org/regexp/apidocs/</link> -->
-
<link>http://velocity.apache.org/engine/releases/velocity-1.5/apidocs/</link>
-
<link>http://maven.apache.org/ref/${mojo.javadoc.mavenVersion}/maven-artifact/apidocs/</link>
-
<link>http://maven.apache.org/ref/${mojo.javadoc.mavenVersion}/maven-model/apidocs/</link>
-
<link>http://maven.apache.org/ref/${mojo.javadoc.mavenVersion}/maven-plugin-api/apidocs/</link>
+
<link>https://velocity.apache.org/engine/1.5/apidocs/</link>
+
<link>http://maven.apache.org/ref/${maven.version}/maven-artifact/apidocs/</link>
+
<link>http://maven.apache.org/ref/${maven.version}/maven-model/apidocs/</link>
+
<link>http://maven.apache.org/ref/${maven.version}/maven-plugin-api/apidocs/</link>
<!-- unreachable site
<link>http://maven.apache.org/ref/${mojo.javadoc.mavenVersion}/maven-project/apidocs/</link>-->
<!-- unreachable site
<link>http://maven.apache.org/ref/${mojo.javadoc.mavenVersion}/maven-reporting/maven-reporting-api/apidocs/</link>-->
<link>http://maven.apache.org/ref/${mojo.javadoc.mavenVersion}/maven-settings/apidocs/</link>
@@ -293,6 +305,27 @@ under the License.
</reporting>
<profiles>
<profile>
+ <activation>
+ <jdk>[9,)</jdk>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <release>8</release>
+ </configuration>
+ </plugin>
+ <plugin>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <configuration>
+ <release>8</release>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ <profile>
<id>tools.jar</id>
<activation>
<file>
@@ -333,7 +366,7 @@ under the License.
<goal>install</goal>
</goals>
<filterProperties>
- <netbeans.version>RELEASE110</netbeans.version>
+ <netbeans.version>RELEASE113</netbeans.version>
</filterProperties>
</configuration>
<executions>
diff --git a/src/main/java/org/apache/netbeans/nbm/CreateClusterAppMojo.java
b/src/main/java/org/apache/netbeans/nbm/CreateClusterAppMojo.java
index 68f7cbd..c47e2e8 100644
--- a/src/main/java/org/apache/netbeans/nbm/CreateClusterAppMojo.java
+++ b/src/main/java/org/apache/netbeans/nbm/CreateClusterAppMojo.java
@@ -327,17 +327,17 @@ public class CreateClusterAppMojo
InputStream instream =
jf.getInputStream( ent );
if ( ispack200 )
{
+ try ( JarOutputStream jos
= new JarOutputStream( outstream ) )
+ {
Pack200.Unpacker unp =
Pack200.newUnpacker();
- JarOutputStream jos = new
JarOutputStream( outstream );
GZIPInputStream gzip = new
GZIPInputStream( instream );
- try
- {
- unp.unpack( gzip, jos
);
+ unp.unpack( gzip, jos );
}
- finally
+ catch ( LinkageError cnfe )
{
- jos.close();
- }
+ throw new
BuildException( "Using jdk 14 and later prevents "
+ + "reading of
NBM created with pack200" );
+ }
}
else
{
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists