From 973391504789efcab8e01c2b974f5ceb7f564bee Mon Sep 17 00:00:00 2001 From: Joel Stanley Date: Wed, 2 May 2018 16:48:07 +0930 Subject: tests: Specfiy Qemu with a single environment variable This allows Qemu to work out of the box if the user has an appropriate Qemu installed. Support for running TCG power guests has come a long way from when we first added these test scripts. It makes sense to use the system Qemu where possible, as for most people this will succeed. Signed-off-by: Joel Stanley Signed-off-by: Stewart Smith --- test/hello_world/run_qemu_hello_world.sh | 14 +++++--------- test/run_qemu-jessie-debian-installer_boot_test.sh | 14 +++++--------- test/run_qemu_boot_test.sh | 14 +++++--------- 3 files changed, 15 insertions(+), 27 deletions(-) (limited to 'test') diff --git a/test/hello_world/run_qemu_hello_world.sh b/test/hello_world/run_qemu_hello_world.sh index e08f851..cc5055e 100755 --- a/test/hello_world/run_qemu_hello_world.sh +++ b/test/hello_world/run_qemu_hello_world.sh @@ -1,16 +1,12 @@ #!/bin/bash -if [ -z "$QEMU_PATH" ]; then - QEMU_PATH=`pwd`/opal-ci/qemu/ppc64-softmmu/ +if [ -z "$QEMU" ]; then + QEMU="qemu-system-ppc64" fi -if [ -z "$QEMU_BINARY" ]; then - QEMU_BINARY="qemu-system-ppc64" -fi - -if [ ! -x "$QEMU_PATH/$QEMU_BINARY" ]; then - echo 'Could not find executable QEMU_BINARY. Skipping hello_world test'; +if [ ! `command -v $QEMU` ]; then + echo 'Could not find executable QEMU. Skipping hello_world test'; exit 0; fi @@ -34,7 +30,7 @@ trap "rm -f -- '$t'" EXIT ( cat <&1 > $T ( cat <