mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2026-01-07 00:40:13 +01:00
gitlab CI: build an rpm package to verify the installed file list
This is not a package intended for, it's a job to fail when we accidentally
change the file list. An rpmbuild job like this was what detected
f15da0f108.
The spec file resembles the Fedora one but has BuildRequires removed (we rely
on the container for that).
The same task could be achieved by keeping a file list and comparing the
installed tree but since I had the rpm spec file already, let's use that for
now.
This requires meson 0.55 which hit F32 yesterday.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
813a458352
commit
b74f03301b
4 changed files with 190 additions and 7 deletions
|
|
@ -84,12 +84,12 @@ variables:
|
|||
# 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: '2020-03-17.0'
|
||||
UBUNTU_TAG: '2020-03-17.0'
|
||||
ARCH_TAG: '2020-03-17.0'
|
||||
ALPINE_TAG: '2020-03-17.0'
|
||||
FREEBSD_TAG: '2020-03-17.0'
|
||||
QEMU_TAG: 'qemu-vm-2020-03-17.0'
|
||||
FEDORA_TAG: '2020-07-22.0'
|
||||
UBUNTU_TAG: '2020-07-22.0'
|
||||
ARCH_TAG: '2020-07-22.0'
|
||||
ALPINE_TAG: '2020-07-22.0'
|
||||
FREEBSD_TAG: '2020-07-22.0'
|
||||
QEMU_TAG: 'qemu-vm-2020-07-22.0'
|
||||
|
||||
UBUNTU_EXEC: "bash .gitlab-ci/ubuntu_install.sh $UBUNTU_CUSTOM_DEBS"
|
||||
|
||||
|
|
@ -905,6 +905,30 @@ freebsd:11.2@default-build:
|
|||
# deploy
|
||||
#
|
||||
|
||||
build rpm:
|
||||
extends:
|
||||
- .fdo.distribution-image@fedora
|
||||
- .policy
|
||||
stage: deploy
|
||||
variables:
|
||||
FDO_DISTRIBUTION_VERSION: '32'
|
||||
FDO_DISTRIBUTION_TAG: $FEDORA_TAG
|
||||
needs:
|
||||
- "fedora:32@container-prep"
|
||||
script:
|
||||
- dnf install -y rpmdevtools jq
|
||||
- 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:
|
||||
image: alpine:latest
|
||||
stage: deploy
|
||||
|
|
|
|||
|
|
@ -675,6 +675,30 @@ freebsd:11.2@default-build:
|
|||
# deploy
|
||||
#
|
||||
|
||||
build rpm:
|
||||
extends:
|
||||
- .fdo.distribution-image@fedora
|
||||
- .policy
|
||||
stage: deploy
|
||||
variables:
|
||||
FDO_DISTRIBUTION_VERSION: '32'
|
||||
FDO_DISTRIBUTION_TAG: $FEDORA_TAG
|
||||
needs:
|
||||
- "fedora:32@container-prep"
|
||||
script:
|
||||
- dnf install -y rpmdevtools jq
|
||||
- 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:
|
||||
image: alpine:latest
|
||||
stage: deploy
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
#
|
||||
|
||||
# We're happy to rebuild all containers when one changes.
|
||||
.default_tag: &default_tag '2020-03-17.0'
|
||||
.default_tag: &default_tag '2020-07-22.0'
|
||||
|
||||
distributions:
|
||||
- name: fedora
|
||||
|
|
|
|||
135
.gitlab-ci/libinput.spec.in
Normal file
135
.gitlab-ci/libinput.spec.in
Normal file
|
|
@ -0,0 +1,135 @@
|
|||
# This specfile should not be used outside the CI
|
||||
# Its main purpose is to sound alarm if files disappear or are added that
|
||||
# weren't intended.
|
||||
|
||||
%global udevdir %(pkg-config --variable=udevdir udev)
|
||||
|
||||
%global pipelineid @PIPELINEID@
|
||||
%global gitversion @GITVERSION@
|
||||
|
||||
Name: libinput
|
||||
Version: @VERSION@
|
||||
Release: %{pipelineid}git%{gitversion}%{?dist}
|
||||
Summary: Input device library
|
||||
|
||||
License: MIT
|
||||
URL: http://www.freedesktop.org/wiki/Software/libinput/
|
||||
Source0: %{name}-%{version}.tar.xz
|
||||
|
||||
# No BuildRequires, we rely on the container setup to have
|
||||
# all the requires installed
|
||||
|
||||
%description
|
||||
libinput is a library that handles input devices for display servers and other
|
||||
applications that need to directly deal with input devices.
|
||||
|
||||
It provides device detection, device handling, input device event processing
|
||||
and abstraction so minimize the amount of custom input code the user of
|
||||
libinput need to provide the common set of functionality that users expect.
|
||||
|
||||
|
||||
%package devel
|
||||
Summary: Development files for %{name}
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
|
||||
%description devel
|
||||
The %{name}-devel package contains libraries and header files for
|
||||
developing applications that use %{name}.
|
||||
|
||||
%package utils
|
||||
Summary: Utilities and tools for debugging %{name}
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
Requires: python3-pyudev python3-libevdev
|
||||
|
||||
%description utils
|
||||
The %{name}-utils package contains tools to debug hardware and analyze
|
||||
%{name}.
|
||||
|
||||
%package test
|
||||
Summary: libinput integration test suite
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
|
||||
%description test
|
||||
The %{name}-test package contains the libinput test suite. It is not
|
||||
intended to be run by users.
|
||||
|
||||
%prep
|
||||
%autosetup -S git -n %{name}-%{version}
|
||||
|
||||
%build
|
||||
%meson -Dtests=true \
|
||||
-Dinstall-tests=true \
|
||||
-Dudev-dir=%{udevdir}
|
||||
%meson_build
|
||||
|
||||
%install
|
||||
%meson_install
|
||||
|
||||
%post
|
||||
%{?ldconfig}
|
||||
|
||||
%ldconfig_postun
|
||||
|
||||
|
||||
%files
|
||||
%doc COPYING
|
||||
%{_libdir}/libinput.so.*
|
||||
%{udevdir}/libinput-device-group
|
||||
%{udevdir}/libinput-fuzz-extract
|
||||
%{udevdir}/libinput-fuzz-to-zero
|
||||
%{udevdir}/rules.d/80-libinput-device-groups.rules
|
||||
%{udevdir}/rules.d/90-libinput-fuzz-override.rules
|
||||
%{_bindir}/libinput
|
||||
%dir %{_libexecdir}/libinput/
|
||||
%{_libexecdir}/libinput/libinput-debug-events
|
||||
%{_libexecdir}/libinput/libinput-list-devices
|
||||
%{_mandir}/man1/libinput.1*
|
||||
%{_datadir}/libinput/*.quirks
|
||||
%dir %{_datadir}/zsh
|
||||
%dir %{_datadir}/zsh/site-functions
|
||||
%{_datadir}/zsh/site-functions/*
|
||||
%{_mandir}/man1/libinput-list-devices.1*
|
||||
%{_mandir}/man1/libinput-debug-events.1*
|
||||
|
||||
%files devel
|
||||
%{_includedir}/libinput.h
|
||||
%{_libdir}/libinput.so
|
||||
%{_libdir}/pkgconfig/libinput.pc
|
||||
|
||||
%files utils
|
||||
%{_libexecdir}/libinput/libinput-debug-gui
|
||||
%{_libexecdir}/libinput/libinput-debug-tablet
|
||||
%{_libexecdir}/libinput/libinput-measure
|
||||
%{_libexecdir}/libinput/libinput-measure-fuzz
|
||||
%{_libexecdir}/libinput/libinput-measure-touchpad-tap
|
||||
%{_libexecdir}/libinput/libinput-measure-touchpad-pressure
|
||||
%{_libexecdir}/libinput/libinput-measure-touch-size
|
||||
%{_libexecdir}/libinput/libinput-measure-touchpad-size
|
||||
%{_libexecdir}/libinput/libinput-quirks
|
||||
%{_libexecdir}/libinput/libinput-record
|
||||
%{_libexecdir}/libinput/libinput-replay
|
||||
%{_libexecdir}/libinput/libinput-analyze
|
||||
%{_libexecdir}/libinput/libinput-analyze-per-slot-delta
|
||||
%{_mandir}/man1/libinput-debug-gui.1*
|
||||
%{_mandir}/man1/libinput-debug-tablet.1*
|
||||
%{_mandir}/man1/libinput-measure.1*
|
||||
%{_mandir}/man1/libinput-measure-fuzz.1*
|
||||
%{_mandir}/man1/libinput-measure-touchpad-tap.1*
|
||||
%{_mandir}/man1/libinput-measure-touch-size.1*
|
||||
%{_mandir}/man1/libinput-measure-touchpad-size.1*
|
||||
%{_mandir}/man1/libinput-measure-touchpad-pressure.1*
|
||||
%{_mandir}/man1/libinput-quirks.1*
|
||||
%{_mandir}/man1/libinput-quirks-list.1*
|
||||
%{_mandir}/man1/libinput-quirks-validate.1*
|
||||
%{_mandir}/man1/libinput-record.1*
|
||||
%{_mandir}/man1/libinput-replay.1*
|
||||
%{_mandir}/man1/libinput-analyze.1*
|
||||
%{_mandir}/man1/libinput-analyze-per-slot-delta.1*
|
||||
|
||||
%files test
|
||||
%{_libexecdir}/libinput/libinput-test-suite
|
||||
%{_mandir}/man1/libinput-test-suite.1*
|
||||
|
||||
%changelog
|
||||
* Wed Jul 15 2020 Peter Hutterer <peter.hutterer@redhat.com>
|
||||
- Add basic spec file for package build testing
|
||||
Loading…
Add table
Reference in a new issue