Skip to content

Commit

Permalink
clh: correct cloud-hypervisor installation
Browse files Browse the repository at this point in the history
Currently, there is cloud hypervisor binary released only for x86, thus
we must build from source code when install cloud hypervisor on arm64.

Fixes: #2410
Signed-off-by: Jianyong Wu <jianyong.wu@arm.com>
  • Loading branch information
jongwu committed Aug 9, 2021
1 parent e07a9fe commit f981fc6
Showing 1 changed file with 7 additions and 2 deletions.
Expand Up @@ -8,6 +8,11 @@ set -o errexit
set -o nounset
set -o pipefail

ARCH=$(uname -m)

# Currently, Cloud Hypervisor only support arm64 and x86_64
[ "${ARCH}" != "aarch64" ] && [ "${ARCH}" != "x86_64" ] && exit

script_dir=$(dirname $(readlink -f "$0"))
kata_version="${kata_version:-}"

Expand Down Expand Up @@ -50,7 +55,7 @@ build_clh_from_source() {
popd
}

if ! pull_clh_released_binary; then
info "failed to pull cloud-hypervisor released binary, trying to build from source"
if [ ${ARCH} == "aarch64" ] || ! pull_clh_released_binary; then
info "arch is aarch64 or failed to pull cloud-hypervisor released binary on x86_64, trying to build from source"
build_clh_from_source
fi

0 comments on commit f981fc6

Please sign in to comment.