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

Unified Diff: src/scripts/image_to_usb.sh

Issue 600074: Create a fourth partition to put the raw kernel image in. (Closed)
Patch Set: Simplify kernel_fetcher.sh and make it more robust. Created 10 years, 10 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 | « no previous file | src/scripts/kernel_fetcher.sh » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/scripts/image_to_usb.sh
diff --git a/src/scripts/image_to_usb.sh b/src/scripts/image_to_usb.sh
index d0cc1ebfc8999fd47f84867b84a978544023e012..c674e2f8fdc777cfa5f3e7bb7d9a984c0a062fda 100755
--- a/src/scripts/image_to_usb.sh
+++ b/src/scripts/image_to_usb.sh
@@ -19,6 +19,8 @@ DEFINE_string to "" "$DEFAULT_TO_HELP"
DEFINE_boolean yes $FLAGS_FALSE "Answer yes to all prompts" "y"
DEFINE_boolean install_autotest $FLAGS_FALSE \
"Whether to install autotest to the stateful partition."
+DEFINE_boolean copy_kernel $FLAGS_FALSE \
+ "Copy the kernel to the fourth partition."
# Parse command line
FLAGS "$@" || exit 1
@@ -159,6 +161,15 @@ then
trap - EXIT
+ if [ $FLAGS_copy_kernel -eq $FLAGS_TRUE ]
+ then
+ echo "Copying Kernel..."
+ "${SCRIPTS_DIR}"/kernel_fetcher.sh \
+ --from "${FLAGS_from}" \
+ --to "${FLAGS_to}" \
+ --offset "$(( ($PART_SIZE * 3) + 512 ))"
+ fi
+
echo "Copying MBR..."
sudo "${SCRIPTS_DIR}"/file_copy.py \
if="${FLAGS_from}/mbr.image" of="$FLAGS_to"
« no previous file with comments | « no previous file | src/scripts/kernel_fetcher.sh » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698