Skip to contentSkip to conversation

Misc fixes / improvements for the docker and travis configs

PATCH In review Daniel P. Berrangé 3 participants 17 messages Jan 9, 2019 – Jan 13, 2019

lore
Share & tools
lore
#0 lore raw

cover Misc fixes / improvements for the docker and travis configs

I've be exploring the possibility of using docker images from within travis to let us avoid the ancient versions of ubuntu travis requires.

As part of this I needed todo some refactoring of travis config to more consistently structure build / test commands and use of env variables. That resulted in this series of misc fixes and improvements for both docker & travis configs.

I've struggled to get travis to complete successfully in testing this, but to best of my knowledge the problems I'm hitting are pre-existing. In particular the gprof test fails reliably with 10 min timeout. The OS-X build is failing fairly often with "make: write error" which looks like a possible travis infrastructure bug AFAICT. Other tests get some non-deterministic failures too which are things we've seen often in QEMU.

Daniel P. Berrangé (13):
tests: run ldconfig after installing extra software
tests: remove obsolete 'debian' dockerfile
tests: update Fedora dockerfile to use Fedora 29
tests: update Fedora i386 cross image to Fedora 29
travis: add whitespace between each major section & matrix entry
travis: define all the build matrix entries in one place
travis: standardize the syntax used for env variables
travis: don't clone git submodules upfront
travis: move macOS brew setup into the macOS matrix entries
travis: stop redefining the script commands
travis: stop using container based envs
travis: run tests in verbose mode
travis: remove matrix settings that duplicate global settings

 .travis.yml                                   | 164 ++++++++++++------
 tests/docker/dockerfiles/debian-amd64.docker  |   2 +
 tests/docker/dockerfiles/debian.docker        |  13 --
 .../dockerfiles/fedora-i386-cross.docker      |   2 +-
 tests/docker/dockerfiles/fedora.docker        |   4 +-
 5 files changed, 117 insertions(+), 68 deletions(-)
 delete mode 100644 tests/docker/dockerfiles/debian.docker
Signature · 1 line
2.19.2
#1 lore raw

PATCH 1/13 tests: run ldconfig after installing extra software

The docker file builds and installs software into /usr/local but does not run ldconfig. As a result QEMU links to libvirglrenderer.so, but then crashes in "make check" unable to find the library.

---
 tests/docker/dockerfiles/debian-amd64.docker | 2 ++
 1 file changed, 2 insertions(+)
tests/docker/dockerfiles/debian-amd64.docker +2 -0
index 24b113b76f..1f597121dc 100644
@@ -35,5 +35,7 @@ RUN git clone https://github.com/luigirizzo/netmap.git /usr/src/netmap
 RUN cd /usr/src/netmap/LINUX && ./configure --no-drivers --no-apps --kernel-dir=$(ls -d /usr/src/linux-headers-*-amd64) && make install
 ENV QEMU_CONFIGURE_OPTS --enable-netmap
 
+RUN ldconfig
+
 # gcrypt
 ENV QEMU_CONFIGURE_OPTS $QEMU_CONFIGURE_OPTS --enable-gcrypt
Signature · 1 line
2.19.2
#2 lore raw

PATCH 2/13 tests: remove obsolete 'debian' dockerfile

In reply to Daniel P. Berrangé

The 'debian' dockerfile was deprecated in favour of versioned dockerfiles in July 2017. That is enough time for developers to be warned about the rename.

---
 tests/docker/dockerfiles/debian.docker | 13 -------------
 1 file changed, 13 deletions(-)
 delete mode 100644 tests/docker/dockerfiles/debian.docker
tests/docker/dockerfiles/debian.docker deleted +0 -13
deleted file mode 100644
index fd32e71b79..0000000000
@@ -1,13 +0,0 @@
-# This template is deprecated and was previously based on Jessie on QEMU 2.9.
-# Now than Stretch is out, please use qemu:debian8 as base for Jessie,
-# and qemu:debian9 for Stretch.
-#
-FROM qemu:debian9
-
-MAINTAINER Philippe Mathieu-Daudé <[email protected]>
-
-RUN for n in $(seq 8); do echo; done && \
-    echo "\n\t\tThis image is deprecated." && echo && \
-    echo "\tUse 'FROM qemu:debian9' to use the stable Debian Stretch image" && \
-    echo "\tor 'FROM qemu:debian8' to use old Debian Jessie." && \
-    for n in $(seq 8); do echo; done
Signature · 1 line
2.19.2
#3 lore raw

