diff options
author | Clark Williams <williams@redhat.com> | 2020-08-28 12:14:48 -0500 |
---|---|---|
committer | Clark Williams <williams@redhat.com> | 2020-08-28 12:14:48 -0500 |
commit | 91b36ebf1b7f60d698eede88bd2ebab19c4c2236 (patch) | |
tree | 096331ebfa92b8ab47f928122a4bebab02af772c | |
parent | dbc6ad1fb63f3160f41057fae944129c50fda7f9 (diff) | |
download | stalld-91b36ebf1b7f60d698eede88bd2ebab19c4c2236.tar.gz |
redhat/stalld.spec: address requires and build review concerns
Added BuildRequires for: gcc make systemd-rpm-macros
Fixed install section make invocations, using %make_install macro
Fix systemd presets using systemd macros in %post, %preun, %postun
sections
Signed-off-by: Clark Williams <williams@redhat.com>
-rw-r--r-- | redhat/stalld.spec | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/redhat/stalld.spec b/redhat/stalld.spec index a8480d6..29432de 100644 --- a/redhat/stalld.spec +++ b/redhat/stalld.spec @@ -7,7 +7,7 @@ License: GPLv2 URL: https://git.kernel.org/pub/scm/utils/stalld/stalld.git Source0: https://jcwillia.fedorapeople.org/%{name}-%{version}.tar.xz -BuildRequires: glibc-devel +BuildRequires: glibc-devel gcc make systemd-rpm-macros Requires: systemd %description @@ -21,15 +21,12 @@ allow 10 microseconds of runtime for 1 second of clock time. %prep %autosetup - %build %make_build - %install -rm -rf $RPM_BUILD_ROOT -make DESTDIR=$RPM_BUILD_ROOT install -make DESTDIR=$RPM_BUILD_ROOT -C redhat install +%make_install +%make_install -C redhat %files %{_bindir}/%{name} @@ -38,6 +35,15 @@ make DESTDIR=$RPM_BUILD_ROOT -C redhat install %doc %{_datadir}/%{name}-%{version}/README.md %doc %{_datadir}/man/man8/stalld.8.gz +%post +%systemd_post %{name}.service + +%preun +%systemd_preun %{name}.service + +%postun +%systemd_postun_with_restart %{name}.service + %changelog * Tue Aug 25 2020 williams@redhat,com - 1.0-1 - rename project to stalld |