diff --git a/keepalived.changes b/keepalived.changes index b25215c..34d9b5b 100644 --- a/keepalived.changes +++ b/keepalived.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Mon Apr 30 14:41:46 UTC 2018 - crrodriguez@opensuse.org + +- Only Require insserv on distributions without systemd. +- Fix systemd related requires/buildRequires +- Do not run scriptlets that use insserv when using systemd + ------------------------------------------------------------------- Thu Feb 22 10:07:17 UTC 2018 - dmueller@suse.com diff --git a/keepalived.spec b/keepalived.spec index 4ab8daa..1f7a27a 100644 --- a/keepalived.spec +++ b/keepalived.spec @@ -33,7 +33,7 @@ Name: keepalived Version: 1.4.1 Release: 0 Summary: A keepalive facility for Linux -License: GPL-2.0+ +License: GPL-2.0-or-later Group: Productivity/Networking/Routing Url: http://www.keepalived.org/ Source: http://www.keepalived.org/software/%{name}-%{version}.tar.gz @@ -72,11 +72,12 @@ BuildRequires: popt-devel BuildRequires: cyrus-sasl-devel %endif Requires(pre): pwdutils -Requires(pre): %insserv_prereq Requires(pre): %fillup_prereq %if %{with systemd} -BuildRequires: systemd -Requires: systemd +BuildRequires: systemd-rpm-macros +%{?systemd_requires} +%else +Requires(pre): %insserv_prereq %endif BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -168,9 +169,10 @@ getent passwd %{name} >/dev/null || \ %endif %preun -%stop_on_removal %{name} %if %{with systemd} %service_del_preun %{name}.service +%else +%stop_on_removal %{name} %endif %post @@ -180,10 +182,11 @@ getent passwd %{name} >/dev/null || \ %endif %postun -%insserv_cleanup -%restart_on_update %{name} %if %{with systemd} %service_del_postun %{name}.service +%else +%insserv_cleanup +%restart_on_update %{name} %endif %files