Merge lp:~mwaddel/linaro-image-tools/create-gzip-image into lp:linaro-image-tools/11.11

Proposed by Matt Waddel
Status: Merged
Merged at revision: 20
Proposed branch: lp:~mwaddel/linaro-image-tools/create-gzip-image
Merge into: lp:linaro-image-tools/11.11
Diff against target: 28 lines (+6/-2)
1 file modified
linaro-media-create (+6/-2)
To merge this branch: bzr merge lp:~mwaddel/linaro-image-tools/create-gzip-image
Reviewer Review Type Date Requested Status
Alexander Sack (community) Approve
Review via email: mp+28947@code.launchpad.net

Description of the change

Create .gz file from <file>.img.
Fix SWAP file calculation.

To post a comment you must log in.
Revision history for this message
Alexander Sack (asac) wrote :

ok. pushed this change though i think committing both changes in separate commits would have been cleaner :). Anyway, lets continue ...

review: Needs Resubmitting
Revision history for this message
Alexander Sack (asac) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'linaro-media-create'
--- linaro-media-create 2010-06-18 18:56:17 +0000
+++ linaro-media-create 2010-06-30 22:42:25 +0000
@@ -250,14 +250,14 @@
250250
251 SPACE_LEFT=$(df ${DIR}/disk/ | grep ${MMC2} | awk '{print $4}')251 SPACE_LEFT=$(df ${DIR}/disk/ | grep ${MMC2} | awk '{print $4}')
252252
253 let SIZE=$SWAP_SIZE*1024*1024253 let SIZE=$SWAP_SIZE*1024
254254
255 if [ $SPACE_LEFT -ge $SIZE ] ; then255 if [ $SPACE_LEFT -ge $SIZE ] ; then
256 sudo dd if=/dev/zero of=${DIR}/disk/mnt/SWAP.swap bs=1M count=$SWAP_SIZE256 sudo dd if=/dev/zero of=${DIR}/disk/mnt/SWAP.swap bs=1M count=$SWAP_SIZE
257 sudo mkswap ${DIR}/disk/mnt/SWAP.swap257 sudo mkswap ${DIR}/disk/mnt/SWAP.swap
258 echo "/mnt/SWAP.swap none swap sw 0 0" | sudo tee -a ${DIR}/disk/etc/fstab258 echo "/mnt/SWAP.swap none swap sw 0 0" | sudo tee -a ${DIR}/disk/etc/fstab
259 else259 else
260 echo "FIXME Recovery after user selects SWAP file bigger then whats left not implemented"260 echo "SWAP file bigger then whats left on partition"
261 fi261 fi
262 fi262 fi
263263
@@ -532,3 +532,7 @@
532 populate_boot532 populate_boot
533 populate_rootfs533 populate_rootfs
534534
535 if [ "${IMAGE_FILE}" ]; then
536 echo "Create ${IMAGE_FILE}.gz"
537 gzip -f ${IMAGE_FILE} > ${IMAGE_FILE}.gz
538 fi

Subscribers

People subscribed via source and target branches