diff options
author | Jessica Wagantall <jwagantall@cyngn.com> | 2015-11-11 13:00:36 -0800 |
---|---|---|
committer | Jessica Wagantall <jwagantall@cyngn.com> | 2015-11-11 16:12:04 -0800 |
commit | 854ca26f5a3dab57a995db4c989636865c960128 (patch) | |
tree | 1eaa3143da59ea9797662c2c5803eb2c6ca8eab9 /tools/device | |
parent | e9f828c71cf3c5a5c2eb3c00f0a8ea28a867d5ba (diff) | |
download | build-854ca26f5a3dab57a995db4c989636865c960128.zip build-854ca26f5a3dab57a995db4c989636865c960128.tar.gz build-854ca26f5a3dab57a995db4c989636865c960128.tar.bz2 |
build: Do not make recoveries or recoveryzip
Change-Id: I5a599eb3ba3f3450d9dfeab390c527a586bcaa68
Diffstat (limited to 'tools/device')
-rw-r--r-- | tools/device/makerecoveries.sh | 69 | ||||
-rwxr-xr-x | tools/device/mkrecoveryzip.sh | 97 | ||||
-rwxr-xr-x | tools/device/mkvendor.sh | 2 |
3 files changed, 0 insertions, 168 deletions
diff --git a/tools/device/makerecoveries.sh b/tools/device/makerecoveries.sh deleted file mode 100644 index f561c81..0000000 --- a/tools/device/makerecoveries.sh +++ /dev/null @@ -1,69 +0,0 @@ -if [ -z "$1" ] -then - echo "Please provide a lunch option." - return -fi - -PRODUCTS=$1 - -for product in $PRODUCTS -do - echo $product -done - -echo $(echo $PRODUCTS | wc -w) Products - -unset PUBLISHED_RECOVERIES - -MCP=$(which mcp) -if [ -z "$MCP" ] -then - NO_UPLOAD=true -fi - -function mcpguard () { - if [ -z $NO_UPLOAD ] - then - mcp $1 $2 - md5sum $1 > $1.md5sum.txt - mcp $1.md5sum.txt $2.md5sum.txt - fi -} - -VERSION=$(cat bootable/recovery/Android.mk | grep RECOVERY_VERSION | grep RECOVERY_NAME | awk '{ print $4 }' | sed s/v//g) -echo Recovery Version: $VERSION - -for lunchoption in $PRODUCTS -do - lunch $lunchoption - if [ -z $NO_CLEAN ] - then - rm -rf $OUT/obj/EXECUTABLES/recovery_intermediates - rm -rf $OUT/recovery* - rm -rf $OUT/root* - fi - DEVICE_NAME=$(echo $TARGET_PRODUCT | sed s/koush_// | sed s/aosp_// | sed s/motorola// | sed s/huawei_// | sed s/htc_// | sed s/_us// | sed s/cyanogen_// | sed s/generic_// | sed s/full_//) - PRODUCT_NAME=$(basename $OUT) - make -j16 recoveryzip - RESULT=$? - if [ $RESULT != "0" ] - then - echo build error! - break - fi - mcpguard $OUT/recovery.img recoveries/recovery-clockwork-$VERSION-$DEVICE_NAME.img - mcpguard $OUT/utilities/update.zip recoveries/recovery-clockwork-$VERSION-$DEVICE_NAME.zip - - if [ -f "ROMManagerManifest/devices.rb" ] - then - pushd ROMManagerManifest - ruby devices.rb $DEVICE_NAME $VERSION $lunchoption - popd - fi -done - -for published_recovery in $PUBLISHED_RECOVERIES -do - echo $published_recovery -done - diff --git a/tools/device/mkrecoveryzip.sh b/tools/device/mkrecoveryzip.sh deleted file mode 100755 index e6fae37..0000000 --- a/tools/device/mkrecoveryzip.sh +++ /dev/null @@ -1,97 +0,0 @@ -#!/bin/bash - -OUT=$1 -SIGNAPK=$2 - -if [ -z "$OUT" -o -z "$SIGNAPK" ] -then - echo "Android build environment not detected." - exit 1 -fi - -ANDROID_ROOT=$(pwd) -OUT=$ANDROID_ROOT/$OUT -SIGNAPK=$ANDROID_ROOT/$SIGNAPK - -pushd . > /dev/null 2> /dev/null - -UTILITIES_DIR=$OUT/utilities -mkdir -p $UTILITIES_DIR -RECOVERY_DIR=$UTILITIES_DIR/recovery -rm -rf $RECOVERY_DIR -mkdir -p $RECOVERY_DIR -cd $RECOVERY_DIR -cp -R $OUT/recovery/root/etc etc -cp -R $OUT/recovery/root/sbin sbin -cp -R $OUT/recovery/root/res res -SCRIPT_DIR=META-INF/com/google/android -mkdir -p $SCRIPT_DIR -cp $OUT/system/bin/updater $SCRIPT_DIR/update-binary - - -UPDATER_SCRIPT=$SCRIPT_DIR/updater-script -rm -f $UPDATER_SCRIPT -touch $UPDATER_SCRIPT -mkdir -p $(dirname $UPDATER_SCRIPT) - -FILES= -SYMLINKS= - -for file in $(find .) -do - -if [ -d $file ] -then - continue -fi - -META_INF=$(echo $file | grep META-INF) -if [ ! -z $META_INF ] -then - continue; -fi - -if [ -h $file ] -then - SYMLINKS=$SYMLINKS' '$file -elif [ -f $file ] -then - FILES=$FILES' '$file -fi -done - - -echo 'ui_print("Replacing stock recovery with ClockworkMod recovery...");' >> $UPDATER_SCRIPT - -echo 'delete("sbin/recovery");' >> $UPDATER_SCRIPT -echo 'package_extract_file("sbin/recovery", "/sbin/recovery");' >> $UPDATER_SCRIPT -echo 'set_perm(0, 0, 0755, "/sbin/recovery");' >> $UPDATER_SCRIPT -echo 'symlink("recovery", "/sbin/busybox");' >> $UPDATER_SCRIPT - -echo 'run_program("/sbin/busybox", "sh", "-c", "busybox rm -f /etc ; busybox mkdir -p /etc;");' >> $UPDATER_SCRIPT - -for file in $FILES -do - echo 'delete("'$(echo $file | sed s!\\./!!g)'");' >> $UPDATER_SCRIPT - echo 'package_extract_file("'$(echo $file | sed s!\\./!!g)'", "'$(echo $file | sed s!\\./!/!g)'");' >> $UPDATER_SCRIPT - if [ -x $file ] - then - echo 'set_perm(0, 0, 0755, "'$(echo $file | sed s!\\./!/!g)'");' >> $UPDATER_SCRIPT - fi -done - -for file in $SYMLINKS -do - echo 'symlink("'$(readlink $file)'", "'$(echo $file | sed s!\\./!/!g)'");' >> $UPDATER_SCRIPT -done - -echo 'set_perm_recursive(0, 2000, 0755, 0755, "/sbin");' >> $UPDATER_SCRIPT -echo 'run_program("/sbin/busybox", "sh", "-c", "/sbin/killrecovery.sh");' >> $UPDATER_SCRIPT -rm -f $UTILITIES_DIR/unsigned.zip -rm -f $UTILITIES_DIR/update.zip -echo zip -ry $UTILITIES_DIR/unsigned.zip . -x $SYMLINKS '*\[*' '*\[\[*' -zip -ry $UTILITIES_DIR/unsigned.zip . -x $SYMLINKS '*\[*' '*\[\[*' -java -jar $SIGNAPK -w $ANDROID_ROOT/build/target/product/security/testkey.x509.pem $ANDROID_ROOT/build/target/product/security/testkey.pk8 $UTILITIES_DIR/unsigned.zip $UTILITIES_DIR/update.zip - -echo Recovery FakeFlash is now available at $OUT/utilities/update.zip -popd > /dev/null 2> /dev/null diff --git a/tools/device/mkvendor.sh b/tools/device/mkvendor.sh index 778d82d..18671c0 100755 --- a/tools/device/mkvendor.sh +++ b/tools/device/mkvendor.sh @@ -111,5 +111,3 @@ popd echo Done! echo Use the following command to set up your build environment: echo ' 'lunch cm_$DEVICE-eng -echo And use the follwowing command to build a recovery: -echo ' '. build/tools/device/makerecoveries.sh cm_$DEVICE-eng |