rm -rf $RPM_BUILD_ROOT
%post
-NAME=svscan; DESC="svscan daemon"; %chkconfig_add
+/sbin/chkconfig --add svscan
+if [ -f /var/lock/subsys/svscan ]; then
+ /etc/rc.d/init.d/svscan restart >&2
+else
+ echo "Execute \"/etc/rc.d/init.d/svscan\" to start svscan daemon."
+fi
%preun
-NAME=svscan; %chkconfig_del
+if [ "$1" = "0" ]; then
+ if [ -f /var/lock/subsys/svscan ]; then
+ /etc/rc.d/init.d/svscan stop >&2
+ fi
+ /sbin/chkconfig --del svscan
+fi
%files
%defattr(644,root,root,755)