aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile5
-rwxr-xr-xmodprobe-blacklist25
-rw-r--r--rc.conf21
-rwxr-xr-xrc.d16
-rwxr-xr-xrc.sysinit3
5 files changed, 29 insertions, 41 deletions
diff --git a/Makefile b/Makefile
index 968cfb9..fcabb0e 100644
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,5 @@
VER := $(shell git describe)
-DIRS := /etc/rc.d /etc/conf.d /etc/rc.d/functions.d /etc/cron.hourly /sbin /etc/modprobe.d /etc/bash_completion.d /usr/share/zsh/site-functions
+DIRS := /etc/rc.d /etc/conf.d /etc/rc.d/functions.d /etc/cron.hourly /sbin /etc/bash_completion.d /usr/share/zsh/site-functions
minilogd: minilogd.o
@@ -12,8 +12,7 @@ install: minilogd installdirs
install -m755 -t $(DESTDIR)/etc/cron.hourly adjtime
install -m644 -t $(DESTDIR)/etc/rc.d functions
install -m755 -t $(DESTDIR)/etc/rc.d hwclock network netfs
- install -m755 -t $(DESTDIR)/sbin minilogd rc.d modprobe-blacklist
- ln -s /run/initscripts/modprobe-blacklist.conf $(DESTDIR)/etc/modprobe.d/arch-blacklist.conf
+ install -m755 -t $(DESTDIR)/sbin minilogd rc.d
install -m644 -T bash-completion $(DESTDIR)/etc/bash_completion.d/rc.d
install -m644 -T zsh-completion $(DESTDIR)/usr/share/zsh/site-functions/_rc.d
diff --git a/modprobe-blacklist b/modprobe-blacklist
deleted file mode 100755
index 8af5d90..0000000
--- a/modprobe-blacklist
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/bin/bash
-#
-# /etc/rc.gen-modules-list
-#
-
-. /etc/rc.conf
-
-declare -a blacklist
-for mod in "${MODULES[@]}"; do
- case $mod in
- !*) blacklist+=("${mod:1}") ;;
- *) ;;
- esac
-done
-
-# create new module blacklist in /run/initscripts, there should be a symlink in /etc/modprobe.d/ pointing here
-if [[ $blacklist ]]; then
- /bin/mkdir -p /run/initscripts
- echo "# Autogenerated from rc.conf at boot, do not edit" > /run/initscripts/modprobe-blacklist.conf
- (( ${#blacklist[@]} )) && printf 'blacklist %s\n' "${blacklist[@]}" >> /run/initscripts/modprobe-blacklist.conf
-fi
-
-unset blacklist
-
-# vim: set noet ts=2 sw=2:
diff --git a/rc.conf b/rc.conf
index 5ebcd35..534112f 100644
--- a/rc.conf
+++ b/rc.conf
@@ -33,10 +33,14 @@ VERBOSE="3"
# HARDWARE
# -----------------------------------------------------------------------
#
-# MOD_AUTOLOAD: Allow autoloading of modules at boot and when needed
-# MODULES: Modules to load at boot-up. Prefix with a ! to blacklist.
+# MOD_AUTOLOAD: Deprecated. Always leave at "yes".
+# MODULES: Modules to load at boot-up. Blacklisting is no longer supported.
+# Replace every !module by an entry as on the following line in a file in
+# /etc/modprobe.d:
+# blacklist module
+# See "man modprobe.conf" for details.
#
-MOD_AUTOLOAD="yes" # (DEPRECATED) always leave at "yes"
+MOD_AUTOLOAD="yes"
MODULES=()
# Udev settle timeout (default to 30)
@@ -67,6 +71,17 @@ HOSTNAME="myhost"
# - netmask: subnet mask (ignored for DHCP)
# - gateway: default route (ignored for DHCP)
#
+# Static IP example
+# interface=eth0
+# address=192.168.0.2
+# netmask=255.255.255.0
+# gateway=192.168.0.1
+#
+# DHCP example
+# interface=eth0
+# address=
+# netmask=
+# gateway=
interface=
address=
diff --git a/rc.d b/rc.d
index 97f266a..772f2c6 100755
--- a/rc.d
+++ b/rc.d
@@ -42,19 +42,21 @@ case $1 in
done
;;
*)
+ # check min args count
+ (( $# < 2 )) && usage
action=$1
shift
# set same environment variables as init
runlevel=$(/sbin/runlevel)
- ENV="PATH='/bin:/usr/bin:/sbin:/usr/sbin'"
- ENV+=" PREVLEVEL='${runlevel:0:1}'"
- ENV+=" RUNLEVEL='${runlevel:2:1}'"
- ENV+=" CONSOLE='${CONSOLE:-/dev/console}'"
- ENV+=" TERM='${TERM}'"
+ ENV=("PATH=/bin:/usr/bin:/sbin:/usr/sbin"
+ "PREVLEVEL=${runlevel%% *}"
+ "RUNLEVEL=${runlevel##* }"
+ "CONSOLE=${CONSOLE:-/dev/console}"
+ "TERM=$TERM")
+ cd /
for i; do
if [[ -x "/etc/rc.d/$i" ]]; then
- cd /
- eval /usr/bin/env -i $ENV "/etc/rc.d/$i" "$action"
+ /usr/bin/env -i "${ENV[@]}" "/etc/rc.d/$i" "$action"
else
printf "${C_OTHER}:: ${C_FAIL}Error: ${C_DONE}Daemon script $i does not exist.\n"
fi
diff --git a/rc.sysinit b/rc.sysinit
index b8553e9..00a328e 100755
--- a/rc.sysinit
+++ b/rc.sysinit
@@ -83,9 +83,6 @@ if [[ $HWCLOCK_PARAMS ]]; then
fi
fi
-# parse rc.conf and create the blacklist file for use by modprobe
-status "Creating UDev blacklist" /sbin/modprobe-blacklist
-
status "Starting UDev Daemon" /sbin/udevd --daemon
run_hook sysinit_udevlaunched