PATCH 3/13 tests: update Fedora dockerfile to use Fedora 29

In reply to Daniel P. Berrangé

Fedora 29 is the current newest release, so switch to using that from the current Fedora 28.

---
 tests/docker/dockerfiles/fedora.docker | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
tests/docker/dockerfiles/fedora.docker +2 -2
index 0c4eb9e49c..58474a5322 100644
@@ -1,4 +1,4 @@
-FROM fedora:28
+FROM fedora:29
 ENV PACKAGES \
     bc \
     bison \
@@ -81,7 +81,7 @@ ENV PACKAGES \
     tar \
     usbredir-devel \
     virglrenderer-devel \
-    vte3-devel \
+    vte291-devel \
     which \
     xen-devel \
     zlib-devel
Signature · 1 line
2.19.2
#4 lore raw

PATCH 4/13 tests: update Fedora i386 cross image to Fedora 29

In reply to Daniel P. Berrangé

Using the "latest" tag is not a good idea because this changes what release it points to every 6 months. Together with caching of docker builds this can cause confusion where CI has cached & built with Fedora N, while a developer tries to reproduce a CI problem with Fedora N + 1, or vica-verca.

---
 tests/docker/dockerfiles/fedora-i386-cross.docker | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tests/docker/dockerfiles/fedora-i386-cross.docker +1 -1
index a4fd895b07..eb8108d118 100644
@@ -1,4 +1,4 @@
-FROM fedora:latest
+FROM fedora:29
 ENV PACKAGES \
     gcc \
     glib2-devel.i686 \
Signature · 1 line
2.19.2
#5 lore raw

PATCH 5/13 travis: add whitespace between each major section & matrix entry

In reply to Daniel P. Berrangé

Improve the readability of the travis config by adding two blank lines between each major section and matrix entry.

---
 .travis.yml | 42 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)
.travis.yml +42 -0
index d472fd650b..bb43792627 100644
@@ -1,6 +1,7 @@
 # The current Travis default is a container based 14.04 Trust on EC2
 # Additional builds with specific requirements for a full VM need to
 # be added as additional matrix: entries later on
+
 sudo: false
 dist: trusty
 language: c
@@ -9,6 +10,8 @@ python:
 compiler:
   - gcc
 cache: ccache
+
+
 addons:
   apt:
     packages:
@@ -40,6 +43,7 @@ addons:
       - uuid-dev
       - gcovr
 
+
 # The channel name "irc.oftc.net#qemu" is encrypted against qemu/qemu
 # to prevent IRC notifications from forks. This was created using:
 # $ travis encrypt -r "qemu/qemu" "irc.oftc.net#qemu"
@@ -49,6 +53,8 @@ notifications:
       - secure: "F7GDRgjuOo5IUyRLqSkmDL7kvdU4UcH3Lm/W2db2JnDHTGCqgEdaYEYKciyCLZ57vOTsTsOgesN8iUT7hNHBd1KWKjZe9KDTZWppWRYVwAwQMzVeSOsbbU4tRoJ6Pp+3qhH1Z0eGYR9ZgKYAoTumDFgSAYRp4IscKS8jkoedOqM="
     on_success: change
     on_failure: always
+
+
 env:
   global:
     - SRC_DIR="."
@@ -63,9 +69,13 @@ env:
     - CONFIG="--enable-modules --disable-linux-user"
     - CONFIG="--with-coroutine=ucontext --disable-linux-user"
     - CONFIG="--with-coroutine=sigaltstack --disable-linux-user"
+
+
 git:
   # we want to do this ourselves
   submodules: false
+
+
 before_install:
   - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew update ; fi
   - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew install libffi gettext glib pixman ; fi
@@ -75,54 +85,82 @@ before_script:
   - ${SRC_DIR}/configure ${CONFIG} || { cat config.log && exit 1; }
 script:
   - make ${MAKEFLAGS} && ${TEST_CMD}
+
+
 matrix:
   include:
     # Test out-of-tree builds
     - env: CONFIG="--enable-debug --enable-debug-tcg"
            BUILD_DIR="out-of-tree/build/dir" SRC_DIR="../../.."
+
+
     # Test with Clang for compile portability (Travis uses clang-5.0)
     - env: CONFIG="--disable-system"
       compiler: clang
