%define lib_major 10 # The naming scheme in non-Mandriva-based distros %if 0%{!?mklibname:1} %define mklibname(ds) lib%{1}%{?2:%{2}}%{-s:-static}%{-d:-devel} %endif %if 0%{!?mkrel:1} %define mkrel(c) %{1}%{?dist} %endif %define lib_name %mklibname input %{lib_major} %define develname %mklibname input -d Name: libinput Version: 1.27.0 Release: 1%{?dist} Summary: Input device library License: MIT Group: System/Libraries URL: https://gitlab.freedesktop.org/libinput/libinput/-/releases Source0: https://gitlab.freedesktop.org/%{name}/%{name}/-/archive/%{version}/%{name}-%{version}.tar.bz2 BuildRequires: meson BuildRequires: pkgconfig(libudev) BuildRequires: pkgconfig(mtdev) >= 1.1.0 BuildRequires: pkgconfig(libevdev) >= 0.4 BuildRequires: pkgconfig(libwacom) >= 0.20 BuildRequires: python3-devel BuildRequires: check-devel %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 -n %{lib_name} Summary: Libraries for libinput Group: System/Libraries Requires: libinput-udev %description -n %{lib_name} 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 -n %{develname} Summary: Development files for %{name} Group: Development/X11 Provides: %{name}-devel = %{version}-%{release} Requires: %{lib_name} = %{version} %description -n %{develname} The %{develname} package contains libraries and header files for developing applications that use %{name}. %package tools Summary: Tools for libinput Group: System/Base %description tools 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. This package contains the libinput tools. %package udev Summary: Tools for libinput Group: System/Base %description udev 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. This package contains the udev rules for libinput. %package test Summary: libinput integration test suite Requires: %{lib_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 -p1 %build %meson -Ddebug-gui=false \ -Ddocumentation=false \ -Dtests=true \ -Dinstall-tests=true \ %meson_build %install %meson_install %files tools %{_bindir}/* %dir %{_libexecdir}/libinput/ %{_libexecdir}/libinput/libinput-debug-events %{_libexecdir}/libinput/libinput-list-devices %{_libexecdir}/libinput/libinput-list-kernel-devices %{_mandir}/man1/libinput.1* %dir %{_datadir}/zsh %dir %{_datadir}/zsh/site-functions %{_datadir}/zsh/site-functions/* %{_mandir}/man1/libinput-list-devices.1* %{_mandir}/man1/libinput-list-kernel-devices.1* %{_mandir}/man1/libinput-debug-events.1* %{_libexecdir}/libinput/libinput-analyze %{_libexecdir}/libinput/libinput-analyze-buttons %{_libexecdir}/libinput/libinput-analyze-per-slot-delta %{_libexecdir}/libinput/libinput-analyze-recording %{_libexecdir}/libinput/libinput-analyze-touch-down-state %{_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-touchpad-size %{_libexecdir}/libinput/libinput-measure-touch-size %{_libexecdir}/libinput/libinput-quirks %{_libexecdir}/libinput/libinput-record %{_libexecdir}/libinput/libinput-replay %{_libexecdir}/libinput/libinput-test %{_libexecdir}/libinput/libinput-test-utils %{_mandir}/man1/libinput-analyze.1* %{_mandir}/man1/libinput-analyze-buttons.1* %{_mandir}/man1/libinput-analyze-per-slot-delta.1* %{_mandir}/man1/libinput-analyze-recording.1* %{_mandir}/man1/libinput-analyze-touch-down-state.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-pressure.1* %{_mandir}/man1/libinput-measure-touchpad-size.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* %files udev %{_udevrulesdir}/* /usr/lib/udev/libinput-device-group /usr/lib/udev/libinput-fuzz-extract /usr/lib/udev/libinput-fuzz-to-zero %{_datadir}/libinput/*.quirks %files -n %{lib_name} %{_libdir}/*.so.%{lib_major}{,.*} %files -n %{develname} %doc README.md COPYING %{_includedir}/libinput.h %{_libdir}/libinput.so %{_libdir}/pkgconfig/libinput.pc %files test %{_libexecdir}/libinput/libinput-test %{_libexecdir}/libinput/libinput-test-suite %{_mandir}/man1/libinput-test.1* %{_mandir}/man1/libinput-test-suite.1*