diff options
| author | emmett1 <emmett1.2miligrams@protonmail.com> | 2024-07-26 23:27:57 +0800 |
|---|---|---|
| committer | emmett1 <emmett1.2miligrams@protonmail.com> | 2024-07-26 23:27:57 +0800 |
| commit | 882049c9847b6e49e1d68ae4109bd4cb36d1b566 (patch) | |
| tree | f62b2bcb2a7ce30767da93a22a0b2780c3a6c22f /repos/core/initscripts | |
| parent | 31702b76095315712ac584c8acfbe3f27e9fedf9 (diff) | |
| download | alicelinux-882049c9847b6e49e1d68ae4109bd4cb36d1b566.tar.gz alicelinux-882049c9847b6e49e1d68ae4109bd4cb36d1b566.zip | |
initscripts: updated to 20240726
Diffstat (limited to 'repos/core/initscripts')
| -rw-r--r-- | repos/core/initscripts/abuild | 6 | ||||
| -rwxr-xr-x[-rw-r--r--] | repos/core/initscripts/rc.boot | 24 | ||||
| -rw-r--r-- | repos/core/initscripts/rc.modules | 2 |
3 files changed, 14 insertions, 18 deletions
diff --git a/repos/core/initscripts/abuild b/repos/core/initscripts/abuild index e9a0d75c..5a2f4feb 100644 --- a/repos/core/initscripts/abuild +++ b/repos/core/initscripts/abuild @@ -1,11 +1,11 @@ name=initscripts -version=20240626 +version=20240726 release=1 -source="rc.boot rc.shutdown rc.boot.local rc.shutdown.local rc.modules inittab" +source="rc.boot rc.shutdown rc.boot.local rc.shutdown.local inittab" build() { mkdir -p $PKG/etc $PKG/var/service - for i in boot boot.local shutdown shutdown.local modules; do + for i in boot boot.local shutdown shutdown.local; do install -m755 $SRC/rc.$i $PKG/etc/rc.$i done install -m644 $SRC/inittab $PKG/etc/inittab diff --git a/repos/core/initscripts/rc.boot b/repos/core/initscripts/rc.boot index 8e4bba4b..0b208a17 100644..100755 --- a/repos/core/initscripts/rc.boot +++ b/repos/core/initscripts/rc.boot @@ -2,7 +2,7 @@ PATH=/bin:/usr/bin:/sbin:/usr/sbin -echo "Alice booting" +echo "Alice booting..." mountpoint -q /proc || mount -t proc proc /proc -o nosuid,noexec,nodev mountpoint -q /sys || mount -t sysfs sys /sys -o nosuid,noexec,nodev @@ -16,20 +16,15 @@ if [ "$(command -v udevd)" ]; then udevd --daemon udevadm trigger --action=add --type=subsystems udevadm trigger --action=add --type=devices - udevadm trigger --action=change --type=devices udevadm settle else echo "/sbin/mdev" > /proc/sys/kernel/hotplug - for i in $(find /sys/devices -name 'usb[0-9]*'); do - [ -e $i/uevent ] && echo add > $i/uevent - done mdev -s find /sys -name 'modalias' -type f -exec cat '{}' + | sort -u | xargs modprobe -b -a 2>/dev/null - find /sys -name 'modalias' -type f -exec cat '{}' + | sort -u | xargs modprobe -b -a 2>/dev/null ln -s /proc/self/fd /dev/fd - ln -s fd/0 /dev/stdin - ln -s fd/1 /dev/stdout - ln -s fd/2 /dev/stderr + ln -s fd/0 /dev/stdin + ln -s fd/1 /dev/stdout + ln -s fd/2 /dev/stderr fi swapon -a @@ -58,7 +53,7 @@ mount -o remount,rw / mount -a if [ ! -f /etc/hostname ]; then - echo linux > /etc/hostname + echo alice > /etc/hostname fi hostname -F /etc/hostname @@ -82,6 +77,9 @@ fi dmesg >/var/log/dmesg.log -for i in /etc/rc.modules /etc/rc.boot.local ; do - [ -x "$i" ] && "$i" -done +if [ -x /etc/rc.boot.local ]; then + /etc/rc.boot.local +fi + +IFS=. read -r boottime _ < /proc/uptime +echo "booted in ${boottime}s..." diff --git a/repos/core/initscripts/rc.modules b/repos/core/initscripts/rc.modules deleted file mode 100644 index 13f47935..00000000 --- a/repos/core/initscripts/rc.modules +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh - |