You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

.travis.yml 7.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297
  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: ccache
  9. addons:
  10. apt:
  11. packages:
  12. # Build dependencies
  13. - libaio-dev
  14. - libattr1-dev
  15. - libbrlapi-dev
  16. - libcap-ng-dev
  17. - libgcc-4.8-dev
  18. - libgnutls-dev
  19. - libgtk-3-dev
  20. - libiscsi-dev
  21. - liblttng-ust-dev
  22. - libncurses5-dev
  23. - libnfs-dev
  24. - libnss3-dev
  25. - libpixman-1-dev
  26. - libpng12-dev
  27. - librados-dev
  28. - libsdl1.2-dev
  29. - libseccomp-dev
  30. - libspice-protocol-dev
  31. - libspice-server-dev
  32. - libssh2-1-dev
  33. - liburcu-dev
  34. - libusb-1.0-0-dev
  35. - libvte-2.91-dev
  36. - sparse
  37. - uuid-dev
  38. - gcovr
  39. homebrew:
  40. packages:
  41. - glib
  42. - pixman
  43. - gnu-sed
  44. # The channel name "irc.oftc.net#qemu" is encrypted against qemu/qemu
  45. # to prevent IRC notifications from forks. This was created using:
  46. # $ travis encrypt -r "qemu/qemu" "irc.oftc.net#qemu"
  47. notifications:
  48. irc:
  49. channels:
  50. - secure: "F7GDRgjuOo5IUyRLqSkmDL7kvdU4UcH3Lm/W2db2JnDHTGCqgEdaYEYKciyCLZ57vOTsTsOgesN8iUT7hNHBd1KWKjZe9KDTZWppWRYVwAwQMzVeSOsbbU4tRoJ6Pp+3qhH1Z0eGYR9ZgKYAoTumDFgSAYRp4IscKS8jkoedOqM="
  51. on_success: change
  52. on_failure: always
  53. env:
  54. global:
  55. - SRC_DIR="."
  56. - BUILD_DIR="."
  57. - BASE_CONFIG="--disable-docs --disable-tools"
  58. - TEST_CMD="make check -j3 V=1"
  59. # This is broadly a list of "mainline" softmmu targets which have support across the major distros
  60. - MAIN_SOFTMMU_TARGETS="aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
  61. git:
  62. # we want to do this ourselves
  63. submodules: false
  64. before_script:
  65. - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
  66. - ${SRC_DIR}/configure ${BASE_CONFIG} ${CONFIG} || { cat config.log && exit 1; }
  67. script:
  68. - make -j3 && ${TEST_CMD}
  69. matrix:
  70. include:
  71. - env:
  72. - CONFIG="--disable-system"
  73. # we split the system builds as it takes a while to build them all
  74. - env:
  75. - CONFIG="--disable-user --target-list=${MAIN_SOFTMMU_TARGETS}"
  76. - env:
  77. - CONFIG="--disable-user --target-list-exclude=${MAIN_SOFTMMU_TARGETS}"
  78. # Just build tools and run minimal unit and softfloat checks
  79. - env:
  80. - BASE_CONFIG="--enable-tools"
  81. - CONFIG="--disable-user --disable-system"
  82. - TEST_CMD="make check-unit check-softfloat -j3"
  83. - env:
  84. - CONFIG="--enable-debug --enable-debug-tcg --disable-user"
  85. # TCG debug can be run just on it's own and is mostly agnostic to user/softmmu distinctions
  86. - env:
  87. - CONFIG="--enable-debug-tcg --disable-system"
  88. - env:
  89. - CONFIG="--disable-linux-aio --disable-cap-ng --disable-attr --disable-brlapi --disable-libusb --disable-replication --target-list=${MAIN_SOFTMMU_TARGETS}"
  90. # Module builds are mostly of interest to major distros
  91. - env:
  92. - CONFIG="--enable-modules --target-list=${MAIN_SOFTMMU_TARGETS}"
  93. # Alternate coroutines implementations are only really of interest to KVM users
  94. # However we can't test against KVM on Travis so we can only run unit tests
  95. - env:
  96. - CONFIG="--with-coroutine=ucontext --disable-tcg"
  97. - TEST_CMD="make check-unit -j3 V=1"
  98. - env:
  99. - CONFIG="--with-coroutine=sigaltstack --disable-tcg"
  100. - TEST_CMD="make check-unit -j3 V=1"
  101. # Check we can build docs and tools (out of tree)
  102. - env:
  103. - BUILD_DIR="out-of-tree/build/dir" SRC_DIR="../../.."
  104. - BASE_CONFIG="--enable-tools --enable-docs"
  105. - CONFIG="--target-list=x86_64-softmmu,aarch64-linux-user"
  106. addons:
  107. apt:
  108. packages:
  109. - python-sphinx
  110. - texinfo
  111. - perl
  112. # Test with Clang for compile portability (Travis uses clang-5.0)
  113. - env:
  114. - CONFIG="--disable-system"
  115. compiler: clang
  116. - env:
  117. - CONFIG="--disable-user --target-list=${MAIN_SOFTMMU_TARGETS}"
  118. compiler: clang
  119. - env:
  120. - CONFIG="--target-list=${MAIN_SOFTMMU_TARGETS} "
  121. compiler: clang
  122. before_script:
  123. - ./configure ${CONFIG} --extra-cflags="-fsanitize=undefined -Werror" || { cat config.log && exit 1; }
  124. - env:
  125. - CONFIG="--disable-user --target-list-exclude=${MAIN_SOFTMMU_TARGETS}"
  126. compiler: clang
  127. # gprof/gcov are GCC features
  128. - env:
  129. - CONFIG="--enable-gprof --enable-gcov --disable-pie --target-list=${MAIN_SOFTMMU_TARGETS}"
  130. after_success:
  131. - ${SRC_DIR}/scripts/travis/coverage-summary.sh
  132. # We manually include builds which we disable "make check" for
  133. - env:
  134. - CONFIG="--without-default-devices --disable-user"
  135. - TEST_CMD=""
  136. # We manually include builds which we disable "make check" for
  137. - env:
  138. - CONFIG="--enable-debug --enable-tcg-interpreter"
  139. - TEST_CMD=""
  140. # We don't need to exercise every backend with every front-end
  141. - env:
  142. - CONFIG="--enable-trace-backends=log,simple,syslog --disable-system"
  143. - TEST_CMD=""
  144. - env:
  145. - CONFIG="--enable-trace-backends=ftrace --target-list=x86_64-softmmu"
  146. - TEST_CMD=""
  147. - env:
  148. - CONFIG="--enable-trace-backends=ust --target-list=x86_64-softmmu"
  149. - TEST_CMD=""
  150. # MacOSX builds
  151. - env:
  152. - CONFIG="--target-list=${MAIN_SOFTMMU_TARGETS}"
  153. os: osx
  154. osx_image: xcode9.4
  155. compiler: clang
  156. - env:
  157. - CONFIG="--target-list=i386-softmmu,ppc-softmmu,ppc64-softmmu,m68k-softmmu,x86_64-softmmu"
  158. os: osx
  159. osx_image: xcode10.2
  160. compiler: clang
  161. # Python builds
  162. - env:
  163. - CONFIG="--target-list=x86_64-softmmu"
  164. language: python
  165. python:
  166. - "3.4"
  167. - env:
  168. - CONFIG="--target-list=x86_64-softmmu"
  169. language: python
  170. python:
  171. - "3.6"
  172. # Acceptance (Functional) tests
  173. - env:
  174. - CONFIG="--python=/usr/bin/python3 --target-list=x86_64-softmmu,mips-softmmu,mips64el-softmmu,aarch64-softmmu,arm-softmmu,s390x-softmmu,alpha-softmmu"
  175. - TEST_CMD="make check-acceptance"
  176. after_failure:
  177. - cat tests/results/latest/job.log
  178. addons:
  179. apt:
  180. packages:
  181. - python3-pip
  182. - python3.5-venv
  183. # Using newer GCC with sanitizers
  184. - addons:
  185. apt:
  186. update: true
  187. sources:
  188. # PPAs for newer toolchains
  189. - ubuntu-toolchain-r-test
  190. packages:
  191. # Extra toolchains
  192. - gcc-9
  193. - g++-9
  194. # Build dependencies
  195. - libaio-dev
  196. - libattr1-dev
  197. - libbrlapi-dev
  198. - libcap-ng-dev
  199. - libgnutls-dev
  200. - libgtk-3-dev
  201. - libiscsi-dev
  202. - liblttng-ust-dev
  203. - libnfs-dev
  204. - libncurses5-dev
  205. - libnss3-dev
  206. - libpixman-1-dev
  207. - libpng12-dev
  208. - librados-dev
  209. - libsdl1.2-dev
  210. - libseccomp-dev
  211. - libspice-protocol-dev
  212. - libspice-server-dev
  213. - libssh2-1-dev
  214. - liburcu-dev
  215. - libusb-1.0-0-dev
  216. - libvte-2.91-dev
  217. - sparse
  218. - uuid-dev
  219. language: generic
  220. compiler: none
  221. env:
  222. - COMPILER_NAME=gcc CXX=g++-9 CC=gcc-9
  223. - CONFIG="--cc=gcc-9 --cxx=g++-9 --disable-pie --disable-linux-user"
  224. - TEST_CMD=""
  225. before_script:
  226. - ./configure ${CONFIG} --extra-cflags="-g3 -O0 -Wno-error=stringop-truncation -fsanitize=thread -fuse-ld=gold" || { cat config.log && exit 1; }
  227. # Run check-tcg against linux-user
  228. - env:
  229. - CONFIG="--disable-system"
  230. - TEST_CMD="make -j3 check-tcg V=1"
  231. # Run check-tcg against softmmu targets
  232. - env:
  233. - CONFIG="--target-list=xtensa-softmmu,arm-softmmu,aarch64-softmmu,alpha-softmmu"
  234. - TEST_CMD="make -j3 check-tcg V=1"