docs: stop documenting the e1000 NIC model as the default
[qemu/ar7.git] / .travis.yml
blob6c0ec6cf69f09dff01cab0df6e8aa29cc368d28e
1 # The current Travis default is a VM based 16.04 Xenial on GCE
2 # Additional builds with specific requirements for a full VM need to
3 # be added as additional matrix: entries later on
4 dist: xenial
5 language: c
6 compiler:
7   - gcc
8 cache:
9   # There is one cache per branch and compiler version.
10   # characteristics of each job are used to identify the cache:
11   # - OS name (currently, linux, osx, or windows)
12   # - OS distribution (for Linux, xenial, trusty, or precise)
13   # - macOS image name (e.g., xcode7.2)
14   # - Names and values of visible environment variables set in .travis.yml or Settings panel
15   timeout: 1200
16   ccache: true
17   pip: true
18   directories:
19   - $HOME/avocado/data/cache
22 addons:
23   apt:
24     packages:
25       # Build dependencies
26       - libaio-dev
27       - libattr1-dev
28       - libbrlapi-dev
29       - libcap-ng-dev
30       - libgcc-4.8-dev
31       - libgnutls28-dev
32       - libgtk-3-dev
33       - libiscsi-dev
34       - liblttng-ust-dev
35       - libncurses5-dev
36       - libnfs-dev
37       - libnss3-dev
38       - libpixman-1-dev
39       - libpng-dev
40       - librados-dev
41       - libsdl2-dev
42       - libsdl2-image-dev
43       - libseccomp-dev
44       - libspice-protocol-dev
45       - libspice-server-dev
46       - libssh-dev
47       - liburcu-dev
48       - libusb-1.0-0-dev
49       - libvdeplug-dev
50       - libvte-2.91-dev
51       - sparse
52       - uuid-dev
53       - gcovr
54       # Tests dependencies
55       - genisoimage
58 # The channel name "irc.oftc.net#qemu" is encrypted against qemu/qemu
59 # to prevent IRC notifications from forks. This was created using:
60 # $ travis encrypt -r "qemu/qemu" "irc.oftc.net#qemu"
61 notifications:
62   irc:
63     channels:
64       - secure: "F7GDRgjuOo5IUyRLqSkmDL7kvdU4UcH3Lm/W2db2JnDHTGCqgEdaYEYKciyCLZ57vOTsTsOgesN8iUT7hNHBd1KWKjZe9KDTZWppWRYVwAwQMzVeSOsbbU4tRoJ6Pp+3qhH1Z0eGYR9ZgKYAoTumDFgSAYRp4IscKS8jkoedOqM="
65     on_success: change
66     on_failure: always
69 env:
70   global:
71     - SRC_DIR=".."
72     - BUILD_DIR="build"
73     - BASE_CONFIG="--disable-docs --disable-tools"
74     - TEST_BUILD_CMD=""
75     - TEST_CMD="make check V=1"
76     # This is broadly a list of "mainline" softmmu targets which have support across the major distros
77     - MAIN_SOFTMMU_TARGETS="aarch64-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
78     - CCACHE_SLOPPINESS="include_file_ctime,include_file_mtime"
79     - CCACHE_MAXSIZE=1G
82 git:
83   # we want to do this ourselves
84   submodules: false
86 # Common first phase for all steps
87 before_install:
88   - if command -v ccache ; then ccache --zero-stats ; fi
89   - export JOBS=$(($(getconf _NPROCESSORS_ONLN) + 1))
90   - echo "=== Using ${JOBS} simultaneous jobs ==="
92 # Configure step - may be overridden
93 before_script:
94   - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
95   - ${SRC_DIR}/configure ${BASE_CONFIG} ${CONFIG} || { cat config.log && exit 1; }
97 # Main build & test - rarely overridden - controlled by TEST_CMD
98 script:
99   - BUILD_RC=0 && make -j${JOBS} || BUILD_RC=$?
100   - |
101     if [ "$BUILD_RC" -eq 0 ] && [ -n "$TEST_BUILD_CMD" ]; then
102         ${TEST_BUILD_CMD} || BUILD_RC=$?
103     else
104         $(exit $BUILD_RC);
105     fi
106   - |
107     if [ "$BUILD_RC" -eq 0 ] ; then
108         ${TEST_CMD} ;
109     else
110         $(exit $BUILD_RC);
111     fi
112 after_script:
113   - if command -v ccache ; then ccache --show-stats ; fi
116 matrix:
117   include:
118     - name: "GCC static (user)"
119       env:
120         - CONFIG="--disable-system --static"
121         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
124     # we split the system builds as it takes a while to build them all
125     - name: "GCC (main-softmmu)"
126       env:
127         - CONFIG="--disable-user --target-list=${MAIN_SOFTMMU_TARGETS}"
128         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
131     - name: "GCC (other-softmmu)"
132       env:
133        - CONFIG="--disable-user --target-list-exclude=${MAIN_SOFTMMU_TARGETS}"
134         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
137     # Just build tools and run minimal unit and softfloat checks
138     - name: "GCC check-softfloat (user)"
139       env:
140         - BASE_CONFIG="--enable-tools"
141         - CONFIG="--disable-user --disable-system"
142         - TEST_CMD="make check-unit check-softfloat -j${JOBS}"
143         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
146     # --enable-debug implies --enable-debug-tcg, also runs quite a bit slower
147     - name: "GCC debug (main-softmmu)"
148       env:
149         - CONFIG="--enable-debug --target-list=${MAIN_SOFTMMU_TARGETS}"
150         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-debug"
153     # TCG debug can be run just on its own and is mostly agnostic to user/softmmu distinctions
154     - name: "GCC debug (user)"
155       env:
156         - CONFIG="--enable-debug-tcg --disable-system"
157         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-debug-tcg"
160     - name: "GCC some libs disabled (main-softmmu)"
161       env:
162         - CONFIG="--disable-linux-aio --disable-cap-ng --disable-attr --disable-brlapi --disable-libusb --disable-replication --target-list=${MAIN_SOFTMMU_TARGETS}"
165     # Module builds are mostly of interest to major distros
166     - name: "GCC modules (main-softmmu)"
167       env:
168         - CONFIG="--enable-modules --target-list=${MAIN_SOFTMMU_TARGETS}"
169         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
172     # Alternate coroutines implementations are only really of interest to KVM users
173     # However we can't test against KVM on Travis so we can only run unit tests
174     - name: "check-unit coroutine=ucontext"
175       env:
176         - CONFIG="--with-coroutine=ucontext --disable-tcg"
177         - TEST_CMD="make check-unit -j${JOBS} V=1"
180     - name: "check-unit coroutine=sigaltstack"
181       env:
182         - CONFIG="--with-coroutine=sigaltstack --disable-tcg"
183         - TEST_CMD="make check-unit -j${JOBS} V=1"
186     # Check we can build docs and tools (out of tree)
187     - name: "tools and docs (bionic)"
188       dist: bionic
189       env:
190         - BUILD_DIR="out-of-tree/build/dir" SRC_DIR="../../.."
191         - BASE_CONFIG="--enable-tools --enable-docs"
192         - CONFIG="--target-list=x86_64-softmmu,aarch64-linux-user"
193         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
194       addons:
195         apt:
196           packages:
197             - python3-sphinx
198             - texinfo
199             - perl
202     # Test with Clang for compile portability (Travis uses clang-5.0)
203     - name: "Clang (user)"
204       env:
205         - CONFIG="--disable-system"
206         - CACHE_NAME="${TRAVIS_BRANCH}-linux-clang-default"
207       compiler: clang
210     - name: "Clang (main-softmmu)"
211       env:
212         - CONFIG="--target-list=${MAIN_SOFTMMU_TARGETS} "
213         - CACHE_NAME="${TRAVIS_BRANCH}-linux-clang-sanitize"
214       compiler: clang
215       before_script:
216         - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
217         - ${SRC_DIR}/configure ${CONFIG} --extra-cflags="-fsanitize=undefined -Werror" || { cat config.log && exit 1; }
220     - name: "Clang (other-softmmu)"
221       env:
222         - CONFIG="--disable-user --target-list-exclude=${MAIN_SOFTMMU_TARGETS}"
223         - CACHE_NAME="${TRAVIS_BRANCH}-linux-clang-default"
224       compiler: clang
227     # gprof/gcov are GCC features
228     - name: "GCC gprof/gcov"
229       env:
230         - CONFIG="--enable-gprof --enable-gcov --disable-pie --target-list=${MAIN_SOFTMMU_TARGETS}"
231       after_success:
232         - ${SRC_DIR}/scripts/travis/coverage-summary.sh
235     # We manually include builds which we disable "make check" for
236     - name: "GCC without-default-devices (softmmu)"
237       env:
238         - CONFIG="--without-default-devices --disable-user"
239         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
240         - TEST_CMD=""
243     # Check the TCG interpreter (TCI)
244     - name: "GCC TCI"
245       env:
246         - CONFIG="--enable-debug-tcg --enable-tcg-interpreter --disable-kvm --disable-containers
247             --target-list=alpha-softmmu,arm-softmmu,hppa-softmmu,m68k-softmmu,microblaze-softmmu,moxie-softmmu,ppc-softmmu,s390x-softmmu,x86_64-softmmu"
248         - TEST_CMD="make check-qtest check-tcg V=1"
251     # We don't need to exercise every backend with every front-end
252     - name: "GCC trace log,simple,syslog (user)"
253       env:
254         - CONFIG="--enable-trace-backends=log,simple,syslog --disable-system"
255         - TEST_CMD=""
258     - name: "GCC trace ftrace (x86_64-softmmu)"
259       env:
260         - CONFIG="--enable-trace-backends=ftrace --target-list=x86_64-softmmu"
261         - TEST_CMD=""
264     - name: "GCC trace ust (x86_64-softmmu)"
265       env:
266         - CONFIG="--enable-trace-backends=ust --target-list=x86_64-softmmu"
267         - TEST_CMD=""
270     # MacOSX builds - cirrus.yml also tests some MacOS builds including latest Xcode
272     - name: "OSX Xcode 10.3"
273       env:
274         - CONFIG="--target-list=i386-softmmu,ppc-softmmu,ppc64-softmmu,m68k-softmmu,x86_64-softmmu"
275       os: osx
276       osx_image: xcode10.3
277       compiler: clang
278       addons:
279         homebrew:
280           packages:
281             - ccache
282             - glib
283             - pixman
284             - gnu-sed
285             - python
286           update: true
287       before_script:
288         - brew link --overwrite python
289         - export PATH="/usr/local/opt/ccache/libexec:$PATH"
290         - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
291         - ${SRC_DIR}/configure ${BASE_CONFIG} ${CONFIG} || { cat config.log && exit 1; }
294     # Python builds
295     - name: "GCC Python 3.5 (x86_64-softmmu)"
296       env:
297         - CONFIG="--target-list=x86_64-softmmu"
298         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
299       language: python
300       python:
301         - "3.5"
304     - name: "GCC Python 3.6 (x86_64-softmmu)"
305       env:
306         - CONFIG="--target-list=x86_64-softmmu"
307         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
308       language: python
309       python:
310         - "3.6"
313     # Acceptance (Functional) tests
314     - name: "GCC check-acceptance"
315       env:
316         - CONFIG="--target-list=x86_64-softmmu,mips-softmmu,mips64el-softmmu,aarch64-softmmu,arm-softmmu,s390x-softmmu,alpha-softmmu,ppc-softmmu,ppc64-softmmu,m68k-softmmu,sparc-softmmu"
317         - TEST_CMD="make check-acceptance"
318       after_script:
319         - python3 -c 'import json; r = json.load(open("tests/results/latest/results.json")); [print(t["logfile"]) for t in r["tests"] if t["status"] not in ("PASS", "SKIP")]' | xargs cat
320       addons:
321         apt:
322           packages:
323             - python3-pil
324             - python3-pip
325             - python3.5-venv
326             - tesseract-ocr
327             - tesseract-ocr-eng
330     # Using newer GCC with sanitizers
331     - name: "GCC9 with sanitizers (softmmu)"
332       addons:
333         apt:
334           update: true
335           sources:
336             # PPAs for newer toolchains
337             - ubuntu-toolchain-r-test
338           packages:
339             # Extra toolchains
340             - gcc-9
341             - g++-9
342             # Build dependencies
343             - libaio-dev
344             - libattr1-dev
345             - libbrlapi-dev
346             - libcap-ng-dev
347             - libgnutls-dev
348             - libgtk-3-dev
349             - libiscsi-dev
350             - liblttng-ust-dev
351             - libnfs-dev
352             - libncurses5-dev
353             - libnss3-dev
354             - libpixman-1-dev
355             - libpng12-dev
356             - librados-dev
357             - libsdl2-dev
358             - libsdl2-image-dev
359             - libseccomp-dev
360             - libspice-protocol-dev
361             - libspice-server-dev
362             - libssh-dev
363             - liburcu-dev
364             - libusb-1.0-0-dev
365             - libvte-2.91-dev
366             - sparse
367             - uuid-dev
368       language: generic
369       compiler: none
370       env:
371         - COMPILER_NAME=gcc CXX=g++-9 CC=gcc-9
372         - CONFIG="--cc=gcc-9 --cxx=g++-9 --disable-pie --disable-linux-user"
373         - TEST_CMD=""
374       before_script:
375         - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
376         - ${SRC_DIR}/configure ${CONFIG} --extra-cflags="-g3 -O0 -Wno-error=stringop-truncation -fsanitize=thread" --extra-ldflags="-fuse-ld=gold" || { cat config.log && exit 1; }
379     # Run check-tcg against linux-user
380     - name: "GCC check-tcg (user)"
381       env:
382         - CONFIG="--disable-system --enable-debug-tcg"
383         - TEST_BUILD_CMD="make build-tcg"
384         - TEST_CMD="make check-tcg"
385         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-debug-tcg"
388     # Run check-tcg against linux-user (with plugins)
389     # we skip sparc64-linux-user until it has been fixed somewhat
390     # we skip cris-linux-user as it doesn't use the common run loop
391     - name: "GCC plugins check-tcg (user)"
392       env:
393         - CONFIG="--disable-system --enable-plugins --enable-debug-tcg --target-list-exclude=sparc64-linux-user,cris-linux-user"
394         - TEST_BUILD_CMD="make build-tcg"
395         - TEST_CMD="make check-tcg"
396         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-debug-tcg"
399     # Run check-tcg against softmmu targets
400     - name: "GCC check-tcg (some-softmmu)"
401       env:
402         - CONFIG="--enable-debug-tcg --target-list=xtensa-softmmu,arm-softmmu,aarch64-softmmu,alpha-softmmu"
403         - TEST_BUILD_CMD="make -j${JOBS} build-tcg"
404         - TEST_CMD="make check-tcg"
405         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-debug-tcg"
408     # Run check-tcg against softmmu targets (with plugins)
409     - name: "GCC plugins check-tcg (some-softmmu)"
410       env:
411         - CONFIG="--enable-plugins --enable-debug-tcg --target-list=xtensa-softmmu,arm-softmmu,aarch64-softmmu,alpha-softmmu"
412         - TEST_BUILD_CMD="make -j${JOBS} build-tcg"
413         - TEST_CMD="make check-tcg"
414         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-debug-tcg"
416     - name: "[aarch64] GCC check-tcg"
417       arch: arm64
418       dist: xenial
419       addons:
420         apt_packages:
421           - libaio-dev
422           - libattr1-dev
423           - libbrlapi-dev
424           - libcap-ng-dev
425           - libgcrypt20-dev
426           - libgnutls28-dev
427           - libgtk-3-dev
428           - libiscsi-dev
429           - liblttng-ust-dev
430           - libncurses5-dev
431           - libnfs-dev
432           - libnss3-dev
433           - libpixman-1-dev
434           - libpng-dev
435           - librados-dev
436           - libsdl2-dev
437           - libseccomp-dev
438           - liburcu-dev
439           - libusb-1.0-0-dev
440           - libvdeplug-dev
441           - libvte-2.91-dev
442           # Tests dependencies
443           - genisoimage
444       env:
445         - TEST_CMD="make check check-tcg V=1"
446         - CONFIG="--disable-containers --target-list=${MAIN_SOFTMMU_TARGETS}"
448     - name: "[ppc64] GCC check-tcg"
449       arch: ppc64le
450       dist: xenial
451       addons:
452         apt_packages:
453           - libaio-dev
454           - libattr1-dev
455           - libbrlapi-dev
456           - libcap-ng-dev
457           - libgcrypt20-dev
458           - libgnutls28-dev
459           - libgtk-3-dev
460           - libiscsi-dev
461           - liblttng-ust-dev
462           - libncurses5-dev
463           - libnfs-dev
464           - libnss3-dev
465           - libpixman-1-dev
466           - libpng-dev
467           - librados-dev
468           - libsdl2-dev
469           - libseccomp-dev
470           - liburcu-dev
471           - libusb-1.0-0-dev
472           - libvdeplug-dev
473           - libvte-2.91-dev
474           # Tests dependencies
475           - genisoimage
476       env:
477         - TEST_CMD="make check check-tcg V=1"
478         - CONFIG="--disable-containers --target-list=${MAIN_SOFTMMU_TARGETS},ppc64le-linux-user"
480     - name: "[s390x] GCC check-tcg"
481       arch: s390x
482       dist: bionic
483       addons:
484         apt_packages:
485           - libaio-dev
486           - libattr1-dev
487           - libbrlapi-dev
488           - libcap-ng-dev
489           - libgcrypt20-dev
490           - libgnutls28-dev
491           - libgtk-3-dev
492           - libiscsi-dev
493           - liblttng-ust-dev
494           - libncurses5-dev
495           - libnfs-dev
496           - libnss3-dev
497           - libpixman-1-dev
498           - libpng-dev
499           - librados-dev
500           - libsdl2-dev
501           - libseccomp-dev
502           - liburcu-dev
503           - libusb-1.0-0-dev
504           - libvdeplug-dev
505           - libvte-2.91-dev
506           # Tests dependencies
507           - genisoimage
508       env:
509         - TEST_CMD="make check check-tcg V=1"
510         - CONFIG="--disable-containers --target-list=${MAIN_SOFTMMU_TARGETS},s390x-linux-user"
512     # Release builds
513     # The make-release script expect a QEMU version, so our tag must start with a 'v'.
514     # This is the case when release candidate tags are created.
515     - name: "Release tarball"
516       if: tag IS present AND tag =~ /^v\d+\.\d+(\.\d+)?(-\S*)?$/
517       env:
518         # We want to build from the release tarball
519         - BUILD_DIR="release/build/dir" SRC_DIR="../../.."
520         - BASE_CONFIG="--prefix=$PWD/dist"
521         - CONFIG="--target-list=x86_64-softmmu,aarch64-softmmu,armeb-linux-user,ppc-linux-user"
522         - TEST_CMD="make install -j${JOBS}"
523         - QEMU_VERSION="${TRAVIS_TAG:1}"
524         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
525       script:
526         - make -C ${SRC_DIR} qemu-${QEMU_VERSION}.tar.bz2
527         - ls -l ${SRC_DIR}/qemu-${QEMU_VERSION}.tar.bz2
528         - tar -xf ${SRC_DIR}/qemu-${QEMU_VERSION}.tar.bz2 && cd qemu-${QEMU_VERSION}
529         - mkdir -p release-build && cd release-build
530         - ../configure ${BASE_CONFIG} ${CONFIG} || { cat config.log && exit 1; }
531         - make install