2023-03-09 20:08:24 +00:00
|
|
|
.templates_sha: &templates_sha fddab8aa63e89a8e65214f59860d9c0f030360c9
|
2020-04-21 10:19:38 +00:00
|
|
|
|
|
|
|
include:
|
|
|
|
- project: 'freedesktop/ci-templates'
|
|
|
|
ref: *templates_sha
|
|
|
|
file: '/templates/debian.yml'
|
|
|
|
|
2022-09-22 19:35:09 +00:00
|
|
|
- project: 'gstreamer/gstreamer-rs'
|
|
|
|
ref: main
|
|
|
|
file: '/ci/images_template.yml'
|
|
|
|
|
|
|
|
- project: 'gstreamer/gstreamer'
|
|
|
|
ref: main
|
|
|
|
file: '/.gitlab-image-tags.yml'
|
2020-04-21 10:19:38 +00:00
|
|
|
|
|
|
|
variables:
|
|
|
|
FDO_UPSTREAM_REPO: gstreamer/gst-plugins-rs
|
|
|
|
|
2022-09-15 18:35:28 +00:00
|
|
|
# We use GStreamer image to build the documentation as it is the simplest way
|
|
|
|
# to ensure that we are testing against the same thing as GStreamer itself.
|
2022-09-22 19:35:09 +00:00
|
|
|
# The tag name is included above from the main repo.
|
|
|
|
GSTREAMER_DOC_IMAGE: "registry.freedesktop.org/gstreamer/gstreamer/amd64/fedora:$FEDORA_TAG-main"
|
2022-08-23 14:29:21 +00:00
|
|
|
WINDOWS_BASE: "registry.freedesktop.org/gstreamer/gstreamer-rs/windows"
|
|
|
|
WINDOWS_RUST_MINIMUM_IMAGE: "$WINDOWS_BASE:$GST_RS_IMG_TAG-main-$GST_RS_MSRV"
|
|
|
|
WINDOWS_RUST_STABLE_IMAGE: "$WINDOWS_BASE:$GST_RS_IMG_TAG-main-$GST_RS_STABLE"
|
|
|
|
|
2021-09-09 02:58:39 +00:00
|
|
|
workflow:
|
|
|
|
rules:
|
|
|
|
- if: $CI_MERGE_REQUEST_IID
|
|
|
|
# don't create a pipeline if its a commit pipeline, on a branch and that branch has
|
|
|
|
# open merge requests (bc we will get a MR build instead)
|
|
|
|
- if: $CI_OPEN_MERGE_REQUESTS
|
|
|
|
when: never
|
|
|
|
- if: $CI_COMMIT_TAG
|
|
|
|
- if: $CI_COMMIT_BRANCH
|
|
|
|
|
2022-09-02 04:21:19 +00:00
|
|
|
default:
|
|
|
|
interruptible: true
|
|
|
|
|
2020-03-19 09:39:52 +00:00
|
|
|
stages:
|
2022-10-20 12:39:46 +00:00
|
|
|
- "trigger"
|
2020-04-21 10:19:38 +00:00
|
|
|
- "prep"
|
2020-03-19 09:39:52 +00:00
|
|
|
- "lint"
|
|
|
|
- "test"
|
|
|
|
- "extras"
|
2022-11-05 11:44:54 +00:00
|
|
|
- "integration"
|
2018-10-15 12:08:29 +00:00
|
|
|
|
2022-10-20 12:39:46 +00:00
|
|
|
# This is an empty job that is used to trigger the pipeline.
|
|
|
|
trigger:
|
|
|
|
image: alpine:latest
|
|
|
|
stage: 'trigger'
|
|
|
|
variables:
|
|
|
|
GIT_STRATEGY: none
|
|
|
|
script:
|
|
|
|
- echo "Trigger job done, now running the pipeline."
|
|
|
|
rules:
|
|
|
|
- if: $CI_PIPELINE_SOURCE == "schedule"
|
|
|
|
# If the MR is assigned to the Merge bot, trigger the pipeline automatically
|
|
|
|
- if: '$CI_MERGE_REQUEST_ASSIGNEES == "gstreamer-merge-bot"'
|
|
|
|
# Require explicit action to trigger tests post merge
|
|
|
|
- if: '$CI_PROJECT_NAMESPACE == "gstreamer" && $CI_COMMIT_BRANCH == "main"'
|
|
|
|
when: 'manual'
|
|
|
|
# When the assignee isn't the merge bot, require an explicit action to trigger the pipeline
|
|
|
|
# to avoid wasting CI resources
|
|
|
|
- if: '$CI_MERGE_REQUEST_ASSIGNEES != "gstreamer-merge-bot"'
|
|
|
|
when: 'manual'
|
|
|
|
allow_failure: false
|
|
|
|
|
2023-03-09 20:08:24 +00:00
|
|
|
.debian:12:
|
2018-10-15 12:08:29 +00:00
|
|
|
variables:
|
2023-03-09 20:08:24 +00:00
|
|
|
FDO_DISTRIBUTION_VERSION: 'bookworm-slim'
|
2018-10-15 12:08:29 +00:00
|
|
|
before_script:
|
2020-04-21 10:19:38 +00:00
|
|
|
- source ./ci/env.sh
|
2020-04-21 09:52:09 +00:00
|
|
|
- mkdir .cargo && echo -e "[net]\ngit-fetch-with-cli = true" > .cargo/config
|
2020-08-21 02:29:35 +00:00
|
|
|
# If cargo exists assume we probably will want to update
|
|
|
|
# the lockfile
|
|
|
|
- |
|
|
|
|
if command -v cargo; then
|
|
|
|
cargo generate-lockfile
|
|
|
|
cargo update
|
|
|
|
fi
|
2020-04-21 10:19:38 +00:00
|
|
|
|
2023-03-09 20:08:24 +00:00
|
|
|
.debian:12-stable:
|
|
|
|
extends: .debian:12
|
2020-04-21 10:19:38 +00:00
|
|
|
variables:
|
2023-02-20 09:11:33 +00:00
|
|
|
FDO_DISTRIBUTION_TAG: '$GST_RS_STABLE-${GST_RS_IMG_TAG}_2023-02-20.0'
|
2023-03-09 20:08:24 +00:00
|
|
|
FDO_BASE_IMAGE: "registry.freedesktop.org/gstreamer/gstreamer-rs/debian/bookworm-slim:$GST_RS_STABLE-$GST_RS_IMG_TAG"
|
2020-04-21 10:19:38 +00:00
|
|
|
|
2023-03-09 20:08:24 +00:00
|
|
|
.debian:12-msrv:
|
|
|
|
extends: .debian:12
|
2020-04-21 10:19:38 +00:00
|
|
|
variables:
|
2023-02-20 09:11:33 +00:00
|
|
|
FDO_DISTRIBUTION_TAG: '$GST_RS_MSRV-${GST_RS_IMG_TAG}_2023-02-20.0'
|
2023-03-09 20:08:24 +00:00
|
|
|
FDO_BASE_IMAGE: "registry.freedesktop.org/gstreamer/gstreamer-rs/debian/bookworm-slim:$GST_RS_MSRV-$GST_RS_IMG_TAG"
|
2020-04-21 10:19:38 +00:00
|
|
|
|
2023-03-09 20:08:24 +00:00
|
|
|
.debian:12-nightly:
|
|
|
|
extends: .debian:12
|
2020-04-21 10:19:38 +00:00
|
|
|
variables:
|
2023-02-20 09:11:33 +00:00
|
|
|
FDO_DISTRIBUTION_TAG: 'nightly-${GST_RS_IMG_TAG}_2023-02-20.0'
|
2023-03-09 20:08:24 +00:00
|
|
|
FDO_BASE_IMAGE: "registry.freedesktop.org/gstreamer/gstreamer-rs/debian/bookworm-slim:nightly-$GST_RS_IMG_TAG"
|
2020-04-21 10:19:38 +00:00
|
|
|
|
|
|
|
.build-debian-container:
|
|
|
|
extends:
|
|
|
|
- .fdo.container-build@debian
|
|
|
|
stage: prep
|
|
|
|
variables:
|
2022-08-30 19:59:17 +00:00
|
|
|
FDO_DISTRIBUTION_PACKAGES: "libcsound64-dev llvm clang nasm libsodium-dev libwebp-dev python3-pip"
|
2021-01-04 09:23:22 +00:00
|
|
|
FDO_DISTRIBUTION_EXEC: >-
|
|
|
|
bash ci/install-dav1d.sh &&
|
|
|
|
apt clean &&
|
2022-08-30 19:59:17 +00:00
|
|
|
bash ./ci/install-rust-ext.sh &&
|
2023-03-09 20:08:24 +00:00
|
|
|
pip install tomli --break-system-packages
|
2022-10-20 12:39:46 +00:00
|
|
|
needs:
|
|
|
|
- "trigger"
|
2020-04-22 06:33:36 +00:00
|
|
|
rules:
|
|
|
|
- if: '$UPDATE_IMG == null'
|
2020-04-21 10:19:38 +00:00
|
|
|
|
|
|
|
build-stable:
|
|
|
|
extends:
|
|
|
|
- .build-debian-container
|
2023-03-09 20:08:24 +00:00
|
|
|
- .debian:12-stable
|
2020-04-21 10:19:38 +00:00
|
|
|
|
2020-11-01 10:13:36 +00:00
|
|
|
build-msrv:
|
2020-04-21 10:19:38 +00:00
|
|
|
extends:
|
|
|
|
- .build-debian-container
|
2023-03-09 20:08:24 +00:00
|
|
|
- .debian:12-msrv
|
2020-04-21 10:19:38 +00:00
|
|
|
|
|
|
|
build-nightly:
|
|
|
|
extends:
|
|
|
|
- .build-debian-container
|
2023-03-09 20:08:24 +00:00
|
|
|
- .debian:12-nightly
|
2020-04-21 10:19:38 +00:00
|
|
|
|
2020-04-22 06:33:36 +00:00
|
|
|
# Those jobs are triggered by gstreamer-rs when updating its images
|
|
|
|
update-stable:
|
|
|
|
extends: build-stable
|
|
|
|
rules:
|
|
|
|
- if: '$UPDATE_IMG == "stable"'
|
|
|
|
variables:
|
|
|
|
FDO_FORCE_REBUILD: 1
|
|
|
|
|
2020-11-01 10:13:36 +00:00
|
|
|
update-msrv:
|
|
|
|
extends: build-msrv
|
2020-04-22 06:33:36 +00:00
|
|
|
rules:
|
2020-11-01 10:13:36 +00:00
|
|
|
- if: '$UPDATE_IMG == "msrv"'
|
2020-04-22 06:33:36 +00:00
|
|
|
variables:
|
|
|
|
FDO_FORCE_REBUILD: 1
|
|
|
|
|
|
|
|
update-nightly:
|
|
|
|
extends: build-nightly
|
|
|
|
rules:
|
|
|
|
- if: '$UPDATE_IMG == "nightly"'
|
|
|
|
variables:
|
|
|
|
FDO_FORCE_REBUILD: 1
|
|
|
|
|
2020-04-21 10:19:38 +00:00
|
|
|
.dist-debian-container:
|
|
|
|
extends:
|
|
|
|
- .fdo.distribution-image@debian
|
|
|
|
variables:
|
|
|
|
SODIUM_USE_PKG_CONFIG: "true"
|
|
|
|
after_script:
|
|
|
|
- rm -rf target
|
|
|
|
|
|
|
|
.img-stable:
|
|
|
|
extends:
|
|
|
|
- .dist-debian-container
|
2023-03-09 20:08:24 +00:00
|
|
|
- .debian:12-stable
|
2022-09-14 12:19:21 +00:00
|
|
|
needs:
|
|
|
|
- job: 'build-stable'
|
|
|
|
optional: true
|
|
|
|
- job: 'update-stable'
|
|
|
|
optional: true
|
2020-04-21 10:19:38 +00:00
|
|
|
|
2020-11-01 10:13:36 +00:00
|
|
|
.img-msrv:
|
2020-04-21 10:19:38 +00:00
|
|
|
extends:
|
|
|
|
- .dist-debian-container
|
2023-03-09 20:08:24 +00:00
|
|
|
- .debian:12-msrv
|
2022-09-14 12:19:21 +00:00
|
|
|
needs:
|
|
|
|
- job: 'build-msrv'
|
|
|
|
optional: true
|
|
|
|
- job: 'update-msrv'
|
|
|
|
optional: true
|
2020-04-21 10:19:38 +00:00
|
|
|
|
|
|
|
.img-nightly:
|
|
|
|
extends:
|
|
|
|
- .dist-debian-container
|
2023-03-09 20:08:24 +00:00
|
|
|
- .debian:12-nightly
|
2022-09-14 12:19:21 +00:00
|
|
|
needs:
|
|
|
|
- job: 'build-nightly'
|
|
|
|
optional: true
|
|
|
|
- job: 'update-nightly'
|
|
|
|
optional: true
|
2019-07-04 14:37:17 +00:00
|
|
|
|
|
|
|
.cargo test:
|
2020-03-19 09:39:52 +00:00
|
|
|
stage: "test"
|
2021-08-16 15:43:09 +00:00
|
|
|
variables:
|
|
|
|
# csound-sys only looks at /usr/lib and /usr/local top levels
|
|
|
|
CSOUND_LIB_DIR: '/usr/lib/x86_64-linux-gnu/'
|
2022-02-22 16:31:35 +00:00
|
|
|
RUST_BACKTRACE: 'full'
|
2018-10-15 12:08:29 +00:00
|
|
|
script:
|
2019-07-04 14:37:17 +00:00
|
|
|
- rustc --version
|
2020-08-21 02:29:35 +00:00
|
|
|
|
2022-02-21 20:12:32 +00:00
|
|
|
- cargo build --locked --color=always --workspace --all-targets
|
|
|
|
- G_DEBUG=fatal_warnings cargo test --locked --color=always --workspace --all-targets
|
|
|
|
- cargo build --locked --color=always --workspace --all-targets --all-features
|
|
|
|
- G_DEBUG=fatal_warnings cargo test --locked --color=always --workspace --all-targets --all-features
|
2022-09-10 11:36:56 +00:00
|
|
|
- cargo build --locked --color=always --workspace --all-targets --no-default-features
|
|
|
|
- G_DEBUG=fatal_warnings cargo test --locked --color=always --workspace --all-targets --no-default-features
|
2018-10-15 12:08:29 +00:00
|
|
|
|
2020-11-01 10:13:36 +00:00
|
|
|
test msrv:
|
2020-04-21 10:19:38 +00:00
|
|
|
extends:
|
|
|
|
- '.cargo test'
|
2020-11-01 10:13:36 +00:00
|
|
|
- .img-msrv
|
2020-04-22 06:33:36 +00:00
|
|
|
rules:
|
2020-11-01 10:13:36 +00:00
|
|
|
- if: '$UPDATE_IMG == null || $UPDATE_IMG == "msrv"'
|
2018-10-15 12:08:29 +00:00
|
|
|
|
2019-11-30 18:51:31 +00:00
|
|
|
test stable:
|
2020-04-21 10:19:38 +00:00
|
|
|
extends:
|
|
|
|
- '.cargo test'
|
|
|
|
- .img-stable
|
2020-04-22 06:33:36 +00:00
|
|
|
rules:
|
|
|
|
- if: '$UPDATE_IMG == null || $UPDATE_IMG == "stable"'
|
2018-10-15 12:08:29 +00:00
|
|
|
|
|
|
|
test nightly:
|
|
|
|
allow_failure: true
|
2020-04-21 10:19:38 +00:00
|
|
|
extends:
|
|
|
|
- '.cargo test'
|
|
|
|
- .img-nightly
|
2020-04-22 06:33:36 +00:00
|
|
|
rules:
|
|
|
|
- if: '$UPDATE_IMG == null || $UPDATE_IMG == "nightly"'
|
2018-10-15 12:08:29 +00:00
|
|
|
|
2021-05-26 09:07:27 +00:00
|
|
|
.meson:
|
2020-11-18 14:12:34 +00:00
|
|
|
extends: .img-stable
|
2021-05-26 09:07:27 +00:00
|
|
|
rules:
|
|
|
|
- if: '$UPDATE_IMG == null || $UPDATE_IMG == "stable"'
|
|
|
|
variables:
|
2021-08-16 15:43:09 +00:00
|
|
|
# csound-sys only looks at /usr/lib and /usr/local top levels
|
|
|
|
CSOUND_LIB_DIR: '/usr/lib/x86_64-linux-gnu/'
|
2021-05-26 09:07:27 +00:00
|
|
|
|
|
|
|
meson shared:
|
|
|
|
extends: .meson
|
2022-08-29 16:33:57 +00:00
|
|
|
variables:
|
|
|
|
CI_ARTIFACTS_URL: "${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/"
|
2020-11-18 14:12:34 +00:00
|
|
|
script:
|
2020-11-18 14:53:01 +00:00
|
|
|
- meson build --default-library=shared --prefix=$(pwd)/install
|
|
|
|
- ninja -C build install
|
2022-10-20 17:10:43 +00:00
|
|
|
- ./ci/check-installed.py install
|
2022-08-29 16:33:57 +00:00
|
|
|
- ninja -C build docs/gst_plugins_cache.json
|
|
|
|
- ci/check-documentation-diff.py
|
|
|
|
artifacts:
|
|
|
|
when: always
|
|
|
|
expire_in: "7 days"
|
|
|
|
paths:
|
|
|
|
- plugins-cache-diffs/
|
2022-09-01 19:13:18 +00:00
|
|
|
- 'build/meson-logs/'
|
2020-11-18 14:12:34 +00:00
|
|
|
|
|
|
|
meson static:
|
2021-05-26 09:07:27 +00:00
|
|
|
extends: .meson
|
2020-11-18 14:12:34 +00:00
|
|
|
script:
|
2022-12-27 18:25:16 +00:00
|
|
|
- meson build --default-library=static --prefix=$(pwd)/install -Dsodium-source=built-in
|
2020-11-27 12:44:04 +00:00
|
|
|
- ninja -C build install
|
|
|
|
- ./ci/generate-static-test.py test-static-link-all
|
|
|
|
- cd test-static-link-all
|
|
|
|
- PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$(pwd)/../install/lib/x86_64-linux-gnu/pkgconfig meson build
|
2020-11-18 14:12:34 +00:00
|
|
|
- ninja -C build
|
2020-11-27 12:44:04 +00:00
|
|
|
- ./build/test-gst-static
|
2022-09-01 19:13:18 +00:00
|
|
|
artifacts:
|
|
|
|
when: always
|
|
|
|
expire_in: "7 days"
|
|
|
|
paths:
|
|
|
|
- 'build/meson-logs/'
|
2020-11-18 14:12:34 +00:00
|
|
|
|
2022-09-15 18:35:28 +00:00
|
|
|
# Check that the gstreamer documentation keeps working
|
|
|
|
documentation:
|
|
|
|
image: $GSTREAMER_DOC_IMAGE
|
2022-11-05 11:44:54 +00:00
|
|
|
stage: 'integration'
|
2022-09-15 18:35:28 +00:00
|
|
|
variables:
|
|
|
|
MESON_ARGS: >
|
2022-09-15 21:27:37 +00:00
|
|
|
-Ddoc=enabled
|
2022-09-15 18:35:28 +00:00
|
|
|
-Domx=disabled
|
|
|
|
-Dpython=disabled
|
|
|
|
-Dlibav=disabled
|
|
|
|
-Dlibnice=disabled
|
|
|
|
-Ddevtools=disabled
|
|
|
|
-Dges=disabled
|
|
|
|
-Dsharp=disabled
|
|
|
|
-Dgst-examples=disabled
|
|
|
|
-Drs=enabled
|
2022-12-27 18:25:16 +00:00
|
|
|
-Dgst-plugins-rs:sodium-source=system
|
2022-09-15 18:35:28 +00:00
|
|
|
-Dgst-docs:fatal_warnings=true
|
|
|
|
-Dorc=disabled
|
|
|
|
script:
|
2022-09-15 21:27:37 +00:00
|
|
|
- export PATH=/usr/local/cargo/bin/:/usr/local/bin/:$PATH
|
|
|
|
- export RUSTUP_HOME='/usr/local/rustup'
|
2022-09-15 18:35:28 +00:00
|
|
|
- P=$(pwd)
|
|
|
|
- cd ..
|
|
|
|
- rm -rf gstreamer
|
|
|
|
- git clone --depth 1 https://gitlab.freedesktop.org/gstreamer/gstreamer.git --branch main
|
|
|
|
- cd gstreamer
|
|
|
|
- ln -s $P subprojects/gst-plugins-rs
|
|
|
|
- meson build $MESON_ARGS
|
|
|
|
- ./gst-env.py ninja -C build subprojects/gst-docs/GStreamer-doc
|
2022-09-15 21:27:37 +00:00
|
|
|
- mv build/subprojects/gst-docs/GStreamer-doc/html $P/documentation/
|
2022-09-15 18:35:28 +00:00
|
|
|
artifacts:
|
|
|
|
expire_in: '7 days'
|
|
|
|
when: always
|
|
|
|
paths:
|
|
|
|
- documentation/
|
|
|
|
needs: []
|
2022-10-20 12:39:46 +00:00
|
|
|
rules:
|
|
|
|
# Run job if the MR is assigned to the Merge bot or it a post-merge pipeline on main branch
|
|
|
|
- if: '$CI_MERGE_REQUEST_ASSIGNEES == "gstreamer-merge-bot"'
|
|
|
|
when: 'always'
|
|
|
|
- if: '$CI_PROJECT_NAMESPACE == "gstreamer" && $CI_COMMIT_BRANCH == "main"'
|
|
|
|
when: 'always'
|
|
|
|
# Require explicit action to trigger otherwise
|
|
|
|
- if: '$CI_PROJECT_NAMESPACE != "gstreamer" || $CI_COMMIT_BRANCH != "main"'
|
|
|
|
when: 'manual'
|
2022-09-15 18:35:28 +00:00
|
|
|
|
2021-11-02 13:03:47 +00:00
|
|
|
# build gst-plugins-rs as a gst-build subproject
|
2022-12-03 17:55:41 +00:00
|
|
|
# Disabled because of https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/262
|
|
|
|
#gst-build:
|
|
|
|
# extends: .meson
|
|
|
|
# rules:
|
|
|
|
# - if: '$CI_PIPELINE_SOURCE == "schedule"'
|
|
|
|
# - if: $CI_PIPELINE_SOURCE == "merge_request_event"
|
|
|
|
# when: 'manual'
|
|
|
|
# allow_failure: true
|
|
|
|
# variables:
|
|
|
|
# MESON_ARGS: >
|
|
|
|
# -Domx=disabled
|
|
|
|
# -Dpython=disabled
|
|
|
|
# -Dlibav=disabled
|
|
|
|
# -Dlibnice=disabled
|
|
|
|
# -Dugly=disabled
|
|
|
|
# -Dbad=disabled
|
|
|
|
# -Ddevtools=disabled
|
|
|
|
# -Dges=disabled
|
|
|
|
# -Drtsp_server=disabled
|
|
|
|
# -Dvaapi=disabled
|
|
|
|
# -Dsharp=disabled
|
|
|
|
# -Dgst-examples=disabled
|
|
|
|
# -Drs=enabled
|
2022-12-27 18:25:16 +00:00
|
|
|
# -Dgst-plugins-rs:sodium-source=system
|
2022-12-03 17:55:41 +00:00
|
|
|
# script:
|
|
|
|
# - P=$(pwd)
|
|
|
|
# - cd ..
|
|
|
|
# - rm -rf gstreamer
|
|
|
|
# - git clone --depth 1 https://gitlab.freedesktop.org/gstreamer/gstreamer.git --branch main
|
|
|
|
# - cd gstreamer
|
|
|
|
# - ln -s $P subprojects/gst-plugins-rs
|
|
|
|
# - meson build $MESON_ARGS
|
|
|
|
# - ninja -C build
|
|
|
|
# # Check static Rust plugins can be linked into gst-full
|
|
|
|
# - meson build-gst-full --default-library=static $MESON_ARGS
|
|
|
|
# - ninja -C build-gst-full
|
|
|
|
# - meson devenv -C build-gst-full ./gst-inspect-1.0 rsaudiofx
|
|
|
|
# artifacts:
|
|
|
|
# expire_in: '7 days'
|
|
|
|
# when: always
|
|
|
|
# paths:
|
|
|
|
# - 'build/meson-logs/'
|
|
|
|
# - 'build-gst-full/meson-logs/'
|
2021-11-02 13:03:47 +00:00
|
|
|
|
2022-08-23 14:29:21 +00:00
|
|
|
.msvc2019 build:
|
|
|
|
stage: 'test'
|
2022-10-20 12:39:46 +00:00
|
|
|
needs:
|
|
|
|
- 'trigger'
|
2022-08-23 14:29:21 +00:00
|
|
|
tags:
|
|
|
|
- 'docker'
|
|
|
|
- 'windows'
|
|
|
|
- '2022'
|
|
|
|
script:
|
|
|
|
# Set the code page to UTF-8
|
|
|
|
- chcp 65001
|
|
|
|
|
|
|
|
# We need to build each crate separately to choose that can build on windows
|
|
|
|
- cmd.exe /C "C:\BuildTools\Common7\Tools\VsDevCmd.bat -host_arch=amd64 -arch=amd64 &&
|
|
|
|
powershell ./ci/run_windows_tests.ps1"
|
|
|
|
|
|
|
|
- |
|
|
|
|
if (!$?) {
|
|
|
|
Write-Host "Tests Failed!"
|
|
|
|
Exit 1
|
|
|
|
}
|
|
|
|
|
|
|
|
test windows msrv:
|
|
|
|
extends: '.msvc2019 build'
|
|
|
|
image: $WINDOWS_RUST_MINIMUM_IMAGE
|
2022-10-20 12:49:39 +00:00
|
|
|
when: 'manual'
|
2022-08-23 14:29:21 +00:00
|
|
|
|
|
|
|
test windows stable:
|
|
|
|
extends: '.msvc2019 build'
|
|
|
|
image: "$WINDOWS_RUST_STABLE_IMAGE"
|
|
|
|
|
2018-10-15 12:08:29 +00:00
|
|
|
rustfmt:
|
2020-04-21 10:19:38 +00:00
|
|
|
extends: .img-stable
|
2020-03-19 09:39:52 +00:00
|
|
|
stage: "lint"
|
2020-04-30 16:19:48 +00:00
|
|
|
rules:
|
|
|
|
- when: 'always'
|
2018-10-15 12:08:29 +00:00
|
|
|
script:
|
|
|
|
- cargo fmt --version
|
|
|
|
- cargo fmt -- --color=always --check
|
2019-07-04 14:37:17 +00:00
|
|
|
|
2022-10-18 16:46:35 +00:00
|
|
|
gstwebrtc-api lint:
|
|
|
|
image: node:lts
|
|
|
|
stage: "lint"
|
|
|
|
rules:
|
|
|
|
- when: 'always'
|
|
|
|
script:
|
|
|
|
- cd net/webrtc/gstwebrtc-api
|
|
|
|
- npm install
|
|
|
|
- npm run check
|
|
|
|
|
2020-06-11 13:17:33 +00:00
|
|
|
check commits:
|
|
|
|
extends: .img-stable
|
|
|
|
stage: "lint"
|
|
|
|
rules:
|
|
|
|
- when: 'always'
|
|
|
|
script:
|
|
|
|
- ci-fairy check-commits --textwidth 0 --no-signed-off-by
|
|
|
|
|
2019-07-04 14:37:17 +00:00
|
|
|
clippy:
|
2020-04-21 10:19:38 +00:00
|
|
|
extends: .img-stable
|
2020-03-19 09:39:52 +00:00
|
|
|
stage: 'extras'
|
2021-08-16 15:43:09 +00:00
|
|
|
variables:
|
|
|
|
# csound-sys only looks at /usr/lib and /usr/local top levels
|
|
|
|
CSOUND_LIB_DIR: '/usr/lib/x86_64-linux-gnu/'
|
2020-04-30 16:19:48 +00:00
|
|
|
rules:
|
|
|
|
- when: 'always'
|
2019-07-04 14:37:17 +00:00
|
|
|
script:
|
2022-11-01 09:15:28 +00:00
|
|
|
- cargo clippy --locked --color=always --all --all-features --all-targets -- -D warnings -A unknown-lints
|
2019-10-10 12:40:09 +00:00
|
|
|
|
2020-04-16 11:03:28 +00:00
|
|
|
deny:
|
2020-04-21 10:19:38 +00:00
|
|
|
extends: .img-stable
|
2020-03-19 09:39:52 +00:00
|
|
|
stage: 'extras'
|
2020-04-30 16:11:25 +00:00
|
|
|
rules:
|
|
|
|
- if: '$CI_PIPELINE_SOURCE == "schedule"'
|
2019-10-10 12:40:09 +00:00
|
|
|
script:
|
2020-04-16 11:03:28 +00:00
|
|
|
- cargo deny check
|
2019-11-21 08:15:36 +00:00
|
|
|
|
|
|
|
outdated:
|
2020-04-21 10:19:38 +00:00
|
|
|
extends: .img-stable
|
2020-04-14 08:49:14 +00:00
|
|
|
allow_failure: true
|
2019-11-21 08:15:36 +00:00
|
|
|
stage: 'extras'
|
2020-04-30 16:11:25 +00:00
|
|
|
rules:
|
|
|
|
- if: '$CI_PIPELINE_SOURCE == "schedule"'
|
2019-11-21 08:15:36 +00:00
|
|
|
script:
|
|
|
|
- cargo outdated --root-deps-only --exit-code 1 -v
|
2021-01-11 15:26:57 +00:00
|
|
|
|
|
|
|
coverage:
|
2021-04-22 08:25:00 +00:00
|
|
|
allow_failure: true
|
2021-01-11 15:26:57 +00:00
|
|
|
extends:
|
2022-04-07 16:48:57 +00:00
|
|
|
- .img-stable
|
2021-01-11 15:26:57 +00:00
|
|
|
stage: 'extras'
|
|
|
|
rules:
|
|
|
|
- when: 'always'
|
|
|
|
variables:
|
2022-03-30 13:16:25 +00:00
|
|
|
RUSTFLAGS: "-Cinstrument-coverage"
|
2021-01-11 15:26:57 +00:00
|
|
|
LLVM_PROFILE_FILE: "gst-plugins-rs-%p-%m.profraw"
|
2021-08-16 15:43:09 +00:00
|
|
|
# csound-sys only looks at /usr/lib and /usr/local top levels
|
|
|
|
CSOUND_LIB_DIR: '/usr/lib/x86_64-linux-gnu/'
|
2021-01-11 15:26:57 +00:00
|
|
|
script:
|
2022-05-12 15:32:04 +00:00
|
|
|
- cargo test --locked --color=always --all --all-features
|
2021-01-11 15:26:57 +00:00
|
|
|
# generate html report
|
2021-04-23 12:19:53 +00:00
|
|
|
- grcov . --binary-path ./target/debug/ -s . -t html --branch --ignore-not-existing --ignore "*target*" --ignore "*/build.rs" -o ./coverage/
|
2021-01-11 15:26:57 +00:00
|
|
|
# generate cobertura report for gitlab integration
|
2021-04-23 12:19:53 +00:00
|
|
|
- grcov . --binary-path ./target/debug/ -s . -t cobertura --branch --ignore-not-existing --ignore "*target*" --ignore "*/build.rs" -o coverage.xml
|
|
|
|
# output coverage summary for gitlab parsing.
|
|
|
|
# TODO: use grcov once https://github.com/mozilla/grcov/issues/556 is fixed
|
|
|
|
- grep "%" coverage/index.html | head -1 || true
|
2021-01-11 15:26:57 +00:00
|
|
|
artifacts:
|
|
|
|
paths:
|
|
|
|
- 'coverage'
|
|
|
|
reports:
|
2022-06-07 06:04:40 +00:00
|
|
|
coverage_report:
|
|
|
|
coverage_format: cobertura
|
|
|
|
path: coverage.xml
|