| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362 |
- # vim: set expandtab shiftwidth=2 tabstop=8 textwidth=0 filetype=yaml:
- ########################################
- # #
- # THIS FILE IS GENERATED, DO NOT EDIT #
- # #
- ########################################
- # To change the gitlab CI, edit .gitlab-ci/ci.template and/or .gitlab-ci/config.yaml
- # and run ci-fairy generate-template. For details, see
- # https://freedesktop.pages.freedesktop.org/ci-templates/ci-fairy.html#templating-gitlab-ci-yml
- # This is a bit complicated for two reasons:
- # - we really want to run dnf/apt/... only once, updating on the test runner for
- # each job takes forever. So we create a container image for each distribution
- # tested, then run the tests on this container image.
- #
- # This is handled by the ci-templates, ensuring containers are only rebuilt
- # when the TAG changes.
- #
- # - GitLab only allows one script: set per job but we have a bunch of commands
- # we need to re-run for each build (meson && ninja && etc). YAML cannot merge
- # arrays so we're screwed.
- #
- # So instead we use a default_build template and override everything with
- # variables. The only two variables that matter:
- # MESON_ARGS=-Denable-something=true
- # NINJA_ARGS=dist ... to run 'ninja -C builddir dist'
- # Note that you cannot use scripts: in any target if you expect default_build
- # to work.
- #
- #
- # All jobs must follow the naming scheme of
- # <distribution>:<version>@activity:
- # e.g. fedora:31@build-default
- .templates_sha: &template_sha c6aeb16f86e32525fa630fb99c66c4f3e62fc3cb
- include:
- - project: 'freedesktop/ci-templates'
- ref: *template_sha
- file:
- - '/templates/ci-fairy.yml'
- # Alpine container builder template
- - '/templates/alpine.yml'
- # Arch container builder template
- - '/templates/arch.yml'
- # Debian container builder template
- - '/templates/debian.yml'
- # Fedora container builder template
- - '/templates/fedora.yml'
- # Ubuntu container builder template
- - '/templates/ubuntu.yml'
- workflow:
- rules:
- # do not duplicate pipelines on merge pipelines
- - if: $CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS && $CI_PIPELINE_SOURCE == "push"
- when: never
- # merge pipeline
- - if: &is-merge-attempt $GITLAB_USER_LOGIN == "marge-bot" && $CI_PIPELINE_SOURCE == "merge_request_event"
- variables:
- FDO_RUNNER_JOB_PRIORITY_TAG_X86_64: priority:high
- FDO_RUNNER_JOB_PRIORITY_TAG_X86_64_KVM: priority:high-kvm
- FDO_RUNNER_JOB_PRIORITY_TAG_AARCH64: priority:high-aarch64
- # post-merge pipeline
- - if: &is-post-merge $GITLAB_USER_LOGIN == "marge-bot" && $CI_PIPELINE_SOURCE == "push"
- variables:
- FDO_RUNNER_JOB_PRIORITY_TAG_X86_64: priority:high
- FDO_RUNNER_JOB_PRIORITY_TAG_X86_64_KVM: priority:high-kvm
- FDO_RUNNER_JOB_PRIORITY_TAG_AARCH64: priority:high-aarch64
- # Pre-merge pipeline
- - if: &is-pre-merge $CI_PIPELINE_SOURCE == "merge_request_event"
- # Push to a branch on a fork
- - if: $CI_COMMIT_BRANCH
- stages:
- - sanity check # CI/commit checks
- - prep # prep work like rebuilding the container images if there is a change
- - build # for actually building and testing things in a container
- - test-suite # for running the test suite in a VM
- - test-suite-no-libwacom # for running the test suite in a VM (libwacom disabled)
- - valgrind # for running the test suite under valgrind in a VM
- - distro # distribs test
- - deploy # trigger wayland's website generation
- - container_clean # clean up unused container images (scheduled jobs only)
- variables:
- ###############################################################################
- # This is the list of packages required to build libinput with the default #
- # configuration. #
- # #
- # Run dnf install/apt-get install/.. with the list of packages for your #
- # distribution #
- # #
- # See the documentation here: #
- # https://wayland.freedesktop.org/libinput/doc/latest/building.html #
- ###############################################################################
- FEDORA_PACKAGES: 'git-core gcc gcc-c++ pkgconf-pkg-config meson check-devel libudev-devel libevdev-devel doxygen graphviz python3-sphinx python3-recommonmark python3-sphinx_rtd_theme python3-pytest-xdist libwacom-devel cairo-devel gtk4-devel glib2-devel mtdev-devel diffutils wayland-protocols-devel black clang clang-tools-extra jq rpmdevtools valgrind systemd-udev qemu-img qemu-system-x86-core qemu-system-aarch64-core jq python3-click python3-rich virtme-ng lua-devel'
- DEBIAN_PACKAGES: 'git gcc g++ pkg-config meson check libudev-dev libevdev-dev doxygen graphviz python3-sphinx python3-recommonmark python3-sphinx-rtd-theme python3-pytest-xdist libwacom-dev libcairo2-dev libgtk-3-dev libglib2.0-dev libmtdev-dev curl lua5.4-dev'
- UBUNTU_PACKAGES: 'git gcc g++ pkg-config meson check libudev-dev libevdev-dev doxygen graphviz python3-sphinx python3-recommonmark python3-sphinx-rtd-theme python3-pytest-xdist libwacom-dev libcairo2-dev libgtk-3-dev libglib2.0-dev libmtdev-dev lua5.4-dev'
- ARCH_PACKAGES: 'git gcc pkgconfig meson check libsystemd libevdev python-pytest-xdist libwacom gtk4 mtdev diffutils lua'
- ALPINE_PACKAGES: 'git gcc build-base pkgconfig meson check-dev eudev-dev libevdev-dev libwacom-dev cairo-dev gtk4.0-dev mtdev-dev bash lua5.4-dev'
- ############################ end of package lists #############################
- # these tags should be updated each time the list of packages is updated
- # changing these will force rebuilding the associated image
- # Note: these tags have no meaning and are not tied to a particular
- # libinput version
- FEDORA_TAG: '2026-01-09.0'
- DEBIAN_TAG: '2026-01-09.0'
- UBUNTU_TAG: '2026-01-09.0'
- ARCH_TAG: '2026-01-09.0'
- ALPINE_TAG: '2026-01-09.0'
- FDO_UPSTREAM_REPO: libinput/libinput
- MESON_BUILDDIR: "build dir"
- NINJA_ARGS: ''
- MESON_ARGS: ''
- MESON_TEST_ARGS: '--no-suite=hardware'
- # udev isn't available/working properly in the containers
- UDEV_NOT_AVAILABLE: 1
- GIT_DEPTH: 1
- # Default priority for non-merge pipelines
- FDO_RUNNER_JOB_PRIORITY_TAG_X86_64: "" # Empty tags are ignored by gitlab
- FDO_RUNNER_JOB_PRIORITY_TAG_X86_64_KVM: kvm
- FDO_RUNNER_JOB_PRIORITY_TAG_AARCH64: aarch64
- .policy:
- retry:
- max: 2
- when:
- - runner_system_failure
- - stuck_or_timeout_failure
- # cancel run when a newer version is pushed to the branch
- interruptible: true
- dependencies: []
- .policy-retry-on-failure:
- retry:
- max: 1
- when:
- - runner_system_failure
- - stuck_or_timeout_failure
- # cancel run when a newer version is pushed to the branch
- interruptible: true
- dependencies: []
- .default_artifacts:
- artifacts:
- name: "meson-logs-$CI_JOB_NAME"
- when: always
- expire_in: 1 week
- paths:
- - $MESON_BUILDDIR/meson-logs
- - $MESON_BUILDDIR/valgrind.*.log
- reports:
- junit: $MESON_BUILDDIR/*junit*.xml
- .fdo-runner-tags:
- tags:
- - $FDO_RUNNER_JOB_PRIORITY_TAG_X86_64
- #################################################################
- # #
- # sanity check stage #
- # #
- #################################################################
- fail-if-fork-is-not-public:
- extends:
- - .fdo-runner-tags
- stage: sanity check
- script:
- - |
- if [ $CI_PROJECT_VISIBILITY != "public" ]; then
- echo "*************************************************************************************"
- echo "Project visibility must be set to 'public'"
- echo "Change this in $CI_PROJECT_URL/edit under 'Visibility, project features, permissions'"
- echo "*************************************************************************************"
- exit 1
- fi
- except:
- - main@libinput/libinput
- # Re-generate the CI script and make sure it's the one currently checked in
- # If this job fails, re-generate the gitlab-ci.yml script, see
- # $SRCDIR/.gitlab-ci/generate-gitlab-ci.py
- #
- check-ci-script:
- extends:
- - .fdo.ci-fairy
- - .fdo-runner-tags
- stage: sanity check
- script:
- - ci-fairy generate-template --verify && exit 0 || true
- - >
- printf "%s\n" \
- "Committed gitlab-ci.yml differs from generated gitlab-ci.yml. Please verify" \
- "https://wayland.freedesktop.org/libinput/doc/latest/contributing.html"
- - exit 1
- #
- # Verify that commit messages are as expected, etc.
- #
- check-commit:
- extends:
- - .fdo.ci-fairy
- - .fdo-runner-tags
- stage: sanity check
- script:
- - ci-fairy -vv check-commits --junit-xml=results.xml && exit 0 || true
- - >
- printf "%s\n" \
- "Error checking commit format. Please verify" \
- "https://wayland.freedesktop.org/libinput/doc/latest/contributing.html"
- - exit 1
- except:
- - main@libinput/libinput
- variables:
- GIT_DEPTH: 100
- artifacts:
- reports:
- junit: results.xml
- #
- # Check for trailing whitespaces
- #
- check-whitespace:
- extends:
- - .fdo.ci-fairy
- - .fdo-runner-tags
- stage: sanity check
- script:
- - .gitlab-ci/whitespace-check.py $(git ls-files)
- #
- # pre-commit hooks
- #
- pre-commit-hooks:
- extends:
- - .fdo.ci-fairy
- - .fdo-runner-tags
- stage: sanity check
- script:
- - python3 -m venv venv
- - source venv/bin/activate
- - pip3 install pre-commit
- - pre-commit run --all-files
- - git diff --exit-code || (echo "ERROR - Code style errors found, please fix" && false)
- #################################################################
- # #
- # prep stage #
- # #
- #################################################################
- fedora:42@container-prep:
- extends:
- - .fdo.container-build@fedora
- - .policy
- - .fdo-runner-tags
- stage: prep
- variables:
- GIT_STRATEGY: none
- FDO_DISTRIBUTION_VERSION: '42'
- FDO_DISTRIBUTION_PACKAGES: $FEDORA_PACKAGES
- FDO_DISTRIBUTION_TAG: $FEDORA_TAG
- fedora:43@container-prep:
- extends:
- - .fdo.container-build@fedora
- - .policy
- - .fdo-runner-tags
- stage: prep
- variables:
- GIT_STRATEGY: none
- FDO_DISTRIBUTION_VERSION: '43'
- FDO_DISTRIBUTION_PACKAGES: $FEDORA_PACKAGES
- FDO_DISTRIBUTION_TAG: $FEDORA_TAG
- debian:stable@container-prep:
- extends:
- - .fdo.container-build@debian
- - .policy
- - .fdo-runner-tags
- stage: prep
- variables:
- GIT_STRATEGY: none
- FDO_DISTRIBUTION_VERSION: 'stable'
- FDO_DISTRIBUTION_PACKAGES: $DEBIAN_PACKAGES
- FDO_DISTRIBUTION_TAG: $DEBIAN_TAG
- ubuntu:25.10@container-prep:
- extends:
- - .fdo.container-build@ubuntu
- - .policy
- - .fdo-runner-tags
- stage: prep
- variables:
- GIT_STRATEGY: none
- FDO_DISTRIBUTION_VERSION: '25.10'
- FDO_DISTRIBUTION_PACKAGES: $UBUNTU_PACKAGES
- FDO_DISTRIBUTION_TAG: $UBUNTU_TAG
- arch:rolling@container-prep:
- extends:
- - .fdo.container-build@arch
- - .policy
- - .fdo-runner-tags
- stage: prep
- variables:
- GIT_STRATEGY: none
- FDO_DISTRIBUTION_VERSION: 'rolling'
- FDO_DISTRIBUTION_PACKAGES: $ARCH_PACKAGES
- FDO_DISTRIBUTION_TAG: $ARCH_TAG
- alpine:latest@container-prep:
- extends:
- - .fdo.container-build@alpine
- - .policy
- - .fdo-runner-tags
- stage: prep
- variables:
- GIT_STRATEGY: none
- FDO_DISTRIBUTION_VERSION: 'latest'
- FDO_DISTRIBUTION_PACKAGES: $ALPINE_PACKAGES
- FDO_DISTRIBUTION_TAG: $ALPINE_TAG
- #################################################################
- # #
- # container clean stage #
- # run during the clean stage #
- # #
- #################################################################
- #
- # This stage will look for the container images we currently have in
- # the registry and will remove any that are not tagged with the provided
- # $container_image:$tag
- #
- .container-clean:
- extends:
- - .policy
- - .fdo.ci-fairy
- - .fdo-runner-tags
- stage: container_clean
- script:
- # Go to your Profile, Settings, Access Tokens
- # Create a personal token with 'api' scope, copy the value.
- # Go to CI/CD, Schedules, schedule a new monthly job (or edit the existing one)
- # Define a variable of type File named AUTHFILE. Content is that token
- # value.
- - ci-fairy -v --authfile $AUTHFILE delete-image
- --repository $FDO_DISTRIBUTION_NAME/$FDO_DISTRIBUTION_VERSION
- --exclude-tag $FDO_DISTRIBUTION_TAG
- allow_failure: true
- only:
- - schedules
- fedora:42@container-clean:
- extends:
- - .policy
- - .container-clean
- variables:
- GIT_STRATEGY: none
- CURRENT_CONTAINER_IMAGE: $CI_REGISTRY_IMAGE/fedora/$FDO_DISTRIBUTION_VERSION:$FDO_DISTRIBUTION_TAG
- FDO_DISTRIBUTION_VERSION: '42'
- FDO_DISTRIBUTION_TAG: $FEDORA_TAG
- fedora:43@container-clean:
- extends:
- - .policy
- - .container-clean
- variables:
- GIT_STRATEGY: none
- CURRENT_CONTAINER_IMAGE: $CI_REGISTRY_IMAGE/fedora/$FDO_DISTRIBUTION_VERSION:$FDO_DISTRIBUTION_TAG
- FDO_DISTRIBUTION_VERSION: '43'
- FDO_DISTRIBUTION_TAG: $FEDORA_TAG
- debian:stable@container-clean:
- extends:
- - .policy
- - .container-clean
- variables:
- GIT_STRATEGY: none
- CURRENT_CONTAINER_IMAGE: $CI_REGISTRY_IMAGE/debian/$FDO_DISTRIBUTION_VERSION:$FDO_DISTRIBUTION_TAG
- FDO_DISTRIBUTION_VERSION: 'stable'
- FDO_DISTRIBUTION_TAG: $DEBIAN_TAG
- ubuntu:25.10@container-clean:
- extends:
- - .policy
- - .container-clean
- variables:
- GIT_STRATEGY: none
- CURRENT_CONTAINER_IMAGE: $CI_REGISTRY_IMAGE/ubuntu/$FDO_DISTRIBUTION_VERSION:$FDO_DISTRIBUTION_TAG
- FDO_DISTRIBUTION_VERSION: '25.10'
- FDO_DISTRIBUTION_TAG: $UBUNTU_TAG
- arch:rolling@container-clean:
- extends:
- - .policy
- - .container-clean
- variables:
- GIT_STRATEGY: none
- CURRENT_CONTAINER_IMAGE: $CI_REGISTRY_IMAGE/arch/$FDO_DISTRIBUTION_VERSION:$FDO_DISTRIBUTION_TAG
- FDO_DISTRIBUTION_VERSION: 'rolling'
- FDO_DISTRIBUTION_TAG: $ARCH_TAG
- alpine:latest@container-clean:
- extends:
- - .policy
- - .container-clean
- variables:
- GIT_STRATEGY: none
- CURRENT_CONTAINER_IMAGE: $CI_REGISTRY_IMAGE/alpine/$FDO_DISTRIBUTION_VERSION:$FDO_DISTRIBUTION_TAG
- FDO_DISTRIBUTION_VERSION: 'latest'
- FDO_DISTRIBUTION_TAG: $ALPINE_TAG
- #################################################################
- # #
- # build stage #
- # #
- #################################################################
- .build@template:
- extends:
- - .policy
- - .default_artifacts
- - .fdo-runner-tags
- stage: build
- script:
- - .gitlab-ci/meson-build.sh
- # Run meson and meson test in the container image through qemu
- .build-in-vng@template:
- extends:
- - .policy
- - .default_artifacts
- tags:
- - $FDO_RUNNER_JOB_PRIORITY_TAG_X86_64_KVM
- variables:
- MESON_BUILDDIR: build_dir
- VNG_KERNEL: https://gitlab.freedesktop.org/api/v4/projects/libevdev%2Fhid-tools/packages/generic/kernel-x86_64/v6.14/bzImage
- script:
- # first build in the host container
- - .gitlab-ci/meson-build.sh --skip-test
- - mkdir -p $MESON_BUILDDIR
- - curl -LO $VNG_KERNEL
- - export -p > .vngenv
- # runs the test suite only
- - |
- vng --run ./bzImage \
- --user root \
- --overlay-rwdir=$HOME \
- --append HOME=$HOME \
- --overlay-rwdir=$(pwd) \
- --rwdir=$MESON_BUILDDIR \
- --exec "source $PWD/.vngenv; rm $PWD/.vngenv; .gitlab-ci/meson-build.sh --skip-setup --skip-build --run-test"
- #
- # Fedora
- #
- .check_tainted: &check_tainted |
- # make sure the kernel is not tainted
- if [[ "$(ssh localhost -p 5555 cat /proc/sys/kernel/tainted)" -gt 0 ]];
- then
- echo tainted kernel ;
- exit 1 ;
- fi
- # Run meson and meson test in the qemu image
- .build-in-qemu@template:
- extends:
- - .policy
- tags:
- - $FDO_RUNNER_JOB_PRIORITY_TAG_X86_64_KVM
- variables:
- MESON_BUILDDIR: build_dir
- script:
- # start our vm, no args required
- - /app/vmctl start || (echo "Error - Failed to start the VM." && exit 1)
- - *check_tainted
- - "scp -r $PWD vm:"
- - echo "CI_JOB_ID=\"$CI_JOB_ID\"" > sshenv
- - echo "CI_JOB_NAME=\"$CI_JOB_NAME\"" >> sshenv
- - echo "MESON_ARGS=\"$MESON_ARGS\"" >> sshenv
- - echo "MESON_BUILDDIR=\"$MESON_BUILDDIR\"" >> sshenv
- - echo "MESON_TEST_ARGS=\"$MESON_TEST_ARGS\"" >> sshenv
- - echo "NINJA_ARGS=\"$NINJA_ARGS\"" >> sshenv
- - "scp sshenv vm:~/$CI_PROJECT_NAME/.meson_environment"
- - /app/vmctl exec "cd $CI_PROJECT_NAME ; .gitlab-ci/meson-build.sh" && touch .success || true
- # no matter the results of the tests, we want to fetch the logs
- - scp -r vm:$CI_PROJECT_NAME/$MESON_BUILDDIR .
- - *check_tainted
- - /app/vmctl stop
- - if [[ ! -e .success ]] ;
- then
- exit 1 ;
- fi
- artifacts:
- name: "qemu-meson-logs-$CI_JOB_NAME"
- when: always
- expire_in: 1 week
- paths:
- - $MESON_BUILDDIR/meson-logs
- - console.out
- reports:
- junit: $MESON_BUILDDIR/*junit*.xml
- # Run in a test suite. Special variables:
- # - SUITES: the meson test suites to run, or
- # - SUITE_NAMES: all elements will be expanded to libinput-test-suite-$value
- # Set one or the other, not both.
- .test-suite-vm:
- extends:
- - .build-in-vng@template
- stage: test-suite
- variables:
- # remove the global --no-suite=hardware
- MESON_TEST_ARGS: ''
- LITEST_JOBS: 4
- before_script:
- - if ! [[ -z $SUITE_NAMES ]]; then SUITES=$(echo $SUITE_NAMES | sed 's/\([^ ]*\)/libinput-test-suite-\1/g'); fi
- - echo "Testing $SUITES"
- - export MESON_TEST_ARGS="$MESON_TEST_ARGS $SUITES"
- .fedora:43@test-suite-vm:
- extends:
- - .fdo.distribution-image@fedora
- - .test-suite-vm
- variables:
- FDO_DISTRIBUTION_VERSION: 43
- FDO_DISTRIBUTION_TAG: $FEDORA_TAG
- needs:
- - "fedora:43@container-prep"
- vm-touchpad:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'touchpad'
- vm-touchpad-no-libwacom:
- extends:
- - vm-touchpad
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-touchpad_palm:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'touchpad_palm'
- vm-touchpad_palm-no-libwacom:
- extends:
- - vm-touchpad_palm
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-touchpad_dwt:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'touchpad_dwt'
- vm-touchpad_dwt-no-libwacom:
- extends:
- - vm-touchpad_dwt
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-tap:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'touchpad_tap'
- vm-tap-no-libwacom:
- extends:
- - vm-tap
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-tap-drag:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'touchpad_tap_drag'
- vm-tap-drag-no-libwacom:
- extends:
- - vm-tap-drag
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-tap-palm:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'touchpad_tap_palm'
- vm-tap-palm-no-libwacom:
- extends:
- - vm-tap-palm
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-touchpad-buttons:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'touchpad_buttons'
- vm-touchpad-buttons-no-libwacom:
- extends:
- - vm-touchpad-buttons
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-tablet:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'tablet'
- vm-tablet-no-libwacom:
- extends:
- - vm-tablet
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-tablet_left_handed:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'tablet_left_handed'
- vm-tablet_left_handed-no-libwacom:
- extends:
- - vm-tablet_left_handed
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-tablet_proximity_tip:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'tablet_proximity tablet_tip'
- vm-tablet_proximity_tip-no-libwacom:
- extends:
- - vm-tablet_proximity_tip
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-tablet_eraser:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'tablet_eraser'
- vm-tablet_eraser-no-libwacom:
- extends:
- - vm-tablet_eraser
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-gestures:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'gestures'
- vm-gestures-no-libwacom:
- extends:
- - vm-gestures
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-backends:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'path udev'
- vm-backends-no-libwacom:
- extends:
- - vm-backends
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-misc:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'log misc quirks device'
- vm-misc-no-libwacom:
- extends:
- - vm-misc
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-other devices:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'keyboard pad switch trackball trackpoint totem touch'
- vm-other devices-no-libwacom:
- extends:
- - vm-other devices
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-pointer:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'pointer'
- vm-pointer-no-libwacom:
- extends:
- - vm-pointer
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-lua:
- extends:
- - .fedora:43@test-suite-vm
- variables:
- SUITE_NAMES: 'lua'
- vm-lua-no-libwacom:
- extends:
- - vm-lua
- stage: test-suite-no-libwacom
- variables:
- MESON_ARGS: '-Dlibwacom=false'
- vm-valgrind-touchpad:
- stage: valgrind
- extends:
- - vm-touchpad
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-touchpad_palm:
- stage: valgrind
- extends:
- - vm-touchpad_palm
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-touchpad_dwt:
- stage: valgrind
- extends:
- - vm-touchpad_dwt
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-tap:
- stage: valgrind
- extends:
- - vm-tap
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-tap-drag:
- stage: valgrind
- extends:
- - vm-tap-drag
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-tap-palm:
- stage: valgrind
- extends:
- - vm-tap-palm
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-touchpad-buttons:
- stage: valgrind
- extends:
- - vm-touchpad-buttons
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-tablet:
- stage: valgrind
- extends:
- - vm-tablet
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-tablet_left_handed:
- stage: valgrind
- extends:
- - vm-tablet_left_handed
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-tablet_proximity_tip:
- stage: valgrind
- extends:
- - vm-tablet_proximity_tip
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-tablet_eraser:
- stage: valgrind
- extends:
- - vm-tablet_eraser
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-gestures:
- stage: valgrind
- extends:
- - vm-gestures
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-backends:
- stage: valgrind
- extends:
- - vm-backends
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-misc:
- stage: valgrind
- extends:
- - vm-misc
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-other devices:
- stage: valgrind
- extends:
- - vm-other devices
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-pointer:
- stage: valgrind
- extends:
- - vm-pointer
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- vm-valgrind-lua:
- stage: valgrind
- extends:
- - vm-lua
- - .policy-retry-on-failure
- variables:
- MESON_TEST_ARGS: '--setup=valgrind'
- LITEST_JOBS: 0
- retry:
- max: 2
- rules:
- - if: $GITLAB_USER_LOGIN != "marge-bot"
- .fedora-build@template:
- extends:
- - .fdo.distribution-image@fedora
- - .build@template
- variables:
- FDO_DISTRIBUTION_VERSION: '43'
- FDO_DISTRIBUTION_TAG: $FEDORA_TAG
- needs:
- - "fedora:43@container-prep"
- default-build-release@fedora:43:
- stage: distro
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Dbuildtype=release"
- CFLAGS: "-Werror"
- clang-tidy@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- NINJA_ARGS: ''
- MESON_TEST_ARGS: ''
- CC: 'clang'
- script:
- - .gitlab-ci/meson-build.sh
- - ninja -C "$MESON_BUILDDIR" clang-tidy
- # Below jobs are build option combinations. We only
- # run them on one image, they shouldn't fail on one distro
- # when they succeed on another.
- build-no-libwacom@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Dlibwacom=false"
- build-no-libwacom-nodeps@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Dlibwacom=false"
- before_script:
- - dnf remove -y libwacom libwacom-devel
- build-no-mtdev@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Dmtdev=false"
- build-no-mtdev-nodeps@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Dmtdev=false"
- before_script:
- - dnf remove -y mtdev mtdev-devel
- build-no-lua@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Dlua-plugins=disabled"
- build-no-lua-nodeps@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Dlua-plugins=disabled"
- before_script:
- - dnf remove -y lua lua-devel
- build-docs@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Ddocumentation=true"
- build-no-docs-nodeps@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Ddocumentation=false"
- before_script:
- - dnf remove -y doxygen graphviz
- build-no-debuggui@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Ddebug-gui=false"
- build-no-debuggui-nodeps@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Ddebug-gui=false"
- before_script:
- - dnf remove -y gtk3-devel gtk4-devel
- build-no-tests@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Dtests=false"
- build-no-tests-nodeps@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_ARGS: "-Dtests=false"
- before_script:
- - dnf remove -y check-devel
- valgrind@fedora:43:
- extends:
- - .fedora-build@template
- variables:
- MESON_TEST_ARGS: '--suite=valgrind --no-suite=hardware --setup=valgrind'
- # Python checks, only run on Fedora
- usr-bin-env-python@fedora:43:
- extends:
- - .fedora-build@template
- script:
- - |
- if git grep -l '^#!/usr/bin/python'; then
- echo "Use '/usr/bin/env python3' in the above files";
- /bin/false
- fi
- # A job to check we're actually running all test suites in the CI
- check-test-suites:
- extends:
- - .fedora-build@template
- script:
- - meson setup builddir
- - meson introspect builddir --test | jq -r '.[].name' | grep 'libinput-test-suite' | sort > meson-testsuites
- - |
- cat <<EOF > ci-testsuites ;
- libinput-test-suite-touchpad
- libinput-test-suite-touchpad_palm
- libinput-test-suite-touchpad_dwt
- libinput-test-suite-touchpad_tap
- libinput-test-suite-touchpad_tap_drag
- libinput-test-suite-touchpad_tap_palm
- libinput-test-suite-touchpad_buttons
- libinput-test-suite-tablet
- libinput-test-suite-tablet_left_handed
- libinput-test-suite-tablet_proximity
- libinput-test-suite-tablet_tip
- libinput-test-suite-tablet_eraser
- libinput-test-suite-gestures
- libinput-test-suite-path
- libinput-test-suite-udev
- libinput-test-suite-log
- libinput-test-suite-misc
- libinput-test-suite-quirks
- libinput-test-suite-device
- libinput-test-suite-keyboard
- libinput-test-suite-pad
- libinput-test-suite-switch
- libinput-test-suite-trackball
- libinput-test-suite-trackpoint
- libinput-test-suite-totem
- libinput-test-suite-touch
- libinput-test-suite-pointer
- libinput-test-suite-lua
- EOF
- - sort -o ci-testsuites ci-testsuites
- - diff -u8 -w ci-testsuites meson-testsuites || (echo "Some test suites are not run in the CI" && false)
- only:
- changes:
- - "meson.build"
- - ".gitlab-ci.yml"
- #
- # coverity run
- #
- # This requires the COVERITY_SCAN_TOKEN. Log into scan.coverity.com and get
- # the token from the respective project settings page.
- # Schedule a pipeline and set a variable COVERITY_SCAN_TOKEN with the token value.
- # https://gitlab.freedesktop.org/$CI_PROJECT_PATH/-/pipeline_schedules
- # Email from coverity will be sent to the GITLAB_USER_EMAIL that scheduled the
- # job.
- #
- # Coverity ratelimits submissions and the coverity tools download is about
- # 700M, do not run this too often.
- #
- coverity:
- extends:
- - .fdo.distribution-image@debian
- - .policy
- - .fdo-runner-tags
- stage: build
- variables:
- FDO_DISTRIBUTION_VERSION: 'stable'
- FDO_DISTRIBUTION_TAG: $DEBIAN_TAG
- # so git-describe works, or should work
- GIT_DEPTH: 200
- only:
- variables:
- - $COVERITY_SCAN_TOKEN
- script:
- - curl https://scan.coverity.com/download/linux64
- -o /tmp/cov-analysis-linux64.tgz
- --form project=$CI_PROJECT_NAME
- --form token=$COVERITY_SCAN_TOKEN
- - tar xfz /tmp/cov-analysis-linux64.tgz
- # coverity has special build options in meson, make sure we enable those
- - meson coverity-build -Ddocumentation=false -Dcoverity=true
- - cov-analysis-linux64-*/bin/cov-build --dir cov-int ninja -C coverity-build
- - tar cfz cov-int.tar.gz cov-int
- - curl https://scan.coverity.com/builds?project=$CI_PROJECT_NAME
- --form token=$COVERITY_SCAN_TOKEN --form email=$GITLAB_USER_EMAIL
- --form file=@cov-int.tar.gz --form version="$(git describe --tags)"
- --form description="$(git describe --tags) / $CI_COMMIT_TITLE / $CI_COMMIT_REF_NAME:$CI_PIPELINE_ID"
- artifacts:
- name: "coverity-submit-data"
- when: always
- expire_in: 1 week
- paths:
- - cov-int.tar.gz
- needs:
- - "debian:stable@container-prep"
- #################################################################
- # #
- # distro stage #
- # #
- #################################################################
- fedora:42@default-build:
- stage: distro
- extends:
- - .build@template
- - .fdo.distribution-image@fedora
- variables:
- FDO_DISTRIBUTION_VERSION: '42'
- FDO_DISTRIBUTION_TAG: $FEDORA_TAG
- needs:
- - "fedora:42@container-prep"
- fedora:43@default-build:
- stage: distro
- extends:
- - .build@template
- - .fdo.distribution-image@fedora
- variables:
- FDO_DISTRIBUTION_VERSION: '43'
- FDO_DISTRIBUTION_TAG: $FEDORA_TAG
- needs:
- - "fedora:43@container-prep"
- debian:stable@default-build:
- stage: distro
- extends:
- - .build@template
- - .fdo.distribution-image@debian
- variables:
- FDO_DISTRIBUTION_VERSION: 'stable'
- FDO_DISTRIBUTION_TAG: $DEBIAN_TAG
- needs:
- - "debian:stable@container-prep"
- ubuntu:25.10@default-build:
- stage: distro
- extends:
- - .build@template
- - .fdo.distribution-image@ubuntu
- variables:
- FDO_DISTRIBUTION_VERSION: '25.10'
- FDO_DISTRIBUTION_TAG: $UBUNTU_TAG
- needs:
- - "ubuntu:25.10@container-prep"
- arch:rolling@default-build:
- stage: distro
- extends:
- - .build@template
- - .fdo.distribution-image@arch
- variables:
- FDO_DISTRIBUTION_VERSION: 'rolling'
- FDO_DISTRIBUTION_TAG: $ARCH_TAG
- MESON_ARGS: '-Ddocumentation=false'
- needs:
- - "arch:rolling@container-prep"
- alpine:latest@default-build:
- stage: distro
- extends:
- - .build@template
- - .fdo.distribution-image@alpine
- variables:
- FDO_DISTRIBUTION_VERSION: 'latest'
- FDO_DISTRIBUTION_TAG: $ALPINE_TAG
- MESON_ARGS: '-Ddocumentation=false' # alpine does not have python-recommonmark
- MESON_TEST_ARGS: '' # litest-selftest fails on musl
- needs:
- - "alpine:latest@container-prep"
- #################################################################
- # #
- # deploy stage #
- # #
- #################################################################
- build rpm:
- extends:
- - .fdo.distribution-image@fedora
- - .policy
- - .fdo-runner-tags
- stage: deploy
- variables:
- FDO_DISTRIBUTION_VERSION: '43'
- FDO_DISTRIBUTION_TAG: $FEDORA_TAG
- needs:
- - "fedora:43@container-prep"
- script:
- - meson "$MESON_BUILDDIR"
- - VERSION=$(meson introspect "$MESON_BUILDDIR" --projectinfo | jq -r .version)
- - sed -e "s/@PIPELINEID@/${CI_PIPELINE_ID}/"
- -e "s/@GITVERSION@/${CI_COMMIT_SHA}/"
- -e "s/@VERSION@/${VERSION}/" .gitlab-ci/libinput.spec.in > libinput.spec
- - git config --local user.name 'gitlab CI'
- - git config --local user.email 'noreply@nowhere'
- - git add libinput.spec && git commit -m 'Add libinput.spec for build testing' libinput.spec
- - cd "$MESON_BUILDDIR"
- - meson dist --no-test
- - rpmbuild -ta meson-dist/libinput*.tar.xz
- wayland-web:
- stage: deploy
- trigger: wayland/wayland.freedesktop.org
- variables:
- MESON_ARGS: '-Ddocumentation=true -Ddebug-gui=false -Dlibwacom=false -Dtests=false'
- MESON_BUILDDIR: 'builddir'
- rules:
- - if: '$CI_PIPELINE_SOURCE == "schedule"'
- when: never
- - if: '$CI_COMMIT_BRANCH == "main" && $GITLAB_USER_LOGIN != "marge-bot" && $CI_PROJECT_PATH == $FDO_UPSTREAM_REPO'
- when: on_success
- - when: never
|