diff --git a/0004-Port-to-OpenJDK-21.patch b/0004-Port-to-OpenJDK-21.patch new file mode 100644 index 0000000..ec61e2f --- /dev/null +++ b/0004-Port-to-OpenJDK-21.patch @@ -0,0 +1,64 @@ +From e5cf5ee78f8504ccdd5af0a05ef7739a99f31059 Mon Sep 17 00:00:00 2001 +From: Marian Koncek +Date: Tue, 20 Feb 2024 16:56:44 +0100 +Subject: [PATCH] Port to OpenJDK 21 + +--- + .../src/aQute/lib/collections/SortedList.java | 36 +++++++++++++++++++ + 1 file changed, 36 insertions(+) + +diff --git a/aQute.libg/src/aQute/lib/collections/SortedList.java b/aQute.libg/src/aQute/lib/collections/SortedList.java +index ed33e7f..f584e57 100644 +--- a/aQute.libg/src/aQute/lib/collections/SortedList.java ++++ b/aQute.libg/src/aQute/lib/collections/SortedList.java +@@ -3,6 +3,7 @@ package aQute.lib.collections; + import java.lang.reflect.Array; + import java.util.Arrays; + import java.util.Collection; ++import java.util.Collections; + import java.util.Comparator; + import java.util.Iterator; + import java.util.List; +@@ -510,4 +511,39 @@ public class SortedList implements SortedSet, List { + public Spliterator spliterator() { + return SortedSet.super.spliterator(); + } ++ ++ @Override ++ public SortedList reversed() { ++ return new SortedList(this.list, this.start, this.end, Collections.reverseOrder(this.comparator)); ++ } ++ ++ @Override ++ public T removeFirst() { ++ return List.super.removeFirst(); ++ } ++ ++ @Override ++ public T removeLast() { ++ return List.super.removeLast(); ++ } ++ ++ @Override ++ public T getFirst() { ++ return List.super.getFirst(); ++ } ++ ++ @Override ++ public T getLast() { ++ return List.super.getLast(); ++ } ++ ++ @Override ++ public void addFirst(T v) { ++ add(v); ++ } ++ ++ @Override ++ public void addLast(T v) { ++ add(v); ++ } + } +-- +2.43.0 + diff --git a/aqute-bnd.spec b/aqute-bnd.spec index 762dd72..21a3206 100644 --- a/aqute-bnd.spec +++ b/aqute-bnd.spec @@ -8,7 +8,7 @@ Name: aqute-bnd Version: 6.3.1 -Release: 9%{?dist} +Release: 10%{?dist} Summary: BND Tool # Part of jpm is under BSD, but jpm is not included in binary RPM License: Apache-2.0 OR EPL-2.0 @@ -34,6 +34,7 @@ Source8: https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd.util/ Patch1: 0001-Disable-removed-commands.patch Patch2: 0002-Port-to-OSGI-7.0.0.patch Patch3: 0003-Remove-unmet-dependencies.patch +Patch4: 0004-Port-to-OpenJDK-21.patch %if %{with bootstrap} BuildRequires: javapackages-bootstrap @@ -101,9 +102,10 @@ API documentation for %{name}. %prep %setup -q -%patch1 -p1 -%patch2 -p1 -%patch3 -p1 +%patch 1 -p1 +%patch 2 -p1 +%patch 3 -p1 +%patch 4 -p1 # the commands pull in more dependencies than we want (felix-resolver, jetty) rm biz.aQute.bnd/src/aQute/bnd/main/{ExportReportCommand,MbrCommand,RemoteCommand,ReporterLogger,ResolveCommand,Shell}.java @@ -244,6 +246,10 @@ echo "aqute-bnd slf4j/api slf4j/simple osgi-annotation osgi-core osgi-compendium %license LICENSE %changelog +* Mon Aug 05 2024 Mikolaj Izdebski - 6.3.1-10 +- Port to OpenJDK 21 +- Resolves: RHEL-52710 + * Thu Aug 01 2024 Troy Dawson - 6.3.1-9 - Bump release for Aug 2024 java mass rebuild