Make architecture checking more stringent when installing emulators

Also change the documentation to an armv7hf.

Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
This commit is contained in:
Cameron Diver 2018-12-03 13:10:54 +00:00
parent 6070ee0f83
commit a357405f3a
No known key found for this signature in database
GPG Key ID: 49690ED87032539F
3 changed files with 5 additions and 4 deletions

View File

@ -1569,7 +1569,7 @@ Examples:
$ balena build
$ balena build ./source/
$ balena build --deviceType raspberrypi3 --arch armhf --emulated
$ balena build --deviceType raspberrypi3 --arch armv7hf --emulated
$ balena build --application MyApp ./source/
$ balena build --docker '/var/run/docker.sock'
$ balena build --dockerHost my.docker.host --dockerPort 2376 --ca ca.pem --key key.pem --cert cert.pem

View File

@ -66,7 +66,7 @@ module.exports =
$ balena build
$ balena build ./source/
$ balena build --deviceType raspberrypi3 --arch armhf --emulated
$ balena build --deviceType raspberrypi3 --arch armv7hf --emulated
$ balena build --application MyApp ./source/
$ balena build --docker '/var/run/docker.sock'
$ balena build --dockerHost my.docker.host --dockerPort 2376 --ca ca.pem --key key.pem --cert cert.pem

View File

@ -104,5 +104,6 @@ installQemu = (arch) ->
balenaArchToQemuArch = (arch) ->
switch arch
when 'armv7hf', 'rpi' then 'arm'
else arch
when 'armv7hf', 'rpi', 'armhf' then 'arm'
when 'aarch64' then 'aarch64'
else throw new Error("Cannot install emulator for architecture #{arch}")