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

Unified Diff: platform_tools/android/bin/utils/setup_toolchain.sh

Issue 1780223002: Android NDK: r10e -> r11 (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 9 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: platform_tools/android/bin/utils/setup_toolchain.sh
diff --git a/platform_tools/android/bin/utils/setup_toolchain.sh b/platform_tools/android/bin/utils/setup_toolchain.sh
index b4234468128576a282326214a1cac6445daa3ebb..93322da48f2eac962f54f8936a7e437ea550941d 100755
--- a/platform_tools/android/bin/utils/setup_toolchain.sh
+++ b/platform_tools/android/bin/utils/setup_toolchain.sh
@@ -35,8 +35,7 @@ function default_toolchain() {
TOOLCHAINS=${SCRIPT_DIR}/../toolchains
ANDROID_ARCH=${ANDROID_ARCH-arm}
- LLVM=3.6
- NDK=r10e
+ NDK=r11
if [[ $ANDROID_ARCH == *64* ]]; then
API=21 # Android 5.0
@@ -52,17 +51,17 @@ function default_toolchain() {
if [ ! -d "$ANDROID_TOOLCHAIN" ]; then
mkdir -p $TOOLCHAINS
pushd $TOOLCHAINS
- curl -o $NDK.bin https://dl.google.com/android/ndk/android-ndk-$NDK-$HOST-x86_64.bin
- chmod +x $NDK.bin
- ./$NDK.bin -y
- ./android-ndk-$NDK/build/tools/make-standalone-toolchain.sh \
+ curl -o $NDK.zip https://dl.google.com/android/repository/android-ndk-$NDK-$HOST-x86_64.zip
+ unzip $NDK.zip
+ UNZIPPED=android-ndk-$NDK-$HOST-x86_64.tar.bz2
+ ./$UNZIPPED/build/tools/make-standalone-toolchain.sh \
+ --use-llvm \
--arch=$ANDROID_ARCH \
- --llvm-version=$LLVM \
--platform=android-$API \
--install_dir=$TOOLCHAIN
- cp android-ndk-$NDK/prebuilt/android-$ANDROID_ARCH/gdbserver/gdbserver $TOOLCHAIN
- rm $NDK.bin
- rm -rf android-ndk-$NDK
+ cp $UNZIPPED/prebuilt/android-$ANDROID_ARCH/gdbserver/gdbserver $TOOLCHAIN
+ rm $NDK.zip
+ rm -rf $UNZIPPED
popd
fi
@@ -149,12 +148,4 @@ if [ $(uname) == "Darwin" ]; then
ln -sf $ANDROID_TOOLCHAIN_PREFIX-as $ANDROID_TOOLCHAIN/as
fi
-# fix bug in the toolchain in order to enable ccache to work with clang
-if [ $(head -c 2 $ANDROID_TOOLCHAIN_PREFIX-clang) != "#!" ]; then
- echo -e "#!/bin/bash\n$(cat $ANDROID_TOOLCHAIN_PREFIX-clang)" > $ANDROID_TOOLCHAIN_PREFIX-clang
-fi
-if [ $(head -c 2 $ANDROID_TOOLCHAIN_PREFIX-clang++) != "#!" ]; then
- echo -e "#!/bin/bash\n$(cat $ANDROID_TOOLCHAIN_PREFIX-clang++)" > $ANDROID_TOOLCHAIN_PREFIX-clang++
-fi
-
exportVar PATH $ANDROID_TOOLCHAIN:$PATH
« 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