- require initscripts for post/postun

This commit is contained in:
Florian La Roche 2006-07-19 22:27:17 +00:00
parent 6a006832ce
commit 65eb3c1136

View File

@ -4,7 +4,7 @@
Name: ccid
Version: 1.0.1
Release: 4
Release: 5
Summary: Generic USB CCID smart card reader driver
Group: System Environment/Libraries
@ -15,6 +15,8 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: libusb-devel >= %{libusb_ver}
BuildRequires: pcsc-lite-devel >= %{pcsc-lite_ver}
Requires(post): initscripts
Requires(postun): initscripts
Requires: libusb >= %{libusb_ver}
Requires: pcsc-lite >= %{pcsc-lite_ver}
Provides: pcsc-ifd-handler
@ -51,11 +53,13 @@ rm -rf $RPM_BUILD_ROOT
%post
if [ $1 -eq 1 -a -x %{_initrddir}/pcscd ] ; then
%{_initrddir}/pcscd try-restart >/dev/null || :
%{_initrddir}/pcscd try-restart >/dev/null
fi
exit 0
%postun
[ -x %{_initrddir}/pcscd ] && %{_initrddir}/pcscd try-restart >/dev/null || :
[ -x %{_initrddir}/pcscd ] && %{_initrddir}/pcscd try-restart >/dev/null
exit 0
%files