+
+
     - env: CONFIG="--disable-user"
       compiler: clang
+
+
     # gprof/gcov are GCC features
     - env: CONFIG="--enable-gprof --enable-gcov --disable-pie --target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
       after_success:
         - ${SRC_DIR}/scripts/travis/coverage-summary.sh
       compiler: gcc
+
+
     # We manually include builds which we disable "make check" for
     - env: CONFIG="--enable-debug --enable-tcg-interpreter"
            TEST_CMD=""
       compiler: gcc
+
+
     # We don't need to exercise every backend with every front-end
     - env: CONFIG="--enable-trace-backends=log,simple,syslog --disable-system"
            TEST_CMD=""
       compiler: gcc
+
+
     - env: CONFIG="--enable-trace-backends=ftrace --target-list=x86_64-softmmu"
            TEST_CMD=""
       compiler: gcc
+
+
     - env: CONFIG="--enable-trace-backends=ust --target-list=x86_64-softmmu"
            TEST_CMD=""
       compiler: gcc
+
+
     - env: CONFIG="--disable-tcg"
            TEST_CMD=""
       compiler: gcc
+
+
     # MacOSX builds
     - env: CONFIG="--target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
       os: osx
       osx_image: xcode9.4
       compiler: clang
+
+
     - env: CONFIG="--target-list=i386-softmmu,ppc-softmmu,ppc64-softmmu,m68k-softmmu,x86_64-softmmu"
       os: osx
       osx_image: xcode10
       compiler: clang
+
+
     # Python builds
     - env: CONFIG="--target-list=x86_64-softmmu"
       python:
         - "3.0"
+
+
     - env: CONFIG="--target-list=x86_64-softmmu"
       python:
         - "3.6"
+
+
     # Acceptance (Functional) tests
     - env: CONFIG="--python=/usr/bin/python3 --target-list=x86_64-softmmu"
            TEST_CMD="make AVOCADO_SHOW=app check-acceptance"
@@ -131,6 +169,8 @@ matrix:
           packages:
             - python3-pip
             - python3.4-venv
+
+
     # Using newer GCC with sanitizers
     - addons:
         apt:
@@ -175,6 +215,8 @@ matrix:
         - TEST_CMD=""
       before_script:
         - ./configure ${CONFIG} --extra-cflags="-g3 -O0 -fsanitize=thread -fuse-ld=gold" || { cat config.log && exit 1; }
+
+
     - env:
         - CONFIG="--disable-system --disable-docs"
         - TEST_CMD="make check-tcg"
Signature · 1 line
2.19.2
#6 lore raw

PATCH 6/13 travis: define all the build matrix entries in one place

In reply to Daniel P. Berrangé

The current build matrix is constructed from entries listed under the environment variable config section, as well as the general purpose build matrix section. Move everything under the general purpose section so it is clear at a glance what is in the matrix.

---
 .travis.yml | 29 +++++++++++++++++++++--------
 1 file changed, 21 insertions(+), 8 deletions(-)
.travis.yml +21 -8
index bb43792627..96917df9c5 100644
@@ -61,14 +61,6 @@ env:
     - BUILD_DIR="."
     - TEST_CMD="make check"
     - MAKEFLAGS="-j3"
-  matrix:
-    - CONFIG="--disable-system"
-    - CONFIG="--disable-user"
-    - CONFIG="--enable-debug --enable-debug-tcg"
-    - CONFIG="--disable-linux-aio --disable-cap-ng --disable-attr --disable-brlapi --disable-uuid --disable-libusb --disable-user"
-    - CONFIG="--enable-modules --disable-linux-user"
-    - CONFIG="--with-coroutine=ucontext --disable-linux-user"
-    - CONFIG="--with-coroutine=sigaltstack --disable-linux-user"
 
 
 git:
@@ -89,6 +81,27 @@ script:
 
 matrix:
   include:
+    - env: CONFIG="--disable-system"
+
+
+    - env: CONFIG="--disable-user"
+
+
+    - env: CONFIG="--enable-debug --enable-debug-tcg"
+
+
+    - env: CONFIG="--disable-linux-aio --disable-cap-ng --disable-attr --disable-brlapi --disable-uuid --disable-libusb --disable-user"
+
+
+    - env: CONFIG="--enable-modules --disable-linux-user"
+
+
+    - env: CONFIG="--with-coroutine=ucontext --disable-linux-user"
+
+
+    - env: CONFIG="--with-coroutine=sigaltstack --disable-linux-user"
+
+
     # Test out-of-tree builds
     - env: CONFIG="--enable-debug --enable-debug-tcg"
            BUILD_DIR="out-of-tree/build/dir" SRC_DIR="../../.."
