xref: /openbmc/qemu/.travis.yml (revision 29b22c79)
1sudo: false
2language: c
3python:
4  - "2.4"
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-6-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"
56    - CONFIG="--with-coroutine=ucontext"
57    - CONFIG="--with-coroutine=sigaltstack"
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
120    - sudo: required
121      addons:
122      dist: trusty
123      language: generic
124      compiler: none
125      env:
126        - COMPILER_NAME=clang CXX=clang++-3.9 CC=clang-3.9
127        - CONFIG="--disable-linux-user --cc=clang-3.9 --cxx=clang++-3.9"
128      before_install:
129        - wget -nv -O - http://llvm.org/apt/llvm-snapshot.gpg.key | sudo apt-key add -
130        - sudo apt-add-repository -y 'deb http://llvm.org/apt/trusty llvm-toolchain-trusty-3.9 main'
131        - sudo apt-get update -qq
132        - sudo apt-get install -qq -y clang-3.9
133        - sudo apt-get build-dep -qq qemu
134        - wget -O - http://people.linaro.org/~alex.bennee/qemu-submodule-git-seed.tar.xz | tar -xvJ
135        - git submodule update --init --recursive
136      before_script:
137        - ./configure ${CONFIG} || cat config.log
138    # Trusty Linux User build with latest stable clang
139    - sudo: required
140      addons:
141      dist: trusty
142      language: generic
143      compiler: none
144      env:
145        - COMPILER_NAME=clang CXX=clang++-3.9 CC=clang-3.9
146        - CONFIG="--disable-system --cc=clang-3.9 --cxx=clang++-3.9"
147      before_install:
148        - wget -nv -O - http://llvm.org/apt/llvm-snapshot.gpg.key | sudo apt-key add -
149        - sudo apt-add-repository -y 'deb http://llvm.org/apt/trusty llvm-toolchain-trusty-3.9 main'
150        - sudo apt-get update -qq
151        - sudo apt-get install -qq -y clang-3.9
152        - sudo apt-get build-dep -qq qemu
153        - wget -O - http://people.linaro.org/~alex.bennee/qemu-submodule-git-seed.tar.xz | tar -xvJ
154        - git submodule update --init --recursive
155      before_script:
156        - ./configure ${CONFIG} || cat config.log
157    # Using newer GCC with sanitizers
158    - addons:
159        apt:
160          sources:
161            # PPAs for newer toolchains
162            - ubuntu-toolchain-r-test
163          packages:
164            # Extra toolchains
165            - gcc-5
166            - g++-5
167            # Build dependencies
168            - libaio-dev
169            - libattr1-dev
170            - libbrlapi-dev
171            - libcap-ng-dev
172            - libgnutls-dev
173            - libgtk-3-dev
174            - libiscsi-dev
175            - liblttng-ust-dev
176            - libnfs-dev
177            - libncurses5-dev
178            - libnss3-dev
179            - libpixman-1-dev
180            - libpng12-dev
181            - librados-dev
182            - libsdl1.2-dev
183            - libseccomp-dev
184            - libspice-protocol-dev
185            - libspice-server-dev
186            - libssh2-1-dev
187            - liburcu-dev
188            - libusb-1.0-0-dev
189            - libvte-2.90-dev
190            - sparse
191            - uuid-dev
192      language: generic
193      compiler: none
194      env:
195        - COMPILER_NAME=gcc CXX=g++-5 CC=gcc-5
196        - CONFIG="--cc=gcc-5 --cxx=g++-5 --disable-pie --disable-linux-user"
197        - TEST_CMD=""
198      before_script:
199        - ./configure ${CONFIG} --extra-cflags="-g3 -O0 -fsanitize=thread -fuse-ld=gold" || cat config.log
200