diff --git a/.gitignore b/.gitignore index 6954f48..fbab2db 100644 --- a/.gitignore +++ b/.gitignore @@ -62,3 +62,4 @@ jetty-6.1.26-src.zip /jetty-9.4.10.RC1.tar.gz /jetty-9.4.10.v20180503.tar.gz /jetty-9.4.11.v20180605.tar.gz +/jetty-9.4.14.v20181114.tar.gz diff --git a/0001-Fedora-jetty.home.patch b/0001-Fedora-jetty.home.patch index 3d40be5..90b4743 100644 --- a/0001-Fedora-jetty.home.patch +++ b/0001-Fedora-jetty.home.patch @@ -1,7 +1,7 @@ -From e1f6d2f9749b6a04a3b7d163d17df41751fb8977 Mon Sep 17 00:00:00 2001 +From 46f7ec33b83c28459496739f4d8b91329fb82bc6 Mon Sep 17 00:00:00 2001 From: Michael Simacek Date: Tue, 2 Jun 2015 22:52:21 +0200 -Subject: [PATCH] Fedora jetty.home +Subject: [PATCH 1/2] Fedora jetty.home --- .../eclipse/jetty/start/config/CommandLineConfigSource.java | 3 +++ @@ -22,5 +22,5 @@ index f0c9e07..7d2ee3e 100644 return home; } -- -2.17.1 +2.19.1 diff --git a/0002-Allow-building-with-ASM6-on-Fedora-29.patch b/0002-Allow-building-with-ASM6-on-Fedora-29.patch new file mode 100644 index 0000000..3bf22f2 --- /dev/null +++ b/0002-Allow-building-with-ASM6-on-Fedora-29.patch @@ -0,0 +1,53 @@ +From 743dedbd36be295bcc4952611cc89c577ec0a693 Mon Sep 17 00:00:00 2001 +From: Mat Booth +Date: Thu, 6 Dec 2018 09:49:35 +0000 +Subject: [PATCH 2/2] Allow building with ASM6 on Fedora <= 29 + +--- + .../org/eclipse/jetty/annotations/AnnotationParser.java | 9 ++------- + .../eclipse/jetty/osgi/annotations/AnnotationParser.java | 2 +- + 2 files changed, 3 insertions(+), 8 deletions(-) + +diff --git a/jetty-annotations/src/main/java/org/eclipse/jetty/annotations/AnnotationParser.java b/jetty-annotations/src/main/java/org/eclipse/jetty/annotations/AnnotationParser.java +index a23b685..832ae20 100644 +--- a/jetty-annotations/src/main/java/org/eclipse/jetty/annotations/AnnotationParser.java ++++ b/jetty-annotations/src/main/java/org/eclipse/jetty/annotations/AnnotationParser.java +@@ -69,8 +69,8 @@ import org.objectweb.asm.Opcodes; + public class AnnotationParser + { + private static final Logger LOG = Log.getLogger(AnnotationParser.class); +- private static final int ASM_OPCODE_VERSION = Opcodes.ASM7; //compatibility of api +- private static final String ASM_OPCODE_VERSION_STR = "ASM7"; ++ private static final int ASM_OPCODE_VERSION = Opcodes.ASM6; //compatibility of api ++ private static final String ASM_OPCODE_VERSION_STR = "ASM6"; + + /** + * Map of classnames scanned and the first location from which scan occurred +@@ -115,11 +115,6 @@ public class AnnotationParser + asmVersion = Opcodes.ASM6; + break; + } +- case 7: +- { +- asmVersion = Opcodes.ASM7; +- break; +- } + default: + { + LOG.warn("Unrecognized ASM version, assuming {}", ASM_OPCODE_VERSION_STR); +diff --git a/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/annotations/AnnotationParser.java b/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/annotations/AnnotationParser.java +index 00f0919..1350eb4 100644 +--- a/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/annotations/AnnotationParser.java ++++ b/jetty-osgi/jetty-osgi-boot/src/main/java/org/eclipse/jetty/osgi/annotations/AnnotationParser.java +@@ -49,7 +49,7 @@ public class AnnotationParser extends org.eclipse.jetty.annotations.AnnotationPa + + public AnnotationParser(int javaPlatform) + { +- super(javaPlatform, Opcodes.ASM7); ++ super(javaPlatform, Opcodes.ASM6); + } + + /** +-- +2.19.1 + diff --git a/jetty.spec b/jetty.spec index b2d0c1b..15b7dea 100644 --- a/jetty.spec +++ b/jetty.spec @@ -40,7 +40,7 @@ %global appdir %{jettylibdir}/webapps -%global addver .v20180605 +%global addver .v20181114 # minimal version required to build eclipse and thermostat # eclipse needs: util, server, http, continuation, io, security, servlet @@ -49,12 +49,12 @@ %bcond_with jp_minimal Name: jetty -Version: 9.4.11 -Release: 4%{addver}%{?dist} +Version: 9.4.14 +Release: 1%{addver}%{?dist} Summary: Java Webserver and Servlet Container # Jetty is dual licensed under both ASL 2.0 and EPL 1.0, see NOTICE.txt -License: ASL 2.0 or EPL +License: ASL 2.0 or EPL-1.0 URL: http://www.eclipse.org/jetty/ Source0: https://github.com/eclipse/%{name}.project/archive/%{name}-%{version}%{addver}.tar.gz Source1: jetty.sh @@ -64,6 +64,7 @@ Source5: %{name}.service Source6: LICENSE-MIT Patch1: 0001-Fedora-jetty.home.patch +Patch2: 0002-Allow-building-with-ASM6-on-Fedora-29.patch BuildRequires: maven-local BuildRequires: mvn(javax.servlet:javax.servlet-api) @@ -75,8 +76,6 @@ BuildRequires: mvn(org.slf4j:slf4j-api) %if %{without jp_minimal} BuildRequires: maven-local BuildRequires: mvn(com.github.jnr:jnr-unixsocket) -BuildRequires: mvn(com.hazelcast:hazelcast) -BuildRequires: mvn(com.hazelcast:hazelcast-client) BuildRequires: mvn(javax.annotation:javax.annotation-api) BuildRequires: mvn(javax.enterprise:cdi-api) BuildRequires: mvn(javax.servlet:javax.servlet-api) @@ -133,6 +132,7 @@ BuildRequires: mvn(org.eclipse.jetty.toolchain:jetty-test-policy) BuildRequires: maven-javadoc-plugin BuildRequires: glassfish-el BuildRequires: systemd +BuildRequires: junit5 # duplicate providers, choose one BuildRequires: jboss-websocket-1.0-api @@ -178,7 +178,6 @@ Requires: %{name}-util-ajax = %{version}-%{release} Requires: %{name}-webapp = %{version}-%{release} Requires: %{name}-xml = %{version}-%{release} Requires: %{name}-infinispan = %{version}-%{release} -Requires: %{name}-hazelcast = %{version}-%{release} Requires: %{name}-cdi = %{version}-%{release} Requires: %{name}-websocket-api = %{version}-%{release} Requires: %{name}-websocket-client = %{version}-%{release} @@ -221,6 +220,9 @@ Obsoletes: %{name}-runner < 9.4.0-0.4 Obsoletes: %{name}-osgi-npn < 9.4.0-0.4 Obsoletes: %{name}-monitor < 9.4.0-0.4 +# Hazelcast in Fedora is too old for jetty to build against +Obsoletes: %{name}-hazelcast < 9.4.14-1 + %description %global desc \ Jetty is a 100% Java HTTP Server and Servlet Container. This means that you\ @@ -363,12 +365,6 @@ Summary: Jetty CDI Configuration %description cdi %{extdesc} %{summary}. -%package hazelcast -Summary: hazelcast module for Jetty - -%description hazelcast -%{extdesc} %{summary}. - %package fcgi-client Summary: FastCGI client module for Jetty @@ -606,6 +602,11 @@ License: (ASL 2.0 or EPL) and MIT %patch1 -p1 +# ASM 7 is only available on F30+ +%if 0%{?fedora} > 0 && 0%{?fedora} < 30 +%patch2 -p1 +%endif + find . -name "*.?ar" -exec rm {} \; find . -name "*.class" -exec rm {} \; @@ -622,6 +623,7 @@ find . -name "*.class" -exec rm {} \; %pom_remove_plugin -r :jacoco-maven-plugin %pom_remove_plugin -r :maven-release-plugin %pom_remove_plugin -r :buildnumber-maven-plugin +%pom_remove_plugin -r :h2spec-maven-plugin %pom_disable_module aggregates/jetty-all @@ -632,6 +634,8 @@ find . -name "*.class" -exec rm {} \; %pom_change_dep -r org.mortbay.jasper:apache-jsp org.apache.tomcat:tomcat-jasper +%pom_add_dep 'org.junit.jupiter:junit-jupiter-engine:${junit.version}' tests/test-sessions/test-sessions-common + # provided by glassfish-jsp-api that has newer version %pom_change_dep -r javax.servlet.jsp:jsp-api javax.servlet.jsp:javax.servlet.jsp-api @@ -645,9 +649,6 @@ find . -name "*.class" -exec rm {} \; # Unwanted JS in javadoc sed -i '/^\s*\*.*