Signature · 1 line
2.19.2
#7 lore raw

PATCH 7/13 travis: standardize the syntax used for env variables

In reply to Daniel P. Berrangé

Matrix entries are defining env variables using two different syntax styles:

- env: FOO=bar
WIZZ=bang

and

- env:
- FOO=bar
- WIZZ=bang

Switch everything to use the latter style as the more normal indentation approach.

---
 .travis.yml | 77 ++++++++++++++++++++++++++++++++++-------------------
 1 file changed, 49 insertions(+), 28 deletions(-)
.travis.yml +49 -28
index 96917df9c5..f539f8b556 100644
@@ -81,102 +81,123 @@ script:
 
 matrix:
   include:
-    - env: CONFIG="--disable-system"
+    - env:
+        - CONFIG="--disable-system"
 
 
-    - env: CONFIG="--disable-user"
+    - env:
+        - CONFIG="--disable-user"
 
 
-    - env: CONFIG="--enable-debug --enable-debug-tcg"
+    - env:
+        - CONFIG="--enable-debug --enable-debug-tcg"
 
 
-    - env: CONFIG="--disable-linux-aio --disable-cap-ng --disable-attr --disable-brlapi --disable-uuid --disable-libusb --disable-user"
+    - env:
+        - CONFIG="--disable-linux-aio --disable-cap-ng --disable-attr --disable-brlapi --disable-uuid --disable-libusb --disable-user"
 
 
-    - env: CONFIG="--enable-modules --disable-linux-user"
+    - env:
+        - CONFIG="--enable-modules --disable-linux-user"
 
 
-    - env: CONFIG="--with-coroutine=ucontext --disable-linux-user"
+    - env:
+        - CONFIG="--with-coroutine=ucontext --disable-linux-user"
 
 
-    - env: CONFIG="--with-coroutine=sigaltstack --disable-linux-user"
+    - env:
+        - CONFIG="--with-coroutine=sigaltstack --disable-linux-user"
 
 
     # Test out-of-tree builds
-    - env: CONFIG="--enable-debug --enable-debug-tcg"
-           BUILD_DIR="out-of-tree/build/dir" SRC_DIR="../../.."
+    - env:
+        - CONFIG="--enable-debug --enable-debug-tcg"
+        - BUILD_DIR="out-of-tree/build/dir" SRC_DIR="../../.."
 
 
     # Test with Clang for compile portability (Travis uses clang-5.0)
-    - env: CONFIG="--disable-system"
+    - env:
+        - CONFIG="--disable-system"
       compiler: clang
 
 
-    - env: CONFIG="--disable-user"
+    - env:
+        - CONFIG="--disable-user"
       compiler: clang
 
 
     # gprof/gcov are GCC features
-    - env: CONFIG="--enable-gprof --enable-gcov --disable-pie --target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
+    - env:
+        - CONFIG="--enable-gprof --enable-gcov --disable-pie --target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
       after_success:
         - ${SRC_DIR}/scripts/travis/coverage-summary.sh
       compiler: gcc
 
 
     # We manually include builds which we disable "make check" for
-    - env: CONFIG="--enable-debug --enable-tcg-interpreter"
-           TEST_CMD=""
+    - env:
+        - CONFIG="--enable-debug --enable-tcg-interpreter"
+        - TEST_CMD=""
       compiler: gcc
 
 
     # We don't need to exercise every backend with every front-end
-    - env: CONFIG="--enable-trace-backends=log,simple,syslog --disable-system"
-           TEST_CMD=""
+    - env:
+        - CONFIG="--enable-trace-backends=log,simple,syslog --disable-system"
+        - TEST_CMD=""
       compiler: gcc
 
 
-    - env: CONFIG="--enable-trace-backends=ftrace --target-list=x86_64-softmmu"
-           TEST_CMD=""
+    - env:
+        - CONFIG="--enable-trace-backends=ftrace --target-list=x86_64-softmmu"
+        - TEST_CMD=""
       compiler: gcc
 
 
