From: Lucas Meneghel Rodrigues <lmr@redhat.com>
To: qemu-devel@nongnu.org
Cc: kwolf@redhat.com, Lucas Meneghel Rodrigues <lmr@redhat.com>,
hch@lst.de, kvm@vger.kernel.org
Subject: [Qemu-devel] [PATCH 2/2] common.config: Allow use of arbitrary qemu* paths
Date: Thu, 1 Dec 2011 11:41:24 -0200 [thread overview]
Message-ID: <1322746884-8723-3-git-send-email-lmr@redhat.com> (raw)
In-Reply-To: <1322746884-8723-1-git-send-email-lmr@redhat.com>
Since we might want to test arbitrary qemu, qemu-img and
qemu-io paths, allow users to specify environment variable
values for QEMU_PROG, QEMU_IMG_PROG and QEMU_IO_PROG so
the testsuite will use those values rather than find them
on PATH. Obviously, if such env variables are not set
prior to script execution, normal detection mechanism
takes place.
Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
---
common.config | 12 +++++++++---
1 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/common.config b/common.config
index d5a72af..d07f435 100644
--- a/common.config
+++ b/common.config
@@ -87,13 +87,19 @@ export BC_PROG="`set_prog_path bc`"
export PS_ALL_FLAGS="-ef"
-export QEMU_PROG="`set_prog_path qemu`"
+if [ -z "$QEMU_PROG" ]; then
+ export QEMU_PROG="`set_prog_path qemu`"
+fi
[ "$QEMU_PROG" = "" ] && _fatal "qemu not found"
-export QEMU_IMG_PROG="`set_prog_path qemu-img`"
+if [ -z "$QEMU_IMG_PROG" ]; then
+ export QEMU_IMG_PROG="`set_prog_path qemu-img`"
+fi
[ "$QEMU_IMG_PROG" = "" ] && _fatal "qemu-img not found"
-export QEMU_IO_PROG="`set_prog_path qemu-io`"
+if [ -z "$QEMU_IO_PROG" ]; then
+ export QEMU_IO_PROG="`set_prog_path qemu-io`"
+fi
[ "$QEMU_IO_PROG" = "" ] && _fatal "qemu-io not found"
export QEMU=$QEMU_PROG
--
1.7.7.3
next prev parent reply other threads:[~2011-12-01 13:41 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-01 13:41 [Qemu-devel] [PATCH 0/2] qemu-io tests: More fine grained control of qemu paths Lucas Meneghel Rodrigues
2011-12-01 13:41 ` [Qemu-devel] [PATCH 1/2] check: print relevant path information Lucas Meneghel Rodrigues
2011-12-01 13:41 ` Lucas Meneghel Rodrigues [this message]
2011-12-08 16:51 ` [Qemu-devel] [PATCH 0/2] qemu-io tests: More fine grained control of qemu paths Christoph Hellwig
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1322746884-8723-3-git-send-email-lmr@redhat.com \
--to=lmr@redhat.com \
--cc=hch@lst.de \
--cc=kvm@vger.kernel.org \
--cc=kwolf@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).