Reverted change which allows Makefile-style fiels to be found
in /var/lib/insserv or /lib/insserv as these changes are technically likely tocause problems and/or do not conform to FHS.
This commit is contained in:
parent
d93d095e72
commit
523051dab3
10
CHANGELOG
10
CHANGELOG
|
@ -1,16 +1,6 @@
|
|||
startpar 0.63
|
||||
===============
|
||||
|
||||
* startpar now looks for Makefile-style dependency scripts in
|
||||
/lib/insserv/ by default. If no scripts are found there
|
||||
it will fall back to using the legacy /etc/init.d/ location.
|
||||
If no scripts are found there, startpar will print an error
|
||||
and exit.
|
||||
|
||||
* Added -l flag to modify -M. When -l is used, startpar skips looking
|
||||
in the /lib/insserv/ directory for Makefile-style scripts. The
|
||||
-l flag jumps straight to looking in the /etc/init.d/ directory.
|
||||
|
||||
* Used constants for some strings instead of checking sizeof().
|
||||
|
||||
* Made makefile parsing more fault talerant so the parsing function
|
||||
|
|
20
startpar.1
20
startpar.1
|
@ -51,7 +51,6 @@ startpar \- start runlevel scripts in parallel
|
|||
.IR timeout ]
|
||||
.RB [ \-T
|
||||
.IR global_timeout ]
|
||||
.RB [ \-l ]
|
||||
.B \-M [
|
||||
.IR boot | start | stop ]
|
||||
.br
|
||||
|
@ -115,21 +114,12 @@ into a
|
|||
like behaviour. This option takes three different arguments:
|
||||
.IR boot ", " start ", and " stop
|
||||
for reading
|
||||
.IR depend.boot " or " depend.start " or " depend.stop
|
||||
.IR .depend.boot " or " .depend.start " or " .depend.stop
|
||||
respectively in the directory
|
||||
.IR /lib/insserv/ .
|
||||
.IR /etc/init.d/ .
|
||||
By scanning the boot and runlevel directories in
|
||||
.I /etc/init.d/
|
||||
it then executes the appropriate scripts in parallel.
|
||||
When the \-M flag is used with the \-l flag startpar looks
|
||||
for the depend.boot, depend.start, and depend.stop scripts
|
||||
in its legacy location of /etc/init.d/ instead of
|
||||
/lib/insserv/.
|
||||
|
||||
Also note that if startpar cannot find its makefile-style
|
||||
scripts in /lib/insserv/, it will automatically check
|
||||
the legacy location as a fallback in case startpar is being
|
||||
run on a system that uses the old location.
|
||||
|
||||
The
|
||||
.B \-e
|
||||
|
@ -151,11 +141,11 @@ version flag is used, all other command line parameters are ignored.
|
|||
The version number will be printed and startpar then immediately exits.
|
||||
|
||||
.SH FILES
|
||||
.I /lib/insserv/depend.boot
|
||||
.I /etc/init.d/.depend.boot
|
||||
.br
|
||||
.I /lib/insserv/depend.start
|
||||
.I /etc/init.d/.depend.start
|
||||
.br
|
||||
.I /lib/insserv/depend.stop
|
||||
.I /etc/init.d/.depend.stop
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR init.d (7),
|
||||
|
|
10
startpar.c
10
startpar.c
|
@ -118,8 +118,8 @@ const char *initddir = "/etc/init.d";
|
|||
const char *etcdir = "/etc";
|
||||
|
||||
#define LEGACY_DEPENDENCY_PATH "/etc/init.d/."
|
||||
#define DEPENDENCY_PATH "/lib/insserv/"
|
||||
char *dependency_path = DEPENDENCY_PATH;
|
||||
/* #define DEPENDENCY_PATH "/lib/insserv/" */
|
||||
char *dependency_path = LEGACY_DEPENDENCY_PATH;
|
||||
#ifndef PATH_MAX
|
||||
#define PATH_MAX 2048
|
||||
#endif
|
||||
|
@ -861,8 +861,10 @@ void usage(int status)
|
|||
fprintf(stderr, " startpar -v\n");
|
||||
fprintf(stderr, " show version number\n");
|
||||
fprintf(stderr, "general options:\n");
|
||||
/*
|
||||
fprintf(stderr, " -l use legacy /etc/init.d path for Makefile-style scripts\n");
|
||||
fprintf(stderr, " The default is to use the location /lib/insserv\n");
|
||||
*/
|
||||
fprintf(stderr, " -p parallel tasks\n");
|
||||
fprintf(stderr, " -t I/O timeout\n");
|
||||
fprintf(stderr, " -T global I/O timeout\n");
|
||||
|
@ -902,7 +904,7 @@ int main(int argc, char **argv)
|
|||
numcpu = sysconf(_SC_NPROCESSORS_ONLN);
|
||||
myname = argv[0];
|
||||
|
||||
while ((c = getopt(argc, argv, "flhp:t:T:a:M:P:R:S:vi:e:d:")) != EOF)
|
||||
while ((c = getopt(argc, argv, "fhp:t:T:a:M:P:R:S:vi:e:d:")) != EOF)
|
||||
{
|
||||
switch(c)
|
||||
{
|
||||
|
@ -927,10 +929,12 @@ int main(int argc, char **argv)
|
|||
case 'e':
|
||||
etcdir = optarg;
|
||||
break;
|
||||
/*
|
||||
case 'l':
|
||||
dependency_path = LEGACY_DEPENDENCY_PATH;
|
||||
using_legacy_path = TRUE;
|
||||
break;
|
||||
*/
|
||||
case 'M':
|
||||
run_mode = optarg;
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue