blob: 5914c3f87036e7cffceb8153332c4977427bec0a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
#!/bin/sh
prefix=@prefix@
exec_prefix=@exec_prefix@
if [ -x @bindir@/showiframe -a -f /boot/backdrop.mvi ]; then
@bindir@/showiframe /boot/backdrop.mvi
fi
# hook to execute scripts always before enigma2 start
if [ -x @bindir@/enigma2_pre_start.sh ]; then
@bindir@/enigma2_pre_start.sh
fi
if [ -d /home/root ]; then
cd /home/root
fi
LIBS=@libdir@/libopen.so.0.0.0
#check for dreambox specific passthrough helper lib
if [ -e @libdir@/libpassthrough.so ]; then
LIBS="$LIBS @libdir@/libpassthrough.so"
fi
LD_PRELOAD=$LIBS @bindir@/enigma2
# enigma2 exit codes:
#
# 0 - restart enigma
# 1 - halt
# 2 - reboot
#
# >128 signal
ret=$?
case $ret in
1)
/sbin/halt
;;
2)
/sbin/reboot
;;
4)
/sbin/rmmod lcd
/usr/sbin/fpupgrade --upgrade 2>&1 | tee /home/root/fpupgrade.log
sleep 1;
/sbin/rmmod fp
/sbin/modprobe fp
/sbin/reboot
;;
*)
;;
esac
|