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

Unified Diff: platform_tools/android/bin/android_gdb

Issue 22411004: Re-organize Android scripts (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 4 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 | platform_tools/android/bin/android_gdb_exe » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: platform_tools/android/bin/android_gdb
===================================================================
--- platform_tools/android/bin/android_gdb (revision 10559)
+++ platform_tools/android/bin/android_gdb (working copy)
@@ -4,32 +4,11 @@
# and enters debugging environment.
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-APP_NAME=$(basename $1)
+source $SCRIPT_DIR/android_setup.sh
+
+APP_NAME=${APP_ARGS[0]}
PORT=5039
-# Collect extra arguments to be passed to the Skia binary
-shift
-deviceID=""
-while (( "$#" )); do
-
- if [[ $(echo "$1" | grep "^-d$") != "" ]];
- then
- deviceID=$2
- shift
- else
- APP_ARGS="$APP_ARGS $1"
- fi
-
- shift
-done
-
-# hack for x86 support in android_setup.sh
-if [ "$deviceID" == "x86" ] || [ "$deviceID" == "razr_i" ]
-then
- ANDROID_ARCH=x86
-fi
-
-source $SCRIPT_DIR/android_setup.sh
source $SCRIPT_DIR/utils/setup_adb.sh
echo "Installing Skia Android app"
@@ -43,14 +22,14 @@
# We need the debug symbols from these files
GDB_TMP_DIR=$(pwd)/android_gdb_tmp
-mkdir $GDB_TMP_DIR
+mkdir -p $GDB_TMP_DIR
echo "Copying symbol files"
$ADB pull /system/bin/app_process $GDB_TMP_DIR
$ADB pull /system/lib/libc.so $GDB_TMP_DIR
$ADB pull /data/data/com.skia/lib/lib$APP_NAME.so $GDB_TMP_DIR
# Launch the app
-SK_COMMAND="$APP_NAME$APP_ARGS"
+SK_COMMAND="$APP_ARGS"
echo "Running command $SK_COMMAND"
$ADB shell am broadcast -a com.skia.intent.action.LAUNCH_SKIA -n com.skia/.SkiaReceiver -e args "$SK_COMMAND"
« no previous file with comments | « no previous file | platform_tools/android/bin/android_gdb_exe » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698