gn2bp: move proto_gen_headers special casing to additional_args
Statically applied attributes should live in additonal_args.
Test: //net:net
Change-Id: Ia473587f06ae2fa4831f10f897bdcc1c5e5f5b82
diff --git a/tools/gn2bp/gen_android_bp b/tools/gn2bp/gen_android_bp
index 1b7bec0..b4f2cda 100755
--- a/tools/gn2bp/gen_android_bp
+++ b/tools/gn2bp/gen_android_bp
@@ -102,8 +102,10 @@
# Additional arguments to apply to Android.bp rules.
additional_args = {
- # TODO: remove if this is not useful for the cronet build.
- # Consider using additional_args for overriding the genrule cmd property for gn actions.
+ 'cronet_aml_net_third_party_quiche_net_quic_proto_gen_headers': [
+ # This is needed for cached_network_parameters_proto.h
+ ('export_include_dirs', {'net/third_party/quiche/src'}),
+ ],
}
@@ -590,9 +592,6 @@
header_module.cmd = source_module.cmd
source_module.tools = tools
header_module.tools = tools
- if header_module.name == "cronet_aml_net_third_party_quiche_net_quic_proto_gen_headers":
- # This is needed for cached_network_parameters_proto.h
- header_module.export_include_dirs.add("net/third_party/quiche/src")
for sfx in suffixes:
source_module.out.update('%s/%s' %