Compare commits
No commits in common. "rawhide" and "f42" have entirely different histories.
3 changed files with 18 additions and 72 deletions
|
|
@ -1,64 +0,0 @@
|
|||
From 756ccf40723d9ba68872252810f3dbb2b186be0c Mon Sep 17 00:00:00 2001
|
||||
From: forax <forax@univ-mlv.fr>
|
||||
Date: Tue, 10 Dec 2024 11:11:49 +0100
|
||||
Subject: [PATCH] Add support of Java 25
|
||||
|
||||
---
|
||||
asm-util/src/main/java/org/objectweb/asm/util/ASMifier.java | 1 +
|
||||
asm/src/main/java/org/objectweb/asm/ClassReader.java | 2 +-
|
||||
asm/src/main/java/org/objectweb/asm/Opcodes.java | 1 +
|
||||
asm/src/test/java/org/objectweb/asm/ConstantsTest.java | 1 +
|
||||
4 files changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/asm-util/src/main/java/org/objectweb/asm/util/ASMifier.java b/asm-util/src/main/java/org/objectweb/asm/util/ASMifier.java
|
||||
index 4ede9201..9ce9f1c6 100644
|
||||
--- a/asm-util/src/main/java/org/objectweb/asm/util/ASMifier.java
|
||||
+++ b/asm-util/src/main/java/org/objectweb/asm/util/ASMifier.java
|
||||
@@ -114,6 +114,7 @@ public class ASMifier extends Printer {
|
||||
classVersions.put(Opcodes.V22, "V22");
|
||||
classVersions.put(Opcodes.V23, "V23");
|
||||
classVersions.put(Opcodes.V24, "V24");
|
||||
+ classVersions.put(Opcodes.V25, "V25");
|
||||
CLASS_VERSIONS = Collections.unmodifiableMap(classVersions);
|
||||
}
|
||||
|
||||
diff --git a/asm/src/main/java/org/objectweb/asm/ClassReader.java b/asm/src/main/java/org/objectweb/asm/ClassReader.java
|
||||
index 33b2a300..5f66ed2b 100644
|
||||
--- a/asm/src/main/java/org/objectweb/asm/ClassReader.java
|
||||
+++ b/asm/src/main/java/org/objectweb/asm/ClassReader.java
|
||||
@@ -195,7 +195,7 @@ public class ClassReader {
|
||||
this.b = classFileBuffer;
|
||||
// Check the class' major_version. This field is after the magic and minor_version fields, which
|
||||
// use 4 and 2 bytes respectively.
|
||||
- if (checkClassVersion && readShort(classFileOffset + 6) > Opcodes.V24) {
|
||||
+ if (checkClassVersion && readShort(classFileOffset + 6) > Opcodes.V25) {
|
||||
throw new IllegalArgumentException(
|
||||
"Unsupported class file major version " + readShort(classFileOffset + 6));
|
||||
}
|
||||
diff --git a/asm/src/main/java/org/objectweb/asm/Opcodes.java b/asm/src/main/java/org/objectweb/asm/Opcodes.java
|
||||
index 9aa8a3b0..4ed95869 100644
|
||||
--- a/asm/src/main/java/org/objectweb/asm/Opcodes.java
|
||||
+++ b/asm/src/main/java/org/objectweb/asm/Opcodes.java
|
||||
@@ -290,6 +290,7 @@ public interface Opcodes {
|
||||
int V22 = 0 << 16 | 66;
|
||||
int V23 = 0 << 16 | 67;
|
||||
int V24 = 0 << 16 | 68;
|
||||
+ int V25 = 0 << 16 | 69;
|
||||
|
||||
/**
|
||||
* Version flag indicating that the class is using 'preview' features.
|
||||
diff --git a/asm/src/test/java/org/objectweb/asm/ConstantsTest.java b/asm/src/test/java/org/objectweb/asm/ConstantsTest.java
|
||||
index e7af1d04..543ba044 100644
|
||||
--- a/asm/src/test/java/org/objectweb/asm/ConstantsTest.java
|
||||
+++ b/asm/src/test/java/org/objectweb/asm/ConstantsTest.java
|
||||
@@ -257,6 +257,7 @@ class ConstantsTest {
|
||||
case "V22":
|
||||
case "V23":
|
||||
case "V24":
|
||||
+ case "V25":
|
||||
return ConstantType.CLASS_VERSION;
|
||||
case "ACC_PUBLIC":
|
||||
case "ACC_PRIVATE":
|
||||
--
|
||||
2.48.1
|
||||
|
||||
|
|
@ -22,17 +22,13 @@ Source7: https://repo1.maven.org/maven2/org/ow2/asm/asm-util/%{version}/a
|
|||
Source9: generate-tarball.sh
|
||||
Source10: tools-retrofitter.pom
|
||||
|
||||
Patch: 0001-Add-support-of-Java-25.patch
|
||||
|
||||
%if %{with bootstrap}
|
||||
BuildRequires: javapackages-bootstrap
|
||||
%else
|
||||
BuildRequires: maven-local-openjdk25
|
||||
BuildRequires: maven-local
|
||||
BuildRequires: mvn(org.apache.maven.plugins:maven-antrun-plugin)
|
||||
BuildRequires: mvn(org.ow2.asm:asm)
|
||||
%endif
|
||||
# TODO Remove in Fedora 46
|
||||
Obsoletes: %{name}-javadoc < 9.7.1-9
|
||||
|
||||
%description
|
||||
ASM is an all purpose Java bytecode manipulation and analysis
|
||||
|
|
@ -41,6 +37,12 @@ generate classes, directly in binary form. Provided common
|
|||
transformations and analysis algorithms allow to easily assemble
|
||||
custom complex transformations and code analysis tools.
|
||||
|
||||
%package javadoc
|
||||
Summary: API documentation for %{name}
|
||||
|
||||
%description javadoc
|
||||
API documentation for %{name}.
|
||||
|
||||
%prep
|
||||
%autosetup -p1 -C
|
||||
|
||||
|
|
@ -58,6 +60,8 @@ for pom in asm asm-analysis asm-commons asm-test asm-tree asm-util; do
|
|||
%pom_xpath_inject pom:parent '<relativePath>..</relativePath>' ${pom}
|
||||
done
|
||||
|
||||
%pom_add_dep org.ow2.asm:asm-tree:%{version} asm-analysis
|
||||
|
||||
# Don't ship poms used for build only
|
||||
%mvn_package :aggregator __noinstall
|
||||
%mvn_package :tools-retrofitter __noinstall
|
||||
|
|
@ -66,13 +70,19 @@ done
|
|||
%mvn_package :asm-test __noinstall
|
||||
|
||||
%build
|
||||
%mvn_build -j -f -- -Dmaven.compiler.source=1.8 -Dmaven.compiler.target=1.8
|
||||
%mvn_build -f -- -Dmaven.compiler.source=1.8 -Dmaven.compiler.target=1.8
|
||||
|
||||
%install
|
||||
%mvn_install
|
||||
|
||||
%jpackage_script org.objectweb.asm.xml.Processor "" "" %{name}/asm:%{name}/asm-attrs:%{name}/asm-util %{name}-processor true
|
||||
|
||||
%files -f .mfiles
|
||||
%license LICENSE.txt
|
||||
%{_bindir}/%{name}-processor
|
||||
|
||||
%files javadoc -f .mfiles-javadoc
|
||||
%license LICENSE.txt
|
||||
|
||||
%changelog
|
||||
%autochangelog
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
summary: Run javapackages-specific tests
|
||||
discover:
|
||||
how: fmf
|
||||
url: https://gitlab.com/redhat/centos-stream/tests/javapackages.git
|
||||
ref: f43
|
||||
url: https://src.fedoraproject.org/tests/javapackages
|
||||
ref: f42
|
||||
execute:
|
||||
how: tmt
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue