Name: xkeyboard-config-user-hw-extras Version: 0.2.4 Release: 10%{?dist} Summary: XKB extension: user-contributed hardware keyboard models and symbol options License: Apache-2.0 URL: https://gitlab.com/copr-projekte/user-hw-extras Source0: https://gitlab.com/copr-projekte/user-hw-extras/-/archive/%{version}/user-hw-extras-%{version}.tar.gz BuildArch: noarch Requires: libxkbcommon >= 1.13 Requires: xkeyboard-config >= 2.45 Requires: perl-XML-LibXML %package compat Summary: xkbcomp compatibility for user-hw-extras (patches system evdev rules) Requires: %{name} = %{version}-%{release} %description User-contributed XKB extension: hardware keyboard models, geometry definitions, and symbol options not (yet) available in upstream xkeyboard-config. Currently includes: Models: cherrymx20s, cherrymx30s, cherrymxboard30 (Cherry MX family) Option: userhw:type_and_check Registered via libxkbregistry (libxkbcommon >= 1.13). Automatically discovered by KDE Plasma, GNOME Settings, and compatible desktops. %description compat Extends xkbcomp-based tools (keyboard geometry preview, setxkbmap) by: - symlinking userhw XKB data files into the system XKB path - appending model/geometry rules to the system evdev rules and xml files WARNING: This subpackage patches /usr/share/X11/xkb/rules/evdev and neighbouring xml. Backups are kept at %{xkbextdir} and restored on uninstall. This approach most likely is not suitable for upstream inclusion. %define myDir user-hw-extras %define xkbsysdir %{_datadir}/X11/xkb %define xkbextdir %{_datadir}/xkeyboard-config.d/%{myDir} %define handler %{_libexecdir}/%{myDir}/handler.pl %prep %autosetup -n %{name}-%{version} %build # nothing to build %files %dir %{xkbextdir} %file %{handler} %{xkbextdir}/*.extra %doc %{_pkgdocdir}/*.md %files compat %ghost %{xkbextdir}/backup.evdev %ghost %{xkbextdir}/backup.evdev.xml %install install -d %{buildroot}%{xkbextdir} install -m644 *.extra %{buildroot}%{xkbextdir}/ install -d %{buildroot}%{_pkgdocdir}/ install -m644 *.md %{buildroot}%{_pkgdocdir}/ install -d %{buildroot}%{_libexecdir}/%{myDir}/ install -m755 handler.pl %{handler} %post perl %{handler} %{xkbextdir} 0 2 %preun perl %{handler} %{xkbextdir} 0 $1 %post compat perl %{handler} %{xkbextdir} 1 2 %preun compat perl %{handler} %{xkbextdir} 1 $1 %triggerpostun compat -- xkeyboard-config perl %{handler} %{xkbextdir} 1 1 %changelog * Fri May 29 2026 Stefan Kaps - 0.2.4-1 - compat: replace filetriggerin with triggerpostun (filetriggerin path never matched xkeyboard-config RPM db path) - compat: add logger calls for upgrade debugging - compat: fix preun to check $1 — on upgrade ($1=1) do nothing; new %post already handled setup - compat: fix post to check for existing patch before patching — prevents double-application on upgrade - compat: comprehensive logger calls in post/preun/triggerpostun for auditability * Fri May 29 2026 Stefan Kaps - 0.2.3-1 - compat: manage userhw.xml via scriptlet+ghost instead of %install to avoid crossing package boundaries * Fri May 29 2026 Stefan Kaps - 0.2.1-1 - ci: fix autosetup directory name to match GitLab archive structure * Thu May 28 2026 Stefan Kaps - 0.2-1 - Redesign: flat .extra source files, scriptlet-driven XKB structure - Split rules/evdev into evdev_incl + evdev_body - compat: filetriggerin for automatic re-patching after xkeyboard-config updates - compat: backup/restore instead of marker parsing * Thu May 28 2026 Stefan Kaps - 0.1-1 - Initial release