Subject: Re: Updating /etc...
To: None <current-users@NetBSD.ORG>
From: Mike Long <mike.long@analog.com>
List: current-users
Date: 12/20/1995 11:43:08
>Posted-Date: Tue, 19 Dec 1995 23:12:24 -0600
>Date: Tue, 19 Dec 1995 23:12:52 -0600
>From: Peter Seebach <seebs@solon.com>
>
>Re: between S49blowfish and S50 oracle...
>Presumably, we would look into dependancies, rather than simple
>ordering.  If all I have in init.d/7.d is "Sfoo", but foo depends
>on oracle, bananas, and three other packages, they are looked for
>and started - if they fail, they are killed, and the state change
>fails.

How about something like Emacs' provide/require system?  (Just because
its from Emacs doesn't mean that it *has* to be cumbersome!)

Add two lines to each /etc/init.d script; one lists features required
by the script, and the other lists features provided by the script.
So the equivalent of /etc/netstart would contain something like:

#REQUIRES fsck
#PROVIDES network

An install utility would collect these lines from scripts in
/etc/init.d and run them through /usr/bin/tsort to obtain the order in
which the scripts should be run.  Then it would regenerate links in
/etc/rc.d to reflect that order.  Another benefit would be that the
install utility can find errors, like a script that requires a feature
provided by none of the other scripts or a dependency loop.

Yet another wacky idea from:
-- 
Mike Long <mike.long@analog.com>           http://www.shore.net/~mikel
VLSI Design Engineer         finger mikel@shore.net for PGP public key
Analog Devices, CPD Division          CCBF225E7D3F7ECB2C8F7ABB15D9BE7B
Norwood, MA 02062 USA       (eq (opinion 'ADI) (opinion 'mike)) -> nil