xref: /openbmc/qemu/.travis.yml (revision 06329cce)
1sudo: false
2language: c
3python:
4  - "2.6"
5compiler:
6  - gcc
7cache: ccache
8addons:
9  apt:
10    packages:
11      # Build dependencies
12      - libaio-dev
13      - libattr1-dev
14      - libbrlapi-dev
15      - libcap-ng-dev
16      - libgcc-4.8-dev
17      - libgnutls-dev
18      - libgtk-3-dev
19      - libiscsi-dev
20      - liblttng-ust-dev
21      - libncurses5-dev
22      - libnfs-dev
23      - libnss3-dev
24      - libpixman-1-dev
25      - libpng12-dev
26      - librados-dev
27      - libsdl1.2-dev
28      - libseccomp-dev
29      - libspice-protocol-dev
30      - libspice-server-dev
31      - libssh2-1-dev
32      - liburcu-dev
33      - libusb-1.0-0-dev
34      - libvte-2.90-dev
35      - sparse
36      - uuid-dev
37
38# The channel name "irc.oftc.net#qemu" is encrypted against qemu/qemu
39# to prevent IRC notifications from forks. This was created using:
40# $ travis encrypt -r "qemu/qemu" "irc.oftc.net#qemu"
41notifications:
42  irc:
43    channels:
44      - secure: "F7GDRgjuOo5IUyRLqSkmDL7kvdU4UcH3Lm/W2db2JnDHTGCqgEdaYEYKciyCLZ57vOTsTsOgesN8iUT7hNHBd1KWKjZe9KDTZWppWRYVwAwQMzVeSOsbbU4tRoJ6Pp+3qhH1Z0eGYR9ZgKYAoTumDFgSAYRp4IscKS8jkoedOqM="
45    on_success: change
46    on_failure: always
47env:
48  global:
49    - TEST_CMD="make check"
50    - MAKEFLAGS="-j3"
51  matrix:
52    - CONFIG=""
53    - CONFIG="--enable-debug --enable-debug-tcg --enable-trace-backends=log"
54    - CONFIG="--disable-linux-aio --disable-cap-ng --disable-attr --disable-brlapi --disable-uuid --disable-libusb"
55    - CONFIG="--enable-modules --disable-linux-user"
56    - CONFIG="--with-coroutine=ucontext --disable-linux-user"
57    - CONFIG="--with-coroutine=sigaltstack --disable-linux-user"
58git:
59  # we want to do this ourselves
60  submodules: false
61before_install:
62  - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew update ; fi
63  - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew install libffi gettext glib pixman ; fi
64  - wget -O - http://people.linaro.org/~alex.bennee/qemu-submodule-git-seed.tar.xz | tar -xvJ
65  - git submodule update --init --recursive
66before_script:
67  - ./configure ${CONFIG}
68script:
69  - make ${MAKEFLAGS} && ${TEST_CMD}
70matrix:
71  include:
72    # Test with CLang for compile portability
73    - env: CONFIG=""
74      compiler: clang
75    # gprof/gcov are GCC features
76    - env: CONFIG="--enable-gprof --enable-gcov --disable-pie"
77      compiler: gcc
78    # We manually include builds which we disable "make check" for
79    - env: CONFIG="--enable-debug --enable-tcg-interpreter"
80           TEST_CMD=""
81      compiler: gcc
82    - env: CONFIG="--enable-trace-backends=simple"
83           TEST_CMD=""
84      compiler: gcc
85    - env: CONFIG="--enable-trace-backends=ftrace"
86           TEST_CMD=""
87      compiler: gcc
88    - env: CONFIG="--enable-trace-backends=ust"
89           TEST_CMD=""
90      compiler: gcc
91    - env: CONFIG="--disable-tcg"
92           TEST_CMD=""
93      compiler: gcc
94    - env: CONFIG=""
95      os: osx
96      compiler: clang
97    # Plain Trusty System Build
98    - env: CONFIG="--disable-linux-user"
99      sudo: required
100      addons:
101      dist: trusty
102      compiler: gcc
103      before_install:
104        - sudo apt-get update -qq
105        - sudo apt-get build-dep -qq qemu
106        - wget -O - http://people.linaro.org/~alex.bennee/qemu-submodule-git-seed.tar.xz | tar -xvJ
107        - git submodule update --init --recursive
108    # Plain Trusty Linux User Build
109    - env: CONFIG="--disable-system"
110      sudo: required
111      addons:
112      dist: trusty
113      compiler: gcc
114      before_install:
115        - sudo apt-get update -qq
116        - sudo apt-get build-dep -qq qemu
117        - wget -O - http://people.linaro.org/~alex.bennee/qemu-submodule-git-seed.tar.xz | tar -xvJ
118        - git submodule update --init --recursive
119    # Trusty System build with latest stable clang & python 3.0
120    - sudo: required
121      addons:
122      dist: trusty
123      language: generic
124      compiler: none
125      python:
126        - "3.0"
127      env:
128        - COMPILER_NAME=clang CXX=clang++-3.9 CC=clang-3.9
129        - CONFIG="--disable-linux-user --cc=clang-3.9 --cxx=clang++-3.9 --python=/usr/bin/python3"
130      before_install:
131        - wget -nv -O - http://llvm.org/apt/llvm-snapshot.gpg.key | sudo apt-key add -
132        - sudo apt-add-repository -y 'deb http://llvm.org/apt/trusty llvm-toolchain-trusty-3.9 main'
133        - sudo apt-get update -qq
134        - sudo apt-get install -qq -y clang-3.9
135        - sudo apt-get build-dep -qq qemu
136        - wget -O - http://people.linaro.org/~alex.bennee/qemu-submodule-git-seed.tar.xz | tar -xvJ
137        - git submodule update --init --recursive
138      before_script:
139        - ./configure ${CONFIG} || cat config.log
140    # Trusty Linux User build with latest stable clang & python 3.6
141    - sudo: required
142      addons:
143      dist: trusty
144      language: generic
145      compiler: none
146      python:
147        - "3.6"
148      env:
149        - COMPILER_NAME=clang CXX=clang++-3.9 CC=clang-3.9
150        - CONFIG="--disable-system --cc=clang-3.9 --cxx=clang++-3.9 --python=/usr/bin/python3"
151      before_install:
152        - wget -nv -O - http://llvm.org/apt/llvm-snapshot.gpg.key | sudo apt-key add -
153        - sudo apt-add-repository -y 'deb http://llvm.org/apt/trusty llvm-toolchain-trusty-3.9 main'
154        - sudo apt-get update -qq
155        - sudo apt-get install -qq -y clang-3.9
156        - sudo apt-get build-dep -qq qemu
157        - wget -O - http://people.linaro.org/~alex.bennee/qemu-submodule-git-seed.tar.xz | tar -xvJ
158        - git submodule update --init --recursive
159      before_script:
160        - ./configure ${CONFIG} || cat config.log
161    # Using newer GCC with sanitizers
162    - addons:
163        apt:
164          sources:
165            # PPAs for newer toolchains
166            - ubuntu-toolchain-r-test
167          packages:
168            # Extra toolchains
169            - gcc-5
170            - g++-5
171            # Build dependencies
172            - libaio-dev
173            - libattr1-dev
174            - libbrlapi-dev
175            - libcap-ng-dev
176            - libgnutls-dev
177            - libgtk-3-dev
178            - libiscsi-dev
179            - liblttng-ust-dev
180            - libnfs-dev
181            - libncurses5-dev
182            - libnss3-dev
183            - libpixman-1-dev
184            - libpng12-dev
185            - librados-dev
186            - libsdl1.2-dev
187            - libseccomp-dev
188            - libspice-protocol-dev
189            - libspice-server-dev
190            - libssh2-1-dev
191            - liburcu-dev
192            - libusb-1.0-0-dev
193            - libvte-2.90-dev
194            - sparse
195            - uuid-dev
196      language: generic
197      compiler: none
198      env:
199        - COMPILER_NAME=gcc CXX=g++-5 CC=gcc-5
200        - CONFIG="--cc=gcc-5 --cxx=g++-5 --disable-pie --disable-linux-user"
201        - TEST_CMD=""
202      before_script:
203        - ./configure ${CONFIG} --extra-cflags="-g3 -O0 -fsanitize=thread -fuse-ld=gold" || cat config.log
204