resolved conflicts for merge of 296e4828 to master
Change-Id: Iae41a458f1eed497119c3abe4bf27194821c075d
diff --git a/envsetup.sh b/envsetup.sh
index 7711e0d..d3344d2 100644
--- a/envsetup.sh
+++ b/envsetup.sh
@@ -116,17 +116,21 @@
# The gcc toolchain does not exists for windows/cygwin. In this case, do not reference it.
export ANDROID_EABI_TOOLCHAIN=
- toolchaindir=arm/arm-linux-androideabi-4.6/bin
+ local ARCH=$(get_build_var TARGET_ARCH)
+ case $ARCH in
+ x86) toolchaindir=x86/i686-android-linux-4.4.3/bin
+ ;;
+ arm) toolchaindir=arm/arm-linux-androideabi-4.6/bin
+ ;;
+ *)
+ echo "Can't find toolchain for unknown architecture: $ARCH"
+ toolchaindir=xxxxxxxxx
+ ;;
+ esac
if [ -d "$gccprebuiltdir/$toolchaindir" ]; then
export ANDROID_EABI_TOOLCHAIN=$gccprebuiltdir/$toolchaindir
fi
- export ARM_EABI_TOOLCHAIN=
- toolchaindir=arm/arm-eabi-4.6/bin
- if [ -d "$gccprebuiltdir/$toolchaindir" ]; then
- export ARM_EABI_TOOLCHAIN=$gccprebuiltdir/$toolchaindir
- fi
-
export ANDROID_TOOLCHAIN=$ANDROID_EABI_TOOLCHAIN
export ANDROID_QTOOLS=$T/development/emulator/qtools
export ANDROID_BUILD_PATHS=:$(get_build_var ANDROID_BUILD_PATHS):$ANDROID_QTOOLS:$ANDROID_TOOLCHAIN:$ARM_EABI_TOOLCHAIN$CODE_REVIEWS
@@ -762,7 +766,7 @@
echo >>"$OUT_ROOT/gdbclient.cmds" "target remote $PORT"
echo >>"$OUT_ROOT/gdbclient.cmds" ""
- $GDB -x "$OUT_ROOT/gdbclient.cmds" "$OUT_EXE_SYMBOLS/$EXE"
+ $ANDROID_TOOLCHAIN/$GDB -x "$OUT_ROOT/gdbclient.cmds" "$OUT_EXE_SYMBOLS/$EXE"
else
echo "Unable to determine build system output dir."
fi