#6 Port to OpenJDK 21
Merged 2 months ago by jvanek. Opened 2 months ago by pmikova.
rpms/ pmikova/apache-commons-collections f40  into  f40

@@ -1,13 +0,0 @@ 

- diff --git a/src/test/org/apache/commons/collections/collection/AbstractTestCollection.java b/src/test/org/apache/commons/collections/collection/AbstractTestCollection.java

- index dfde362..00c5d26 100644

- --- a/src/test/org/apache/commons/collections/collection/AbstractTestCollection.java

- +++ b/src/test/org/apache/commons/collections/collection/AbstractTestCollection.java

- @@ -1116,7 +1116,7 @@ public abstract class AbstractTestCollection extends AbstractTestObject {

-          verify();

-  

-          try {

- -            array = collection.toArray(null);

- +            array = collection.toArray((Object[])null);

-              fail("toArray(null) should raise NPE");

-          } catch (NullPointerException e) {

-              // expected

@@ -0,0 +1,47 @@ 

+ From 086878cf280edc7c88d6fc990fefea2ffda4556f Mon Sep 17 00:00:00 2001

+ From: Marian Koncek <mkoncek@redhat.com>

+ Date: Tue, 20 Feb 2024 18:23:57 +0100

+ Subject: [PATCH] Port to OpenJDK 21

+ 

+ ---

+  .../collections/TestExtendedProperties.java   | 26 -------------------

+  1 file changed, 26 deletions(-)

+ 

+ diff --git a/src/test/org/apache/commons/collections/TestExtendedProperties.java b/src/test/org/apache/commons/collections/TestExtendedProperties.java

+ index f64812f..13f623a 100644

+ --- a/src/test/org/apache/commons/collections/TestExtendedProperties.java

+ +++ b/src/test/org/apache/commons/collections/TestExtendedProperties.java

+ @@ -315,30 +315,4 @@ public class TestExtendedProperties extends TestCase {

+          assertEquals("class", extended.getString("resource.loader"));

+      }

+  

+ -    public void testActiveSecurityManager() {

+ -        SecurityManager manager = new SecurityManager() {

+ -

+ -            public void checkPropertyAccess(String key) {

+ -                if ("file.separator".equals(key)) {

+ -                    throw new SecurityException();

+ -                }

+ -            }

+ -

+ -            public void checkPermission(Permission perm) {

+ -            }

+ -            

+ -        };

+ -

+ -        System.setSecurityManager(manager);

+ -

+ -        try {

+ -            ExtendedProperties properties = new ExtendedProperties();

+ -            assertNotNull(properties);

+ -        } catch (Exception ex) {

+ -            fail("failed to instantiate ExtendedProperties");

+ -        } finally {

+ -            System.setSecurityManager(null);

+ -        }

+ -    }

+ -

+  }

+ -- 

+ 2.43.0

+ 

@@ -2,7 +2,7 @@ 

  

  Name:           apache-commons-collections

  Version:        3.2.2

- Release:        34%{?dist}

+ Release:        35%{?dist}

  Summary:        Provides new interfaces, implementations and utilities for Java Collections

  License:        Apache-2.0

  URL:            http://commons.apache.org/collections/
@@ -13,6 +13,7 @@ 

  

  Patch0:         0001-Port-to-Java-8.patch

  Patch1:         0002-Port-to-OpenJDK-11.patch

+ Patch2:         0003-Port-to-OpenJDK-21.patch

  

  %if %{with bootstrap}

  BuildRequires:  javapackages-bootstrap
@@ -58,8 +59,9 @@ 

  find . -name "*.jar" -exec rm -f {} \;

  find . -name "*.class" -exec rm -f {} \;

  

- %patch0 -p1

- %patch1 -p1

+ %patch 0 -p1

+ %patch 1 -p1

+ %patch 2 -p1

  

  # Port to maven-antrun-plugin 3.0.0

  sed -i s/tasks/target/ pom.xml
@@ -87,6 +89,9 @@ 

  %license LICENSE.txt NOTICE.txt

  

  %changelog

+ * Tue Feb 20 2024 Marian Koncek <mkoncek@redhat.com> - 3.2.2-35

+ - Port to OpenJDK 21

+ 

  * Mon Jan 22 2024 Fedora Release Engineering <releng@fedoraproject.org> - 3.2.2-34

  - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild

  

no initial comment

Pull-Request has been merged by jvanek

2 months ago