xref: /qemu/.gitlab-ci.yml (revision 9f3a24cf)
1# Currently we have two build stages after our containers are built:
2#  - build (for traditional build and test or first stage build)
3#  - test (for test stages, using build artefacts from a build stage)
4stages:
5  - containers
6  - containers-layer2
7  - build
8  - test
9
10include:
11  - local: '/.gitlab-ci.d/edk2.yml'
12  - local: '/.gitlab-ci.d/opensbi.yml'
13  - local: '/.gitlab-ci.d/containers.yml'
14  - local: '/.gitlab-ci.d/crossbuilds.yml'
15
16.native_build_job_template: &native_build_job_definition
17  stage: build
18  image: $CI_REGISTRY_IMAGE/qemu/$IMAGE:latest
19  before_script:
20    - JOBS=$(expr $(nproc) + 1)
21  script:
22    - mkdir build
23    - cd build
24    - if test -n "$TARGETS";
25      then
26        ../configure --enable-werror $CONFIGURE_ARGS --target-list="$TARGETS" ;
27      else
28        ../configure --enable-werror $CONFIGURE_ARGS ;
29      fi || { cat config.log meson-logs/meson-log.txt && exit 1; }
30    - make -j"$JOBS"
31    - if test -n "$MAKE_CHECK_ARGS";
32      then
33        make -j"$JOBS" $MAKE_CHECK_ARGS ;
34      fi
35
36.native_test_job_template: &native_test_job_definition
37  stage: test
38  image: $CI_REGISTRY_IMAGE/qemu/$IMAGE:latest
39  script:
40    - scripts/git-submodule.sh update
41        $(grep GIT_SUBMODULES build/config-host.mak | sed 's/GIT_SUBMODULES=//')
42    - cd build
43    - find . -type f -exec touch {} +
44    # Avoid recompiling by hiding ninja with NINJA=":"
45    - make NINJA=":" $MAKE_CHECK_ARGS
46
47.acceptance_template: &acceptance_definition
48  cache:
49    key: "${CI_JOB_NAME}-cache"
50    paths:
51      - ${CI_PROJECT_DIR}/avocado-cache
52    policy: pull-push
53  artifacts:
54    name: "$CI_JOB_NAME-$CI_COMMIT_REF_SLUG"
55    when: always
56    expire_in: 2 days
57    paths:
58      - build/tests/results/latest/results.xml
59      - build/tests/results/latest/test-results
60    reports:
61      junit: build/tests/results/latest/results.xml
62  before_script:
63    - mkdir -p ~/.config/avocado
64    - echo "[datadir.paths]" > ~/.config/avocado/avocado.conf
65    - echo "cache_dirs = ['${CI_PROJECT_DIR}/avocado-cache']"
66           >> ~/.config/avocado/avocado.conf
67    - echo -e '[job.output.testlogs]\nstatuses = ["FAIL", "INTERRUPT"]'
68           >> ~/.config/avocado/avocado.conf
69    - if [ -d ${CI_PROJECT_DIR}/avocado-cache ]; then
70        du -chs ${CI_PROJECT_DIR}/avocado-cache ;
71      fi
72    - export AVOCADO_ALLOW_UNTRUSTED_CODE=1
73  after_script:
74    - cd build
75    - du -chs ${CI_PROJECT_DIR}/avocado-cache
76
77build-system-alpine:
78  <<: *native_build_job_definition
79  needs:
80    - job: amd64-alpine-container
81  variables:
82    IMAGE: alpine
83    TARGETS: aarch64-softmmu alpha-softmmu cris-softmmu hppa-softmmu
84      moxie-softmmu microblazeel-softmmu mips64el-softmmu
85    MAKE_CHECK_ARGS: check-build
86    CONFIGURE_ARGS: --enable-docs
87  artifacts:
88    expire_in: 2 days
89    paths:
90      - .git-submodule-status
91      - build
92
93check-system-alpine:
94  <<: *native_test_job_definition
95  needs:
96    - job: build-system-alpine
97      artifacts: true
98  variables:
99    IMAGE: alpine
100    MAKE_CHECK_ARGS: check
101
102acceptance-system-alpine:
103  <<: *native_test_job_definition
104  needs:
105    - job: build-system-alpine
106      artifacts: true
107  variables:
108    IMAGE: alpine
109    MAKE_CHECK_ARGS: check-acceptance
110  <<: *acceptance_definition
111
112build-system-ubuntu:
113  <<: *native_build_job_definition
114  needs:
115    job: amd64-ubuntu2004-container
116  variables:
117    IMAGE: ubuntu2004
118    CONFIGURE_ARGS: --enable-fdt=system --enable-slirp=system
119    TARGETS: aarch64-softmmu alpha-softmmu cris-softmmu hppa-softmmu
120      moxie-softmmu microblazeel-softmmu mips64el-softmmu
121    MAKE_CHECK_ARGS: check-build
122  artifacts:
123    expire_in: 2 days
124    paths:
125      - build
126
127check-system-ubuntu:
128  <<: *native_test_job_definition
129  needs:
130    - job: build-system-ubuntu
131      artifacts: true
132  variables:
133    IMAGE: ubuntu2004
134    MAKE_CHECK_ARGS: check
135
136acceptance-system-ubuntu:
137  <<: *native_test_job_definition
138  needs:
139    - job: build-system-ubuntu
140      artifacts: true
141  variables:
142    IMAGE: ubuntu2004
143    MAKE_CHECK_ARGS: check-acceptance
144  <<: *acceptance_definition
145
146build-system-debian:
147  <<: *native_build_job_definition
148  needs:
149    job: amd64-debian-container
150  variables:
151    IMAGE: debian-amd64
152    CONFIGURE_ARGS: --enable-fdt=system
153    TARGETS: arm-softmmu avr-softmmu i386-softmmu mipsel-softmmu
154      riscv64-softmmu sh4eb-softmmu sparc-softmmu xtensaeb-softmmu
155    MAKE_CHECK_ARGS: check-build
156  artifacts:
157    expire_in: 2 days
158    paths:
159      - build
160
161check-system-debian:
162  <<: *native_test_job_definition
163  needs:
164    - job: build-system-debian
165      artifacts: true
166  variables:
167    IMAGE: debian-amd64
168    MAKE_CHECK_ARGS: check
169
170# No targets are built here, just tools, docs, and unit tests. This
171# also feeds into the eventual documentation deployment steps later
172build-tools-and-docs-debian:
173  <<: *native_build_job_definition
174  variables:
175    IMAGE: debian-amd64
176    MAKE_CHECK_ARGS: check-unit check-softfloat ctags TAGS cscope
177    CONFIGURE_ARGS: --disable-system --disable-user --enable-docs --enable-tools
178  artifacts:
179    expire_in: 2 days
180    paths:
181      - build
182
183acceptance-system-debian:
184  <<: *native_test_job_definition
185  needs:
186    - job: build-system-debian
187      artifacts: true
188  variables:
189    IMAGE: debian-amd64
190    MAKE_CHECK_ARGS: check-acceptance
191  <<: *acceptance_definition
192
193build-system-fedora:
194  <<: *native_build_job_definition
195  needs:
196    job: amd64-fedora-container
197  variables:
198    IMAGE: fedora
199    CONFIGURE_ARGS: --disable-gcrypt --enable-nettle --enable-docs
200             --enable-fdt=system --enable-slirp=system --enable-capstone=system
201    TARGETS: tricore-softmmu microblaze-softmmu mips-softmmu
202      xtensa-softmmu m68k-softmmu riscv32-softmmu ppc-softmmu sparc64-softmmu
203    MAKE_CHECK_ARGS: check-build
204  artifacts:
205    expire_in: 2 days
206    paths:
207      - build
208
209check-system-fedora:
210  <<: *native_test_job_definition
211  needs:
212    - job: build-system-fedora
213      artifacts: true
214  variables:
215    IMAGE: fedora
216    MAKE_CHECK_ARGS: check
217
218acceptance-system-fedora:
219  <<: *native_test_job_definition
220  needs:
221    - job: build-system-fedora
222      artifacts: true
223  variables:
224    IMAGE: fedora
225    MAKE_CHECK_ARGS: check-acceptance
226  <<: *acceptance_definition
227
228build-system-centos:
229  <<: *native_build_job_definition
230  needs:
231    job: amd64-centos8-container
232  variables:
233    IMAGE: centos8
234    CONFIGURE_ARGS: --disable-nettle --enable-gcrypt --enable-fdt=system
235                    --enable-modules
236    TARGETS: ppc64-softmmu or1k-softmmu s390x-softmmu
237      x86_64-softmmu rx-softmmu sh4-softmmu nios2-softmmu
238    MAKE_CHECK_ARGS: check-build
239  artifacts:
240    expire_in: 2 days
241    paths:
242      - build
243
244check-system-centos:
245  <<: *native_test_job_definition
246  needs:
247    - job: build-system-centos
248      artifacts: true
249  variables:
250    IMAGE: centos8
251    MAKE_CHECK_ARGS: check
252
253acceptance-system-centos:
254  <<: *native_test_job_definition
255  needs:
256    - job: build-system-centos
257      artifacts: true
258  variables:
259    IMAGE: centos8
260    MAKE_CHECK_ARGS: check-acceptance
261  <<: *acceptance_definition
262
263build-system-opensuse:
264  <<: *native_build_job_definition
265  needs:
266    job: amd64-opensuse-leap-container
267  variables:
268    IMAGE: opensuse-leap
269    CONFIGURE_ARGS: --enable-fdt=system
270    TARGETS: s390x-softmmu x86_64-softmmu aarch64-softmmu
271    MAKE_CHECK_ARGS: check-build
272  artifacts:
273    expire_in: 2 days
274    paths:
275      - build
276
277check-system-opensuse:
278  <<: *native_test_job_definition
279  needs:
280    - job: build-system-opensuse
281      artifacts: true
282  variables:
283    IMAGE: opensuse-leap
284    MAKE_CHECK_ARGS: check
285
286acceptance-system-opensuse:
287  <<: *native_test_job_definition
288  needs:
289    - job: build-system-opensuse
290      artifacts: true
291  variables:
292    IMAGE: opensuse-leap
293    MAKE_CHECK_ARGS: check-acceptance
294  <<: *acceptance_definition
295
296
297build-disabled:
298  <<: *native_build_job_definition
299  needs:
300    job: amd64-fedora-container
301  variables:
302    IMAGE: fedora
303    CONFIGURE_ARGS:
304      --disable-attr
305      --disable-auth-pam
306      --disable-avx2
307      --disable-bochs
308      --disable-brlapi
309      --disable-bzip2
310      --disable-cap-ng
311      --disable-capstone
312      --disable-cloop
313      --disable-coroutine-pool
314      --disable-curl
315      --disable-curses
316      --disable-dmg
317      --disable-docs
318      --disable-gcrypt
319      --disable-glusterfs
320      --disable-gnutls
321      --disable-gtk
322      --disable-guest-agent
323      --disable-iconv
324      --disable-keyring
325      --disable-kvm
326      --disable-libiscsi
327      --disable-libpmem
328      --disable-libssh
329      --disable-libudev
330      --disable-libusb
331      --disable-libxml2
332      --disable-linux-aio
333      --disable-live-block-migration
334      --disable-lzo
335      --disable-malloc-trim
336      --disable-mpath
337      --disable-nettle
338      --disable-numa
339      --disable-opengl
340      --disable-parallels
341      --disable-pie
342      --disable-qcow1
343      --disable-qed
344      --disable-qom-cast-debug
345      --disable-rbd
346      --disable-rdma
347      --disable-replication
348      --disable-sdl
349      --disable-seccomp
350      --disable-sheepdog
351      --disable-slirp
352      --disable-smartcard
353      --disable-snappy
354      --disable-sparse
355      --disable-spice
356      --disable-strip
357      --disable-tpm
358      --disable-usb-redir
359      --disable-vdi
360      --disable-vhost-crypto
361      --disable-vhost-net
362      --disable-vhost-scsi
363      --disable-vhost-kernel
364      --disable-vhost-user
365      --disable-vhost-vdpa
366      --disable-vhost-vsock
367      --disable-virglrenderer
368      --disable-vnc
369      --disable-vte
370      --disable-vvfat
371      --disable-xen
372      --disable-zstd
373    TARGETS: arm-softmmu i386-softmmu ppc64-softmmu mips64-softmmu
374      s390x-softmmu i386-linux-user
375    MAKE_CHECK_ARGS: check-qtest SPEED=slow
376
377# This jobs explicitly disable TCG (--disable-tcg), KVM is detected by
378# the configure script. The container doesn't contain Xen headers so
379# Xen accelerator is not detected / selected. As result it build the
380# i386-softmmu and x86_64-softmmu with KVM being the single accelerator
381# available.
382build-tcg-disabled:
383  <<: *native_build_job_definition
384  needs:
385    job: amd64-centos8-container
386  variables:
387    IMAGE: centos8
388  script:
389    - mkdir build
390    - cd build
391    - ../configure --disable-tcg --audio-drv-list="" || { cat config.log meson-logs/meson-log.txt && exit 1; }
392    - make -j"$JOBS"
393    - make check-unit
394    - make check-qapi-schema
395    - cd tests/qemu-iotests/
396    - ./check -raw 001 002 003 004 005 008 009 010 011 012 021 025 032 033 048
397            052 063 077 086 101 104 106 113 148 150 151 152 157 159 160 163
398            170 171 183 184 192 194 197 208 215 221 222 226 227 236 253 277
399    - ./check -qcow2 028 051 056 057 058 065 068 082 085 091 095 096 102 122
400            124 132 139 142 144 145 151 152 155 157 165 194 196 197 200 202
401            208 209 215 216 218 222 227 234 246 247 248 250 254 255 257 258
402            260 261 262 263 264 270 272 273 277 279
403
404build-user:
405  <<: *native_build_job_definition
406  needs:
407    job: amd64-debian-user-cross-container
408  variables:
409    IMAGE: debian-all-test-cross
410    CONFIGURE_ARGS: --disable-tools --disable-system
411    MAKE_CHECK_ARGS: check-tcg
412
413build-user-static:
414  <<: *native_build_job_definition
415  needs:
416    job: amd64-debian-user-cross-container
417  variables:
418    IMAGE: debian-all-test-cross
419    CONFIGURE_ARGS: --disable-tools --disable-system --static
420    MAKE_CHECK_ARGS: check-tcg
421
422# Only build the softmmu targets we have check-tcg tests for
423build-some-softmmu:
424  <<: *native_build_job_definition
425  needs:
426    job: amd64-debian-user-cross-container
427  variables:
428    IMAGE: debian-all-test-cross
429    CONFIGURE_ARGS: --disable-tools --enable-debug
430    TARGETS: xtensa-softmmu arm-softmmu aarch64-softmmu alpha-softmmu
431    MAKE_CHECK_ARGS: check-tcg
432
433# Run check-tcg against linux-user (with plugins)
434# we skip sparc64-linux-user until it has been fixed somewhat
435# we skip cris-linux-user as it doesn't use the common run loop
436build-user-plugins:
437  <<: *native_build_job_definition
438  needs:
439    job: amd64-debian-user-cross-container
440  variables:
441    IMAGE: debian-all-test-cross
442    CONFIGURE_ARGS: --disable-tools --disable-system --enable-plugins --enable-debug-tcg --target-list-exclude=sparc64-linux-user,cris-linux-user
443    MAKE_CHECK_ARGS: check-tcg
444  timeout: 1h 30m
445
446build-user-centos7:
447  <<: *native_build_job_definition
448  variables:
449    IMAGE: centos7
450    CONFIGURE_ARGS: --disable-system --disable-tools --disable-docs
451    MAKE_CHECK_ARGS: check-tcg
452
453build-some-softmmu-plugins:
454  <<: *native_build_job_definition
455  needs:
456    job: amd64-debian-user-cross-container
457  variables:
458    IMAGE: debian-all-test-cross
459    CONFIGURE_ARGS: --disable-tools --disable-user --enable-plugins --enable-debug-tcg
460    TARGETS: xtensa-softmmu arm-softmmu aarch64-softmmu alpha-softmmu
461    MAKE_CHECK_ARGS: check-tcg
462
463clang-system:
464  <<: *native_build_job_definition
465  needs:
466    job: amd64-fedora-container
467  variables:
468    IMAGE: fedora
469    CONFIGURE_ARGS: --cc=clang --cxx=clang++
470      --extra-cflags=-fsanitize=undefined --extra-cflags=-fno-sanitize-recover=undefined
471    TARGETS: alpha-softmmu arm-softmmu m68k-softmmu mips64-softmmu
472      ppc-softmmu s390x-softmmu
473    MAKE_CHECK_ARGS: check-qtest check-tcg
474
475clang-user:
476  <<: *native_build_job_definition
477  variables:
478    IMAGE: debian-all-test-cross
479    CONFIGURE_ARGS: --cc=clang --cxx=clang++ --disable-system
480      --target-list-exclude=microblazeel-linux-user,aarch64_be-linux-user,i386-linux-user,m68k-linux-user,mipsn32el-linux-user,xtensaeb-linux-user
481      --extra-cflags=-fsanitize=undefined --extra-cflags=-fno-sanitize-recover=undefined
482    MAKE_CHECK_ARGS: check-unit check-tcg
483
484tsan-build:
485  <<: *native_build_job_definition
486  variables:
487    IMAGE: ubuntu2004
488    CONFIGURE_ARGS: --enable-tsan --cc=clang-10 --cxx=clang++-10 --disable-docs
489                    --enable-fdt=system --enable-slirp=system
490    TARGETS: x86_64-softmmu ppc64-softmmu riscv64-softmmu x86_64-linux-user
491    MAKE_CHECK_ARGS: bench V=1
492
493# These targets are on the way out
494build-deprecated:
495  <<: *native_build_job_definition
496  needs:
497    job: amd64-debian-user-cross-container
498  variables:
499    IMAGE: debian-all-test-cross
500    CONFIGURE_ARGS: --disable-docs --disable-tools
501    MAKE_CHECK_ARGS: build-tcg
502    TARGETS: ppc64abi32-linux-user tilegx-linux-user lm32-softmmu
503      unicore32-softmmu
504  artifacts:
505    expire_in: 2 days
506    paths:
507      - build
508
509# We split the check-tcg step as test failures are expected but we still
510# want to catch the build breaking.
511check-deprecated:
512  <<: *native_test_job_definition
513  needs:
514    - job: build-deprecated
515      artifacts: true
516  variables:
517    IMAGE: debian-all-test-cross
518    MAKE_CHECK_ARGS: check-tcg
519  allow_failure: true
520
521# gprof/gcov are GCC features
522gprof-gcov:
523  <<: *native_build_job_definition
524  variables:
525    IMAGE: ubuntu2004
526    CONFIGURE_ARGS: --enable-gprof --enable-gcov
527    MAKE_CHECK_ARGS: check
528    TARGETS: aarch64-softmmu ppc64-softmmu s390x-softmmu x86_64-softmmu
529  timeout: 70m
530  after_script:
531    - ${CI_PROJECT_DIR}/scripts/ci/coverage-summary.sh
532
533build-oss-fuzz:
534  <<: *native_build_job_definition
535  needs:
536    job: amd64-fedora-container
537  variables:
538    IMAGE: fedora
539  script:
540    - mkdir build-oss-fuzz
541    - CC="clang" CXX="clang++" CFLAGS="-fsanitize=address"
542      ./scripts/oss-fuzz/build.sh
543    - export ASAN_OPTIONS="fast_unwind_on_malloc=0"
544    - for fuzzer in $(find ./build-oss-fuzz/DEST_DIR/ -executable -type f
545                      | grep -v slirp); do
546        grep "LLVMFuzzerTestOneInput" ${fuzzer} > /dev/null 2>&1 || continue ;
547        echo Testing ${fuzzer} ... ;
548        "${fuzzer}" -runs=1 -seed=1 || exit 1 ;
549      done
550    # Unrelated to fuzzer: run some tests with -fsanitize=address
551    - cd build-oss-fuzz && make check-qtest-i386 check-unit
552
553build-tci:
554  <<: *native_build_job_definition
555  needs:
556    job: amd64-debian-user-cross-container
557  variables:
558    IMAGE: debian-all-test-cross
559  script:
560    - TARGETS="aarch64 alpha arm hppa m68k microblaze moxie ppc64 s390x x86_64"
561    - mkdir build
562    - cd build
563    - ../configure --enable-tcg-interpreter
564        --target-list="$(for tg in $TARGETS; do echo -n ${tg}'-softmmu '; done)" || { cat config.log meson-logs/meson-log.txt && exit 1; }
565    - make -j"$JOBS"
566    - make tests/qtest/boot-serial-test tests/qtest/cdrom-test tests/qtest/pxe-test
567    - for tg in $TARGETS ; do
568        export QTEST_QEMU_BINARY="./qemu-system-${tg}" ;
569        ./tests/qtest/boot-serial-test || exit 1 ;
570        ./tests/qtest/cdrom-test || exit 1 ;
571      done
572    - QTEST_QEMU_BINARY="./qemu-system-x86_64" ./tests/qtest/pxe-test
573    - QTEST_QEMU_BINARY="./qemu-system-s390x" ./tests/qtest/pxe-test -m slow
574    - make check-tcg
575
576# Alternate coroutines implementations are only really of interest to KVM users
577# However we can't test against KVM on Gitlab-CI so we can only run unit tests
578build-coroutine-ucontext:
579  <<: *native_build_job_definition
580  needs:
581    job: amd64-ubuntu2004-container
582  variables:
583    IMAGE: ubuntu2004
584    CONFIGURE_ARGS: --with-coroutine=ucontext --disable-tcg
585    MAKE_CHECK_ARGS: check-unit
586
587build-coroutine-sigaltstack:
588  <<: *native_build_job_definition
589  needs:
590    job: amd64-ubuntu2004-container
591  variables:
592    IMAGE: ubuntu2004
593    CONFIGURE_ARGS: --with-coroutine=sigaltstack --disable-tcg
594    MAKE_CHECK_ARGS: check-unit
595
596# Most jobs test latest gcrypt or nettle builds
597#
598# These jobs test old gcrypt and nettle from RHEL7
599# which had some API differences.
600build-crypto-old-nettle:
601  <<: *native_build_job_definition
602  needs:
603    job: amd64-centos7-container
604  variables:
605    IMAGE: centos7
606    TARGETS: x86_64-softmmu x86_64-linux-user
607    CONFIGURE_ARGS: --disable-gcrypt --enable-nettle
608    MAKE_CHECK_ARGS: check-build
609  artifacts:
610    paths:
611      - build
612
613check-crypto-old-nettle:
614  <<: *native_test_job_definition
615  needs:
616    - job: build-crypto-old-nettle
617      artifacts: true
618  variables:
619    IMAGE: centos7
620    MAKE_CHECK_ARGS: check
621
622
623build-crypto-old-gcrypt:
624  <<: *native_build_job_definition
625  needs:
626    job: amd64-centos7-container
627  variables:
628    IMAGE: centos7
629    TARGETS: x86_64-softmmu x86_64-linux-user
630    CONFIGURE_ARGS: --disable-nettle --enable-gcrypt
631    MAKE_CHECK_ARGS: check-build
632  artifacts:
633    paths:
634      - build
635
636check-crypto-old-gcrypt:
637  <<: *native_test_job_definition
638  needs:
639    - job: build-crypto-old-gcrypt
640      artifacts: true
641  variables:
642    IMAGE: centos7
643    MAKE_CHECK_ARGS: check
644
645
646build-crypto-only-gnutls:
647  <<: *native_build_job_definition
648  needs:
649    job: amd64-centos7-container
650  variables:
651    IMAGE: centos7
652    TARGETS: x86_64-softmmu x86_64-linux-user
653    CONFIGURE_ARGS: --disable-nettle --disable-gcrypt --enable-gnutls
654    MAKE_CHECK_ARGS: check-build
655  artifacts:
656    paths:
657      - build
658
659check-crypto-only-gnutls:
660  <<: *native_test_job_definition
661  needs:
662    - job: build-crypto-only-gnutls
663      artifacts: true
664  variables:
665    IMAGE: centos7
666    MAKE_CHECK_ARGS: check
667
668# We don't need to exercise every backend with every front-end
669build-trace-multi-user:
670  <<: *native_build_job_definition
671  needs:
672    job: amd64-ubuntu2004-container
673  variables:
674    IMAGE: ubuntu2004
675    CONFIGURE_ARGS: --enable-trace-backends=log,simple,syslog --disable-system
676
677build-trace-ftrace-system:
678  <<: *native_build_job_definition
679  needs:
680    job: amd64-ubuntu2004-container
681  variables:
682    IMAGE: ubuntu2004
683    CONFIGURE_ARGS: --enable-trace-backends=ftrace --target-list=x86_64-softmmu
684
685build-trace-ust-system:
686  <<: *native_build_job_definition
687  needs:
688    job: amd64-ubuntu2004-container
689  variables:
690    IMAGE: ubuntu2004
691    CONFIGURE_ARGS: --enable-trace-backends=ust --target-list=x86_64-softmmu
692
693# Check our reduced build configurations
694build-without-default-devices:
695  <<: *native_build_job_definition
696  needs:
697    job: amd64-centos8-container
698  variables:
699    IMAGE: centos8
700    CONFIGURE_ARGS: --without-default-devices --disable-user
701
702build-without-default-features:
703  <<: *native_build_job_definition
704  needs:
705    job: amd64-debian-container
706  variables:
707    IMAGE: debian-amd64
708    CONFIGURE_ARGS: --without-default-features --disable-user
709        --target-list-exclude=arm-softmmu,i386-softmmu,mipsel-softmmu,mips64-softmmu,ppc-softmmu
710    MAKE_CHECK_ARGS: check-unit
711
712check-patch:
713  stage: build
714  image: $CI_REGISTRY_IMAGE/qemu/centos8:latest
715  needs:
716    job: amd64-centos8-container
717  script: .gitlab-ci.d/check-patch.py
718  except:
719    variables:
720      - $CI_PROJECT_NAMESPACE == 'qemu-project' && $CI_COMMIT_BRANCH == 'master'
721  variables:
722    GIT_DEPTH: 1000
723  allow_failure: true
724
725check-dco:
726  stage: build
727  image: $CI_REGISTRY_IMAGE/qemu/centos8:latest
728  needs:
729    job: amd64-centos8-container
730  script: .gitlab-ci.d/check-dco.py
731  except:
732    variables:
733      - $CI_PROJECT_NAMESPACE == 'qemu-project' && $CI_COMMIT_BRANCH == 'master'
734  variables:
735    GIT_DEPTH: 1000
736
737build-libvhost-user:
738  stage: build
739  image: $CI_REGISTRY_IMAGE/qemu/fedora:latest
740  needs:
741    job: amd64-fedora-container
742  before_script:
743    - dnf install -y meson ninja-build
744  script:
745    - mkdir subprojects/libvhost-user/build
746    - cd subprojects/libvhost-user/build
747    - meson
748    - ninja
749
750# Prepare for GitLab pages deployment. Anything copied into the
751# "public" directory will be deployed to $USER.gitlab.io/$PROJECT
752pages:
753  image: $CI_REGISTRY_IMAGE/qemu/debian-amd64:latest
754  stage: test
755  needs:
756    - job: build-tools-and-docs-debian
757  script:
758    - mkdir -p public
759    # HTML-ised source tree
760    - make gtags
761    - htags -anT --tree-view=filetree -m qemu_init
762        -t "Welcome to the QEMU sourcecode"
763    - mv HTML public/src
764    # Project documentation
765    - make -C build install DESTDIR=$(pwd)/temp-install
766    - mv temp-install/usr/local/share/doc/qemu/* public/
767  artifacts:
768    paths:
769      - public
770