Chromium Code Reviews| Index: build/android/envsetup.sh |
| diff --git a/build/android/envsetup.sh b/build/android/envsetup.sh |
| index 1628dbdb7c237230c93e63b679597588d4e619c2..9f5c4792d9e22d5c536bf9efc54116aac1334a65 100755 |
| --- a/build/android/envsetup.sh |
| +++ b/build/android/envsetup.sh |
| @@ -45,7 +45,30 @@ case "${host_os}" in |
| return 1 |
| esac |
| -export ANDROID_TOOLCHAIN="${ANDROID_NDK_ROOT}/toolchains/arm-linux-androideabi-4.4.3/prebuilt/${toolchain_dir}/bin/" |
| +# If the TARGET_PRODUCT wasn't set, use 'full' by default. |
|
Nico
2012/04/27 05:29:22
s/the //
Wei James
2012/04/27 08:59:05
fixed. thanks.
|
| +if [ -z "${TARGET_PRODUCT}" ]; then |
| + TARGET_PRODUCT="full" |
| +fi |
|
Nico
2012/04/27 05:29:22
You can remove this...
|
| + |
| +# The following defines will affect ARM code generation of both C/C++ compiler |
| +# and V8 mksnapshot. |
| +case "${TARGET_PRODUCT}" in |
|
Nico
2012/04/27 05:29:22
...and say "${TARGET_PRODUCT-full}" here, that wil
Wei James
2012/04/27 08:59:05
fixed. thanks
|
| + "full") |
| + DEFINES=" target_arch=arm" |
| + DEFINES+=" arm_neon=0 armv7=1 arm_thumb=1 arm_fpu=vfpv3-d16" |
| + toolchain_arch="arm-linux-androideabi-4.4.3" |
| + ;; |
| + *x86*) |
| + DEFINES=" target_arch=ia32 use_libffmpeg=0" |
| + toolchain_arch="x86-4.4.3" |
| + ;; |
| + *) |
| + echo "TARGET_PRODUCT: ${TARGET_PRODUCT} is not supported." >& 2 |
| + return 1 |
| +esac |
| + |
| +toolchain_path="${ANDROID_NDK_ROOT}/toolchains/${toolchain_arch}/prebuilt/" |
| +export ANDROID_TOOLCHAIN="${toolchain_path}/${toolchain_dir}/bin/" |
| export ANDROID_SDK_VERSION="15" |
| @@ -93,7 +116,7 @@ export STRIP=$(echo ${ANDROID_TOOLCHAIN}/*-strip) |
| # The set of GYP_DEFINES to pass to gyp. Use 'readlink -e' on directories |
| # to canonicalize them (remove double '/', remove trailing '/', etc). |
| -DEFINES="OS=android" |
| +DEFINES+=" OS=android" |
| DEFINES+=" android_build_type=0" # Currently, Only '0' is supportted. |
| DEFINES+=" host_os=${host_os}" |
| DEFINES+=" linux_fpic=1" |
| @@ -109,26 +132,6 @@ DEFINES+=" build_ffmpegsumo=0" |
| DEFINES+=" gtest_target_type=executable" |
| DEFINES+=" branding=Chromium" |
| -# If the TARGET_PRODUCT wasn't set, use 'full' by default. |
| -if [ -z "${TARGET_PRODUCT}" ]; then |
| - TARGET_PRODUCT="full" |
| -fi |
| - |
| -# The following defines will affect ARM code generation of both C/C++ compiler |
| -# and V8 mksnapshot. |
| -case "${TARGET_PRODUCT}" in |
| - "full") |
| - DEFINES+=" target_arch=arm" |
| - DEFINES+=" arm_neon=0 armv7=1 arm_thumb=1 arm_fpu=vfpv3-d16" |
| - ;; |
| - *x86*) |
| - DEFINES+=" target_arch=ia32 use_libffmpeg=0" |
| - ;; |
| - *) |
| - echo "TARGET_PRODUCT: ${TARGET_PRODUCT} is not supported." >& 2 |
| - return 1 |
| -esac |
| - |
| export GYP_DEFINES="${DEFINES}" |
| # Use the "android" flavor of the Makefile generator for both Linux and OS X. |