add JAVA_OPTS_APPEND option from legacy to X (resolves #9188)

This commit is contained in:
Niko Köbler 2021-12-16 12:22:09 +01:00 committed by Pedro Igor
parent 68271ba486
commit b03269440c
2 changed files with 10 additions and 0 deletions

View file

@ -72,6 +72,11 @@ if not "x%JAVA_OPTS%" == "x" (
set "JAVA_OPTS=-Xms64m -Xmx512m -XX:MetaspaceSize=96M -XX:MaxMetaspaceSize=256m -Djava.net.preferIPv4Stack=true" set "JAVA_OPTS=-Xms64m -Xmx512m -XX:MetaspaceSize=96M -XX:MaxMetaspaceSize=256m -Djava.net.preferIPv4Stack=true"
) )
if not "x%JAVA_OPTS_APPEND%" == "x" (
echo "Appending additional Java properties to JAVA_OPTS: %JAVA_OPTS_APPEND%"
set "JAVA_OPTS=%JAVA_OPTS% %JAVA_OPTS_APPEND%"
)
if NOT "x%DEBUG%" == "x" ( if NOT "x%DEBUG%" == "x" (
set "DEBUG_MODE=%DEBUG% set "DEBUG_MODE=%DEBUG%
) )

View file

@ -68,6 +68,11 @@ else
echo "JAVA_OPTS already set in environment; overriding default settings with values: $JAVA_OPTS" echo "JAVA_OPTS already set in environment; overriding default settings with values: $JAVA_OPTS"
fi fi
if [ "x$JAVA_OPTS_APPEND" != "x" ]; then
echo "Appending additional Java properties to JAVA_OPTS: $JAVA_OPTS_APPEND"
JAVA_OPTS="$JAVA_OPTS $JAVA_OPTS_APPEND"
fi
# Set debug settings if not already set # Set debug settings if not already set
if [ "$DEBUG_MODE" = "true" ]; then if [ "$DEBUG_MODE" = "true" ]; then
DEBUG_OPT=`echo $JAVA_OPTS | $GREP "\-agentlib:jdwp"` DEBUG_OPT=`echo $JAVA_OPTS | $GREP "\-agentlib:jdwp"`