From 1dd2c4eb28cbfc56f1634d19426d4e2a4f5066f8 Mon Sep 17 00:00:00 2001 From: Carl George Date: Oct 06 2021 00:55:20 +0000 Subject: Patch unit file to start after multi-user.target https://github.com/PixlOne/logiops/issues/204 --- diff --git a/0001-Fix-systemd-denepdency.patch b/0001-Fix-systemd-denepdency.patch new file mode 100644 index 0000000..ba331ca --- /dev/null +++ b/0001-Fix-systemd-denepdency.patch @@ -0,0 +1,32 @@ +From 5947cc939eed6891e8008943c9538e662f4218ae Mon Sep 17 00:00:00 2001 +From: Haochuan Guo +Date: Sun, 16 May 2021 13:30:48 +0800 +Subject: [PATCH] Fix systemd denepdency + +Let logiops start after multi-user.target is reached, and change it as a dependency to `graphical.target`. Fix #204 +--- + src/logid/logid.service.cmake | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/src/logid/logid.service.cmake b/src/logid/logid.service.cmake +index 4108a27..dd4e09b 100644 +--- a/src/logid/logid.service.cmake ++++ b/src/logid/logid.service.cmake +@@ -1,6 +1,8 @@ + [Unit] + Description=Logitech Configuration Daemon + StartLimitIntervalSec=0 ++After=multi-user.target ++Wants=multi-user.target + + [Service] + Type=simple +@@ -10,4 +12,4 @@ ExecReload=/bin/kill -HUP $MAINPID + Restart=on-failure + + [Install] +-WantedBy=multi-user.target ++WantedBy=graphical.target +-- +2.31.1 + diff --git a/logiops.spec b/logiops.spec index 454ad06..9a8f9d3 100644 --- a/logiops.spec +++ b/logiops.spec @@ -1,6 +1,6 @@ Name: logiops Version: 0.2.3 -Release: 7%{?dist} +Release: 8%{?dist} Summary: Unofficial driver for Logitech mice and keyboard License: GPLv3 @@ -8,6 +8,9 @@ URL: https://github.com/PixlOne/logiops Source0: https://github.com/PixlOne/logiops/archive/v%{version}/%{name}-%{version}.tar.gz +# https://github.com/PixlOne/logiops/issues/204 +Patch0: 0001-Fix-systemd-denepdency.patch + BuildRequires: cmake BuildRequires: systemd-devel BuildRequires: systemd-udev @@ -23,7 +26,7 @@ This is an unofficial driver for Logitech mice and keyboard. This is currently only compatible with HID++ >2.0 devices. %prep -%setup -q -n %{name}-%{version} +%autosetup -p 1 %build %{cmake} @@ -50,6 +53,9 @@ This is currently only compatible with HID++ >2.0 devices. %doc logid.example.cfg %changelog +* Wed Oct 06 2021 Carl George - 0.2.3-8 +- Patch unit file to start after multi-user.target + * Thu Jul 22 2021 Fedora Release Engineering - 0.2.3-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild