Chromium Code Reviews| Index: build/config/BUILDCONFIG.gn |
| diff --git a/build/config/BUILDCONFIG.gn b/build/config/BUILDCONFIG.gn |
| index 7994dd77f78ac7470c173718d9219cf9417e0ece..890d33e0659e0d0b9ed1bf41b5e572979742b177 100644 |
| --- a/build/config/BUILDCONFIG.gn |
| +++ b/build/config/BUILDCONFIG.gn |
| @@ -71,6 +71,16 @@ declare_args() { |
| # toolchains. |
| cros_use_custom_toolchain = false |
| } |
| + |
| + # TODO(cjhopman): Make target_arch work for all platforms. |
| + |
| + # Architecture of the target device. For Android builds, this will be equal to |
|
cjhopman
2014/10/16 21:29:59
This can't be guarded by (os == "android") because
|
| + # the cpu_arch of the default toolchain. When checking the CPU architecture |
| + # for source files and build dependencies you should almost alway use cpu_arch |
| + # instead. cpu_arch is the architecture of the current toolchain and allows |
| + # cross-compiles (compiling the same target for multiple toolchains in the |
| + # same build) to work. |
| + target_arch = "arm" |
| } |
| # ============================================================================= |
| @@ -174,6 +184,14 @@ if (is_win) { |
| } |
| } |
| +if (is_android) { |
| + # TODO(cjhopman): enable this assert once bots are updated to not set |
| + # cpu_arch. |
| + #assert(cpu_arch == build_cpu_arch, "Android device target architecture should |
| + # be set with 'target_arch', not 'cpu_arch'") |
| + cpu_arch = target_arch |
| +} |
| + |
| # ============================================================================= |
| # SOURCES FILTERS |
| # ============================================================================= |