[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [qemu-xen master] Merge remote-tracking branch 'remotes/famz/tags/for-upstream' into staging



=== This changeset includes merge from high-traffic branch ===
Commits on that branch are not reported individually.

commit ad728364e3916e1159ee94e5cd82b7a9c81d2dcc
Merge: 4378caf59edf6df796b9ad3174e5703fd25a781c 
e86c9a64f455018fb04d631e14c5f926e36c69fb
Author:     Peter Maydell <peter.maydell@xxxxxxxxxx>
AuthorDate: Mon Oct 17 11:56:18 2016 +0100
Commit:     Peter Maydell <peter.maydell@xxxxxxxxxx>
CommitDate: Mon Oct 17 11:56:18 2016 +0100

    Merge remote-tracking branch 'remotes/famz/tags/for-upstream' into staging
    
    # gpg: Signature made Mon 17 Oct 2016 03:08:28 BST
    # gpg:                using RSA key 0xCA35624C6A9171C6
    # gpg: Good signature from "Fam Zheng <famz@xxxxxxxxxx>"
    # gpg: WARNING: This key is not certified with a trusted signature!
    # gpg:          There is no indication that the signature belongs to the 
owner.
    # Primary key fingerprint: 5003 7CB7 9706 0F76 F021  AD56 CA35 624C 6A91 
71C6
    
    * remotes/famz/tags/for-upstream:
      tests/docker/Makefile.include: add a generic docker-run target
      tests/docker: make test-mingw honour TARGET_LIST
      tests/docker: test-build script
      tests/docker: add travis dockerfile
    
    Signed-off-by: Peter Maydell <peter.maydell@xxxxxxxxxx>
 tests/docker/Makefile.include          | 61 +++++++++++++++++++++-------------
 tests/docker/dockerfiles/travis.docker |  6 ++++
 tests/docker/test-build                | 20 +++++++++++
 tests/docker/test-mingw                |  3 +-
 4 files changed, 66 insertions(+), 24 deletions(-)

diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include
index b44daab..3f15d5a 100644
--- a/tests/docker/Makefile.include
+++ b/tests/docker/Makefile.include
@@ -78,6 +78,7 @@ docker:
        @echo '                         "IMAGE" is one of the listed container 
name."'
        @echo '    docker-image:        Build all images.'
        @echo '    docker-image-IMAGE:  Build image "IMAGE".'
+       @echo '    docker-run:          For manually running a "TEST" with 
"IMAGE"'
        @echo
        @echo 'Available container images:'
        @echo '    $(DOCKER_IMAGES)'
@@ -101,31 +102,45 @@ docker:
        @echo '    NOCACHE=1            Ignore cache when build images.'
        @echo '    EXECUTABLE=<path>    Include executable in image.'
 
-docker-run-%: CMD = $(shell echo '$@' | sed -e 
's/docker-run-\([^@]*\)@\(.*\)/\1/')
-docker-run-%: IMAGE = $(shell echo '$@' | sed -e 
's/docker-run-\([^@]*\)@\(.*\)/\2/')
-docker-run-%: docker-qemu-src
+# This rule if for directly running against an arbitrary docker target.
+# It is called by the expanded docker targets (e.g. make
+# docker-test-foo@bar) which will do additional verification.
+#
+# For example: make docker-run TEST="test-quick" IMAGE="debian:arm64" 
EXECUTABLE=./aarch64-linux-user/qemu-aarch64
+#
+docker-run: docker-qemu-src
        @mkdir -p "$(DOCKER_CCACHE_DIR)"
-       @if test -z "$(IMAGE)" || test -z "$(CMD)"; \
-               then echo "Invalid target"; exit 1; \
+       @if test -z "$(IMAGE)" || test -z "$(TEST)"; \
+               then echo "Invalid target $(IMAGE)/$(TEST)"; exit 1; \
        fi
-       $(if $(filter $(TESTS),$(CMD)),$(if $(filter $(IMAGES),$(IMAGE)), \
-               $(call quiet-command,\
-                       if $(SRC_PATH)/tests/docker/docker.py images | \
-                               awk '$$1=="qemu" && $$2=="$(IMAGE)"{found=1} 
END{exit(!found)}'; then \
-                               $(SRC_PATH)/tests/docker/docker.py run $(if 
$V,,--rm) \
-                               -t \
-                               $(if $(DEBUG),-i,--net=none) \
-                               -e TARGET_LIST=$(TARGET_LIST) \
-                               -e EXTRA_CONFIGURE_OPTS=$(EXTRA_CONFIGURE_OPTS) 
\
-                               -e V=$V -e J=$J -e DEBUG=$(DEBUG) -e 
SHOW_ENV=$(SHOW_ENV)\
-                               -e CCACHE_DIR=/var/tmp/ccache \
-                               -v $$(readlink -e 
$(DOCKER_SRC_COPY)):/var/tmp/qemu:z$(COMMA)ro \
-                               -v $(DOCKER_CCACHE_DIR):/var/tmp/ccache:z \
-                               qemu:$(IMAGE) \
-                               /var/tmp/qemu/run \
-                               $(CMD); \
-                       fi \
-                       ,"RUN","$(CMD) in $(IMAGE)")))
+       $(if $(EXECUTABLE),                                             \
+               $(call quiet-command,                                   \
+                       $(SRC_PATH)/tests/docker/docker.py update       \
+                       $(IMAGE) $(EXECUTABLE),                         \
+                       "  COPYING $(EXECUTABLE) to $(IMAGE)"))
+       $(call quiet-command,                                           \
+               $(SRC_PATH)/tests/docker/docker.py run                  \
+                       -t                                              \
+                       $(if $V,,--rm)                                  \
+                       $(if $(DEBUG),-i,--net=none)                    \
+                       -e TARGET_LIST=$(TARGET_LIST)                   \
+                       -e EXTRA_CONFIGURE_OPTS="$(EXTRA_CONFIGURE_OPTS)" \
+                       -e V=$V -e J=$J -e DEBUG=$(DEBUG)               \
+                       -e SHOW_ENV=$(SHOW_ENV)                         \
+                       -e CCACHE_DIR=/var/tmp/ccache                   \
+                       -v $$(readlink -e 
$(DOCKER_SRC_COPY)):/var/tmp/qemu:z$(COMMA)ro \
+                       -v $(DOCKER_CCACHE_DIR):/var/tmp/ccache:z       \
+                       $(IMAGE)                                        \
+                       /var/tmp/qemu/run                               \
+                       $(TEST), "  RUN $(TEST) in ${IMAGE}")
+
+# Run targets:
+#
+# Of the form docker-TEST-FOO@IMAGE-BAR which will then be expanded into a 
call to "make docker-run"
+docker-run-%: CMD = $(shell echo '$@' | sed -e 
's/docker-run-\([^@]*\)@\(.*\)/\1/')
+docker-run-%: IMAGE = $(shell echo '$@' | sed -e 
's/docker-run-\([^@]*\)@\(.*\)/\2/')
+docker-run-%:
+       @$(MAKE) docker-run TEST=$(CMD) IMAGE=qemu:$(IMAGE)
 
 docker-clean:
        $(call quiet-command, $(SRC_PATH)/tests/docker/docker.py clean)
