mirror of
https://gitlab.freedesktop.org/emersion/libdisplay-info.git
synced 2024-11-16 19:48:30 +01:00
1f416f554a
The libc there is a bit different, so it's nice to make sure we don't break it. Signed-off-by: Simon Ser <contact@emersion.fr>
111 lines
2.8 KiB
YAML
111 lines
2.8 KiB
YAML
.templates_sha: &templates_sha d5aa3941aa03c2f716595116354fb81eb8012acb
|
|
|
|
include:
|
|
- project: 'freedesktop/ci-templates'
|
|
ref: *templates_sha
|
|
file: '/templates/ci-fairy.yml'
|
|
- project: 'freedesktop/ci-templates'
|
|
ref: *templates_sha
|
|
file: '/templates/alpine.yml'
|
|
- project: 'freedesktop/ci-templates'
|
|
ref: *templates_sha
|
|
file: '/templates/freebsd.yml'
|
|
|
|
# When updating a prepare-container-* step, make sure to bump
|
|
# FDO_DISTRIBUTION_TAG, otherwise the container won't get rebuilt.
|
|
# To force a rebuild of the container, use:
|
|
# $ git push -f -o ci.variable="FDO_FORCE_REBUILD=1"
|
|
variables:
|
|
FDO_UPSTREAM_REPO: 'emersion/libdisplay-info'
|
|
FDO_DISTRIBUTION_TAG: '2022-00-08.0'
|
|
MESON_FLAGS: '--fatal-meson-warnings -Dwerror=true'
|
|
|
|
stages:
|
|
- "Contribution checks"
|
|
- "Prepare container"
|
|
- "Build and test"
|
|
|
|
check-mr:
|
|
extends: .fdo.ci-fairy
|
|
stage: "Contribution checks"
|
|
script:
|
|
- ci-fairy check-commits --signed-off-by
|
|
- ci-fairy check-merge-request --require-allow-collaboration
|
|
rules:
|
|
- if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "main"'
|
|
when: always
|
|
- when: never
|
|
|
|
.prepare-container:
|
|
stage: "Prepare container"
|
|
variables:
|
|
FDO_DISTRIBUTION_EXEC: |
|
|
git clone git://linuxtv.org/edid-decode.git
|
|
cd edid-decode
|
|
git checkout 6816e6a691f40e6fbb64e6d40f012d7727c6315f
|
|
make
|
|
make install
|
|
cd ..
|
|
rm -rf edid-decode
|
|
rules:
|
|
- when: on_success
|
|
|
|
prepare-container-alpine:
|
|
extends:
|
|
- .prepare-container
|
|
- .fdo.container-build@alpine@x86_64
|
|
variables:
|
|
FDO_DISTRIBUTION_PACKAGES: |
|
|
build-base clang compiler-rt meson make git gcovr py3-pygments
|
|
|
|
prepare-container-freebsd:
|
|
extends:
|
|
- .prepare-container
|
|
- .fdo.container-build@freebsd
|
|
variables:
|
|
FDO_DISTRIBUTION_PACKAGES: |
|
|
meson git
|
|
|
|
.build:
|
|
stage: "Build and test"
|
|
artifacts:
|
|
when: always
|
|
paths:
|
|
- build/meson-logs/
|
|
reports:
|
|
junit: build/meson-logs/testlog.junit.xml
|
|
rules:
|
|
- when: on_success
|
|
|
|
build-alpine-gcc:
|
|
extends:
|
|
- .build
|
|
- .fdo.distribution-image@alpine
|
|
script:
|
|
- CC=gcc meson setup build/ $MESON_FLAGS -Db_coverage=true
|
|
- ninja -C build/
|
|
- ninja -C build/ test
|
|
- ninja -C build/ -j1 coverage-xml coverage-html
|
|
artifacts:
|
|
reports:
|
|
coverage_report:
|
|
coverage_format: cobertura
|
|
path: build/meson-logs/coverage.xml
|
|
|
|
build-alpine-clang:
|
|
extends:
|
|
- .build
|
|
- .fdo.distribution-image@alpine
|
|
script:
|
|
- CC=clang meson setup build/ $MESON_FLAGS -Db_sanitize=address,undefined -Db_lundef=false
|
|
- ninja -C build/
|
|
- ninja -C build/ test
|
|
|
|
build-freebsd:
|
|
extends:
|
|
- .build
|
|
- .fdo.distribution-image@freebsd
|
|
script:
|
|
- meson setup build/ $MESON_FLAGS
|
|
- ninja -C build/
|
|
- ninja -C build/ test
|