X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=shell%2Fupdate-java-alternatives.sh;h=536063b9d6643b80dc2362b76e7dc197aa7b6cb7;hb=e1a8dc64cfe10360ebdcadd28806adf800760ce7;hp=69bf0195fc3aa02bcfcc1f856380ba175447a4fa;hpb=964473c31bfdfa0c9d436510f1608791b49d4c04;p=releng%2Fglobal-jjb.git diff --git a/shell/update-java-alternatives.sh b/shell/update-java-alternatives.sh index 69bf0195..536063b9 100644 --- a/shell/update-java-alternatives.sh +++ b/shell/update-java-alternatives.sh @@ -8,7 +8,7 @@ # which accompanies this distribution, and is available at # http://www.eclipse.org/legal/epl-v10.html ############################################################################## - +echo "---> update-java-alternatives.sh" # This script takes the java-version variable to set the proper alternative # for java, javac and java_sdk_openjdk for ubuntu or centos/fedora/redhat distros @@ -17,6 +17,8 @@ JAVA_ENV_FILE="/tmp/java.env" update-java-redhat() { if [[ "${SET_JDK_VERSION//[a-zA-Z]/}" = "11" ]]; then export JAVA_HOME="/usr/lib/jvm/java-11-openjdk" + elif [[ "${SET_JDK_VERSION//[a-zA-Z]/}" = "12" ]]; then + export JAVA_HOME="/usr/lib/jvm/java-12-openjdk" else export JAVA_HOME="/usr/lib/jvm/java-1.${SET_JDK_VERSION//[a-zA-Z:-]/}.0-openjdk" fi