lfs-execline-scripts

Repository for execline scripts used in my linux-from-scratch builds
Log | Files | Refs

commit 164b790b93632c6e0ff75d3cf119321f34acb7e7
parent 4b94de0615fa654d619333a8b155fca2abf877bf
Author: mrgrouse <bdmfegys@duck.com>
Date:   Sun,  3 Aug 2025 05:04:58 -0400

sinit/rc.shutdown: remove saving of sysclock, offload to svc script call

Diffstat:
Msinit/rc.shutdown | 27++++-----------------------
1 file changed, 4 insertions(+), 23 deletions(-)

diff --git a/sinit/rc.shutdown b/sinit/rc.shutdown @@ -23,28 +23,8 @@ foreground { /bin/stty onclr } background { printf "Shutting down...\n" } -define hwclock_params "-w" - -case -N -- $HARDWARECLOCK -{ - "" {} - "UTC" { HW } #FIXME - "localtime" { define hwclock_params "-l ${hwclock_params}" } - -} { define hwclock_params "" } # default case - -foreground { - if { eltest -n $hwclock_params } - { - background { printf "Saving System Clock\n" } - foreground { - if { eltest -n $TIMEZONE } - { export TZ $TIMEZONE } - } - if { /bin/hwclock ${hwclock_params} /dev/rtc0 } - { unexport TZ } - } -} +# save system clock +foreground { svc -k hwclock } background { /bin/printf "Storing random seed...\n" } @@ -74,4 +54,4 @@ case -N -- $1 { "reboot" { /bin/halt -r } "poweroff" { /bin/halt -p } -} +} +\ No newline at end of file