# # spec file for package ydotool # # Copyright (c) 2025 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via https://bugs.opensuse.org/ # Name: ydotool Version: 1.0.4 Release: 2.5 Summary: Generic command-line automation tool (no X!) License: AGPL-3.0-only URL: https://github.com/ReimuNotMoe/ydotool Source: https://github.com/ReimuNotMoe/ydotool/archive/v1.0.4.tar.gz#/ydotool-1.0.4.tar.gz Source1: 80-ydotool.rules Source2: ydotool.modules-load.conf Patch0: ydotool-service.patch BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: cmake BuildRequires: scdoc BuildRequires: systemd-rpm-macros %description ydotool is not limited to Wayland. You can use it on anything as long as it accepts keyboard/mouse/whatever input. For example, X11, text console, "RetroArch OS", fbdev apps (fbterm/mplayer/SDL1/LittleVGL/Qt Embedded), etc. %prep %autosetup -p1 %build %cmake -DCMAKE_POLICY_VERSION_MINIMUM=3.5 %cmake_build %install %cmake_install install -D -p -m 0644 %{SOURCE1} %{buildroot}%{_udevrulesdir}/80-%{name}.rules install -D -p -m 0644 %{SOURCE2} %{buildroot}%{_modulesloaddir}/%{name}.conf %check %ctest %post %systemd_user_post %{name}.service udevadm control --reload-rules >/dev/null 2>&1 || : udevadm trigger /dev/uinput >/dev/null 2>&1 || : %preun %systemd_user_preun %{name}.service %postun %systemd_user_postun_with_restart %{name}.service %files %license LICENSE %doc README.md %{_bindir}/%{name} %{_bindir}/%{name}d %{_userunitdir}/%{name}.service %{_udevrulesdir}/80-%{name}.rules %{_modulesloaddir}/%{name}.conf %{_mandir}/man1/%{name}.1* %{_mandir}/man8/%{name}d.8* %changelog * Sat Sep 26 2026 Shawn Dunn - 1.0.4-2.5 - Patch ydotool user service to match desired parameters (sleep delay, restart policy) - Add udev rule and modules-load config for /dev/uinput access * Fri Mar 21 2025 Shawn Dunn - Add -DCMAKE_POLICY_VERSION_MINIMUM=3.5 to fix FTBFS with cmake4 - Add %%check section * Tue Aug 8 2023 Dawid Adam - Initial packaging ydotool v1.0.4