From 17f422c7fa855b7010233b37f4b99fec511f50d2 Mon Sep 17 00:00:00 2001 From: Sascha Silbe Date: Wed, 26 Jan 2011 15:06:06 +0000 Subject: sd_card_image: unversioned layout: don't duplicate files for /boot Duplicating the files destined for the boot partition on the root partition takes up precious space and has no real benefit: OFW can't use them because the root file system is ext4 (that was the reason to have a separate boot partition in the first place). --- diff --git a/modules/sd_card_image/image.50.makefs.sh b/modules/sd_card_image/image.50.makefs.sh index 6e61eb7..4fdc677 100644 --- a/modules/sd_card_image/image.50.makefs.sh +++ b/modules/sd_card_image/image.50.makefs.sh @@ -10,12 +10,11 @@ NUM_SECTORS_PER_TRACK=62 # FIXME trap signals and cleanup # FIXME check that traps due to errors are caught -BOOT=$intermediatesdir/mnt-boot ROOT=$intermediatesdir/mnt-root +BOOT=$ROOT/boot umount $BOOT &>/dev/null || : umount $ROOT &>/dev/null || : -mkdir -p $BOOT mkdir -p $ROOT @@ -60,12 +59,13 @@ EOF losetup -o $(((8192 + 131072) * $BLOCK_SIZE)) --sizelimit $(($img_sectors * $BLOCK_SIZE)) /dev/loop7 $img echo "Create filesystems..." - mke2fs -O dir_index,^resize_inode -L Boot -F /dev/loop6 - mount /dev/loop6 $BOOT - mkfs.ext4 -O dir_index,^huge_file -E resize=8G -m1 -L OLPCRoot /dev/loop7 tune2fs -o journal_data_ordered /dev/loop7 mount /dev/loop7 $ROOT + mkdir -p $BOOT + + mke2fs -O dir_index,^resize_inode -L Boot -F /dev/loop6 + mount /dev/loop6 $BOOT echo "Copy in root filesystem..." cp -a $fsmount/* $ROOT @@ -92,12 +92,11 @@ EOF ln -s boot/alt $BOOT/boot-alt cp -ar $ROOT/versions/pristine/$buildnr/boot/* $tgt else - cp -ar $ROOT/boot/* $BOOT ln -s . $BOOT/boot fi - umount $ROOT umount $BOOT + umount $ROOT losetup -d /dev/loop6 || : losetup -d /dev/loop7 || : -- cgit v0.9.1