From b5c2db119b0b153e535fedcd3ce9d8b41b929e95 Mon Sep 17 00:00:00 2001 From: "Cameron (Kamran) Mashayekhi" Date: Sat, 18 Feb 2006 23:01:02 +0000 Subject: [PATCH] Corrections to spec file and scripts and update to the micasad. CASA.spec and CASA_dbg.spec were synched up. --- CASA.changes | 7 +++++++ c_micasad/startup/micasad | 38 ++++++++++++++++++-------------------- shsrc/lshsrc/CASA.spec | 11 +++++++---- shsrc/lshsrc/CASA_dbg.spec | 7 +++++-- 4 files changed, 37 insertions(+), 26 deletions(-) diff --git a/CASA.changes b/CASA.changes index f93320fe..4345ea21 100644 --- a/CASA.changes +++ b/CASA.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Sat Feb 18 15:57:20 MST 2006 - cmashayekhi@novell.com + +- Minor fixes were made to micasad script. +- Minor fixes were made to CASA.spec. +- CASA.spec and CASA_dbg.spec were synched. + ------------------------------------------------------------------- Fri Feb 17 14:01:12 MST 2006 - jnorman@novell.com diff --git a/c_micasad/startup/micasad b/c_micasad/startup/micasad index f46f715d..8e52ec46 100644 --- a/c_micasad/startup/micasad +++ b/c_micasad/startup/micasad @@ -35,9 +35,8 @@ case "$1" in # Remember status and be verbose rc_status -v ;; - stop) - echo "Shutting miCASA daemon down" + echo "Shutting down micasad " #killproc -TERM $MICASAD_BIN pid=`cat /var/run/micasad.pid` >/dev/null 2>&1 kill -s TERM $pid >/dev/null 2>&1 @@ -45,12 +44,17 @@ case "$1" in # Remember status and be verbose rc_status -v ;; - try-restart|condrestart) - $0 status >/dev/null && $0 restart - rc_status - ;; - + $0 status + if test $? = 0 + then + $0 restart + else + rc_reset # Not running is not a failure. + fi + # Remember status and be quiet + rc_status + ;; restart) ## Stop the service and regardless of whether it was ## running or not, start it again. @@ -61,34 +65,28 @@ case "$1" in # Remember status and be quiet rc_status ;; - status) - echo "Checking for service micasad ..." + echo "Checking micasad service ..." /sbin/checkproc micasad - $res=$? + res=$? if [ $res == 0 ] then echo -n "0 - service up and running" elif [ $res == 1 ] then - echo -n "1 - service dead, but /var/run/pid file exists" + echo -n "1 - service running under mono, /var/run/pid file exists" elif [ $res == 2 ] then - echo -n "2 - service dead, but /var/lock/lock file exists" + echo -n "2 - service status unknown, /var/lock/lock file exists" elif [ $res == 3 ] then - echo -n "3 - service not running (unused)" - elif [ $res == 4 ] - then - echo -n "4 - service status unknown" + echo -n "3 - service not running" else - echo -n "5--199 reserved (5--99 LSB, 100--149 distro, 150--199 appl.)" + echo -n "service status unknown" fi - rc_status >/dev/null 2>&1 - + rc_status -v ;; - *) echo "Usage: $0 {start|stop|restart|try-restart|status}" exit 1 diff --git a/shsrc/lshsrc/CASA.spec b/shsrc/lshsrc/CASA.spec index 3dc4d6e2..bc108e51 100644 --- a/shsrc/lshsrc/CASA.spec +++ b/shsrc/lshsrc/CASA.spec @@ -21,16 +21,16 @@ License: LGPL Group: Productivity/Other Autoreqprov: on %define bldno 1.1.1 -Version: 1.6.311 +Version: 1.6.0 Release: 0 Summary: Novell Common Authentication Service Adapter (CASA) Source: %{name}-%{version}.tar.bz2 #Patch: %{name}-%{version}.dif -Patch2: CASA-detect_lib64.patch +Patch2: CASA-detect_lib64.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build Requires: mono >= 1.1.13 mono-core >= 1.1.13 PreReq: %fillup_prereq %insserv_prereq -ExclusiveArch: %ix86 x86_64 +#ExclusiveArch: %ix86 x86_64 #NoSource: 0 %description @@ -153,7 +153,10 @@ echo "/usr/%{_lib}/" >> %{buildroot}/etc/ld.so.conf.d/CASA.conf %post %{fillup_and_insserv -y micasad} -casacfgpam +if [ "x$1" == "x1" ] || [ "x$1" == "x2" ] +then + casacfgpam +fi /sbin/ldconfig %post gui diff --git a/shsrc/lshsrc/CASA_dbg.spec b/shsrc/lshsrc/CASA_dbg.spec index 3d1f1fc2..98a1a31b 100644 --- a/shsrc/lshsrc/CASA_dbg.spec +++ b/shsrc/lshsrc/CASA_dbg.spec @@ -30,7 +30,7 @@ Patch2: CASA-detect_lib64.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build Requires: mono >= 1.1.13 mono-core >= 1.1.13 PreReq: %fillup_prereq %insserv_prereq -ExclusiveArch: %ix86 x86_64 +#ExclusiveArch: %ix86 x86_64 #NoSource: 0 %description @@ -153,7 +153,10 @@ echo "/usr/%{_lib}/" >> %{buildroot}/etc/ld.so.conf.d/CASA.conf %post %{fillup_and_insserv -y micasad} -casacfgpam +if [ "x$1" == "x1" ] || [ "x$1" == "x2" ] +then + casacfgpam +fi /sbin/ldconfig %post gui