-    - env: CONFIG="--enable-trace-backends=ust --target-list=x86_64-softmmu"
-           TEST_CMD=""
+    - env:
+        - CONFIG="--enable-trace-backends=ust --target-list=x86_64-softmmu"
+        - TEST_CMD=""
       compiler: gcc
 
 
-    - env: CONFIG="--disable-tcg"
-           TEST_CMD=""
+    - env:
+        - CONFIG="--disable-tcg"
+        - TEST_CMD=""
       compiler: gcc
 
 
     # MacOSX builds
-    - env: CONFIG="--target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
+    - env:
+        - CONFIG="--target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
       os: osx
       osx_image: xcode9.4
       compiler: clang
 
 
-    - env: CONFIG="--target-list=i386-softmmu,ppc-softmmu,ppc64-softmmu,m68k-softmmu,x86_64-softmmu"
+    - env:
+        - CONFIG="--target-list=i386-softmmu,ppc-softmmu,ppc64-softmmu,m68k-softmmu,x86_64-softmmu"
       os: osx
       osx_image: xcode10
       compiler: clang
 
 
     # Python builds
-    - env: CONFIG="--target-list=x86_64-softmmu"
+    - env:
+        - CONFIG="--target-list=x86_64-softmmu"
       python:
         - "3.0"
 
 
-    - env: CONFIG="--target-list=x86_64-softmmu"
+    - env:
+        - CONFIG="--target-list=x86_64-softmmu"
       python:
         - "3.6"
 
 
     # Acceptance (Functional) tests
-    - env: CONFIG="--python=/usr/bin/python3 --target-list=x86_64-softmmu"
-           TEST_CMD="make AVOCADO_SHOW=app check-acceptance"
+    - env:
+        - CONFIG="--python=/usr/bin/python3 --target-list=x86_64-softmmu"
+        - TEST_CMD="make AVOCADO_SHOW=app check-acceptance"
       addons:
         apt:
           packages:
Signature · 1 line
2.19.2
#8 lore raw

PATCH 8/13 travis: don't clone git submodules upfront

In reply to Daniel P. Berrangé

The configure script & Makefile are already capable of figuring out which git submodules are required for a given build platform, and cloning them at the right time.

---
 .travis.yml | 1 -
 1 file changed, 1 deletion(-)
.travis.yml +0 -1
index f539f8b556..fa70429459 100644
@@ -71,7 +71,6 @@ git:
 before_install:
   - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew update ; fi
   - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew install libffi gettext glib pixman ; fi
-  - git submodule update --init --recursive capstone dtc ui/keycodemapdb
 before_script:
   - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
   - ${SRC_DIR}/configure ${CONFIG} || { cat config.log && exit 1; }
Signature · 1 line
2.19.2
#9 lore raw

PATCH 9/13 travis: move macOS brew setup into the macOS matrix entries

In reply to Daniel P. Berrangé

There is no need to use shell conditionals to run commands when they can simply be listed under the appropriate matrix entry.

---
 .travis.yml | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
.travis.yml +4 -3
index fa70429459..b5f520034f 100644
@@ -68,9 +68,6 @@ git:
   submodules: false
 
 
-before_install:
-  - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew update ; fi
-  - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew install libffi gettext glib pixman ; fi
 before_script:
   - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
   - ${SRC_DIR}/configure ${CONFIG} || { cat config.log && exit 1; }
@@ -171,6 +168,8 @@ matrix:
       os: osx
       osx_image: xcode9.4
       compiler: clang
+      before_install:
+        - brew update && brew install libffi gettext glib pixman
 
 
     - env:
@@ -178,6 +177,8 @@ matrix:
       os: osx
       osx_image: xcode10
       compiler: clang
+      before_install:
+        - brew update && brew install libffi gettext glib pixman
 
 
     # Python builds
Signature · 1 line
2.19.2
#10 lore raw

Re: [Qemu-devel] [PATCH 09/13] travis: move macOS brew setup into the macOS matrix entries

Quoted 32 lines · Daniel P. Berrangé

There is no need to use shell conditionals to run commands when they can simply be listed under the appropriate matrix entry.

---
 .travis.yml | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
.travis.yml +2 -3
index fa70429459..b5f520034f 100644
@@ -68,9 +68,6 @@ git:
   submodules: false
 
 
