Skip to content

Commit 1453583

Browse files
author
urbaneks
committed
javareconf: update VALID_JVM_VARIANTS from JDK 24u (PR#18884)
git-svn-id: https://svn.r-project.org/R/trunk@88154 00db46b3-68df-0310-9c12-caf00c1e9a41
1 parent f5ff079 commit 1453583

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

src/scripts/javareconf.in

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -222,20 +222,23 @@ if test "${JAVA_LIBS}" = '~autodetect~'; then
222222
break
223223
fi
224224
done
225+
IFS=${save_IFS}
225226
# Then try some heuristics using sun.boot.library.path
226227
if test ${has_libjvm} = no; then
227228
boot_path=`"$JAVA" -classpath "${tools_classpath}" getsp sun.boot.library.path| ${SED-sed} -e 's/:$//' -e 's/^://'`
228229
if test -n "${boot_path}"; then
229-
for dir in "${boot_path}" "${boot_path}/client" "${boot_path}/server"; do
230-
if test -f "$dir/libjvm${DYLIB_EXT}"; then
230+
# libjvm is typically in the variant subdirectory. For variants
231+
# see make/autoconf/hotspot.m4 in JDK sources:
232+
VALID_JVM_VARIANTS="server client minimal core zero custom"
233+
for dir in '' ${VALID_JVM_VARIANTS}; do
234+
if test -f "${boot_path}/$dir/libjvm${DYLIB_EXT}"; then
231235
has_libjvm=yes
232-
java_library_path="${dir}"
236+
java_library_path="${boot_path}/$dir"
233237
break
234238
fi
235239
done
236240
fi
237241
fi
238-
IFS=${save_IFS}
239242
# replace occurrences of JAVA_HOME with $(JAVA_HOME)
240243
# If JAVA_HOME was a link, it will be the canonical path we
241244
# want to replace. We need working realpath to determine what that is.

0 commit comments

Comments
 (0)