Index: build/config/android/internal_rules.gni |
diff --git a/build/config/android/internal_rules.gni b/build/config/android/internal_rules.gni |
index f6052ae4229546aeb26da53541a149f19594add3..322f5aeef757f6e959c9ae288daa1776ef3dd1f6 100644 |
--- a/build/config/android/internal_rules.gni |
+++ b/build/config/android/internal_rules.gni |
@@ -689,9 +689,12 @@ if (enable_java_templates) { |
rebase_path(_config_path, root_build_dir), |
"--result-path", |
rebase_path(_result_path, root_build_dir), |
- "--enable", |
] |
+ if (defined(invoker.disable)) { |
+ args += [ "--disable=${invoker.disable}" ] |
+ } |
+ |
if (defined(invoker.create_cache) && invoker.create_cache) { |
args += [ |
"--create-cache", |
@@ -2479,6 +2482,13 @@ if (enable_java_templates) { |
java_sources_file = _java_sources_file |
} |
deps = _accumulated_deps |
+ if (_emma_instrument) { |
+ # Disable the NewApi lint warning when building with coverage |
+ # enabled. Coverage seems to mess with how the linter detects |
+ # the usages of a new API within a conditional. See |
+ # crbug.com/677320 for more. |
+ disable = [ "NewApi" ] |
+ } |
} |
if (_run_findbugs) { |