ci: update rules that pointed to gst-ci subproject
[platform/upstream/gstreamer.git] / .gitlab-ci.yml
1 include:
2   - remote: "https://gitlab.freedesktop.org/freedesktop/ci-templates/-/raw/14731f78c23c7b523a85a26a068ade9ac1ecd2f3/templates/fedora.yml"
3   - remote: "https://gitlab.freedesktop.org/freedesktop/ci-templates/-/raw/14731f78c23c7b523a85a26a068ade9ac1ecd2f3/templates/debian.yml"
4
5 stages:
6   - 'trigger'
7   - 'build docker'
8   - 'preparation'
9   - 'pre-build'
10   - 'build'
11   - 'test'
12   # Use the resulting binaries
13   - 'integrate'
14
15 variables:
16   # Branch to track for modules that have no ref specified in the manifest
17   GST_UPSTREAM_BRANCH: 'main'
18   ORC_UPSTREAM_BRANCH: 'master'
19
20   ###
21   # IMPORTANT
22   # These are the version tags for the docker images the CI runs against.
23   # If you are hacking on them or need a them to rebuild, its enough
24   # to change any part of the string of the image you want.
25   ###
26   FEDORA_TAG:  '2021-10-05.0'
27   INDENT_TAG: '2021-10-04.0'
28   WINDOWS_TAG: "2021-10-04.1"
29
30   GST_UPSTREAM_REPO: 'gstreamer/gstreamer'
31   FDO_UPSTREAM_REPO: 'gstreamer/gstreamer'
32
33   FEDORA_AMD64_SUFFIX:  'amd64/fedora'
34   INDENT_AMD64_SUFFIX: 'amd64/gst-indent'
35   WINDOWS_AMD64_SUFFIX: 'amd64/windows'
36   WINDOWS_RUST_AMD64_SUFFIX: 'amd64/windows-rust'
37
38   FEDORA_DOCS_IMAGE: "registry.freedesktop.org/gstreamer/gst-ci/amd64/fedora:2020-07-03.0-master"
39   WINDOWS_IMAGE: "$CI_REGISTRY_IMAGE/$WINDOWS_AMD64_SUFFIX:$WINDOWS_TAG-$GST_UPSTREAM_BRANCH"
40   WINDOWS_UPSTREAM_IMAGE: "$CI_REGISTRY/$GST_UPSTREAM_REPO/$WINDOWS_AMD64_SUFFIX:$WINDOWS_TAG-$GST_UPSTREAM_BRANCH"
41
42   RUST_MINIMUM_VERSION: '1.54.0'
43   RUST_LATEST_VERSION: '1.55.0'
44
45   WINDOWS_RUST_MINIMUM_IMAGE: "$CI_REGISTRY_IMAGE/$WINDOWS_RUST_AMD64_SUFFIX:$WINDOWS_TAG-$GST_UPSTREAM_BRANCH-rust-$RUST_MINIMUM_VERSION"
46   WINDOWS_RUST_MINIMUM_UPSTREAM_IMAGE: "$CI_REGISTRY/$GST_UPSTREAM_REPO/$WINDOWS_RUST_AMD64_SUFFIX:$WINDOWS_TAG-$GST_UPSTREAM_BRANCH-rust-$RUST_MINIMUM_VERSION"
47
48   WINDOWS_RUST_LATEST_IMAGE: "$CI_REGISTRY_IMAGE/$WINDOWS_RUST_AMD64_SUFFIX:$WINDOWS_TAG-$GST_UPSTREAM_BRANCH-rust-$RUST_LATEST_VERSION"
49   WINDOWS_RUST_LATEST_UPSTREAM_IMAGE: "$CI_REGISTRY/$GST_UPSTREAM_REPO/$WINDOWS_RUST_AMD64_SUFFIX:$WINDOWS_TAG-$GST_UPSTREAM_BRANCH-rust-$RUST_LATEST_VERSION"
50
51   MESON_BUILDTYPE_ARGS: --default-library=both
52   DEFAULT_MESON_ARGS: >
53     -Dlibnice:tests=disabled
54     -Dlibnice:examples=disabled
55     -Dopenh264:tests=disabled
56     -Dpygobject:tests=false
57     -Dpython=enabled
58     -Dlibav=enabled
59     -Dugly=enabled
60     -Dbad=enabled
61     -Ddevtools=enabled
62     -Dges=enabled
63     -Drtsp_server=enabled
64     -Dvaapi=enabled
65     -Dsharp=disabled
66
67   MESON_GST_WERROR: >
68     -Dgstreamer:werror=true
69     -Dgst-plugins-base:werror=true
70     -Dgst-plugins-good:werror=true
71     -Dgst-plugins-ugly:werror=true
72     -Dgst-plugins-bad:werror=true
73     -Dgst-rtsp-server:werror=true
74     -Dgst-libav:werror=true
75     -Dgst-examples:werror=true
76     -Dgst-editing-services:werror=true
77     -Dgst-docs:werror=true
78     -Dgst-omx:werror=true
79     -Dgst-devtools:werror=true
80     -Dgst-python:werror=true
81     -Dgstreamer-vaapi:werror=true
82     -Dgstreamer-sharp:werror=true
83
84 workflow:
85   # https://docs.gitlab.com/ee/ci/yaml/index.html#switch-between-branch-pipelines-and-merge-request-pipelines
86   rules:
87     - if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
88     - if: $CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS && $CI_PIPELINE_SOURCE == "push"
89       when: never
90     - if: '$CI_COMMIT_BRANCH'
91
92 #
93 # Global CI policy
94 #
95 # This can be used to configure global behaviour our our jobs.
96 #
97 default:
98   retry:
99     max: 2
100     when:
101       - 'runner_system_failure'
102       - 'stuck_or_timeout_failure'
103       - 'scheduler_failure'
104       - 'api_failure'
105   interruptible: true
106
107 # This is an empty job that is used to trigger the pipeline.
108 trigger:
109   image: alpine:latest
110   stage: 'trigger'
111   script:
112     - echo "Trigger job done, now running the pipeline."
113   rules:
114     # If the MR is assigned to the Merge bot, trigger the pipeline automatically
115     - if: '$CI_MERGE_REQUEST_ASSIGNEES == "gstreamer-merge-bot"'
116     # When the assignee isn't the merge bot, require an explicit action to trigger the pipeline
117     # to avoid wasting CI resources
118     - if: '$CI_MERGE_REQUEST_ASSIGNEES != "gstreamer-merge-bot"'
119       when: 'manual'
120       allow_failure: false
121     # If this matches, it means the pipeline is running against either the main
122     # or a stable branch, so make it manual
123     - if: '$CI_COMMIT_BRANCH == $GST_UPSTREAM_BRANCH'
124       when: 'manual'
125
126 .fedora image:
127   variables:
128     FDO_DISTRIBUTION_VERSION: '31'
129     FDO_REPO_SUFFIX: "$FEDORA_AMD64_SUFFIX"
130     FDO_DISTRIBUTION_TAG: "$FEDORA_TAG-$GST_UPSTREAM_BRANCH"
131     FDO_DISTRIBUTION_EXEC: 'DEFAULT_BRANCH=$GST_UPSTREAM_BRANCH bash ci/docker/fedora/prepare.sh'
132
133 fedora amd64 docker:
134   extends:
135     - '.fedora image'
136     - '.fdo.container-build@fedora'
137   stage: 'build docker'
138
139 .gst-indent image:
140   variables:
141     FDO_DISTRIBUTION_VERSION: 'stretch'
142     FDO_REPO_SUFFIX: "$INDENT_AMD64_SUFFIX"
143     FDO_DISTRIBUTION_TAG: "$INDENT_TAG-$GST_UPSTREAM_BRANCH"
144     FDO_DISTRIBUTION_PACKAGES: 'curl indent git findutils'
145
146 gst-indent amd64 docker:
147   extends:
148     - '.gst-indent image'
149     - '.fdo.container-build@debian'
150   stage: 'build docker'
151   # Do not depend on the trigger, as we want to run indent always
152   needs: []
153
154 windows amd64 docker:
155   stage: "build docker"
156   needs:
157     - "trigger"
158   variables:
159     # Unlike the buildah/linux jobs, this file
160     # needs to be relative to docker/windows/ subdir
161     # as it makes life easier in the powershell script
162     #
163     # We also don't need a CONTEXT_DIR var as its also
164     # hardcoded to be docker/windows/
165     DOCKERFILE: "ci/docker/windows/Dockerfile"
166   tags:
167     - windows
168     - shell
169     - "1809"
170   script:
171     # We need to pass an array and to resolve the env vars, so we can't use a variable:
172     - $DOCKER_BUILD_ARGS = @("--build-arg", "DEFAULT_BRANCH=$GST_UPSTREAM_BRANCH")
173
174     - "& ci/docker/windows/container.ps1 $CI_REGISTRY $CI_REGISTRY_USER $CI_REGISTRY_PASSWORD $WINDOWS_IMAGE $WINDOWS_UPSTREAM_IMAGE $DOCKERFILE"
175     - |
176       if (!($?)) {
177         echo "Failed to build the image"
178         Exit 1
179       }
180
181 .windows rust docker build:
182   stage: 'build docker'
183   needs:
184     - job: 'windows amd64 docker'
185       artifacts: false
186   rules:
187     - if: '$CI_PROJECT_NAME == "gst-ci"'
188   variables:
189     # Unlike the buildah/linux jobs, this file
190     # needs to be relative to docker/windows/ subdir
191     # as it makes life easier in the powershell script
192     #
193     # We also don't need a CONTEXT_DIR var as its also
194     # hardcoded to be docker/windows/
195     DOCKERFILE: 'docker/windows/rust.Dockerfile'
196   tags:
197     - 'windows'
198     - 'shell'
199     - '1809'
200   script:
201     # We need to pass an array and to resolve the env vars, so we can't use a variable:
202     - $DOCKER_BUILD_ARGS = @("--build-arg", "DEFAULT_BRANCH=$GST_UPSTREAM_BRANCH", "--build-arg", "BASE_IMAGE=$WINDOWS_IMAGE", "--build-arg", "RUST_VERSION=$RUST_VERSION")
203
204     - $env:WINDOWS_CONTAINER_SCRIPT_PATH = "$env:CI_PROJECT_DIR\container.ps1"
205     - echo "Fetching $env:WINDOWS_CONTAINER_SCRIPT_URL"
206     - Invoke-WebRequest -Uri $env:WINDOWS_CONTAINER_SCRIPT_URL -OutFile $env:WINDOWS_CONTAINER_SCRIPT_PATH
207
208     - "& $env:WINDOWS_CONTAINER_SCRIPT_PATH $CI_REGISTRY $CI_REGISTRY_USER $CI_REGISTRY_PASSWORD $RUST_IMAGE $RUST_UPSTREAM_IMAGE $DOCKERFILE"
209     - |
210       if (!($?)) {
211         echo "Failed to build the image"
212         Exit 1
213       }
214
215 windows rust amd64 docker latest stable:
216   extends: '.windows rust docker build'
217   variables:
218     RUST_IMAGE: !reference [variables, "WINDOWS_RUST_LATEST_IMAGE"]
219     RUST_UPSTREAM_IMAGE: !reference [variables, "WINDOWS_RUST_LATEST_UPSTREAM_IMAGE"]
220     RUST_VERSION: !reference [variables, "RUST_LATEST_VERSION"]
221
222 windows rust amd64 docker minimum supported version:
223   extends: '.windows rust docker build'
224   variables:
225     RUST_IMAGE: !reference [variables, "WINDOWS_RUST_MINIMUM_IMAGE"]
226     RUST_UPSTREAM_IMAGE: !reference [variables, "WINDOWS_RUST_MINIMUM_UPSTREAM_IMAGE"]
227     RUST_VERSION: !reference [variables, "RUST_MINIMUM_VERSION"]
228
229
230
231 # ---- Preparation ----- #
232 #
233 # gst-indent!!
234 #
235 gst indent:
236   extends:
237     - '.gst-indent image'
238     - '.fdo.suffixed-image@debian'
239   stage: 'preparation'
240   needs:
241     - job: 'gst-indent amd64 docker'
242       artifacts: false
243   script:
244     # man indent. grep RETURN VALUE, grab a beer on my behalf...
245     - indent --version || true
246     - ./scripts/gst-indent-all
247     - |
248       if git diff --quiet -- ':!subprojects/gst-integration-testsuites/medias' .; then
249           echo "Code is properly formatted"
250       else
251           git diff --color=always -- ':!subprojects/gst-integration-testsuites/medias' .
252           echo 'style diverges, please run gst-indent first'
253           exit 1
254       fi
255
256 #
257 # build setup templates
258 #
259 .build_template: &build
260   - echo $MESON_ARGS
261
262   - meson build/ $MESON_ARGS
263   - ninja -C build/
264   - ccache --show-stats
265
266 .build_ccache_vars:
267   variables:
268     CCACHE_COMPILERCHECK: 'content'
269     CCACHE_COMPRESS: 'true'
270     CCACHE_BASEDIR: '/cache/gstreamer/gstreamer'
271     CCACHE_DIR: '/cache/gstreamer/gstreamer/ccache/'
272     # shared across everything really
273     CCACHE_MAXSIZE: '10G'
274     CARGO_HOME: '/cache/gstreamer/cargo'
275
276 .base_modules_changes: &modules_changes
277   - .gitlab-ci.yml
278   - meson.build
279   - subprojects/*.wrap
280   - subprojects/gst-devtools/**/*
281   - subprojects/gst-editing-services/**/*
282   - subprojects/gst-integration-testsuites/**/*
283   - subprojects/gst-libav/**/*
284   - subprojects/gst-omx/**/*
285   - subprojects/gst-plugins-bad/**/*
286   - subprojects/gst-plugins-base/**/*
287   - subprojects/gst-plugins-good/**/*
288   - subprojects/gst-plugins-ugly/**/*
289   - subprojects/gst-python/**/*
290   - subprojects/gstreamer/**/*
291   - subprojects/gstreamer-sharp/**/*
292   - subprojects/gstreamer-vaapi/**/*
293   - subprojects/gst-rtsp-server/**/*
294
295 .simple_fedora_build: &simple_build >-
296   ${DEFAULT_MESON_ARGS}
297   -Dsharp=enabled
298   -Domx=enabled
299   -Dgst-omx:target=generic
300   -Ddoc=disabled
301   -Drs=disabled
302   ${MESON_BUILDTYPE_ARGS}
303   ${MESON_GST_WERROR}
304
305 .build:
306   stage: 'build'
307   extends:
308     - '.build_ccache_vars'
309   needs:
310     - "trigger"
311   # Taking into account the slowest shared runner + time needed to upload the binaries to artifacts
312   # Also need to take into account I/O of pulling docker images and uploading artifacts
313   timeout: '45min'
314   variables:
315     MESON_ARGS: "${DEFAULT_MESON_ARGS} ${MESON_BUILDTYPE_ARGS} ${MESON_GST_WERROR}"
316   before_script:
317     - export RUSTUP_HOME="/usr/local/rustup"
318     - export CARGO_HOME="/usr/local/cargo"
319     - export PATH="/usr/local/cargo/bin:$PATH"
320
321     - ci/scripts/handle-subprojects-cache.py subprojects/
322     # Update subprojects to respect `.wrap` content
323     - meson subprojects update --reset
324   script:
325     *build
326   after_script:
327     - mv build/meson-logs/ meson-logs
328   artifacts:
329     expire_in: "7 days"
330     when: "always"
331     paths:
332       - 'meson-logs/'
333
334 .build fedora x86_64:
335   extends:
336     - '.fedora image'
337     - '.fdo.suffixed-image@fedora'
338     - '.build'
339   needs:
340     - "fedora amd64 docker"
341   variables:
342     MESON_ARGS: *simple_build
343   rules:
344     - changes:
345         *modules_changes
346
347 build nodebug fedora x86_64:
348   extends:
349     - '.fedora image'
350     - '.fdo.suffixed-image@fedora'
351     - '.build'
352   needs:
353     - "fedora amd64 docker"
354   variables:
355     MESON_ARGS: "${DEFAULT_MESON_ARGS} -Dsharp=enabled -Dgstreamer:gst_debug=false -Domx=enabled -Dgst-omx:target=generic ${MESON_BUILDTYPE_ARGS} ${MESON_GST_WERROR}"
356
357 build static fedora x86_64:
358   extends: '.build fedora x86_64'
359   variables:
360     MESON_BUILDTYPE_ARGS: "--default-library=static -Dintrospection=disabled -Ddoc=disabled"
361
362 build static nodebug fedora x86_64:
363   extends: 'build nodebug fedora x86_64'
364   variables:
365     MESON_BUILDTYPE_ARGS: "--default-library=static -Dintrospection=disabled -Ddoc=disabled"
366
367 build clang fedora x86_64:
368   extends: '.build fedora x86_64'
369   variables:
370     CC: 'ccache clang'
371     CXX: 'ccache clang++'
372
373 .build windows:
374   image: $WINDOWS_IMAGE
375   stage: 'build'
376   tags:
377     - 'docker'
378     - 'windows'
379     - '1809'
380   needs:
381     - "windows amd64 docker"
382   timeout: '45min'
383   variables:
384     MESON_ARGS: >
385       ${DEFAULT_MESON_ARGS}
386       -Dpython=disabled
387       -Dlibav=disabled
388       -Dvaapi=disabled
389       -Dgst-plugins-base:pango=enabled
390       -Dgst-plugins-good:cairo=enabled
391   rules:
392     - changes:
393         *modules_changes
394   before_script:
395     - ci/scripts/handle-subprojects-cache.py subprojects/
396   script:
397     # For some reason, options are separated by newline instead of space, so we
398     # have to replace them first.
399     - $env:MESON_ARGS = $env:MESON_ARGS.replace("`n"," ")
400     - cmd.exe /C "C:\BuildTools\Common7\Tools\VsDevCmd.bat -host_arch=amd64 -arch=$env:ARCH &&
401         meson build $env:MESON_ARGS &&
402         ninja -C build"
403   # XXX: Re-enable when uploading stops timing out
404   #artifacts:
405   #  expire_in: "7 days"
406   #  when: "always"
407   #  paths:
408   #    - 'build/meson-logs/'
409
410 build vs2017 amd64:
411   extends: '.build windows'
412   variables:
413     ARCH: 'amd64'
414
415 build vs2017 x86:
416   extends: '.build windows'
417   variables:
418     ARCH: 'x86'
419
420 build msys2 :
421   extends: '.build windows'
422   timeout: '60min'
423   rules:
424     - changes:
425         *modules_changes
426       allow_failure: true
427       when: 'manual'
428   script:
429     # Make sure powershell exists on errors
430     # https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_preference_variables?view=powershell-6
431     - $ErrorActionPreference = "Stop"
432
433     # For some reason docker build hangs if this is included in the image, needs more troubleshooting
434     - $env:PATH += ';C:\msys64\usr\bin;C:\msys64\mingw64\bin;C:\msys64\mingw32\bin'
435     # Copied from https://github.com/msys2/setup-msys2/blob/master/main.js#L98
436     - C:\msys64\usr\bin\bash -c "pacman-key --init && pacman-key --populate msys2 && pacman-key --refresh-keys || true"
437     - C:\msys64\usr\bin\bash -c "sed -i 's/^CheckSpace/#CheckSpace/g' /etc/pacman.conf"
438     - echo "Updating MSYS2"
439     - C:\msys64\usr\bin\bash -c "pacman -Syuu --noconfirm || echo Update failed, ignoring"
440     - echo "Killing all MSYS2 processes"
441     - taskkill /F /FI "MODULES eq msys-2.0.dll"
442     - echo "Completing MSYS2 update"
443     - C:\msys64\usr\bin\bash -c "pacman -Suu --noconfirm"
444     - echo "Installing needed MSYS2 packages"
445     - C:\msys64\usr\bin\bash -c "pacman -Sy --noconfirm --needed mingw-w64-x86_64-toolchain ninja"
446
447     # For some reason, options are separated by newline instead of space, so we
448     # have to replace them first.
449     - $env:MESON_ARGS = $env:MESON_ARGS.replace("`n"," ")
450     # Replace forward slashes with backwards so bash doesn't complain
451     - $env:_PROJECT_DIR = $env:CI_PROJECT_DIR.replace('\','/')
452     - C:\msys64\usr\bin\bash -c "meson build $env:MESON_ARGS && ninja -C build"
453
454 # ---- Tests ----- #
455
456 .test:
457   stage: 'test'
458   extends:
459     - '.build_ccache_vars'
460   needs:
461     - "trigger"
462   variables:
463     MESON_ARGS: *simple_build
464
465     # Disable colored output to avoid weird rendering issues
466     GST_DEBUG_NO_COLOR: "true"
467     CI_ARTIFACTS_URL: "${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/validate-logs/"
468     GST_VALIDATE_LAUNCHER_FORCE_COLORS: "true"
469     TIMEOUT_FACTOR: "2"
470     CARGO_HOME: "/cache/gstreamer/cargo"
471     # Enable the fault handler so we get backtraces on segfaults.
472     # any non-empty string will do
473     PYTHONFAULTHANDLER: "enabled"
474   rules:
475     - changes:
476         *modules_changes
477   script:
478     - *build
479
480     - echo "-> Running ${TEST_SUITE}"
481     - >
482       ./gst-env.py
483       gst-validate-launcher ${TEST_SUITE}
484       --dump-on-failure
485       --mute
486       --shuffle
487       --no-display
488       --meson-no-rebuild
489       --timeout-factor "${TIMEOUT_FACTOR}"
490       --fail-on-testlist-change
491       -l "${CI_PROJECT_DIR}/validate-logs/"
492       --xunit-file "${CI_PROJECT_DIR}/validate-logs/xunit.xml"
493       ${EXTRA_VALIDATE_ARGS}
494   after_script:
495     - mv build/meson-logs/ meson-logs
496   artifacts:
497     expire_in: '14 days'
498     when: always
499     paths:
500       - 'meson-logs/'
501       - 'validate-logs'
502     reports:
503       junit:
504         - "validate-logs/*.xml"
505
506 .test fedora x86_64:
507   extends:
508     - '.fedora image'
509     - '.fdo.suffixed-image@fedora'
510     - '.test'
511   needs:
512     - "fedora amd64 docker"
513   tags: ['gstreamer']
514
515 check fedora:
516   extends: '.test fedora x86_64'
517   variables:
518     TEST_SUITE: "check.gst*"
519
520 integration testsuites fedora:
521   extends: '.test fedora x86_64'
522   parallel: 4
523   variables:
524     EXTRA_VALIDATE_ARGS: "--timeout-factor=2 --retry-on-failures --check-bugs --parts=${CI_NODE_TOTAL} --part-index=${CI_NODE_INDEX} --sync"
525     TEST_SUITE: "validate ges"
526
527 # gstreamer-full:
528 # introspection has been disabled as the static build does not support it.
529 # See https://gitlab.freedesktop.org/gstreamer/gst-build/-/issues/162
530 gstreamer-full:
531   extends: 'build static fedora x86_64'
532   stage: integrate
533   variables:
534     MESON_ARGS: >
535       --default-library=static
536       -Dintrospection=disabled
537       $MESON_GST_WERROR
538   rules:
539     - changes:
540       - "*"
541       - scripts/*
542       - ci/**/*
543
544   script:
545   - *build
546   - meson test -C build -v test-gst-full
547   artifacts:
548     expire_in: "7 days"
549     when: "always"
550     paths:
551       - 'meson-logs/'
552
553 gstreamer-full-minimal:
554   extends: 'build static fedora x86_64'
555   stage: integrate
556   variables:
557     MESON_ARGS: >
558       --default-library=static
559       -Dauto_features=disabled
560       -Dgstreamer:check=enabled
561       -Dtests=enabled
562       -Dgst-plugins-base:alsa=enabled
563       -Dgst-plugins-base:typefind=enabled
564       -Dgst-plugins-base:pbtypes=enabled
565       -Dgst-full-elements=coreelements:filesrc,fakesink,identity,input-selector
566       -Dgst-full-typefind-functions=typefindfunctions:wav,flv
567       -Dgst-full-device-providers=alsa:alsadeviceprovider
568       -Dgst-full-dynamic-types=pbtypes:video_multiview_flagset
569       $MESON_GST_WERROR
570   rules:
571     - if: '$CI_PROJECT_NAME =~ /^(gst-build|gst-ci)$/'
572
573   script:
574   - *build
575   - meson test -C build -v test-gst-full
576   - meson test -C build test-gst-full-features --test-args "-e filesrc,identity,fakesink -E filesink,capsfilter -t audio/x-wav -T video/vivo -d alsadeviceprovider -D v4l2deviceprovider -l GstVideoMultiviewFlagsSet"
577   - strip build/libgstreamer-full-1.0.so
578   - ls -l build/libgstreamer-full-1.0.so
579   artifacts:
580     expire_in: "7 days"
581     when: "always"
582     paths:
583       - 'meson-logs/'
584
585 # Valgrind
586 .valgrind fedora x86_64:
587   extends: '.test fedora x86_64'
588   stage: 'test'
589   variables:
590     EXTRA_VALIDATE_ARGS: "--valgrind"
591
592 valgrind core:
593   extends: '.valgrind fedora x86_64'
594   variables:
595     TEST_SUITE: "check.gstreamer\\..*"
596   rules:
597     - changes:
598       - "*"
599       - scripts/*
600       - ci/**/*
601       - subprojects/gst-devtools/**/*
602       - subprojects/gstreamer/**/*
603
604 valgrind base:
605   extends: '.valgrind fedora x86_64'
606   variables:
607     TEST_SUITE: "check.gst-plugins-base\\..*"
608   rules:
609     - changes:
610       - "*"
611       - scripts/*
612       - ci//**/*
613       - subprojects/gst-devtools/**/*
614       - subprojects/gstreamer/**/*
615       - subprojects/gst-plugins-base/**/*
616
617 valgrind good:
618   extends: '.valgrind fedora x86_64'
619   variables:
620     TEST_SUITE: "check.gst-plugins-good\\..*"
621     # take longer time due to splitmux unit test
622     TIMEOUT_FACTOR: "4"
623   rules:
624     - changes:
625       - "*"
626       - scripts/*
627       - ci/**/*
628       - subprojects/gst-devtools/**/*
629       - subprojects/gstreamer/**/*
630       - subprojects/gst-plugins-base/**/*
631       - subprojects/gst-plugins-good/**/*
632
633 valgrind ugly:
634   extends: '.valgrind fedora x86_64'
635   variables:
636     TEST_SUITE: "check.gst-plugins-ugly\\..*"
637   rules:
638     - changes:
639       - "*"
640       - scripts/*
641       - ci/**/*
642       - subprojects/gst-devtools/**/*
643       - subprojects/gstreamer/**/*
644       - subprojects/gst-plugins-base/**/*
645       - subprojects/gst-plugins-good/**/*
646       - subprojects/gst-plugins-ugly/**/*
647
648 valgrind bad:
649   extends: '.valgrind fedora x86_64'
650   variables:
651     TEST_SUITE: "check.gst-plugins-bad\\..*"
652   rules:
653     - changes:
654       - "*"
655       - scripts/*
656       - ci/**/*
657       - subprojects/gst-devtools/**/*
658       - subprojects/gstreamer/**/*
659       - subprojects/gst-plugins-base/**/*
660       - subprojects/gst-plugins-good/**/*
661       - subprojects/gst-plugins-bad/**/*
662
663 valgrind ges:
664   extends: '.valgrind fedora x86_64'
665   variables:
666     TEST_SUITE: "check.gst-editing-services\\..*"
667   rules:
668     - changes:
669       - "*"
670       - scripts/*
671       - ci/**/*
672       - subprojects/gst-devtools/**/*
673       - subprojects/gstreamer/**/*
674       - subprojects/gst-plugins-base/**/*
675       - subprojects/gst-plugins-good/**/*
676       - subprojects/gst-plugins-bad/**/*
677       - subprojects/gst-editing-services/**/*
678
679 # ---- Integration ----- #
680
681 .documentation:
682   image: $FEDORA_DOCS_IMAGE
683   extends:
684     - '.build_ccache_vars'
685   variables:
686     MESON_ARGS: *simple_build
687     MESON_BUILDTYPE_ARGS: "-Ddoc=enabled"
688     CI_ARTIFACTS_URL: "${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/"
689   script:
690   - pip3 install --upgrade hotdoc
691   - *build
692   - ./gst-env.py ninja -C build/ plugins_doc_caches
693   - ./ci/scripts/check-documentation-diff.py
694   - ./gst-env.py hotdoc run --conf-file=build/subprojects/gst-docs/GStreamer-doc.json --fatal-warnings
695   - mv build/subprojects/gst-docs/GStreamer-doc/html documentation/
696
697   artifacts:
698     when: always
699     expire_in: "7 days"
700     paths:
701     - documentation/
702     - plugins-cache-diffs/
703
704 #
705 # This jobs runs in gsrtreamer namespace when after the merge into main branch.
706 # The produced artifact is later used to automatically update the web page.
707 #
708 documentation:
709   stage: integrate
710   extends:
711     - '.documentation'
712   needs: []
713   rules:
714     - if: '$CI_PROJECT_NAMESPACE == "gstreamer" && $CI_COMMIT_BRANCH == "main"'
715
716 #
717 # This job is run in users namespace to validate documentation before merging
718 # MR.
719 #
720 build documentation:
721   extends:
722     - '.documentation'
723   stage: build
724   needs:
725     - "trigger"
726   rules:
727     - changes:
728       - .gitlab-ci.yml
729       - ci/gitlab/freedesktop_doc_importer.sh
730       - subprojects/*.wrap
731       - subprojects/gst-docs/**/*
732       - subprojects/gst-devtools/**/*
733       - subprojects/gst-editing-services/**/*
734       - subprojects/gst-libav/**/*
735       - subprojects/gst-omx/**/*
736       - subprojects/gst-plugins-bad/**/*
737       - subprojects/gst-plugins-base/**/*
738       - subprojects/gst-plugins-good/**/*
739       - subprojects/gst-plugins-ugly/**/*
740       - subprojects/gstreamer/**/*
741       - subprojects/gstreamer-vaapi/**/*
742       - subprojects/gst-rtsp-server/**/*
743
744 # FIXME: Using trigger: causes permission issues, workaround using old REST API.
745 # https://gitlab.com/gitlab-org/gitlab/-/issues/341737
746 cerbero trigger:
747   stage: build
748   extends:
749     - '.fedora image'
750     - '.fdo.suffixed-image@fedora'
751   needs:
752     - "fedora amd64 docker"
753   script:
754     - ci/gitlab/trigger_cerbero_pipeline.py
755
756   rules:
757     - changes:
758       - .gitlab-ci.yml
759       - ci/gitlab/trigger_cerbero_pipeline.py
760       - subprojects/gst-devtools/**/*
761       - subprojects/gst-editing-services/**/*
762       - subprojects/gst-libav/**/*
763       - subprojects/gst-plugins-bad/**/*
764       - subprojects/gst-plugins-base/**/*
765       - subprojects/gst-plugins-good/**/*
766       - subprojects/gst-plugins-ugly/**/*
767       - subprojects/gst-python/**/*
768       - subprojects/gstreamer/**/*
769       - subprojects/gst-rtsp-server/**/*
770       - subprojects/gst-examples/**/*