-before_install:
-  - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew update ; fi
-  - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew install libffi gettext glib pixman ; fi
 before_script:
   - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
   - ${SRC_DIR}/configure ${CONFIG} || { cat config.log && exit 1; }
@@ -171,6 +168,8 @@ matrix:
       os: osx
       osx_image: xcode9.4
       compiler: clang
+      before_install:
+        - brew update && brew install libffi gettext glib pixman
 
 
     - env:

.travis.yml matrix: · line 181

Quoted 5 lines
.travis.yml +2 -0
@@ -178,6 +177,8 @@ matrix:
       os: osx
       osx_image: xcode10
       compiler: clang
+      before_install:
+        - brew update && brew install libffi gettext glib pixman

Does this override the global before_install:? I appreciate we've just cleaned that up but if we add it again....

Regardless there is a homebrew add-ons now we can use.

.travis.yml matrix: · line 184

Quoted 3 lines
.travis.yml +0 -0
     # Python builds

--
Alex Bennée

#11 lore raw

Re: [Qemu-devel] [PATCH 09/13] travis: move macOS brew setup into the macOS matrix entries

Quoted 33 lines · Alex Bennée
Quoted 30 lines · Daniel P. Berrangé

There is no need to use shell conditionals to run commands when they can simply be listed under the appropriate matrix entry.

---
 .travis.yml | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
.travis.yml +2 -3
index fa70429459..b5f520034f 100644
@@ -68,9 +68,6 @@ git:
   submodules: false
 
 
-before_install:
-  - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew update ; fi
-  - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew install libffi gettext glib pixman ; fi
 before_script:
   - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
   - ${SRC_DIR}/configure ${CONFIG} || { cat config.log && exit 1; }
@@ -171,6 +168,8 @@ matrix:
       os: osx
       osx_image: xcode9.4
       compiler: clang
+      before_install:
+        - brew update && brew install libffi gettext glib pixman
 
 
Quoted 10 lines

.travis.yml matrix: · line 181

Quoted 7 lines
.travis.yml +2 -0
     - env:
@@ -178,6 +177,8 @@ matrix:
       os: osx
       osx_image: xcode10
       compiler: clang
+      before_install:
+        - brew update && brew install libffi gettext glib pixman

Does this override the global before_install:? I appreciate we've just cleaned that up but if we add it again....

Yes, anything defined under the matrix: generally overrides the same named setting at the top level. I think the env: is the only exception which instead augments top level settings.

Quoted 1 line

Regardless there is a homebrew add-ons now we can use.

Oh that's even better if it works for us.

Regards,
Daniel

Signature · 3 lines
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|
#12 lore raw

PATCH 10/13 travis: stop redefining the script commands

In reply to Daniel P. Berrangé

One of the matrix entries redefines the script command in order to add the ${MAKEFLAGS} variable. Ideally ${MAKEFLAGS} would be referenced by the definition of the ${TEST_CMD} env variable, but this isn't possible in travis. ${MAKEFLAGS} exists to eliminate duplication of flags in every "make" command, but this cure causes a worse problem, namely the reduplication of the "script" command. It is simpler to just insert "-j3" directly into any "make" command.

---
 .travis.yml | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)
.travis.yml +3 -6
index b5f520034f..ddfef6d738 100644
@@ -59,8 +59,7 @@ env:
   global:
     - SRC_DIR="."
     - BUILD_DIR="."
-    - TEST_CMD="make check"
-    - MAKEFLAGS="-j3"
+    - TEST_CMD="make check -j3"
 
 
 git:
@@ -72,7 +71,7 @@ before_script:
   - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
   - ${SRC_DIR}/configure ${CONFIG} || { cat config.log && exit 1; }
 script:
-  - make ${MAKEFLAGS} && ${TEST_CMD}
+  - make -j3 && ${TEST_CMD}
 
 
 matrix:
@@ -253,9 +252,7 @@ matrix:
 
     - env:
         - CONFIG="--disable-system --disable-docs"
-        - TEST_CMD="make check-tcg"
-      script:
-        - make ${MAKEFLAGS} && ${TEST_CMD} ${MAKEFLAGS}
+        - TEST_CMD="make -j3 check-tcg"
       sudo: required
       dist: trusty
       compiler: gcc
Signature · 1 line
2.19.2
#13 lore raw

PATCH 11/13 travis: stop using container based envs

In reply to Daniel P. Berrangé

The Travis container based envs are deprecated:

