slitaz-arm rev 200
tazbian: need mmcblk0 devices
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Tue Nov 18 13:40:01 2014 +0100 (2014-11-18) |
parents | e04e276de7ec |
children | aef225322253 |
files | rpi/tazbian |
line diff
1.1 --- a/rpi/tazbian Tue Nov 18 10:50:30 2014 +0100 1.2 +++ b/rpi/tazbian Tue Nov 18 13:40:01 2014 +0100 1.3 @@ -49,6 +49,10 @@ 1.4 mv piboot $BASE/sbin 1.5 sed -i 's|mnt /mnt|mnt "/mnt -o noatime"|' init 1.6 mv init $BASE/sbin/pisubroot 1.7 +mknod -m 660 $BASE/dev/mmcblk0 b 179 0 1.8 +mknod -m 660 $BASE/dev/mmcblk0p1 b 179 1 1.9 +mknod -m 660 $BASE/dev/mmcblk0p2 b 179 2 1.10 +sed -i 's/.*mmcblk0p[2-9].*/# &/;s/noatime/noauto,/' $BASE/etc/fstab 1.11 wget http://cook.slitaz.org/cross/arm/packages/packages.list 1.12 while read file pkg extra ; do 1.13 [ -s boot$file ] && continue 1.14 @@ -136,12 +140,14 @@ 1.15 RDEV=\$(sed 's/.*root=\([^ ]*\).*/\1/' /boot/cmdline.txt) 1.16 FSTYPE=\$(awk '/ \/ / { if (\$1 != "rootfs") print \$3 }' < /proc/mounts) 1.17 1.18 +echo "Extracting /$DESTDIR ..." 1.19 cd /$DESTDIR 1.20 zcat /boot/slitaz/rootfs-base.gz | cpio -idmu 1.21 zcat /boot/slitaz/rootfs-live.gz | cpio -idmu 1.22 -[ -d mnt/raspbian ] || mkdir -p mnt/raspbian 1.23 if ! grep -qs raspbian etc/fstab ; then 1.24 - sed -i 's/.*mmcblk0p[2-9].*/#&/' etc/fstab 1.25 + echo "Update /$DESTDIR/etc/fstab ..." 1.26 + mkdir -p mnt/raspbian 1.27 + sed -i 's/noauto,//' etc/fstab 1.28 cat >> etc/fstab <<EOM 1.29 \$RDEV /mnt/raspbian \$FSTYPE noatime 0 0 1.30 tmpfs /mnt/raspbian/$DESTDIR tmpfs size=0 0 0 1.31 @@ -151,6 +157,7 @@ 1.32 1.33 if [ ! -f /boot/menu.txt ]; then 1.34 1.35 +echo "Update /boot ..." 1.36 for i in keyboard locale ; do 1.37 [ -s /etc/default/\$i ] && . /etc/default/\$i 1.38 done 1.39 @@ -193,12 +200,14 @@ 1.40 1.41 purge() 1.42 { 1.43 + echo "Remove /$DESTDIR /boot/slitaz* trees..." 1.44 rm -rf /$DESTDIR /boot/slitaz* 1.45 } 1.46 1.47 disable() 1.48 { 1.49 if [ -d /boot/rasbian ]; then 1.50 + echo "Restore rasbian boot files..." 1.51 mv -f /boot/rasbian/* /boot 1.52 rm -rf /boot/rasbian 1.53 fi