Update install.sh

This commit is contained in:
Kroese 2024-05-06 04:52:05 +02:00 committed by GitHub
parent fdf0c72340
commit 6fa56e5d67
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 18 additions and 3 deletions

View File

@ -671,9 +671,24 @@ detectVersion() {
arch=$(sed -n "/$tag/{s/.*<$tag>\(.*\)<\/$tag>.*/\1/;p}" <<< "$xml")
case "${arch,,}" in
"0" ) platform="x86" ;;
"9" ) platform="x64" ;;
"12" ) platform="arm64" ;;
"0" )
platform="x86"
if [[ "${PLATFORM,,}" != "x64" ]]; then
error "You cannot boot $platform images on a $PLATFORM cpu!" && exit 67
fi
;;
"9" )
platform="x64"
if [[ "${PLATFORM,,}" != "x64" ]]; then
error "You cannot boot $platform images on a $PLATFORM cpu!" && exit 67
fi
;;
"12" )
platform="arm64"
if [[ "${PLATFORM,,}" != "arm64" ]]; then
error "You cannot boot ${platform^^} images on a $PLATFORM cpu!" && exit 67
fi
;;
esac
id=$(selectVersion "DISPLAYNAME" "$xml" "$platform")