https://docs.travis-ci.com/user/reference/trusty/

"Container-based infrastructure is currently being deprecated.
Please remove any sudo: false keys in your .travis.yml file to use the default fully-virtualized Linux infrastructure instead."

---
 .travis.yml | 5 -----
 1 file changed, 5 deletions(-)
.travis.yml +0 -5
index ddfef6d738..dc8b37db80 100644
@@ -1,8 +1,4 @@
-# The current Travis default is a container based 14.04 Trust on EC2
-# Additional builds with specific requirements for a full VM need to
-# be added as additional matrix: entries later on
 
-sudo: false
 dist: trusty
 language: c
 python:
@@ -253,6 +249,5 @@ matrix:
     - env:
         - CONFIG="--disable-system --disable-docs"
         - TEST_CMD="make -j3 check-tcg"
-      sudo: required
       dist: trusty
       compiler: gcc
Signature · 1 line
2.19.2
#14 lore raw

PATCH 12/13 travis: run tests in verbose mode

In reply to Daniel P. Berrangé

Travis sometimes fails a build because it produces no console output for over 10 minutes. If this is due to a genuine hang, it would be useful to have used verbose test output to see where it failed. If this is just due to tests being very slow, having verbose output might allow the build to succeed.

---
 .travis.yml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
.travis.yml +2 -2
index dc8b37db80..a632fc0b3a 100644
@@ -55,7 +55,7 @@ env:
   global:
     - SRC_DIR="."
     - BUILD_DIR="."
-    - TEST_CMD="make check -j3"
+    - TEST_CMD="make check -j3 V=1"
 
 
 git:
@@ -248,6 +248,6 @@ matrix:
 
     - env:
         - CONFIG="--disable-system --disable-docs"
-        - TEST_CMD="make -j3 check-tcg"
+        - TEST_CMD="make -j3 check-tcg V=1"
       dist: trusty
       compiler: gcc
Signature · 1 line
2.19.2
#15 lore raw

PATCH 13/13 travis: remove matrix settings that duplicate global settings

In reply to Daniel P. Berrangé

The global defaults request "trusty" and "gcc", so matrix entries do not need to repeat this.

---
 .travis.yml | 8 --------
 1 file changed, 8 deletions(-)
.travis.yml +0 -8
index a632fc0b3a..9859f6e60b 100644
@@ -122,39 +122,33 @@ matrix:
         - CONFIG="--enable-gprof --enable-gcov --disable-pie --target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
       after_success:
         - ${SRC_DIR}/scripts/travis/coverage-summary.sh
-      compiler: gcc
 
 
     # We manually include builds which we disable "make check" for
     - env:
         - CONFIG="--enable-debug --enable-tcg-interpreter"
         - TEST_CMD=""
-      compiler: gcc
 
 
     # We don't need to exercise every backend with every front-end
     - env:
         - CONFIG="--enable-trace-backends=log,simple,syslog --disable-system"
         - TEST_CMD=""
-      compiler: gcc
 
 
     - env:
         - CONFIG="--enable-trace-backends=ftrace --target-list=x86_64-softmmu"
         - TEST_CMD=""
-      compiler: gcc
 
 
     - env:
         - CONFIG="--enable-trace-backends=ust --target-list=x86_64-softmmu"
         - TEST_CMD=""
-      compiler: gcc
 
 
     - env:
         - CONFIG="--disable-tcg"
         - TEST_CMD=""
-      compiler: gcc
 
 
     # MacOSX builds
@@ -249,5 +243,3 @@ matrix:
     - env:
         - CONFIG="--disable-system --disable-docs"
         - TEST_CMD="make -j3 check-tcg V=1"
-      dist: trusty
-      compiler: gcc
Signature · 1 line
2.19.2
#16 lore raw
In reply to Daniel P. Berrangé
Patchew URL: https://patchew.org/QEMU/[email protected]/

Patchew URL: https://patchew.org/QEMU/[email protected]/

Hi,

This series failed the docker-mingw@fedora build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally.

=== TEST SCRIPT BEGIN ===
#!/bin/bash
time make docker-test-mingw@fedora SHOW_ENV=1 J=14 === TEST SCRIPT END ===

The full log is available at
http://patchew.org/logs/[email protected]/testing.docker-mingw@fedora/?type=message.
---
Email generated automatically by Patchew [http://patchew.org/].
Please send your feedback to [email protected]