Move to version 0.10.8
- Use systemd interaction macros in specfile installation sections [RH BZ 850053]. - Fix the service file to use /usr/sbin/ rather than /sbin/. - Turn on RELRO and PIE build hardening in RPM builds.
This commit is contained in:
parent
c91df93eef
commit
ba912d68c4
@ -1,7 +1,7 @@
|
||||
# % define buildid .local
|
||||
|
||||
Name: cachefilesd
|
||||
Version: 0.10.7
|
||||
Version: 0.10.8
|
||||
Release: 1%{?dist}%{?buildid}
|
||||
Summary: CacheFiles user-space management daemon
|
||||
Group: System Environment/Daemons
|
||||
@ -15,6 +15,8 @@ Requires(preun): systemd-units
|
||||
Requires(postun): systemd-units
|
||||
Requires: selinux-policy-base >= 3.7.19-5
|
||||
|
||||
%define _hardened_build 1
|
||||
|
||||
%description
|
||||
The cachefilesd daemon manages the caching files and directory that are that
|
||||
are used by network file systems such a AFS and NFS to do persistent caching to
|
||||
@ -26,19 +28,11 @@ the local disk.
|
||||
%setup -q
|
||||
|
||||
%build
|
||||
%ifarch s390 s390x
|
||||
PIE="-fPIE"
|
||||
%else
|
||||
PIE="-fpie"
|
||||
%endif
|
||||
export PIE
|
||||
CFLAGS="`echo $RPM_OPT_FLAGS $ARCH_OPT_FLAGS $PIE`"
|
||||
|
||||
make all \
|
||||
ETCDIR=%{_sysconfdir} \
|
||||
SBINDIR=%{_sbindir} \
|
||||
MANDIR=%{_mandir} \
|
||||
CFLAGS="-Wall $RPM_OPT_FLAGS -Werror"
|
||||
CFLAGS="-Wall -Werror $RPM_OPT_FLAGS $RPM_LD_FLAGS $ARCH_OPT_FLAGS"
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}%{_sbindir}
|
||||
@ -55,24 +49,13 @@ install -m 644 cachefilesd.conf %{buildroot}%{_sysconfdir}
|
||||
install -m 644 cachefilesd.service %{buildroot}%{_unitdir}/cachefilesd.service
|
||||
|
||||
%post
|
||||
if [ $1 -eq 1 ] ; then
|
||||
# Initial installation
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
%systemd_post cachefilesd.service
|
||||
|
||||
%preun
|
||||
if [ $1 -eq 0 ] ; then
|
||||
# Package removal, not upgrade
|
||||
/bin/systemctl --no-reload disable cachefilesd.service > /dev/null 2>&1 || :
|
||||
/bin/systemctl stop cachefilesd.service > /dev/null 2>&1 || :
|
||||
fi
|
||||
%systemd_preun cachefilesd.service
|
||||
|
||||
%postun
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
if [ $1 -ge 1 ] ; then
|
||||
# Package upgrade, not uninstall
|
||||
/bin/systemctl try-restart cachefilesd.service >/dev/null 2>&1 || :
|
||||
fi
|
||||
%systemd_postun_with_restart cachefilesd.service
|
||||
|
||||
%files
|
||||
%doc README
|
||||
@ -88,6 +71,11 @@ fi
|
||||
%{_localstatedir}/cache/fscache
|
||||
|
||||
%changelog
|
||||
* Wed Feb 17 2016 David Howells <dhowells@redhat.com> 0.10.8-1
|
||||
- Use systemd interaction macros in specfile installation sections [RH BZ 850053].
|
||||
- Fix the service file to use /usr/sbin/ rather than /sbin/.
|
||||
- Turn on RELRO and PIE build hardening in RPM builds.
|
||||
|
||||
* Wed Feb 3 2016 David Howells <dhowells@redhat.com> 0.10.7-1
|
||||
- Call setgroups() before calling setuid() (caught by rpmlint).
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user