Chromium Code Reviews| Index: build/android/adb_gdb |
| diff --git a/build/android/adb_gdb b/build/android/adb_gdb |
| index 4ff4eea6560df421009fd15aaa6f36264fb1ec33..2bb6f87edf1a036dadaf69fd08215a50fb2d50e5 100755 |
| --- a/build/android/adb_gdb |
| +++ b/build/android/adb_gdb |
| @@ -248,10 +248,10 @@ directory. |
| The script tries to find the most recent version of the debug version of |
| shared libraries under one of the following directories: |
| - \$CHROMIUM_SRC/out/Release/lib/ (used by Ninja builds) |
| - \$CHROMIUM_SRC/out/Debug/lib/ (used by Ninja builds) |
| - \$CHROMIUM_SRC/out/Release/lib.target/ (used by Make builds) |
| - \$CHROMIUM_SRC/out/Debug/lib.target/ (used by Make builds) |
| + \$CHROMIUM_SRC/$CHROMIUM_OUT_DIR/Release/lib/ (used by Ninja builds) |
| + \$CHROMIUM_SRC/$CHROMIUM_OUT_DIR/Debug/lib/ (used by Ninja builds) |
| + \$CHROMIUM_SRC/$CHROMIUM_OUT_DIR/Release/lib.target/ (used by Make builds) |
| + \$CHROMIUM_SRC/$CHROMIUM_OUT_DIR/Debug/lib.target/ (used by Make builds) |
|
digit1
2013/11/20 13:49:18
I believe this will get printed before detect_symb
bulach
2013/11/20 16:47:36
excellent idea! done.
|
| You can restrict this search by using --release or --debug to specify the |
| build type, or simply use --symbol-dir=<path> to specify the file manually. |
| @@ -672,13 +672,13 @@ get_file_timestamp () { |
| # Detect the build type and symbol directory. This is done by finding |
| # the most recent sub-directory containing debug shared libraries under |
| -# $CHROMIUM_SRC/out/ |
| +# $CHROMIUM_SRC/$CHROMIUM_OUT_DIR/ |
| # |
| # $1: $BUILDTYPE value, can be empty |
| # Out: nothing, but this sets SYMBOL_DIR |
| # |
| detect_symbol_dir () { |
| - local SUBDIRS SUBDIR LIST DIR DIR_LIBS TSTAMP |
| + local SUBDIRS SUBDIR LIST DIR DIR_LIBS TSTAMP OUT_DIR |
| # Note: Ninja places debug libraries under out/$BUILDTYPE/lib/, while |
| # Make places then under out/$BUILDTYPE/lib.target. |
| if [ "$1" ]; then |
| @@ -686,10 +686,15 @@ detect_symbol_dir () { |
| else |
| SUBDIRS="Release/lib Debug/lib Release/lib.target Debug/lib.target" |
| fi |
| + if [ "$CHROMIUM_OUT_DIR" ]; then |
| + OUT_DIR="$CHROMIUM_OUT_DIR" |
| + else |
| + OUT_DIR="out" |
| + fi |
| LIST=$TMPDIR/scan-subdirs-$$.txt |
| printf "" > "$LIST" |
| for SUBDIR in $SUBDIRS; do |
| - DIR=$CHROMIUM_SRC/out/$SUBDIR |
| + DIR=$CHROMIUM_SRC/$OUT_DIR/$SUBDIR |
| if [ -d "$DIR" ]; then |
| # Ignore build directories that don't contain symbol versions |
| # of the shared libraries. |
| @@ -708,14 +713,14 @@ detect_symbol_dir () { |
| if [ -z "$SUBDIR" ]; then |
| if [ -z "$1" ]; then |
| panic "Could not find any build directory under \ |
| -$CHROMIUM_SRC/out. Please build the program first!" |
| +$CHROMIUM_SRC/$OUT_DIR. Please build the program first!" |
| else |
| panic "Could not find any $1 directory under \ |
| -$CHROMIUM_SRC/out. Check your build type!" |
| +$CHROMIUM_SRC/$OUT_DIR. Check your build type!" |
| fi |
| fi |
| - SYMBOL_DIR=$CHROMIUM_SRC/out/$SUBDIR |
| + SYMBOL_DIR=$CHROMIUM_SRC/$OUT_DIR/$SUBDIR |
| log "Auto-config: --symbol-dir=$SYMBOL_DIR" |
| } |