mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-24 11:16:51 +00:00
init: there can be only one default systemd unit
This commit is contained in:
parent
b793ba8c80
commit
208d45db46
@ -108,10 +108,10 @@
|
||||
wol_wait="${arg#*=}"
|
||||
;;
|
||||
textmode)
|
||||
INIT_ARGS="$INIT_ARGS --unit=textmode.target"
|
||||
INIT_UNIT="--unit=textmode.target"
|
||||
;;
|
||||
installer)
|
||||
INIT_ARGS="$INIT_ARGS --unit=installer.target"
|
||||
INIT_UNIT="--unit=installer.target"
|
||||
;;
|
||||
debugging)
|
||||
DEBUG=yes
|
||||
@ -669,13 +669,13 @@
|
||||
|
||||
BACKUP_FILE=`ls -1 /sysroot/storage/.restore/??????????????.tar 2>/dev/null | head -n 1`
|
||||
if [ -f "$BACKUP_FILE" ] ; then
|
||||
INIT_ARGS="--unit=backup-restore.target"
|
||||
INIT_UNIT="--unit=backup-restore.target"
|
||||
fi
|
||||
|
||||
if [ -f /sysroot/storage/.cache/reset_oe -o -f /sysroot/storage/.cache/reset_xbmc ] ; then
|
||||
INIT_ARGS="--unit=factory-reset.target"
|
||||
INIT_UNIT="--unit=factory-reset.target"
|
||||
fi
|
||||
# switch to new sysroot and start real init
|
||||
exec /bin/busybox switch_root /sysroot /usr/lib/systemd/systemd $INIT_ARGS
|
||||
exec /bin/busybox switch_root /sysroot /usr/lib/systemd/systemd $INIT_ARGS $INIT_UNIT
|
||||
|
||||
error "switch_root" "Error in initramfs. Could not switch to new root"
|
||||
|
Loading…
x
Reference in New Issue
Block a user