dev-java/asm: add 9.8_p20250706

Adds support for Java 26

Signed-off-by: Volkmar W. Pogatzki <gentoo@pogatzki.net>
Part-of: https://github.com/gentoo/gentoo/pull/43388
Closes: https://github.com/gentoo/gentoo/pull/43388
Signed-off-by: Miroslav Šulc <fordfrog@gentoo.org>
This commit is contained in:
Volkmar W. Pogatzki
2025-08-08 20:11:34 +02:00
committed by Miroslav Šulc
parent 374afd87e0
commit d5d5312a57
2 changed files with 102 additions and 0 deletions

View File

@@ -1,2 +1,3 @@
DIST asm-ASM_9_7_1.tar.bz2 1378103 BLAKE2B f7da3a9c1bcf76398c9e9b9b86d60f8854e5248632a8b2d76605851e29ee1807713fb28c9e76012ec8f9444c44e3a151ed409cd120c34ab8d3495fdc9c84edcb SHA512 77ae76464eec97dbc8129c4a746d13f0d286d2033f909b65e0e34858e1785616b7bee22faa92128b91eb39cbd849e262efe574b73ed2859920add457d6422dd0
DIST asm-ASM_9_8.tar.bz2 1378904 BLAKE2B 8ace6a729e28569d21b3b2104d6256836ce552f9e571f62fbf994675ca5dcda846abbaa80ec5cede0ab06e519abfaa6745679733f6780be4d16f3e266651e850 SHA512 61142b14a3e1b9873a71057ef649dce3f40cf7553cf536213bee373ddc3320d4e183290adec5274f31562262845dab4505b16f64ba1be3c9893b6a11d1169370
DIST asm-d4c246469f5fcc477ae943957ac9fa46795ee249.tar.bz2 1382310 BLAKE2B 3048dffbaa1d7374bf53b37bb41bef3a0d7c71a01df1cc28d33a8bed6accb13c0f633783579eb4e91384150bfc3c02104bf297765399063e3fa8e2f1aecba33a SHA512 ce5e10f05d9ec2cf218d211ab6667b3a0cf0c932237a207934fdf9c2da4d9a9cfe70620ee734628872a6742953698c61d1d7a08e3bbb23eee0fd6c6debd09bd8

View File

@@ -0,0 +1,101 @@
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# tests not enabled because of missing eclass support of junit-jupiter
JAVA_PKG_IUSE="doc source"
MAVEN_PROVIDES="
org.ow2.asm:asm-bom:${PV}
org.ow2.asm:asm:${PV}
org.ow2.asm:asm-analysis:${PV}
org.ow2.asm:asm-commons:${PV}
org.ow2.asm:asm-tree:${PV}
org.ow2.asm:asm-util:${PV}
"
# Avoid circular dependency
JAVA_DISABLE_DEPEND_ON_JAVA_DEP_CHECK="true"
inherit java-pkg-2 java-pkg-simple
DESCRIPTION="Bytecode manipulation framework for Java"
HOMEPAGE="https://asm.ow2.io"
MY_P="ASM_${PV//./_}"
MY_COMMIT="d4c246469f5fcc477ae943957ac9fa46795ee249"
SRC_URI="https://gitlab.ow2.org/asm/asm/-/archive/${MY_COMMIT}/asm-${MY_COMMIT}.tar.bz2"
S="${WORKDIR}/asm-${MY_COMMIT}"
LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64 ~arm64 ~ppc64 ~x64-macos"
DEPEND=">=virtual/jdk-11:*"
RDEPEND=">=virtual/jre-1.8:*"
ASM_MODULES=( "asm" "asm-tree" "asm-analysis" "asm-commons" "asm-util" )
JAVADOC_SRC_DIRS=(
asm/src/main/java
asm-tree/src/main/java
asm-analysis/src/main/java
asm-commons/src/main/java
asm-util/src/main/java
)
src_prepare() {
default
local module
touch asm.module || die
for module in "${ASM_MODULES[@]}"; do
module=${module/-/.}
cat > ${module/./-}/src/main/java/module-info.java <<-EOF || die
open module org.objectweb.${module/analysis/tree.analysis} {
$(cat asm.module)
requires java.base;
exports org.objectweb.${module/analysis/tree.analysis};
}
EOF
echo "requires transitive org.objectweb.${module/analysis/tree.analysis};" \
>> asm.module || die
done
sed -e '/^$/d' \
-e '/asm;/p;s:\(asm\)\(;\):\1.signature\2:' \
-i asm/src/main/java/module-info.java || die
sed -e '/analysis/d' \
-i asm-commons/src/main/java/module-info.java || die
sed -e '/commons/d' \
-i asm-util/src/main/java/module-info.java || die
}
src_compile() {
local module
for module in "${ASM_MODULES[@]}"; do
einfo "Compiling ${module}"
JAVA_JAR_FILENAME="${module}.jar"
JAVA_SRC_DIR="${module}/src/main/java"
java-pkg-simple_src_compile
JAVA_GENTOO_CLASSPATH_EXTRA+=":${module}.jar"
rm -r target || die
done
if use doc; then
einfo "Compiling javadocs"
for module in "${ASM_MODULES[@]}"; do
rm "${module}/src/main/java/module-info.java" || die
JAVA_SRC_DIR+=("${module}/src/main/java")
done
ejavadoc
fi
}
src_install() {
JAVA_JAR_FILENAME="asm.jar"
java-pkg-simple_src_install
local module
for module in asm-{analysis,commons,tree,util}; do
java-pkg_dojar ${module}.jar
if use source; then
java-pkg_dosrc "${module}/src/main/java/*"
fi
done
}