1 |
#!/bin/sh |
#!/bin/sh |
2 |
# $Header: /home/cvsd/magellan-cvs/magellan-src/busybox-initscripts/rc/functions,v 1.1 2008-06-02 22:14:35 niro Exp $ |
# $Header: /home/cvsd/magellan-cvs/magellan-src/busybox-initscripts/rc/functions,v 1.2 2008-06-02 22:53:36 niro Exp $ |
3 |
|
|
4 |
# Begin $rc_base/init.d/functions - Run Level Control Functions |
# Begin $rc_base/init.d/functions - Run Level Control Functions |
5 |
|
|
40 |
|
|
41 |
COLOREDSTAR="${COLBLUE}(${COLGREEN}*${COLBLUE})${COLDEFAULT} " |
COLOREDSTAR="${COLBLUE}(${COLGREEN}*${COLBLUE})${COLDEFAULT} " |
42 |
|
|
43 |
#location to save the started services |
# location to save the started services |
44 |
svcdir="/var/lib/init.d" |
svcdir="/var/lib/init.d" |
45 |
svclib="/lib/rcscripts" |
svclib="/lib/rcscripts" |
46 |
svcmount="no" |
svcmount="no" |
47 |
svcfstype="tmpfs" |
svcfstype="tmpfs" |
48 |
svcsize=1024 |
svcsize=1024 |
49 |
|
|
50 |
|
rc_echo() { echo $@; } |
51 |
|
rc_print() { rc_echo -e "${COLOREDSTAR}$@"; } |
52 |
|
|
53 |
# dummy function; needed if splashutils are not installed |
# dummy function; needed if splashutils are not installed |
54 |
splash() { return 0; } |
splash() { return 0; } |
55 |
|
|
56 |
|
# source splash functions if exists |
|
#source splash functions if exists |
|
57 |
[ -f /etc/init.d/splash-functions ] && source /etc/init.d/splash-functions |
[ -f /etc/init.d/splash-functions ] && source /etc/init.d/splash-functions |
58 |
|
|
|
|
|
|
|
|
59 |
print_error_msg() |
print_error_msg() |
60 |
{ |
{ |
61 |
return 0 |
return 0 |
95 |
local SVCD_INITSCRIPT |
local SVCD_INITSCRIPT |
96 |
local x |
local x |
97 |
|
|
|
|
|
98 |
#do this only if proc is mounted |
#do this only if proc is mounted |
99 |
[ ! -f /proc/mounts ] && return 0 |
[ ! -f /proc/mounts ] && return 0 |
100 |
|
|
199 |
getpids() |
getpids() |
200 |
{ |
{ |
201 |
base=${1##*/} |
base=${1##*/} |
202 |
pidlist=$(pidof -o $$ -o $PPID -x $base) |
pidlist=$(pidof -o $$ -o $PPID $base) |
203 |
} |
} |
204 |
|
|
205 |
loadproc() |
loadproc() |
284 |
else |
else |
285 |
signal=${2##-} |
signal=${2##-} |
286 |
signal=${signal##SIG} |
signal=${signal##SIG} |
|
|
|
287 |
fi |
fi |
288 |
|
|
289 |
getpids $1 |
getpids $1 |
455 |
|
|
456 |
return 1 |
return 1 |
457 |
} |
} |
458 |
|
|
459 |
|
start_devicemanager() { touch /dev/.none; return 0; } |
460 |
|
stop_devicemanager() { return 0; } |