-
Notifications
You must be signed in to change notification settings - Fork 1
/
debugchumby
executable file
·64 lines (63 loc) · 2.19 KB
/
debugchumby
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
55
56
57
58
59
60
61
62
63
#!/bin/sh
# kill the built-in web server
stff=`/usr/chumby/scripts/chumby_version -s`
killall httpd
# create the log directory
mkdir /tmp/logs
rm -f /mnt/usb/tmp/*
# start lighttpd
LD_LIBRARY_PATH=/mnt/usb/lighty/lib:${LD_LIBRARY_PATH} /mnt/usb/lighty/sbin/lighttpd -m /mnt/usb/lighty/lib -f /mnt/usb/lighty/lighttpd.conf >/mnt/usb/tmp/write.ok
if [ -f /mnt/usb/autoreboot.on ]; then
/mnt/usb/TalkingChumby/say.sh "Welcome to Zurk's Chumby Offline Firmware v 34"
else
# rebind /scripts for /usr/chumby/scripts. disable the networking scripts as required.
#/usr/bin/iwconfig wlan0 mode Ad-Hoc essid chumbynet key AAAA-1111-22 2>&1 >> /mnt/usb/ifconfig.log
#/sbin/ifconfig wlan0 192.168.2.2 netmask 255.255.255.0 broadcast 192.168.2.255 2>&1 >> /mnt/usb/ifconfig.log
#/sbin/ifconfig wlan0 up 2>&1 >> /mnt/usb/ifconfig.log
#/sbin/ifconfig 2>&1 >> /mnt/usb/ifconfig.log
#mkdir /mnt/usb/tmp
#cp -r /tmp /mnt/usb/tmp
#sync
if [ "$stff" = "1.0.7" ]; then
mount /mnt/usb/scripts -o bind /usr/chumby/scripts
fi
sync
/mnt/usb/TalkingChumby/say.sh "Welcome to Zurk's Chumby Offline Firmware v 34 in networkless mode"
fi
touch /mnt/usb/tmp/write.ok
sync
if [ -f /mnt/usb/tmp/write.ok ]; then
sync
else
/mnt/usb/TalkingChumby/say.sh "Error the storage disk is read only"
fi
if [ -f /mnt/usb/dlna.on ]; then
cp /mnt/usb/dlna.on /tmp/dlna.on
else
sync
fi
if [ -f /mnt/usb/bonjour.off ]; then
cp /mnt/usb/bonjour.off /tmp/bonjour.off
else
sync
fi
#woops - we can't actually mount swap files with this chumby kernel ...so let's disable this whole chunk:
#if [ -f /mnt/usb/swapfile.on ]; then
# if ! [ -f /mnt/usb/.swap ]; then
# rm -f /mnt/usb/swapfile.on
# /mnt/usb/TalkingChumby/say.sh "Building the 512 MegaByte swapfile. This will take quite some time"
# dd if=/dev/zero of=/mnt/usb/.swap bs=1 count=0 seek=512M
# /mnt/usb/TalkingChumby/say.sh "Making the swapfile"
# mkswap /mnt/usb/.swap
# /mnt/usb/TalkingChumby/say.sh "Swapfile built O K"
# else
# /mnt/usb/TalkingChumby/say.sh "Mounting existing swap file"
# mkswap /mnt/usb/.swap
# fi
#else
# sync
#fi
cp -f /mnt/usb/www/gif.swf /tmp/gif.swf
cp -f /mnt/usb/www/gif.swf /tmp/sat.swf
cp -f /psp/crontabs/root /var/spool/cron/crontabs/
/usr/chumby/scripts/fb_cgi.sh