[Initscripts-ng-commits] r783 - in /branches/insserv-1.11.9: Makefile insserv.c insserv.conf tests/suite
kelmo-guest at users.alioth.debian.org
kelmo-guest at users.alioth.debian.org
Tue Jul 15 03:16:21 UTC 2008
Author: kelmo-guest
Date: Tue Jul 15 03:16:21 2008
New Revision: 783
URL: http://svn.debian.org/wsvn/initscripts-ng/?sc=1&rev=783
Log:
Revert accidental commit to upstream sources due to not running clean before commit.
Modified:
branches/insserv-1.11.9/Makefile
branches/insserv-1.11.9/insserv.c
branches/insserv-1.11.9/insserv.conf
branches/insserv-1.11.9/tests/suite
Modified: branches/insserv-1.11.9/Makefile
URL: http://svn.debian.org/wsvn/initscripts-ng/branches/insserv-1.11.9/Makefile?rev=783&op=diff
==============================================================================
--- branches/insserv-1.11.9/Makefile (original)
+++ branches/insserv-1.11.9/Makefile Tue Jul 15 03:16:21 2008
@@ -9,7 +9,7 @@
#DESTDIR = /tmp/root
#DEBUG = -DDEBUG=1 -Wpacked
DEBUG =
-#ISSUSE = -DSUSE
+ISSUSE = -DSUSE
DESTDIR =
VERSION = 1.11.9
DATE = $(shell date +'%d%b%y' | tr '[:lower:]' '[:upper:]')
@@ -27,7 +27,7 @@
COPTS = -g -O2
endif
endif
- CFLAGS = -W -Wall $(COPTS) $(DEBUG) $(LOOPS) -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 \
+ CFLAGS = -Wall $(COPTS) $(DEBUG) $(LOOPS) -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 \
$(ISSUSE) -DINITDIR=\"$(INITDIR)\" -DINSCONF=\"$(INSCONF)\" -pipe
CLOOP = -falign-loops=0
LDFLAGS = -Wl,-O,3,--relax
Modified: branches/insserv-1.11.9/insserv.c
URL: http://svn.debian.org/wsvn/initscripts-ng/branches/insserv-1.11.9/insserv.c?rev=783&op=diff
==============================================================================
--- branches/insserv-1.11.9/insserv.c (original)
+++ branches/insserv-1.11.9/insserv.c Tue Jul 15 03:16:21 2008
@@ -1292,12 +1292,7 @@
error("exiting now!\n");
}
- if (begin && end && (!provides || (provides == empty) ||
-#ifdef SUSE
- !required_start || !required_stop || !default_start))
-#else
- !required_start || !required_stop || !default_start || !default_stop))
-#endif
+ if (verbose && (begin && end && (!provides || (provides == empty) || !required_start || !required_stop)))
{
char *name = basename(path);
if (*name == 'S' || *name == 'K')
@@ -1311,12 +1306,6 @@
warn("missing `Required-Start:' entry: please add even if empty.\n");
if (!required_stop)
warn("missing `Required-Stop:' entry: please add even if empty.\n");
- if (!default_start)
- warn("missing `Default-Start:' entry: please add even if empty.\n");
-#ifndef SUSE
- if (!default_stop)
- warn("missing `Default-Stop:' entry: please add even if empty.\n");
-#endif
}
#undef provides
@@ -2307,24 +2296,24 @@
}
if (S_ISDIR(st_script.st_mode)) {
- const size_t l = strlen(*argv);
-
- path = xstrdup(*argv);
- if (path[l-1] == '/')
- path[l-1] = '\0';
+ const size_t l = strlen(*argv) - 1;
+
+ path = *argv;
+ if (*(path+l) == '/')
+ *(path+l) = '\0';
argv++;
argc--;
if (argc || del)
error("usage: %s [[-r] init_script|init_directory]\n", myname);
+
} else {
- char * base, * ptr = xstrdup(*argv);
-
- if ((base = strrchr(ptr, '/'))) {
+ char * base;
+
+ if ((base = strrchr(*argv, '/'))) {
*base = '\0';
- path = ptr;
- } else
- free(ptr);
+ path = *argv;
+ }
}
}
@@ -2779,9 +2768,8 @@
*/
if (!defaults && (deflvls != service->start->lvl)) {
if (!del && chkfor(d->d_name, argv, argc) && !(argr[curr_argc]))
- warn("Warning, current start runlevel(s) (%s) of script `%s' overwrites defaults (%s).\n",
- service->start->lvl ? lvl2str(service->start->lvl) : "empty", d->d_name,
- lvl2str(deflvls));
+ warn("Warning, current start runlevel(s) %s of script `%s' overwrites defaults %s.\n",
+ lvl2str(service->start->lvl), d->d_name, lvl2str(deflvls));
}
} else
/*
@@ -2790,17 +2778,15 @@
*/
service->start->lvl = deflvls;
- } else if (script_inf.default_start != empty) {
+ } else {
/*
* Could be a none LSB script, use info from current link scheme.
* If not found use default.
*/
if (service->attr.flags & SERV_ENABLED)
script_inf.default_start = lvl2str(service->start->lvl);
-#ifdef SUSE
else
script_inf.default_start = xstrdup(DEFAULT_START_LVL);
-#endif
}
#ifdef SUSE
/*
@@ -2825,9 +2811,8 @@
*/
if (!defaults && (deflvlk != service->stopp->lvl)) {
if (!del && chkfor(d->d_name, argv, argc) && !(argr[curr_argc]))
- warn("Warning, current stop runlevel(s) (%s) of script `%s' overwrites defaults (%s).\n",
- service->stopp->lvl ? lvl2str(service->stopp->lvl) : "empty", d->d_name,
- lvl2str(deflvlk));
+ warn("Warning, current stop runlevel(s) %s of script `%s' overwrites defaults %s.\n",
+ lvl2str(service->stopp->lvl), d->d_name, lvl2str(deflvlk));
}
} else
/*
@@ -2836,41 +2821,26 @@
*/
service->stopp->lvl = deflvlk;
- } else if (script_inf.default_stop != empty) {
+ } else {
/*
* Could be a none LSB script, use info from current link scheme.
* If not found use default.
*/
if (service->attr.flags & SERV_ENABLED)
script_inf.default_stop = lvl2str(service->stopp->lvl);
-#ifdef SUSE
else
script_inf.default_stop = xstrdup(DEFAULT_STOP_LVL);
-#endif
}
}
}
free(provides);
}
-#ifdef SUSE
/* Ahh ... set default multiuser with network */
if (!script_inf.default_start || script_inf.default_start == empty)
script_inf.default_start = xstrdup(DEFAULT_START_LVL);
if (!script_inf.default_stop || script_inf.default_start == empty)
script_inf.default_stop = xstrdup(DEFAULT_STOP_LVL);
-#else
- if (!script_inf.default_start) {
- warn("Default-Start undefined, assuming empty start runlevel(s) for script `%s'\n",
- d->d_name);
- script_inf.default_start = empty;
- }
- if (!script_inf.default_stop) {
- warn("Default-Stop undefined, assuming empty stop runlevel(s) for script `%s'\n",
- d->d_name);
- script_inf.default_stop = empty;
- }
-#endif
if (chkfor(d->d_name, argv, argc) && !defaults && !del) {
if (argr[curr_argc]) {
@@ -2990,7 +2960,7 @@
*/
follow_all();
if (is_loop_detected() && !ignore)
- error("exiting without changing boot order!\n");
+ error("exiting now!\n");
/*
* Be sure that interactive scripts are the only member of
Modified: branches/insserv-1.11.9/insserv.conf
URL: http://svn.debian.org/wsvn/initscripts-ng/branches/insserv-1.11.9/insserv.conf?rev=783&op=diff
==============================================================================
--- branches/insserv-1.11.9/insserv.conf (original)
+++ branches/insserv-1.11.9/insserv.conf Tue Jul 15 03:16:21 2008
@@ -1,29 +1,29 @@
#
# All local filesystems are mounted (done during boot phase)
#
-$local_fs +mountall +mountoverflowtmp +umountfs
+$local_fs boot.localfs
#
# Low level networking (ethernet card)
#
-$network +networking +ifupdown
+$network network +pcmcia +hotplug
#
# Named is operational
#
-$named +named +dnsmasq +lwresd +bind9 $network
+$named +named +dnsmasq +lwresd $network
#
# All remote filesystems are mounted (note in some cases /usr may
# be remote. Most applications that care will probably require
# both $local_fs and $remote_fs)
#
-$remote_fs $local_fs +mountnfs +mountnfs-bootclean +umountnfs +sendsigs
+$remote_fs $local_fs +nfs
#
# System logger is operational
#
-$syslog +syslog +sysklogd +rsyslog +syslog-ng
+$syslog syslog
#
# SunRPC portmapper available
@@ -33,9 +33,9 @@
#
# The system time has been set correctly
#
-$time hwclock
+$time boot.clock +xntpd
#
# Services which need to be interactive
#
-<interactive> glibc hostname mountkernfs udev mountdevsubfs checkroot checkfs console-screen keymap
+<interactive> boot.crypto boot.localfs boot.rootfsck apache apache2 kdump
Modified: branches/insserv-1.11.9/tests/suite
URL: http://svn.debian.org/wsvn/initscripts-ng/branches/insserv-1.11.9/tests/suite?rev=783&op=diff
==============================================================================
--- branches/insserv-1.11.9/tests/suite (original)
+++ branches/insserv-1.11.9/tests/suite Tue Jul 15 03:16:21 2008
@@ -15,15 +15,12 @@
: ${debug:=""}
declare -i retval=0
-declare -i checkfailed=0
-declare -i testcount=0
-declare -i testfailed=0
finish_test ()
{
if test 0 -ne $retval ; then
- echo "error: $testcount test executed, $checkfailed fatal tests failed, $testfailed nonfatal test failed."
+ echo "error: one or more test failed."
else
- echo "success: $testcount test executed, $testfailed nonfatal tests failed."
+ echo "success: no test failed."
fi
rm -rf ${tmpdir}
return $retval
@@ -175,22 +172,15 @@
echo "$path"
}
-counttest ()
-{
- testcount=$(expr $testcount + 1)
-}
-
error ()
{
echo error: $@
- checkfailed=$(expr $checkfailed + 1)
retval=1
}
warning ()
{
echo warning: $@
- testfailed=$(expr $testfailed + 1)
}
addscript ()
@@ -214,7 +204,6 @@
local script=$1; shift
local ret=0
test -L ${rcdpath}/[KS][0-9][0-9]$script || ret=1
- counttest
return $ret
}
@@ -282,7 +271,6 @@
fi
popd &> /dev/null
test "$order" = "$script1 $script2" || ret=1
- counttest
return $ret
}
More information about the Initscripts-ng-commits
mailing list