-dnl $Id: configure.in,v 1.11 1999/08/09 19:44:58 kloczek Exp $
+dnl $Id: configure.in,v 1.12 1999/08/09 20:00:08 wiget Exp $
AC_INIT()
PACKAGE=rc-scripts
rcdir='${sysconfdir}/rc.d'
docdir="${prefix}/doc/$PACKAGE-$VERSION"
libdir="${exec_prefix}/lib"
+
dnl i18n support
+AC_PATH_PROGS(MSGMERGE, msgmerge)
+AC_PATH_PROGS(GMSGFMT, gmsgfmt msgfmt)
+
CATALOGS=
POTFILES=
for lang in $ALL_LINGUAS; do
# functions This file contains functions to be used by most or all
# shell scripts in the /etc/init.d directory.
#
-# $Id: functions,v 1.18 1999/08/07 10:16:14 wiget Exp $
+# $Id: functions,v 1.19 1999/08/09 20:00:08 wiget Exp $
#
# Author: Miquel van Smoorenburg, <miquels@drinkel.nl.mugnet.org>
# Hacked by: Greg Galloway and Marc Ewing
# Some functions to handle PLD-style messages
show()
{
- what="`nls DONE`"; typeset -i offset=${#what}
+ what="`nls "DONE"`"; typeset -i offset=${#what}
text="`nls "$*"`"..................................................................................
printf "%.$((69 - $offset))s" "$text"
}
busy()
{
- echo -n "`tput setaf 6`[`tput setaf 5` `nls BUSY` `tput setaf 6`]`tput setaf 7`"
+ echo -n "`tput setaf 6`[`tput setaf 5` `nls "BUSY"` `tput setaf 6`]`tput setaf 7`"
}
ok()
{
- echo "`tput setaf 6`[`tput setaf 2` `nls DONE` `tput setaf 6`]`tput setaf 7`"
+ echo "`tput setaf 6`[`tput setaf 2` `nls "DONE"` `tput setaf 6`]`tput setaf 7`"
}
started()
{
- echo "`tput setaf 6`[`tput setaf 2` `nls WORK` `tput setaf 6`]`tput setaf 7`"
+ echo "`tput setaf 6`[`tput setaf 2` `nls "WORK"` `tput setaf 6`]`tput setaf 7`"
}
fail()
{
- echo "`tput setaf 6`[`tput setaf 1` `nls FAIL` `tput setaf 6`]`tput setaf 7`"
+ echo "`tput setaf 6`[`tput setaf 1` `nls "FAIL"` `tput setaf 6`]`tput setaf 7`"
}
died()
{
- echo "`tput setaf 6`[`tput setaf 1` `nls DIED` `tput setaf 6`]`tput setaf 7`"
+ echo "`tput setaf 6`[`tput setaf 1` `nls "DIED"` `tput setaf 6`]`tput setaf 7`"
}
deltext()
{
- echo -ne "`nls '\b\b\b\b\b\b\b\b'`"
+ echo -ne "\b\b\b\b\b\b\b\b"
}
# Usage run_cmd Message command_to_run
{
# Test syntax.
if [ $# = 0 ]; then
- echo "Usage: killproc {program} [signal]"
+ nls "Usage: killproc {program} [signal]"
return 1
fi
{
# Test syntax.
if [ $# = 0 ] ; then
- echo "Usage: pidofproc {program}"
+ nls "Usage: pidofproc {program}\n"
return 1
fi
{
# Test syntax.
if [ $# = 0 ] ; then
- echo "Usage: status {program}"
+ nls "Usage: status {program}\n"
return 1
fi
# First try "pidof"
pid=`pidof $1`
if [ "$pid" != "" ] ; then
- echo "$1 (pid $pid) is running..."
+ nls "$1 (pid $pid) is running..."
return 0
else
pid=`ps ax | awk 'BEGIN { prog=ARGV[1]; ARGC=1 }
(("[" prog "]") == $5) ||
((prog ":") == $5)) { print $1 ; exit 0 } }' $1`
if [ "$pid" != "" ] ; then
- echo "$1 (pid $pid) is running..."
+ nls "$1 (pid $pid) is running..."
return 0
fi
fi
if [ -f /var/run/$1.pid ] ; then
pid=`head -1 /var/run/$1.pid`
if [ "$pid" != "" ] ; then
- echo "$1 dead but pid file exists"
+ nls "$1 dead but pid file exists"
return 1
fi
fi
# See if /var/lock/subsys/$1 exists
if [ -f /var/lock/subsys/$1 ]; then
- echo "$1 dead but subsys locked"
+ nls "$1 dead but subsys locked"
return 2
fi
- echo "$1 is stopped"
+ nls "$1 is stopped"
return 3
}