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

Side by Side Diff: build/android/adb_gdb

Issue 26337002: Fix adb_gdb script. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | 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 7
8 # A generic script used to attach to a running Chromium process and 8 # A generic script used to attach to a running Chromium process and
9 # debug it. Most users should not use this directly, but one of the 9 # debug it. Most users should not use this directly, but one of the
10 # wrapper scripts like adb_gdb_content_shell 10 # wrapper scripts like adb_gdb_content_shell
(...skipping 529 matching lines...) Expand 10 before | Expand all | Expand 10 after
540 fi 540 fi
541 ANDROID_TOOLCHAIN=$TOOLCHAIN 541 ANDROID_TOOLCHAIN=$TOOLCHAIN
542 fi 542 fi
543 543
544 # Cosmetic: Remove trailing directory separator. 544 # Cosmetic: Remove trailing directory separator.
545 ANDROID_TOOLCHAIN=${ANDROID_TOOLCHAIN%/} 545 ANDROID_TOOLCHAIN=${ANDROID_TOOLCHAIN%/}
546 546
547 # Find host GDB client binary 547 # Find host GDB client binary
548 if [ -z "$GDB" ]; then 548 if [ -z "$GDB" ]; then
549 GDB=$(which $ANDROID_TOOLCHAIN/*-$GDBEXEPOSTFIX 2>/dev/null | head -1) 549 GDB=$(which $ANDROID_TOOLCHAIN/*-$GDBEXEPOSTFIX 2>/dev/null | head -1)
550 if [ -z "$GDBSERVER" ]; then 550 if [ -z "$GDB" ]; then
551 panic "Can't find Android gdb client in your path, check your \ 551 panic "Can't find Android gdb client in your path, check your \
552 --toolchain or --gdb path." 552 --toolchain or --gdb path."
553 fi 553 fi
554 log "Host gdb client: $GDB" 554 log "Host gdb client: $GDB"
555 fi 555 fi
556 556
557 # Find gdbserver binary, we will later push it to /data/local/tmp 557 # Find gdbserver binary, we will later push it to /data/local/tmp
558 # This ensures that both gdbserver and $GDB talk the same binary protocol, 558 # This ensures that both gdbserver and $GDB talk the same binary protocol,
559 # otherwise weird problems will appear. 559 # otherwise weird problems will appear.
560 # 560 #
(...skipping 398 matching lines...) Expand 10 before | Expand all | Expand 10 after
959 959
960 if [ "$VERBOSE" -gt 0 ]; then 960 if [ "$VERBOSE" -gt 0 ]; then
961 echo "### START $COMMANDS" 961 echo "### START $COMMANDS"
962 cat $COMMANDS 962 cat $COMMANDS
963 echo "### END $COMMANDS" 963 echo "### END $COMMANDS"
964 fi 964 fi
965 965
966 log "Launching gdb client: $GDB $GDBARGS -x $COMMANDS" 966 log "Launching gdb client: $GDB $GDBARGS -x $COMMANDS"
967 $GDB $GDBARGS -x $COMMANDS && 967 $GDB $GDBARGS -x $COMMANDS &&
968 rm -f "$GDBSERVER_PIDFILE" 968 rm -f "$GDBSERVER_PIDFILE"
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698