use uname -m to detect architecture (PR #774)

This commit is contained in:
longpanda 2021-03-01 15:17:26 +08:00
parent eb1a014d5b
commit 9f357f8ed1
2 changed files with 4 additions and 4 deletions

View file

@ -12,9 +12,9 @@ if [ -f ./ventoy/version ]; then
curver=$(cat ./ventoy/version)
fi
if uname -a | egrep -q 'aarch64|arm64'; then
if uname -m | egrep -q 'aarch64|arm64'; then
export TOOLDIR=aarch64
elif uname -a | egrep -q 'x86_64|amd64'; then
elif uname -m | egrep -q 'x86_64|amd64'; then
export TOOLDIR=x86_64
else
export TOOLDIR=i386

View file

@ -23,9 +23,9 @@ fi
OLDDIR=$(pwd)
if uname -a | egrep -q 'aarch64|arm64'; then
if uname -m | egrep -q 'aarch64|arm64'; then
TOOLDIR=aarch64
elif uname -a | egrep -q 'x86_64|amd64'; then
elif uname -m | egrep -q 'x86_64|amd64'; then
TOOLDIR=x86_64
else
TOOLDIR=i386