]> git.proxmox.com Git - mirror_qemu.git/commitdiff
docker: Build in a clean directory
authorFam Zheng <famz@redhat.com>
Wed, 28 Sep 2016 07:31:32 +0000 (15:31 +0800)
committerFam Zheng <famz@redhat.com>
Sun, 2 Oct 2016 01:47:23 +0000 (09:47 +0800)
Currently we configure and build under "$QEMU_SRC/tests/docker" which is
dubious. Create a fixed directory (to be friendly to ccache) and change
to there before calling build_qemu.

Signed-off-by: Fam Zheng <famz@redhat.com>
Message-Id: <1475047892-11955-1-git-send-email-famz@redhat.com>

tests/docker/common.rc
tests/docker/test-clang
tests/docker/test-full
tests/docker/test-mingw
tests/docker/test-quick

index 510a3ad3f443f40e072805239827c92846f9fb78..21657e87c646f812379fbfa6884dfb8aa149c6c9 100755 (executable)
@@ -11,6 +11,9 @@
 # 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
index 60e4e976b32e878f693b6c2427543ac5148102eb..16485e6b7e5b691bc4b8f2717d9edf1d772b334a 100755 (executable)
@@ -15,6 +15,8 @@
 
 requires clang
 
+cd "$BUILD_DIR"
+
 OPTS="--enable-debug --cxx=clang++ --cc=clang --host-cc=clang"
 # -fsanitize=undefined is broken on Fedora 23, skip it for now
 # See also: https://bugzilla.redhat.com/show_bug.cgi?id=1263834
index fd9b798947cb072c69811950e7aa1f3553595198..05f0d491d14f3dbde47857bbdc7047280078ea5a 100755 (executable)
@@ -13,5 +13,7 @@
 
 . common.rc
 
+cd "$BUILD_DIR"
+
 build_qemu
 make check $MAKEFLAGS
index c03757add8ab7eb0fc872ed1ce8d1d241e2ce27e..33968769f883233ce79a23096589c392a6464ed2 100755 (executable)
@@ -15,6 +15,8 @@
 
 requires mingw dtc
 
+cd "$BUILD_DIR"
+
 for prefix in x86_64-w64-mingw32- i686-w64-mingw32-; do
     TARGET_LIST=x86_64-softmmu,aarch64-softmmu \
         build_qemu --cross-prefix=$prefix \
index 7885dfafdbe6a48921a32c0e2da13b217e2d5f4d..c465dc06d89213c71c0a576dc463e0ce44f55277 100755 (executable)
@@ -13,6 +13,8 @@
 
 . common.rc
 
+cd "$BUILD_DIR"
+
 DEF_TARGET_LIST="x86_64-softmmu,aarch64-softmmu"
 TARGET_LIST=${TARGET_LIST:-$DEF_TARGET_LIST} \
 build_qemu