5 [ -f "/tmp/.firstboot" ] && {
6 echo "firstboot is already running"
11 jdev
=$
(mount |
awk '/jffs2/ {print $3}')
13 if [ -z "$jdev" ]; then
14 echo -n "Creating jffs2 partition... "
16 mount
-t jffs2
/dev
/mtdblock
/4 /jffs
20 echo "firstboot has already been run"
21 echo "jffs2 partition is mounted, only resetting files"
27 mount
/dev
/mtdblock
/2 /rom
-o ro
29 echo -n "creating directories... "
37 echo -n "setting up symlinks... "
38 for file in $
(cd /rom
; find * -type f
; find * -type l
;)
40 [ "${file%/*}" = "usr/lib/ipkg/info" ] && {
41 cp -f /rom
/$file $file
43 ln -sf /rom
/$file $file
48 echo -n "fixing ipkg symlinks... "
49 for file in $
( find /usr
/lib
/ipkg
/info
/*list
-type l
;)
51 rm $file; cp -f /rom
/$file $file
54 touch /tmp
/resolv.conf
55 ln -s /tmp
/resolv.conf
/etc
/resolv.conf
58 mount none
/jffs
/proc
-t proc
59 pivot_root
/jffs
/jffs
/rom
60 mount none
/dev
-t devfs
61 mount none
/tmp
-t ramfs
This page took 0.056226 seconds and 5 git commands to generate.