Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 #!/bin/bash | 1 #!/bin/bash |
| 2 | 2 |
| 3 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 3 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
| 5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
| 6 | 6 |
| 7 # This script runs gyp with the configuration required to build WebView in the | 7 # This script runs gyp with the configuration required to build WebView in the |
| 8 # Android build system. It is not necessary to source build/android/envsetup.sh | 8 # Android build system. It is not necessary to source build/android/envsetup.sh |
| 9 # before running this script. | 9 # before running this script. |
| 10 | 10 |
| (...skipping 18 matching lines...) Expand all Loading... | |
| 29 DEFINES+=" android_webview_build=1" | 29 DEFINES+=" android_webview_build=1" |
| 30 | 30 |
| 31 # We need to supply SDK paths relative to the top of the Android tree to make | 31 # We need to supply SDK paths relative to the top of the Android tree to make |
| 32 # sure the generated Android makefiles are portable, as they will be checked | 32 # sure the generated Android makefiles are portable, as they will be checked |
| 33 # into the Android tree. | 33 # into the Android tree. |
| 34 android_sdk=$(python -c \ | 34 android_sdk=$(python -c \ |
| 35 "import os.path; print os.path.relpath('${ANDROID_SDK_ROOT}', \ | 35 "import os.path; print os.path.relpath('${ANDROID_SDK_ROOT}', \ |
| 36 '${ANDROID_BUILD_TOP}')") | 36 '${ANDROID_BUILD_TOP}')") |
| 37 DEFINES+=" android_src=\$(PWD)" | 37 DEFINES+=" android_src=\$(PWD)" |
| 38 DEFINES+=" android_ndk_root=ndk_root_unused_in_webview_build" | 38 DEFINES+=" android_ndk_root=ndk_root_unused_in_webview_build" |
| 39 DEFINES+=" android_ndk_sysroot=ndk_sysroot_unused_in_webview_build" | |
| 40 DEFINES+=" android_gdbserver=gdbserver_unused_in_webview_build" | |
|
Yang Gu
2014/03/13 10:07:29
We don't need to define them in common.gypi for th
Torne
2014/03/13 11:04:46
We don't define them for the other architectures,
Yang Gu
2014/03/13 16:06:07
For 1st comment (take android_ndk_sysroot as examp
Torne
2014/03/17 15:28:14
If other architectures define these variables, the
| |
| 39 DEFINES+=" android_sdk=\$(PWD)/${android_sdk}" | 41 DEFINES+=" android_sdk=\$(PWD)/${android_sdk}" |
| 40 DEFINES+=" android_sdk_root=\$(PWD)/${android_sdk}" | 42 DEFINES+=" android_sdk_root=\$(PWD)/${android_sdk}" |
| 41 DEFINES+=" android_sdk_version=sdk_version_unused_in_webview_build" | 43 DEFINES+=" android_sdk_version=sdk_version_unused_in_webview_build" |
| 42 DEFINES+=" android_toolchain=${ANDROID_TOOLCHAIN}" | 44 DEFINES+=" android_toolchain=${ANDROID_TOOLCHAIN}" |
| 43 | 45 |
| 44 # TODO: Get rid of this block, crbug.com/334021 | 46 # TODO: Get rid of this block, crbug.com/334021 |
| 45 if [[ -n "$CHROME_ANDROID_WEBVIEW_OFFICIAL_BUILD" ]]; then | 47 if [[ -n "$CHROME_ANDROID_WEBVIEW_OFFICIAL_BUILD" ]]; then |
| 46 DEFINES+=" logging_like_official_build=1" | 48 DEFINES+=" logging_like_official_build=1" |
| 47 DEFINES+=" tracing_like_official_build=1" | 49 DEFINES+=" tracing_like_official_build=1" |
| 48 fi | 50 fi |
| (...skipping 12 matching lines...) Expand all Loading... | |
| 61 '${ANDROID_BUILD_TOP}')") | 63 '${ANDROID_BUILD_TOP}')") |
| 62 EFLAGS=\ | 64 EFLAGS=\ |
| 63 "${FLAGS} -Dhost_os=${host_os} -Dandroid_sdk_tools=\$(PWD)/${android_sdk_tools}" | 65 "${FLAGS} -Dhost_os=${host_os} -Dandroid_sdk_tools=\$(PWD)/${android_sdk_tools}" |
| 64 | 66 |
| 65 if [ "$PLATFORM" == "${host_platform}-arm" -o "$PLATFORM" == "all" ]; then | 67 if [ "$PLATFORM" == "${host_platform}-arm" -o "$PLATFORM" == "all" ]; then |
| 66 ${GYP} --suffix .${host_platform}-arm ${EFLAGS} -Dtarget_arch=arm | 68 ${GYP} --suffix .${host_platform}-arm ${EFLAGS} -Dtarget_arch=arm |
| 67 fi | 69 fi |
| 68 if [ "$PLATFORM" == "${host_platform}-x86" -o "$PLATFORM" == "all" ]; then | 70 if [ "$PLATFORM" == "${host_platform}-x86" -o "$PLATFORM" == "all" ]; then |
| 69 ${GYP} --suffix .${host_platform}-x86 ${EFLAGS} -Dtarget_arch=ia32 | 71 ${GYP} --suffix .${host_platform}-x86 ${EFLAGS} -Dtarget_arch=ia32 |
| 70 fi | 72 fi |
| 73 if [ "$PLATFORM" == "${host_platform}-x86_64" -o "$PLATFORM" == "all" ]; then | |
| 74 ${GYP} --suffix .${host_platform}-x86_64 ${EFLAGS} -Dtarget_arch=x64 | |
| 75 fi | |
| 71 if [ "$PLATFORM" == "${host_platform}-mips" -o "$PLATFORM" == "all" ]; then | 76 if [ "$PLATFORM" == "${host_platform}-mips" -o "$PLATFORM" == "all" ]; then |
| 72 ${GYP} --suffix .${host_platform}-mips ${EFLAGS} -Dtarget_arch=mipsel | 77 ${GYP} --suffix .${host_platform}-mips ${EFLAGS} -Dtarget_arch=mipsel |
| 73 fi | 78 fi |
| 74 done | 79 done |
| OLD | NEW |