[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Tiger-devel] [RFC] Moving some check_root checks into OS specific c
From: |
Nicolas François |
Subject: |
Re: [Tiger-devel] [RFC] Moving some check_root checks into OS specific checks. |
Date: |
Thu, 26 Jun 2003 21:25:30 +0200 |
User-agent: |
Mutt/1.5.4i |
Hello all,
On Thu, Jun 26, 2003 at 09:39:52AM +0200, Javier Fernandez-Sanguino wrote:
> Yes, one of the things I wanted to implement in the main engine is to be
> able to override common checks with local (OS-specific) checks. That's
> in the TODO:
>
> "- Modify Tiger so it can use a system's scripts if it exists and
> substitute the one under scripts/ by introducing a run_script funcion
> (check if the script is under scripts and under systems/$OS/... and run
> it)"
I think this can be done by swapping SCRIPTDIR and LSCRIPTDIR in
tigercron :
Index: tigercron
===================================================================
RCS file: /cvsroot/tiger/tiger/tigercron,v
retrieving revision 1.11
diff -u -p -r1.11 tigercron
--- tigercron 12 May 2003 20:11:06 -0000 1.11
+++ tigercron 26 Jun 2003 19:10:02 -0000
@@ -206,10 +206,10 @@ do
outprefix="$LOGDIR/`$BASENAME $script`.out"
suffix=${TigerCron_Log_Keep_Max:=10}
{
- if [ -f $SCRIPTDIR/$script ]; then
- $SCRIPTDIR/$script
- elif [ -f $LSCRIPTDIR/$script ]; then
+ if [ -f $LSCRIPTDIR/$script ]; then
$LSCRIPTDIR/$script
+ elif [ -f $SCRIPTDIR/$script ]; then
+ $SCRIPTDIR/$script
elif [ -f $script ]; then
$script
else
At this time, LSCRIPTDIR is only defined in $BASEDIR/systems/Linux/2/config,
and points to $BASEDIR/systems/$OS/$REL. $BASEDIR/config is in charge to
call the right config (systems/Linux/2/config in this case) for the current
architecture. The definition of LSCRIPTDIR in architecture specific config
files could be generalized.
hth
--
Nekral