diff --git a/tests/docker/dockerfiles/travis.docker 
b/tests/docker/dockerfiles/travis.docker
new file mode 100644
index 0000000..e4983ae
--- /dev/null
+++ b/tests/docker/dockerfiles/travis.docker
@@ -0,0 +1,6 @@
+FROM quay.io/travisci/travis-ruby
+RUN apt-get update
+RUN apt-get -y build-dep qemu
+RUN apt-get -y build-dep device-tree-compiler
+RUN apt-get -y install python2.7 dh-autoreconf
+ENV FEATURES pyyaml
diff --git a/tests/docker/test-build b/tests/docker/test-build
new file mode 100755
index 0000000..031a7d9
--- /dev/null
+++ b/tests/docker/test-build
@@ -0,0 +1,20 @@
+#!/bin/bash -e
+#
+# Quick compile test without the make check step of test-quick.
+#
+# Copyright (c) 2016 Red Hat Inc.
+#
+# Authors:
+#  Fam Zheng <famz@xxxxxxxxxx>
+#
+# This work is licensed under the terms of the GNU GPL, version 2
+# or (at your option) any later version. See the COPYING file in
+# the top-level directory.
+
+. common.rc
+
+cd "$BUILD_DIR"
+
+DEF_TARGET_LIST="x86_64-softmmu,aarch64-softmmu"
+TARGET_LIST=${TARGET_LIST:-$DEF_TARGET_LIST} \
+build_qemu
diff --git a/tests/docker/test-mingw b/tests/docker/test-mingw
index 3396876..2adadcb 100755
--- a/tests/docker/test-mingw
+++ b/tests/docker/test-mingw
@@ -16,9 +16,10 @@
 requires mingw dtc
 
 cd "$BUILD_DIR"
+DEF_TARGET_LIST="x86_64-softmmu,aarch64-softmmu"
 
 for prefix in x86_64-w64-mingw32- i686-w64-mingw32-; do
-    TARGET_LIST=x86_64-softmmu,aarch64-softmmu \
+    TARGET_LIST=${TARGET_LIST:-$DEF_TARGET_LIST} \
         build_qemu --cross-prefix=$prefix \
         --enable-trace-backends=simple \
         --enable-debug \
--
generated by git-patchbot for /home/xen/git/qemu-xen.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.