Skip to contentSkip to conversation

tests/docker: Clean up paths

PATCH In review Fam Zheng 1 participant 2 messages Aug 17, 2017 – Sep 5, 2017

lore
Share & tools
lore

Fam Zheng

author
#0 lore raw

PATCH 1/1 tests/docker: Clean up paths

The 'run' script already creats src, build and install directories under $TEST_DIR, use it in common.rc.

Also the tests always run from $QEMU_SRC/tests/docker, so use a relative $CMD string.

---
 tests/docker/common.rc | 5 +----
 tests/docker/run       | 4 +++-
 2 files changed, 4 insertions(+), 5 deletions(-)
tests/docker/common.rc +1 -4
index 6865689bb5..64b36ba2d0 100755
@@ -11,9 +11,6 @@
 # or (at your option) any later version. See the COPYING file in
 # the top-level directory.
 
-BUILD_DIR=/var/tmp/qemu-build
-mkdir $BUILD_DIR
-
 requires()
 {
     for c in $@; do
@@ -28,7 +25,7 @@ build_qemu()
 {
     config_opts="--enable-werror \
                  ${TARGET_LIST:+--target-list=${TARGET_LIST}} \
-                 --prefix=$PWD/install \
+                 --prefix=$INSTALL_DIR \
                  $QEMU_CONFIGURE_OPTS $EXTRA_CONFIGURE_OPTS \
                  $@"
     echo "Configure options:"
tests/docker/run +3 -1
index c1e4513bce..ec2541cbd9 100755
@@ -52,10 +52,12 @@ if test -n "$SHOW_ENV"; then
 fi
 
 export QEMU_SRC="$TEST_DIR/src"
+export BUILD_DIR="$TEST_DIR/build"
+export INSTALL_DIR="$TEST_DIR/install"
 
 cd "$QEMU_SRC/tests/docker"
 
-CMD="$QEMU_SRC/tests/docker/$@"
+CMD="./$@"
 
 if test -z "$DEBUG"; then
     exec $CMD
Signature · 1 line
2.13.4
author
#1 lore raw
Quoted 7 lines · Fam Zheng

The 'run' script already creats src, build and install directories under $TEST_DIR, use it in common.rc.

Also the tests always run from $QEMU_SRC/tests/docker, so use a relative $CMD string.

Queued.

Fam