Index: build/config/android/internal_rules.gni |
diff --git a/build/config/android/internal_rules.gni b/build/config/android/internal_rules.gni |
index 6a7cda3bc6c150809c8e7defbf06f6d4f11a2d84..b7347ad375b0a58ea0547baf2cfc3b057eddd003 100644 |
--- a/build/config/android/internal_rules.gni |
+++ b/build/config/android/internal_rules.gni |
@@ -332,6 +332,16 @@ template("write_build_config") { |
rebase_path(invoker.proguard_configs, root_build_dir) |
args += [ "--proguard-configs=$_rebased_proguard_configs" ] |
} |
+ if (defined(invoker.gradle_treat_as_prebuilt) && |
+ invoker.gradle_treat_as_prebuilt) { |
+ args += [ "--gradle-treat-as-prebuilt" ] |
+ } |
+ if (defined(invoker.main_class)) { |
+ args += [ |
+ "--main-class", |
+ invoker.main_class, |
+ ] |
+ } |
if (current_toolchain != default_toolchain) { |
# This has to be a built-time error rather than a GN assert because many |
# packages have a mix of java and non-java targets. For example, the |
@@ -2260,7 +2270,9 @@ if (enable_java_templates) { |
write_build_config(build_config_target_name) { |
forward_variables_from(invoker, |
[ |
+ "gradle_treat_as_prebuilt", |
"input_jars_paths", |
+ "main_class", |
"proguard_configs", |
]) |
if (defined(invoker.is_java_binary) && invoker.is_java_binary) { |