Commit 72d0476e authored by ehmaldonado's avatar ehmaldonado Committed by Commit bot

Make android lint suppressions file overridable.

This makes possible for other projects to use their own lint suppressions file.
WebRTC for example, uses its own lint suppressions file.

BUG=

Review-Url: https://codereview.chromium.org/2290323002
Cr-Commit-Position: refs/heads/master@{#415304}
parent 8f00eb0d
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
# Use of this source code is governed by a BSD-style license that can be # Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file. # found in the LICENSE file.
import("//build_overrides/build.gni")
import("//build/config/android/config.gni") import("//build/config/android/config.gni")
import("//build/config/sanitizers/sanitizers.gni") import("//build/config/sanitizers/sanitizers.gni")
...@@ -648,10 +649,15 @@ if (enable_java_templates) { ...@@ -648,10 +649,15 @@ if (enable_java_templates) {
if (!defined(deps)) { if (!defined(deps)) {
deps = [] deps = []
} }
if (!defined(lint_suppressions_file)) {
lint_suppressions_file = "//build/android/lint/suppressions.xml"
}
_cache_dir = "$root_build_dir/android_lint_cache" _cache_dir = "$root_build_dir/android_lint_cache"
_result_path = "$target_gen_dir/$target_name/result.xml" _result_path = "$target_gen_dir/$target_name/result.xml"
_config_path = "$target_gen_dir/$target_name/config.xml" _config_path = "$target_gen_dir/$target_name/config.xml"
_suppressions_file = "//build/android/lint/suppressions.xml" _suppressions_file = lint_suppressions_file
_platform_xml_path = _platform_xml_path =
"${android_sdk_root}/platform-tools/api/api-versions.xml" "${android_sdk_root}/platform-tools/api/api-versions.xml"
_rebased_lint_android_sdk_root = _rebased_lint_android_sdk_root =
......
...@@ -26,3 +26,6 @@ enable_java_templates = true ...@@ -26,3 +26,6 @@ enable_java_templates = true
asan_suppressions_file = "//build/sanitizers/asan_suppressions.cc" asan_suppressions_file = "//build/sanitizers/asan_suppressions.cc"
lsan_suppressions_file = "//build/sanitizers/lsan_suppressions.cc" lsan_suppressions_file = "//build/sanitizers/lsan_suppressions.cc"
tsan_suppressions_file = "//build/sanitizers/tsan_suppressions.cc" tsan_suppressions_file = "//build/sanitizers/tsan_suppressions.cc"
# Uncomment these to specify a different lint suppressions file for android
# lint_suppressions_file = path/to/your/suppressions/file/suppressions.xml
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment