Index: build/config/android/rules.gni |
diff --git a/build/config/android/rules.gni b/build/config/android/rules.gni |
index c9388af8fd7d866b8ef653726d50607fa4ee1cd9..64b1d969b8764ad95fc48c65f7888e3684460de5 100644 |
--- a/build/config/android/rules.gni |
+++ b/build/config/android/rules.gni |
@@ -576,10 +576,10 @@ template("locale_pak_resources") { |
# custom_package: java package for generated .java files. |
# v14_skip: If true, don't run v14 resource generator on this. Defaults to |
# false. (see build/android/gyp/generate_v14_compatible_resources.py) |
-# |
# shared_resources: If true make a resource package that can be loaded by a |
# different application at runtime to access the package's resources. |
-# |
+# app_as_shared_lib: If true make a resource package that can be loaded as |
+# both shared_resources and normal application. |
# Example: |
# android_resources("foo_resources") { |
@@ -635,6 +635,7 @@ template("android_resources") { |
deps = [] |
forward_variables_from(invoker, |
[ |
+ "app_as_shared_lib", |
"android_manifest", |
"custom_package", |
"deps", |
@@ -1182,6 +1183,10 @@ template("android_java_prebuilt") { |
# and (possibly) native libraries. |
# |
# Variables |
+# alternative_android_sdk_jar: The alternative android sdk jar used in |
+# proguard. |
+# android_aapt_path: Android aapt tool to replace default one to build |
+# resource. |
# android_manifest: Path to AndroidManifest.xml. |
# android_manifest_dep: Target that generates AndroidManifest (if applicable) |
# chromium_code: If true, extra analysis warning/errors will be enabled. |
@@ -1409,6 +1414,8 @@ template("android_apk") { |
process_resources(process_resources_target) { |
forward_variables_from(invoker, |
[ |
+ "android_aapt_path", |
+ "app_as_shared_lib", |
"include_all_resources", |
"shared_resources", |
]) |
@@ -1540,6 +1547,7 @@ template("android_apk") { |
} |
_proguard_target = "${_template_name}__proguard" |
proguard(_proguard_target) { |
+ forward_variables_from(invoker, [ "alternative_android_sdk_jar" ]) |
deps = [ |
":$build_config_target", |
":$java_target", |
@@ -1669,6 +1677,8 @@ template("android_apk") { |
deps = [] |
forward_variables_from(invoker, |
[ |
+ "android_aapt_path", |
+ "app_as_shared_lib", |
"deps", |
"extensions_to_not_compress", |
"language_splits", |
@@ -1761,6 +1771,7 @@ template("android_apk") { |
deps = [] |
forward_variables_from(invoker, |
[ |
+ "android_aapt_path", |
"deps", |
"native_lib_placeholders", |
"public_deps", |