From eaff8e2d450292c37e3efa27246e6b3dfba5e6ba Mon Sep 17 00:00:00 2001 From: Sean Hefty Date: Tue, 4 Feb 2014 17:10:43 -0800 Subject: [PATCH] refresh --- meta | 7 ++-- patches/refresh-temp | 86 -------------------------------------------- patches/suse2 | 47 +++++++++++++++++++----- 3 files changed, 41 insertions(+), 99 deletions(-) delete mode 100644 patches/refresh-temp diff --git a/meta b/meta index 9590ca9..58c7e68 100644 --- a/meta +++ b/meta @@ -1,9 +1,8 @@ Version: 1 -Previous: a7b973146e7d0ccc96e078e8ab929251a1062ac5 -Head: 61e3b01cba1303bccd939e57150b584c60a57e8b +Previous: 003e0cd332814b10a7da32b2aa05944f267c48ba +Head: 978a7c1c49e79b9256f071e545db30d076bd59b4 Applied: - suse2: 9b5993fbd79bc35d4d5cb276f6e7b01da93dc67a - refresh-temp: 61e3b01cba1303bccd939e57150b584c60a57e8b + suse2: 978a7c1c49e79b9256f071e545db30d076bd59b4 Unapplied: suse: 7076e2a00570a3cda4e4ce034419399a23ebfb0a dev-name2ip: 8e00708e882239292492e13aa51c82042255933c diff --git a/patches/refresh-temp b/patches/refresh-temp deleted file mode 100644 index 04d2272..0000000 --- a/patches/refresh-temp +++ /dev/null @@ -1,86 +0,0 @@ -Bottom: fb9f097f0cf8ff4c09c0ccb617f41f4b916b1573 -Top: 69a99b919a2a28dade2e890b9a952846dee8f2de -Author: Sean Hefty -Date: 2014-02-04 17:10:43 -0800 - -Refresh of suse2 - ---- - -diff --git a/ibacm.init.in b/ibacm.init.in -index 2f340a5..766d3e9 100644 ---- a/ibacm.init.in -+++ b/ibacm.init.in -@@ -22,20 +22,30 @@ - pidfile=/var/run/ibacm.pid - subsys=/var/lock/subsys/ibacm - --if [-f /etc/init.d/functions]; then -+daemon() { /sbin/daemon ${1+"$@"}; } -+xstatus() { /sbin/status ${1+"$@"}; } -+ -+if [-s /etc/init.d/functions]; then - # RHEL / CentOS / SL / Fedora - . /etc/init.d/functions -+ - rc_status() { :; } - rc_exit() { exit $RETVAL; } --elif [-f /lib/lsb/init-functions]; then -+elif [-s /lib/lsb/init-functions]; then - # SLES / OpenSuSE / Debian - . /lib/lsb/init-functions -+ daemon() { /sbin/start_daemon ${1+"$@"}; } -+ xstatus() { /sbin/checkproc ${1+"$@"}; } -+ - rc_exit() { exit $RETVAL; } - success() { log_success_msg; } - failure() { log_failure_msg; } --elif [-f /etc/rc.status]; then -+elif [-s /etc/rc.status]; then - # Older SuSE - . /etc/rc.status -+ daemon() { /sbin/start_daemon ${1+"$@"}; } -+ xstatus() { /sbin/checkproc ${1+"$@"}; } -+ - success() { rc_status -v; } - failure() { rc_status -v; } - fi -@@ -44,7 +54,7 @@ start() - { - echo -n "Starting ibacm daemon:" - daemon @prefix@/sbin/ibacm -- if [$RETVAL -eq 0]; then -+ if [[$RETVAL -eq 0]]; then - success - else - failure -@@ -56,7 +66,7 @@ stop() - { - echo -n "Stopping ibacm daemon:" - killproc -p $pidfile ibacm -- if [$RETVAL -eq 0]; then -+ if [[$RETVAL -eq 0]]; then - success - else - failure -@@ -67,15 +77,12 @@ stop() - - status() - { -- if [ ! -f $subsys -a ! -f $pidfile ]; then -- return 3 -- fi -- if [ -f $pidfile ]; then -- checkpid `cat $pidfile` -- return $? -- fi -- if [ -f $subsys ]; then -- return 2 -+ echo -n "Checking for ibacm service " -+ xstatus @prefix@/sbin/ibacm -+ if [[$RETVAL -eq 0]]; then -+ success -+ else -+ failure - fi - } diff --git a/patches/suse2 b/patches/suse2 index d97a5d2..3340b97 100644 --- a/patches/suse2 +++ b/patches/suse2 @@ -1,5 +1,5 @@ Bottom: 2f6704a0b1af76a5a8011d2f8e56ad9c4c274210 -Top: fb9f097f0cf8ff4c09c0ccb617f41f4b916b1573 +Top: 69a99b919a2a28dade2e890b9a952846dee8f2de Author: Sean Hefty Date: 2014-02-04 15:47:22 -0800 @@ -11,28 +11,38 @@ Signed-off-by: Sean Hefty --- diff --git a/ibacm.init.in b/ibacm.init.in -index bd2d1bd..2f340a5 100644 +index bd2d1bd..766d3e9 100644 --- a/ibacm.init.in +++ b/ibacm.init.in -@@ -22,28 +22,47 @@ +@@ -22,41 +22,67 @@ pidfile=/var/run/ibacm.pid subsys=/var/lock/subsys/ibacm -. /etc/rc.d/init.d/functions -+if [-f /etc/init.d/functions]; then ++daemon() { /sbin/daemon ${1+"$@"}; } ++xstatus() { /sbin/status ${1+"$@"}; } ++ ++if [-s /etc/init.d/functions]; then + # RHEL / CentOS / SL / Fedora + . /etc/init.d/functions ++ + rc_status() { :; } + rc_exit() { exit $RETVAL; } -+elif [-f /lib/lsb/init-functions]; then ++elif [-s /lib/lsb/init-functions]; then + # SLES / OpenSuSE / Debian + . /lib/lsb/init-functions ++ daemon() { /sbin/start_daemon ${1+"$@"}; } ++ xstatus() { /sbin/checkproc ${1+"$@"}; } ++ + rc_exit() { exit $RETVAL; } + success() { log_success_msg; } + failure() { log_failure_msg; } -+elif [-f /etc/rc.status]; then ++elif [-s /etc/rc.status]; then + # Older SuSE + . /etc/rc.status ++ daemon() { /sbin/start_daemon ${1+"$@"}; } ++ xstatus() { /sbin/checkproc ${1+"$@"}; } ++ + success() { rc_status -v; } + failure() { rc_status -v; } +fi @@ -44,7 +54,7 @@ index bd2d1bd..2f340a5 100644 daemon @prefix@/sbin/ibacm - RC=$? - [ $RC -eq 0 ] && touch $subsys -+ if [$RETVAL -eq 0]; then ++ if [[$RETVAL -eq 0]]; then + success + else + failure @@ -59,7 +69,7 @@ index bd2d1bd..2f340a5 100644 - killproc -p $pidfile ibacm - RC=$? -+ if [$RETVAL -eq 0]; then ++ if [[$RETVAL -eq 0]]; then + success + else + failure @@ -70,7 +80,26 @@ index bd2d1bd..2f340a5 100644 } status() -@@ -85,15 +104,25 @@ case $1 in + { +- if [ ! -f $subsys -a ! -f $pidfile ]; then +- return 3 +- fi +- if [ -f $pidfile ]; then +- checkpid `cat $pidfile` +- return $? +- fi +- if [ -f $subsys ]; then +- return 2 ++ echo -n "Checking for ibacm service " ++ xstatus @prefix@/sbin/ibacm ++ if [[$RETVAL -eq 0]]; then ++ success ++ else ++ failure + fi + } + +@@ -85,15 +111,25 @@ case $1 in esac case $1 in -- 2.41.0