diff options
author | charansingh <charansingh.online@gmail.com> | 2011-02-02 01:35:29 +0530 |
---|---|---|
committer | Steve Kondik <shade@chemlab.org> | 2011-02-05 17:04:52 -0500 |
commit | d204b68f86631f31a54e728d47a760622524db1c (patch) | |
tree | bba9fe6fea7dc6b2fa0504a561370734015e1b40 /tools | |
parent | f161af25cce2eb021e86c294ad62def97b2d37e9 (diff) | |
download | vendor_replicant-d204b68f86631f31a54e728d47a760622524db1c.zip vendor_replicant-d204b68f86631f31a54e728d47a760622524db1c.tar.gz vendor_replicant-d204b68f86631f31a54e728d47a760622524db1c.tar.bz2 |
Add leo related vendor files in Cyanogen Vendor
Change-Id: Idb55f5a74dd07a2964fbc87d98f522bb1d921947
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/leoupdate | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/tools/leoupdate b/tools/leoupdate new file mode 100755 index 0000000..e282e56 --- /dev/null +++ b/tools/leoupdate @@ -0,0 +1,31 @@ +#!/bin/bash + +export LOC="$PWD/out/target/product/leo" + +mkdir -p "$LOC"/temp + +cd "$LOC"/temp +echo "extract update.zip" +unzip -o -qq "$LOC"/$TARGET_PRODUCT-ota-$TARGET_BUILD_VARIANT.$LOGNAME.zip + +echo "Making Leo Compatible Update script" +cd "$LOC" +cd "$LOC"/temp/META-INF/com/google/android +echo 'mount("yaffs2", "MTD", "boot", "/boot");' >> temp +echo 'package_extract_dir("boot", "/boot");' >> temp +grep -vw assert updater-script >> temp +rm -rf updater-script +grep -vw boot.img temp > updater-script +rm -rf temp +echo Zipping Package +cd "$LOC"/temp +rm -rf boot.img +cp -a "$LOC"/boot boot +rm -rf "$LOC"/$TARGET_PRODUCT-ota-$TARGET_BUILD_VARIANT.$LOGNAME.zip +zip -9yr "$LOC"/$TARGET_PRODUCT-ota-$TARGET_BUILD_VARIANT.$LOGNAME.zip * > /dev/null +cd "$LOC" + +echo Cleanup... +rm -rf "$LOC"/temp + +echo done |