Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 882313 Details for
Bug 922157
java-pkg-simple.eclass: improve module support
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
improve decision when to use --module-path
0003-java-pkg-simple.eclass-improve-decission-when-to-use.patch (text/plain), 2.90 KB, created by
Manuel Mommertz
on 2024-01-15 08:25:03 UTC
(
hide
)
Description:
improve decision when to use --module-path
Filename:
MIME Type:
Creator:
Manuel Mommertz
Created:
2024-01-15 08:25:03 UTC
Size:
2.90 KB
patch
obsolete
>From 40041184100964755caa88d7b61ee4bdadd73d7e Mon Sep 17 00:00:00 2001 >From: Manuel Mommertz <manuel.mommertz@desy.de> >Date: Fri, 12 Jan 2024 13:29:12 +0100 >Subject: [PATCH 3/3] java-pkg-simple.eclass: improve decision when to use > --module-path > >Only when java version >= 9 and module-info.java is available. >--- > eclass/java-pkg-simple.eclass | 12 ++++++------ > 1 file changed, 6 insertions(+), 6 deletions(-) > >diff --git a/eclass/java-pkg-simple.eclass b/eclass/java-pkg-simple.eclass >index 0e1d5ba63d66..9f50fce32cb3 100644 >--- a/eclass/java-pkg-simple.eclass >+++ b/eclass/java-pkg-simple.eclass >@@ -370,10 +370,10 @@ java-pkg-simple_src_compile() { > local target="$(java-pkg_get-target)" > if [[ ${target#1.} -lt 9 ]]; then > find "${JAVA_SRC_DIR[@]}" -name \*.java ! -name module-info.java > ${sources} >- moduleinfo=$(find "${JAVA_SRC_DIR[@]}" -name module-info.java) > else > find "${JAVA_SRC_DIR[@]}" -name \*.java > ${sources} > fi >+ moduleinfo=$(find "${JAVA_SRC_DIR[@]}" -name module-info.java) > > # create the target directory > mkdir -p ${classes} || die "Could not create target directory" >@@ -383,7 +383,7 @@ java-pkg-simple_src_compile() { > java-pkg-simple_getclasspath > java-pkg-simple_prepend_resources ${classes} "${JAVA_RESOURCE_DIRS[@]}" > >- if [[ -n ${moduleinfo} ]] || [[ ${target#1.} -lt 9 ]]; then >+ if [[ -z ${moduleinfo} ]] || [[ ${target#1.} -lt 9 ]]; then > ejavac -d ${classes} -encoding ${JAVA_ENCODING}\ > ${classpath:+-classpath ${classpath}} ${JAVAC_ARGS} @${sources} > else >@@ -393,7 +393,7 @@ java-pkg-simple_src_compile() { > fi > > # handle module-info.java separately as it needs at least JDK 9 >- if [[ -n ${moduleinfo} ]]; then >+ if [[ -n ${moduleinfo} ]] && [[ ${target#1.} -lt 9 ]]; then > if java-pkg_is-vm-version-ge "9" ; then > local tmp_source=${JAVA_PKG_WANT_SOURCE} tmp_target=${JAVA_PKG_WANT_TARGET} > >@@ -532,14 +532,14 @@ java-pkg-simple_src_test() { > local target="$(java-pkg_get-target)" > if [[ ${target#1.} -lt 9 ]]; then > find "${JAVA_TEST_SRC_DIR[@]}" -name \*.java ! -name module-info.java > ${test_sources} >- moduleinfo=$(find "${JAVA_TEST_SRC_DIR[@]}" -name module-info.java) > else > find "${JAVA_TEST_SRC_DIR[@]}" -name \*.java > ${test_sources} > fi >+ moduleinfo=$(find "${JAVA_TEST_SRC_DIR[@]}" -name module-info.java) > > # compile > if [[ -s ${test_sources} ]]; then >- if [[ -n ${moduleinfo} ]] || [[ ${target#1.} -lt 9 ]]; then >+ if [[ -z ${moduleinfo} ]] || [[ ${target#1.} -lt 9 ]]; then > ejavac -d ${classes} -encoding ${JAVA_ENCODING}\ > ${classpath:+-classpath ${classpath}} ${JAVAC_ARGS} @${test_sources} > else >@@ -550,7 +550,7 @@ java-pkg-simple_src_test() { > fi > > # handle module-info.java separately as it needs at least JDK 9 >- if [[ -n ${moduleinfo} ]]; then >+ if [[ -n ${moduleinfo} ]] && [[ ${target#1.} -lt 9 ]]; then > if java-pkg_is-vm-version-ge "9" ; then > local tmp_source=${JAVA_PKG_WANT_SOURCE} tmp_target=${JAVA_PKG_WANT_TARGET} > >-- >2.41.0 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 922157
:
882311
|
882312
| 882313