Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(224)

Unified Diff: src/scripts/build_gpt.sh

Issue 2127010: fix for issue 2610 (Closed) Base URL: ssh://git@chromiumos-git/chromeos
Patch Set: fixed a typo on install_gpt line Created 10 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/platform/installer/chromeos-install ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/scripts/build_gpt.sh
diff --git a/src/scripts/build_gpt.sh b/src/scripts/build_gpt.sh
index fb96b85846518bfc6ae79b14863babc74d02dbc6..d9fee4a84493c886ee287887416cce9857cadc12 100755
--- a/src/scripts/build_gpt.sh
+++ b/src/scripts/build_gpt.sh
@@ -80,7 +80,6 @@ set -u
# Check for missing parts.
# For recovery image, only populate ROOT-A and KERN-A
-# TODO(tgao): write a script to populate ROOT-B and KERN-B
ROOTFS_IMG="${IMAGEDIR}/rootfs.image"
if [[ ! -s ${ROOTFS_IMG} ]]; then
error "Can't find ${ROOTFS_IMG}"
@@ -150,6 +149,17 @@ $sudo dd if=${KERNEL_IMG} of=${OUTDEV} conv=notrunc bs=512 seek=${START_KERN_A}
echo "Copying rootfs..."
$sudo dd if=${ROOTFS_IMG} of=${OUTDEV} conv=notrunc bs=512 seek=${START_ROOTFS_A}
+# TODO(tgao): write a script to populate ROOT-B and KERN-B with user-specified
+# rootfs and kernel. Do NOT remove if block below until then (otherwise
+# chromeos-installer will fail b/c it expects to install from partition B)
+if [ ${FLAGS_recovery} -eq $FLAGS_TRUE ]; then
+ echo "Copying kernel B..."
+ $sudo dd if=${KERNEL_IMG} of=${OUTDEV} conv=notrunc bs=512 seek=${START_KERN_B}
adlr 2010/05/20 20:41:22 wrap this and the next line to 80 cols (you'll nee
Tan Gao 2010/05/20 20:50:41 good style! fixed START_KERN_A line above as well
+
+ echo "Copying rootfs B..."
+ $sudo dd if=${ROOTFS_IMG} of=${OUTDEV} conv=notrunc bs=512 seek=${START_ROOTFS_B}
+fi
+
echo "Copying EFI system partition..."
$sudo dd if=${ESP_IMG} of=${OUTDEV} conv=notrunc bs=512 seek=${START_ESP}
« no previous file with comments | « src/platform/installer/chromeos-install ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698