diff --git a/apcupsd-3.10.18-init.patch b/apcupsd-3.10.18-init.patch deleted file mode 100644 index 9c36f93..0000000 --- a/apcupsd-3.10.18-init.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- apcupsd-3.10.18/platforms/redhat/apcupsd.in.orig 2005-01-09 15:55:41.000000000 -0700 -+++ apcupsd-3.10.18/platforms/redhat/apcupsd.in 2005-10-31 10:35:05.000000000 -0700 -@@ -3,7 +3,7 @@ - # apcupsd This shell script takes care of starting and stopping - # the apcupsd UPS monitoring daemon. - # --# chkconfig: 2345 60 99 -+# chkconfig: - 60 99 - # description: apcupsd monitors power and takes action if necessary - # - APCPID=@PIDDIR@/apcupsd.pid -@@ -42,7 +42,7 @@ - rm -f $APCPID - rm -f @LOCKDIR@/subsys/apcupsd - ;; -- restart) -+ restart|reload) - $0 stop - sleep 15 - $0 start diff --git a/apcupsd-3.14.0-init.patch b/apcupsd-3.14.0-init.patch new file mode 100644 index 0000000..86062d9 --- /dev/null +++ b/apcupsd-3.14.0-init.patch @@ -0,0 +1,38 @@ +--- apcupsd-3.14.0/platforms/redhat/apcupsd.in.init 2005-01-09 15:55:41.000000000 -0700 ++++ apcupsd-3.14.0/platforms/redhat/apcupsd.in 2007-04-23 12:13:35.000000000 -0600 +@@ -3,7 +3,7 @@ + # apcupsd This shell script takes care of starting and stopping + # the apcupsd UPS monitoring daemon. + # +-# chkconfig: 2345 60 99 ++# chkconfig: - 60 99 + # description: apcupsd monitors power and takes action if necessary + # + APCPID=@PIDDIR@/apcupsd.pid +@@ -42,13 +42,24 @@ + rm -f $APCPID + rm -f @LOCKDIR@/subsys/apcupsd + ;; +- restart) ++ restart|force-reload) + $0 stop + sleep 15 + $0 start + ;; ++ reload) ++ echo "$0: reload not implemented" ++ exit 3 ++ ;; + status) +- @sbindir@/apcaccess status ++ status apcupsd ++ RETVAL=$? ++ if [ $RETVAL -eq 0 ] ++ then ++ @sbindir@/apcaccess status ++ else ++ exit $RETVAL ++ fi + ;; + *) + echo "Usage: $0 {start|stop|restart|status}" diff --git a/apcupsd.spec b/apcupsd.spec index 622b8ef..049d6f6 100644 --- a/apcupsd.spec +++ b/apcupsd.spec @@ -1,6 +1,6 @@ Name: apcupsd Version: 3.14.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: APC UPS Power Control Daemon for Linux Group: System Environment/Daemons @@ -9,7 +9,7 @@ URL: http://www.apcupsd.com Source0: http://download.sourceforge.net/apcupsd/%{name}-%{version}.tar.gz Source1: apcupsd.logrotate Source2: apcupsd-httpd.conf -Patch0: apcupsd-3.10.18-init.patch +Patch0: apcupsd-3.14.0-init.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: glibc-devel >= 2.3, gd-devel > 2.0 @@ -168,6 +168,9 @@ fi %changelog +* Mon Apr 23 2007 - Orion Poplawski - 3.14.0-2 +- Fix init script for LSB compliance (bug #237532) + * Fri Mar 23 2007 - Orion Poplawski - 3.14.0-1 - Update to 3.14.0 - No tcp_wrappers-devel in EL