Index: third_party/mojo/mojom_bindings_generator_explicit.gypi |
diff --git a/third_party/mojo/mojom_bindings_generator_explicit.gypi b/third_party/mojo/mojom_bindings_generator_explicit.gypi |
index 8c398139c70b036d649d224eac46f259d3f3000e..702456c208668dab67d406c475f523fd41add0ad 100644 |
--- a/third_party/mojo/mojom_bindings_generator_explicit.gypi |
+++ b/third_party/mojo/mojom_bindings_generator_explicit.gypi |
@@ -7,13 +7,25 @@ |
'mojom_bindings_generator_variables.gypi', |
], |
'variables': { |
+ 'variables': { |
+ 'mojom_variant%': 'none', |
+ }, |
+ 'mojom_variant%': '<(mojom_variant)', |
'mojom_base_output_dir': |
'<!(python <(DEPTH)/build/inverse_depth.py <(DEPTH))', |
'mojom_generated_outputs': [ |
- '<!@(python <(DEPTH)/mojo/public/tools/bindings/mojom_list_outputs.py --basedir <(mojom_base_output_dir) <@(mojom_files))', |
+ '<!@(python <(DEPTH)/mojo/public/tools/bindings/mojom_list_outputs.py --basedir <(mojom_base_output_dir) --variant <(mojom_variant) <@(mojom_files))', |
], |
'mojom_include_path%': '<(DEPTH)', |
+ 'mojom_extra_generator_args%': [], |
'require_interface_bindings%': 1, |
+ 'conditions': [ |
+ ['mojom_variant=="none"', { |
+ 'mojom_output_languages%': 'c++,javascript,java', |
+ }, { |
+ 'mojom_output_languages%': 'c++', |
+ }], |
+ ], |
}, |
# Given mojom files as inputs, generate sources. These sources will be |
# exported to another target (via dependent_settings) to be compiled. This |
@@ -63,6 +75,9 @@ |
'<@(mojom_import_args)', |
'-o', '<(SHARED_INTERMEDIATE_DIR)', |
'--java_output_directory=<(java_out_dir)', |
+ '--variant', '<(mojom_variant)', |
+ '-g', '<(mojom_output_languages)', |
+ '<@(mojom_extra_generator_args)', |
], |
'message': 'Generating Mojo bindings from <@(mojom_files)', |
} |