From 7a4a5496aaa2462dc00a771b4cee623208aa8748 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Fournier?= Date: Thu, 26 Apr 2018 14:36:41 +0200 Subject: [PATCH] Support java10 correctly --- pmd-dist/src/main/scripts/run.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pmd-dist/src/main/scripts/run.sh b/pmd-dist/src/main/scripts/run.sh index 5e38865f32..283d00de09 100755 --- a/pmd-dist/src/main/scripts/run.sh +++ b/pmd-dist/src/main/scripts/run.sh @@ -77,14 +77,14 @@ check_lib_dir() { jre_specific_vm_options() { # java_ver is eg "18" for java 1.8, "90" for java 9.0 java_ver=$(java -version 2>&1 | sed -n ';s/.* version "\(.*\)\.\(.*\)\..*"/\1\2/p;') - - if [ $java_ver -ge 90 ] - then - # Opens internal module of javafx to reflection + options="" + + if [ $java_ver -ge 90 ] && [ "${APPNAME}" = "designer" ] + then # open internal module of javafx to reflection options="--add-opens javafx.controls/javafx.scene.control.skin=ALL-UNNAMED" - - echo $options fi + + echo $options } readonly APPNAME="${1}"