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

Unified Diff: build/android/envsetup.sh

Issue 10918045: Fix Clang build on Android. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address Sam's comment Created 8 years, 3 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: build/android/envsetup.sh
diff --git a/build/android/envsetup.sh b/build/android/envsetup.sh
index b0024858d70492f11ba2de8a541d7c71341a9f03..d63189cf221a8469dd6b239784f28042b3aa4484 100755
--- a/build/android/envsetup.sh
+++ b/build/android/envsetup.sh
@@ -95,11 +95,16 @@ if [[ -d $GOMA_DIR ]]; then
fi
export ANDROID_GOMA_WRAPPER
-export CC_target="${ANDROID_GOMA_WRAPPER} $(echo -n ${ANDROID_TOOLCHAIN}/*-gcc)"
-export CXX_target="${ANDROID_GOMA_WRAPPER} \
- $(echo -n ${ANDROID_TOOLCHAIN}/*-g++)"
-export LINK_target=$(echo -n ${ANDROID_TOOLCHAIN}/*-gcc)
-export AR_target=$(echo -n ${ANDROID_TOOLCHAIN}/*-ar)
+# http://crbug.com/143889.
+if ! echo "$GYP_DEFINES" | tr ' ' '\n' | grep -q '^clang=' | tail -n1 | \
+ grep -xq clang=1; then
+ export CC_target="${ANDROID_GOMA_WRAPPER} \
+ $(echo -n ${ANDROID_TOOLCHAIN}/*-gcc)"
+ export CXX_target="${ANDROID_GOMA_WRAPPER} \
+ $(echo -n ${ANDROID_TOOLCHAIN}/*-g++)"
+ export LINK_target=$(echo -n ${ANDROID_TOOLCHAIN}/*-gcc)
+ export AR_target=$(echo -n ${ANDROID_TOOLCHAIN}/*-ar)
+fi
# Performs a gyp_chromium run to convert gyp->Makefile for android code.
android_gyp() {
« 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