mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-28 13:16:41 +00:00
add a simple update mechanism: put a file openelec.kernel or/and openelec.system to a /.update dir on storage device and the OpenELEC system does a automatic update and removes this files on /.update
This commit is contained in:
parent
4c65fa207e
commit
0ce6f9a219
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# Automatically generated make config: don't edit
|
# Automatically generated make config: don't edit
|
||||||
# Busybox version: 1.13.1
|
# Busybox version: 1.13.3
|
||||||
# Thu Dec 4 14:25:56 2008
|
# Mon Apr 6 01:22:51 2009
|
||||||
#
|
#
|
||||||
CONFIG_HAVE_DOT_CONFIG=y
|
CONFIG_HAVE_DOT_CONFIG=y
|
||||||
|
|
||||||
@ -191,8 +191,8 @@ CONFIG_MKDIR=y
|
|||||||
# CONFIG_FEATURE_MKDIR_LONG_OPTIONS is not set
|
# CONFIG_FEATURE_MKDIR_LONG_OPTIONS is not set
|
||||||
# CONFIG_MKFIFO is not set
|
# CONFIG_MKFIFO is not set
|
||||||
# CONFIG_MKNOD is not set
|
# CONFIG_MKNOD is not set
|
||||||
# CONFIG_MV is not set
|
CONFIG_MV=y
|
||||||
# CONFIG_FEATURE_MV_LONG_OPTIONS is not set
|
CONFIG_FEATURE_MV_LONG_OPTIONS=y
|
||||||
# CONFIG_NICE is not set
|
# CONFIG_NICE is not set
|
||||||
# CONFIG_NOHUP is not set
|
# CONFIG_NOHUP is not set
|
||||||
# CONFIG_OD is not set
|
# CONFIG_OD is not set
|
||||||
@ -202,12 +202,12 @@ CONFIG_MKDIR=y
|
|||||||
# CONFIG_READLINK is not set
|
# CONFIG_READLINK is not set
|
||||||
# CONFIG_FEATURE_READLINK_FOLLOW is not set
|
# CONFIG_FEATURE_READLINK_FOLLOW is not set
|
||||||
# CONFIG_REALPATH is not set
|
# CONFIG_REALPATH is not set
|
||||||
# CONFIG_RM is not set
|
CONFIG_RM=y
|
||||||
# CONFIG_RMDIR is not set
|
# CONFIG_RMDIR is not set
|
||||||
# CONFIG_FEATURE_RMDIR_LONG_OPTIONS is not set
|
# CONFIG_FEATURE_RMDIR_LONG_OPTIONS is not set
|
||||||
# CONFIG_SEQ is not set
|
# CONFIG_SEQ is not set
|
||||||
# CONFIG_SHA1SUM is not set
|
# CONFIG_SHA1SUM is not set
|
||||||
# CONFIG_SLEEP is not set
|
CONFIG_SLEEP=y
|
||||||
# CONFIG_FEATURE_FANCY_SLEEP is not set
|
# CONFIG_FEATURE_FANCY_SLEEP is not set
|
||||||
# CONFIG_FEATURE_FLOAT_SLEEP is not set
|
# CONFIG_FEATURE_FLOAT_SLEEP is not set
|
||||||
# CONFIG_SORT is not set
|
# CONFIG_SORT is not set
|
||||||
@ -218,7 +218,7 @@ CONFIG_MKDIR=y
|
|||||||
# CONFIG_FEATURE_STAT_FORMAT is not set
|
# CONFIG_FEATURE_STAT_FORMAT is not set
|
||||||
# CONFIG_STTY is not set
|
# CONFIG_STTY is not set
|
||||||
# CONFIG_SUM is not set
|
# CONFIG_SUM is not set
|
||||||
# CONFIG_SYNC is not set
|
CONFIG_SYNC=y
|
||||||
# CONFIG_TAC is not set
|
# CONFIG_TAC is not set
|
||||||
# CONFIG_TAIL is not set
|
# CONFIG_TAIL is not set
|
||||||
# CONFIG_FEATURE_FANCY_TAIL is not set
|
# CONFIG_FEATURE_FANCY_TAIL is not set
|
||||||
@ -244,6 +244,10 @@ CONFIG_TEST=y
|
|||||||
# CONFIG_WHO is not set
|
# CONFIG_WHO is not set
|
||||||
# CONFIG_WHOAMI is not set
|
# CONFIG_WHOAMI is not set
|
||||||
# CONFIG_YES is not set
|
# CONFIG_YES is not set
|
||||||
|
|
||||||
|
#
|
||||||
|
# Common options for cp and mv
|
||||||
|
#
|
||||||
# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set
|
# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set
|
||||||
# CONFIG_FEATURE_AUTOWIDTH is not set
|
# CONFIG_FEATURE_AUTOWIDTH is not set
|
||||||
# CONFIG_FEATURE_HUMAN_READABLE is not set
|
# CONFIG_FEATURE_HUMAN_READABLE is not set
|
||||||
@ -360,7 +364,7 @@ CONFIG_FEATURE_KILL_DELAY=0
|
|||||||
# CONFIG_FEATURE_EXTRA_QUIET is not set
|
# CONFIG_FEATURE_EXTRA_QUIET is not set
|
||||||
# CONFIG_FEATURE_INIT_COREDUMPS is not set
|
# CONFIG_FEATURE_INIT_COREDUMPS is not set
|
||||||
# CONFIG_FEATURE_INITRD is not set
|
# CONFIG_FEATURE_INITRD is not set
|
||||||
# CONFIG_HALT is not set
|
CONFIG_HALT=y
|
||||||
# CONFIG_MESG is not set
|
# CONFIG_MESG is not set
|
||||||
|
|
||||||
#
|
#
|
||||||
|
@ -11,10 +11,30 @@
|
|||||||
/bin/busybox mount -t ext3 -o ro,noatime $BOOT /flash
|
/bin/busybox mount -t ext3 -o ro,noatime $BOOT /flash
|
||||||
/bin/busybox mount -t ext3 -o rw,noatime $DISK /storage
|
/bin/busybox mount -t ext3 -o rw,noatime $DISK /storage
|
||||||
|
|
||||||
|
if [ -f "/storage/.update/openelec.kernel" ]; then
|
||||||
|
echo "updating Kernel..."
|
||||||
|
/bin/busybox mount -o remount,rw /flash
|
||||||
|
/bin/busybox mv /storage/.update/openelec.kernel /flash/openelec.kernel
|
||||||
|
/bin/busybox mount -o remount,ro /flash
|
||||||
|
/bin/busybox sync
|
||||||
|
echo "... done"
|
||||||
|
echo "System reboots in 5 seconds"
|
||||||
|
/bin/busybox sleep 5
|
||||||
|
/bin/busybox reboot
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -f "/storage/.update/openelec.system" ]; then
|
||||||
|
echo "updating System..."
|
||||||
|
/bin/busybox mount -o remount,rw /flash
|
||||||
|
/bin/busybox mv /storage/.update/openelec.system /flash/openelec.system
|
||||||
|
/bin/busybox mount -o remount,ro /flash
|
||||||
|
echo "... done"
|
||||||
|
fi
|
||||||
|
|
||||||
if [ -f "/flash/openelec.system" ]; then
|
if [ -f "/flash/openelec.system" ]; then
|
||||||
/bin/busybox mount /flash/openelec.system /sysroot
|
/bin/busybox mount /flash/openelec.system /sysroot
|
||||||
if [ $? -ne 0 ] ; then
|
if [ $? -ne 0 ] ; then
|
||||||
echo Could not mount system on /sysroot. Starting debugging shell....
|
echo "Could not mount system on /sysroot. Starting debugging shell..."
|
||||||
/bin/busybox sh </dev/tty1 >/dev/tty1 2>&1
|
/bin/busybox sh </dev/tty1 >/dev/tty1 2>&1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
@ -26,3 +46,6 @@
|
|||||||
/bin/busybox umount /sys
|
/bin/busybox umount /sys
|
||||||
|
|
||||||
exec /bin/busybox switch_root /sysroot /sbin/init.system
|
exec /bin/busybox switch_root /sysroot /sbin/init.system
|
||||||
|
|
||||||
|
echo "Error in initramfs. Starting debugging shell..."
|
||||||
|
/bin/busybox sh </dev/tty1 >/dev/tty1 2>&1
|
||||||
|
Loading…
x
Reference in New Issue
Block a user