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

Unified Diff: build/config/BUILDCONFIG.gn

Issue 936103003: Roll GN binaries to #317120 for the cpu_arch changes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@gn_cpu_arch_changes
Patch Set: fix android_gcc_toolchain() invocations for new toolchains Created 5 years, 10 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 | « DEPS ('k') | build/toolchain/android/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/config/BUILDCONFIG.gn
diff --git a/build/config/BUILDCONFIG.gn b/build/config/BUILDCONFIG.gn
index 890304857be44126404bdeb0528cbefd8bc9a45e..242cea933182cf0afb4303678659eab12dac09c9 100644
--- a/build/config/BUILDCONFIG.gn
+++ b/build/config/BUILDCONFIG.gn
@@ -16,7 +16,47 @@
# KEEP IN ALPHABETICAL ORDER and write a good description for everything.
# Use "is_*" names for intrinsic platform descriptions and build modes, and
# "use_*" names for optional features libraries, and configurations.
+
+# TODO(dpranke): The os and cpu_arch variables exist for backwards
+# compatibility and should be deleted once all of the build files and
+# bots have been updated to use current_cpu/target_cpu and
+# current_os/target_os instead.
+
+if (target_os == "") {
+ if (defined(os)) {
+ # If os is defined, it was set in an args file and needs to be
+ # used for backwards-compatibility.
+ target_os = os
+ } else {
+ target_os = host_os
+ }
+}
+
+if (target_cpu == "") {
+ if (defined(cpu_arch)) {
+ # If cpu_arch is defined, it was set in an args file and needs to be
+ # used for backwards-compatibility.
+ target_cpu = cpu_arch
+ } else {
+ target_cpu = host_cpu
+ }
+}
+
+if (current_cpu == "") {
+ current_cpu = target_cpu
+}
+if (current_os == "") {
+ current_os = target_os
+}
+
declare_args() {
+ # TODO(dpranke): These values are here for backwards compatibility and
+ # should be deleted when all of the builders and configs have been updated.
+ cpu_arch = target_cpu
+ os = target_os
+ build_cpu_arch = host_cpu
+ build_os = host_os
+
# How many symbols to include in the build. This affects the performance of
# the build since the symbols are large and dealing with them is slow.
# 2 means regular build with symbols.
@@ -83,6 +123,10 @@ declare_args() {
link_chrome_on_windows = true
}
+# TODO(dpranke): Remove these asserts when os and cpu_arch are removed.
+assert(current_cpu == cpu_arch)
+assert(current_os == os)
+
# =============================================================================
# OS DEFINITIONS
# =============================================================================
« no previous file with comments | « DEPS ('k') | build/toolchain/android/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698