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

Side by Side Diff: build/android.gypi

Issue 1197703004: [android] Add toolchain path logic to gyp config. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 6 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 unified diff | Download patch
« no previous file with comments | « no previous file | build/standalone.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2012 the V8 project authors. All rights reserved. 1 # Copyright 2012 the V8 project authors. All rights reserved.
2 # Redistribution and use in source and binary forms, with or without 2 # Redistribution and use in source and binary forms, with or without
3 # modification, are permitted provided that the following conditions are 3 # modification, are permitted provided that the following conditions are
4 # met: 4 # met:
5 # 5 #
6 # * Redistributions of source code must retain the above copyright 6 # * Redistributions of source code must retain the above copyright
7 # notice, this list of conditions and the following disclaimer. 7 # notice, this list of conditions and the following disclaimer.
8 # * Redistributions in binary form must reproduce the above 8 # * Redistributions in binary form must reproduce the above
9 # copyright notice, this list of conditions and the following 9 # copyright notice, this list of conditions and the following
10 # disclaimer in the documentation and/or other materials provided 10 # disclaimer in the documentation and/or other materials provided
(...skipping 15 matching lines...) Expand all
26 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 26 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 27
28 # Definitions for building standalone V8 binaries to run on Android. 28 # Definitions for building standalone V8 binaries to run on Android.
29 # This is mostly excerpted from: 29 # This is mostly excerpted from:
30 # http://src.chromium.org/viewvc/chrome/trunk/src/build/common.gypi 30 # http://src.chromium.org/viewvc/chrome/trunk/src/build/common.gypi
31 31
32 { 32 {
33 'variables': { 33 'variables': {
34 # Location of Android NDK. 34 # Location of Android NDK.
35 'variables': { 35 'variables': {
36 'android_ndk_root%': '<!(/bin/echo -n $ANDROID_NDK_ROOT)', 36 'variables': {
37 'android_toolchain%': '<!(/bin/echo -n $ANDROID_TOOLCHAIN)', 37 # The Android toolchain needs to use the absolute path to the NDK
38 # because it is used at different levels in the GYP files.
39 'android_ndk_root%': '<!(cd <(DEPTH) && pwd -P)/third_party/android_tool s/ndk/',
40 'android_host_arch%': "<!(uname -m | sed -e 's/i[3456]86/x86/')",
41 'host_os%': "<!(uname -s | sed -e 's/Linux/linux/;s/Darwin/mac/')",
42 },
43
44 # Copy conditionally-set variables out one scope.
45 'android_ndk_root%': '<(android_ndk_root)',
46
47 # Android API level 16 is JB (Android 4.1) which is the minimum
ulan 2015/06/22 10:41:25 Update the comment?
Michael Achenbach 2015/06/22 11:29:46 Removing the comment.
48 # platform requirement for Chrome on Android, we use it for native
49 # code compilation.
50 'conditions': [
51 ['target_arch == "ia32"', {
52 'android_toolchain%': '<(android_ndk_root)/toolchains/x86-4.9/prebuilt /<(host_os)-<(android_host_arch)/bin',
53 }],
54 ['target_arch == "x64"', {
55 'android_toolchain%': '<(android_ndk_root)/toolchains/x86_64-4.9/prebu ilt/<(host_os)-<(android_host_arch)/bin',
56 }],
57 ['target_arch=="arm"', {
58 'android_toolchain%': '<(android_ndk_root)/toolchains/arm-linux-androi deabi-4.9/prebuilt/<(host_os)-<(android_host_arch)/bin',
59 }],
60 ['target_arch == "arm64"', {
61 'android_toolchain%': '<(android_ndk_root)/toolchains/aarch64-linux-an droid-4.9/prebuilt/<(host_os)-<(android_host_arch)/bin',
62 }],
63 ['target_arch == "mipsel"', {
64 'android_toolchain%': '<(android_ndk_root)/toolchains/mipsel-linux-and roid-4.9/prebuilt/<(host_os)-<(android_host_arch)/bin',
65 }],
66 ['target_arch == "mips64el"', {
67 'android_toolchain%': '<(android_ndk_root)/toolchains/mips64el-linux-a ndroid-4.9/prebuilt/<(host_os)-<(android_host_arch)/bin',
68 }],
69 ],
38 }, 70 },
71
39 'conditions': [ 72 'conditions': [
40 ['android_ndk_root==""', { 73 ['android_ndk_root==""', {
41 'variables': { 74 'variables': {
42 'android_sysroot': '<(android_toolchain)/sysroot/', 75 'android_sysroot': '<(android_toolchain)/sysroot/',
43 'android_stlport': '<(android_toolchain)/sources/cxx-stl/stlport/', 76 'android_stlport': '<(android_toolchain)/sources/cxx-stl/stlport/',
44 }, 77 },
45 'android_include': '<(android_sysroot)/usr/include', 78 'android_include': '<(android_sysroot)/usr/include',
46 'conditions': [ 79 'conditions': [
47 ['target_arch=="x64"', { 80 ['target_arch=="x64"', {
48 'android_lib': '<(android_sysroot)/usr/lib64', 81 'android_lib': '<(android_sysroot)/usr/lib64',
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 'ldflags!': [ 290 'ldflags!': [
258 '-Wl,-z,noexecstack', 291 '-Wl,-z,noexecstack',
259 '-Wl,--gc-sections', 292 '-Wl,--gc-sections',
260 '-Wl,-O1', 293 '-Wl,-O1',
261 '-Wl,--as-needed', 294 '-Wl,--as-needed',
262 ], 295 ],
263 }], 296 }],
264 ], # target_conditions 297 ], # target_conditions
265 }, # target_defaults 298 }, # target_defaults
266 } 299 }
OLDNEW
« no previous file with comments | « no previous file | build/standalone.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698