From 9e6f8f8e09cfc3d193a1a89558e94f1b73a363da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20=C5=A0abata?= Date: Thu, 24 Nov 2011 15:13:00 +0100 Subject: [PATCH] 1.0.21 bump --- .gitignore | 1 + fcoe-utils-1.0.20-init.patch | 111 ----------------------------------- fcoe-utils.spec | 10 ++-- sources | 2 +- 4 files changed, 8 insertions(+), 116 deletions(-) delete mode 100644 fcoe-utils-1.0.20-init.patch diff --git a/.gitignore b/.gitignore index 587081f..e509bf2 100644 --- a/.gitignore +++ b/.gitignore @@ -33,3 +33,4 @@ fcoe-utils-*.rpm /fcoe-utils-1.0.18.tar.bz2 /fcoe-utils-1.0.19.tar.bz2 /fcoe-utils-1.0.20.tar.bz2 +/fcoe-utils-1.0.21.tar.bz2 diff --git a/fcoe-utils-1.0.20-init.patch b/fcoe-utils-1.0.20-init.patch deleted file mode 100644 index 8f493c0..0000000 --- a/fcoe-utils-1.0.20-init.patch +++ /dev/null @@ -1,111 +0,0 @@ -diff --git a/etc/initd/initd.fedora b/etc/initd/initd.fedora -index 5c84e25..f3f3d91 100755 ---- a/etc/initd/initd.fedora -+++ b/etc/initd/initd.fedora -@@ -15,7 +15,7 @@ - # this program; if not, write to the Free Software Foundation, Inc., - # 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA. - # --# chkconfig: - 21 80 -+# chkconfig: 2345 21 80 - # - # Maintained at www.Open-FCoE.org - -@@ -23,7 +23,7 @@ - # Provides: fcoe - # Required-Start: network - # Required-Stop: --# Default-Start: -+# Default-Start: 2 3 4 5 - # Default-Stop: - # Short-Description: Open-FCoE Initiator - # Description: Open-FCoE Initiator -@@ -63,6 +63,16 @@ test -x $FCOEMON || { - fi - } - -+have_fcoe_root() { -+ # This simply checks if root is on a net device -+ local rootopts=$(awk '{ if ($1 !~ /^[ \t]*#/ && $2 == "/") { print $4; }}' /etc/mtab) -+ if [[ "$rootopts" =~ "_netdev" ]]; then -+ return 0 -+ else -+ return 1 -+ fi -+} -+ - start() - { - echo -n $"Starting FCoE initiator service: " -@@ -75,26 +85,59 @@ start() - echo - touch /var/lock/subsys/fcoe - -+ # Wait for the _netdev devices -+ if [ "$WAIT_TIMEOUT" = "" ]; then -+ WAIT_TIMEOUT=65 -+ fi -+ local donewait=1 -+ local devs=($(egrep 'by-path\/fc-.*_netdev' /etc/fstab | cut -d ' ' -f1)) -+ if [ "$devs" != "" ]; then -+ echo -n "Waiting for FCoE devices . " -+ while [ $WAIT_TIMEOUT -gt 0 ]; do -+ for disk in ${devs[*]}; do -+ if ! test -b $disk; then -+ donewait=0 -+ break -+ fi -+ done -+ test $donewait -eq 1 && break; -+ sleep 1 -+ echo -n ". " -+ donewait=1 -+ WAIT_TIMEOUT=$(($WAIT_TIMEOUT-1)) -+ done -+ if [ "$WAIT_TIMEOUT" -eq 0 ]; then -+ echo "timed out!" -+ else -+ echo "done!" -+ fi -+ fi -+ - echo - } - - stop() - { -- local force=$1 -- -- pid=$(pidof "$FCOEMON") -- if [ "$force" == "force" ] -- then -- action "Destroying any active fcoe interface/s" -- [ "$pid" ] && kill -HUP $pid -+ if have_fcoe_root; then -+ echo $"Possible FCoE root detected, not stopping FCoE." -+ exit 1 - else -- [ "$pid" ] && kill -TERM $pid -- fi -+ local force=$1 -+ -+ pid=$(pidof "$FCOEMON") -+ if [ "$force" == "force" ] -+ then -+ action "Destroying any active fcoe interface/s" -+ [ "$pid" ] && kill -HUP $pid -+ else -+ [ "$pid" ] && kill -TERM $pid -+ fi - -- action $"Stopping FCoE initiator service: " -+ action $"Stopping FCoE initiator service: " - -- rm -f ${PID_FILE} -- rm -f /var/lock/subsys/fcoe -+ rm -f ${PID_FILE} -+ rm -f /var/lock/subsys/fcoe -+ fi - } - - status() diff --git a/fcoe-utils.spec b/fcoe-utils.spec index 1575c76..1797e43 100644 --- a/fcoe-utils.spec +++ b/fcoe-utils.spec @@ -2,8 +2,8 @@ %define _hardened_build 1 Name: fcoe-utils -Version: 1.0.20 -Release: 5%{?dist} +Version: 1.0.21 +Release: 1%{?dist} Summary: Fibre Channel over Ethernet utilities Group: Applications/System License: GPLv2 @@ -14,13 +14,13 @@ Source1: quickstart.txt Source2: fcoe.service Source3: fcoe.config # Generic Fedora patches -Patch0: fcoe-utils-1.0.20-init.patch Patch1: fcoe-utils-1.0.19-make.patch Patch2: fcoe-utils-1.0.18-help.patch Patch3: fcoe-utils-1.0.18-config.patch BuildRequires: libtool automake autoconf BuildRequires: lldpad-devel >= 0.9.43 BuildRequires: libhbaapi-devel >= 2.2-12 +BuildRequires: libhbalinux-devel >= 1.0.13 BuildRequires: libnl-devel BuildRequires: systemd-units Requires: lldpad >= 0.9.43 @@ -39,7 +39,6 @@ or lldpad %prep %setup -q -%patch0 -p1 -b .init %patch1 -p1 -b .make %patch2 -p1 -b .help %patch3 -p1 -b .config @@ -97,6 +96,9 @@ fi %changelog +* Thu Nov 24 2011 Petr Ĺ abata - 1.0.21-1 +- 1.0.21 bump + * Mon Oct 31 2011 Petr Sabata - 1.0.20-5 - Remove useless PIDFile from fcoe.service unit file diff --git a/sources b/sources index 8b37a56..8adba46 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -d23061aa7e353c5df14cc2429314117b fcoe-utils-1.0.20.tar.bz2 +f24599efe32c49bc9357620405e57064 fcoe-utils-1.0.21.tar.bz2