diff --git a/fcoe-utils-1.0.8-init-LSB.patch b/fcoe-utils-1.0.8-init-LSB.patch new file mode 100644 index 0000000..3c677e9 --- /dev/null +++ b/fcoe-utils-1.0.8-init-LSB.patch @@ -0,0 +1,34 @@ +--- fcoe-utils-1.0.8/etc/initd/initd.fedora.orig 2009-09-14 09:40:57.000000000 +0200 ++++ fcoe-utils-1.0.8/etc/initd/initd.fedora 2009-09-14 11:06:34.000000000 +0200 +@@ -231,11 +231,13 @@ + + service_status() + { ++ status=0 + pidof $FCOEMON + if [ $? -eq 0 ]; then + echo "$FCOEMON -- RUNNING, pid=`cat $PID_FILE`" + else + echo "$FCOEMON -- UNUSED" ++ status=3 + fi + IF_LIST=`$FCOEADM -i 2>&1 | \ + awk '/Symbolic Name:/{print $6}' | \ +@@ -244,9 +246,15 @@ + echo "No interfaces created." + else + echo "Created interfaces: $IF_LIST" ++ status=0 + fi +- test -f /var/lock/subsys/fcoe +- return $@ ++ if [ -f /var/lock/subsys/fcoe -a $status -eq 3 ]; then ++ status=2 ++ fi ++ if [ -f /var/run/fcoe.pid -a $status -eq 3 ]; then ++ status=1 ++ fi ++ return $status + } + + case "$1" in diff --git a/fcoe-utils.spec b/fcoe-utils.spec index 0573802..dda33f8 100644 --- a/fcoe-utils.spec +++ b/fcoe-utils.spec @@ -1,6 +1,6 @@ Name: fcoe-utils Version: 1.0.8 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Fibre Channel over Ethernet utilities Group: Applications/System @@ -16,6 +16,7 @@ Source1: quickstart.txt Patch0: fcoe-utils-1.0.7-init.patch Patch1: fcoe-utils-1.0.7-init-condrestart.patch Patch2: fcoe-utils-1.0.8-includes.patch +Patch3: fcoe-utils-1.0.8-init-LSB.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: libhbaapi-devel dcbd-devel libtool automake kernel-devel @@ -34,6 +35,7 @@ fcoemon - service to configure DCB Ethernet QOS filters, works with dcbd %patch0 -p1 -b .initPatch %patch1 -p1 -b .condrestartPatch %patch2 -p1 -b .includes-fix +%patch3 -p1 -b .initLSB %build ./bootstrap.sh @@ -96,6 +98,9 @@ fi %changelog +* Mon Sep 14 2009 Jan Zeleny - 1.0.8-3 +- update of init script to be LSB-compliant + * Fri Jul 31 2009 Jan Zeleny - 1.0.8-2 - patch for clean compilation without usage of upstream's ugly hack