You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@impala.apache.org by ta...@apache.org on 2020/02/20 02:02:57 UTC
[impala] 02/03: IMPALA-9396 Add arm64 openjdk version for Ubuntu
18.04
This is an automated email from the ASF dual-hosted git repository.
tarmstrong pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/impala.git
commit 88b6dd6a712cde32465308291af6341ce31676de
Author: zhaorenhai <zh...@hotmail.com>
AuthorDate: Tue Feb 18 13:41:25 2020 +0000
IMPALA-9396 Add arm64 openjdk version for Ubuntu 18.04
Add arm64 openjdk version for Ubuntu 18.04 in bootstrap_system.sh
Change-Id: I8a7572439cef8f53499c3b20a09269613feea2cf
Reviewed-on: http://gerrit.cloudera.org:8080/15237
Reviewed-by: Tim Armstrong <ta...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
bin/bootstrap_system.sh | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/bin/bootstrap_system.sh b/bin/bootstrap_system.sh
index c6ef1d1..9473eb4 100755
--- a/bin/bootstrap_system.sh
+++ b/bin/bootstrap_system.sh
@@ -217,8 +217,12 @@ fi
# Ubuntu 18.04 installs OpenJDK 11 and configures it as the default Java version.
# Impala is currently tested with OpenJDK 8, so configure that version as the default.
-ubuntu18 sudo update-java-alternatives -s java-1.8.0-openjdk-amd64
-
+ARCH_NAME=$(uname -p)
+if [[ $ARCH_NAME == 'aarch64' ]]; then
+ ubuntu18 sudo update-java-alternatives -s java-1.8.0-openjdk-arm64
+else
+ ubuntu18 sudo update-java-alternatives -s java-1.8.0-openjdk-amd64
+fi
redhat sudo yum install -y curl gcc gcc-c++ git krb5-devel krb5-server krb5-workstation \
libevent-devel libffi-devel make ntp ntpdate ntp-perl openssl-devel cyrus-sasl \
@@ -290,7 +294,7 @@ notindocker redhat7 sudo service ntpd start
# IMPALA-3932, IMPALA-3926
if [[ $UBUNTU = true && ( $DISTRIB_RELEASE = 16.04 || $DISTRIB_RELEASE = 18.04 ) ]]
then
- SET_LD_LIBRARY_PATH='export LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu/${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}'
+ SET_LD_LIBRARY_PATH="export LD_LIBRARY_PATH=/usr/lib/${ARCH_NAME}-linux-gnu/${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}"
echo -e "\n$SET_LD_LIBRARY_PATH" >> "${IMPALA_HOME}/bin/impala-config-local.sh"
eval "$SET_LD_LIBRARY_PATH"
fi
@@ -395,7 +399,9 @@ eval "$SET_IMPALA_HOME"
# Ubuntu and RH install JDK's in slightly different paths.
if [[ $UBUNTU == true ]]; then
- SET_JAVA_HOME="export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64"
+ # Assert that there's only one glob match.
+ [ 1 == $(compgen -G "/usr/lib/jvm/java-8-openjdk-*" | wc -l) ]
+ SET_JAVA_HOME="export JAVA_HOME=$(compgen -G '/usr/lib/jvm/java-8-openjdk-*')"
else
# Assert that there's only one glob match.
[ 1 == $(compgen -G "/usr/lib/jvm/java-1.8.0-openjdk-*" | wc -l) ]