Index: build/config/compiler/BUILD.gn |
diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn |
index 79c79a42d21ad8fdb6f807ab5ae6990280b20693..d3b63e5c4505fceca9b645a58b5049b06aa9d3a7 100644 |
--- a/build/config/compiler/BUILD.gn |
+++ b/build/config/compiler/BUILD.gn |
@@ -1577,3 +1577,18 @@ if (is_ios || is_mac) { |
cflags_objcc = common_flags |
} |
} |
+ |
+# |
+# Extra flags |
+# |
+# This is a placeholder config so that users with custom toolchains |
+# can more easily set extra flags to be passed to each target, while |
+# still allowing for those flags to be turned off on a per-target basis. |
+# We generally do not want people to specify extra flags, so for now |
+# this hook is only exposed to the CrOS build. |
+ |
+config("extra_flags") { |
+ if (default_toolchain == "//build/config/cros:target") { |
+ configs = [ "//build/toolchain/cros:extra_flags" ] |
+ } |
Dirk Pranke
2016/08/02 00:28:10
Perhaps instead of hardcoding the toolchain and co
brettw
2016/08/03 23:02:14
Can this just be:
if (target_os == "chromeos") ?
Dirk Pranke
2016/08/03 23:09:07
No, because that would break the "desktop chromeos
brettw
2016/08/08 22:10:56
Ah, then can you add an explicit comment explainin
|
+} |