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

Side by Side Diff: build/android/gdb_apk

Issue 15028013: Use $ANDROID_TOOLCHAIN set by envsetup.sh in adb_gdb and gdb_apk (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased on https://codereview.chromium.org/14858018/ (r199234) Created 7 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 unified diff | Download patch
« no previous file with comments | « build/android/adb_gdb ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/bin/bash 1 #!/bin/bash
2 # 2 #
3 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 3 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 # 6 #
7 # Attach gdb to a running android application. Similar to ndk-gdb. 7 # Attach gdb to a running android application. Similar to ndk-gdb.
8 # Run with --annotate=3 if running under emacs (M-x gdb). 8 # Run with --annotate=3 if running under emacs (M-x gdb).
9 # 9 #
10 # By default it is used to debug content shell, if it is used to 10 # By default it is used to debug content shell, if it is used to
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
151 151
152 # gdb commands 152 # gdb commands
153 cmdfile=$(mktemp /tmp/gdb_android_XXXXXXXX) 153 cmdfile=$(mktemp /tmp/gdb_android_XXXXXXXX)
154 cat >$cmdfile<<EOF 154 cat >$cmdfile<<EOF
155 # set solib-absolute-prefix null 155 # set solib-absolute-prefix null
156 set solib-search-path ${shared_lib_dir} 156 set solib-search-path ${shared_lib_dir}
157 file ${app_process} 157 file ${app_process}
158 target remote :4321 158 target remote :4321
159 EOF 159 EOF
160 160
161 gdb=$(echo $ANDROID_TOOLCHAIN/../../linux-x86/bin/*gdb) 161 gdb=$(echo $ANDROID_TOOLCHAIN/*gdb)
162 if [[ ! -f ${gdb} ]] ; then 162 if [[ ! -f ${gdb} ]] ; then
163 echo "Wow no gdb in env var ANDROID_TOOLCHAIN which is $ANDROID_TOOLCHAIN" 163 echo "Wow no gdb in env var ANDROID_TOOLCHAIN which is $ANDROID_TOOLCHAIN"
164 exit 4 164 exit 4
165 else 165 else
166 echo Using $gdb 166 echo Using $gdb
167 fi 167 fi
168 168
169 # ${gdb} -x $cmdfile $* $app_process 169 # ${gdb} -x $cmdfile $* $app_process
170 ${gdb} -x $cmdfile $gdb_args 170 ${gdb} -x $cmdfile $gdb_args
171 rm $cmdfile 171 rm $cmdfile
OLDNEW
« no previous file with comments | « build/android/adb_gdb ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698