OLD | NEW |
| (Empty) |
1 # Copyright 2013 The Chromium Authors. All rights reserved. | |
2 # Use of this source code is governed by a BSD-style license that can be | |
3 # found in the LICENSE file. | |
4 | |
5 { | |
6 'includes': [ | |
7 'mojom_bindings_generator_variables.gypi', | |
8 ], | |
9 'rules': [ | |
10 { | |
11 'rule_name': '<(_target_name)_mojom_bindings_generator', | |
12 'extension': 'mojom', | |
13 'variables': { | |
14 'mojom_base_output_dir': | |
15 '<!(python <(DEPTH)/build/inverse_depth.py <(DEPTH))', | |
16 'java_out_dir': '<(PRODUCT_DIR)/java_mojo/<(_target_name)/src', | |
17 'mojom_import_args%': [ | |
18 '-I<(DEPTH)' | |
19 ], | |
20 }, | |
21 'inputs': [ | |
22 '<@(mojom_bindings_generator_sources)', | |
23 ], | |
24 'outputs': [ | |
25 '<(SHARED_INTERMEDIATE_DIR)/<(mojom_base_output_dir)/<(RULE_INPUT_DIRNAM
E)/<(RULE_INPUT_ROOT).mojom.cc', | |
26 '<(SHARED_INTERMEDIATE_DIR)/<(mojom_base_output_dir)/<(RULE_INPUT_DIRNAM
E)/<(RULE_INPUT_ROOT).mojom.h', | |
27 '<(SHARED_INTERMEDIATE_DIR)/<(mojom_base_output_dir)/<(RULE_INPUT_DIRNAM
E)/<(RULE_INPUT_ROOT).mojom.js', | |
28 '<(SHARED_INTERMEDIATE_DIR)/<(mojom_base_output_dir)/<(RULE_INPUT_DIRNAM
E)/<(RULE_INPUT_ROOT)_mojom.py', | |
29 '<(SHARED_INTERMEDIATE_DIR)/<(mojom_base_output_dir)/<(RULE_INPUT_DIRNAM
E)/<(RULE_INPUT_ROOT).mojom-internal.h', | |
30 ], | |
31 'action': [ | |
32 'python', '<@(mojom_bindings_generator)', | |
33 './<(RULE_INPUT_DIRNAME)/<(RULE_INPUT_ROOT).mojom', | |
34 '--use_bundled_pylibs', | |
35 '-d', '<(DEPTH)', | |
36 '<@(mojom_import_args)', | |
37 '-o', '<(SHARED_INTERMEDIATE_DIR)', | |
38 '--java_output_directory=<(java_out_dir)', | |
39 ], | |
40 'message': 'Generating Mojo bindings from <(RULE_INPUT_DIRNAME)/<(RULE_INP
UT_ROOT).mojom', | |
41 'process_outputs_as_sources': 1, | |
42 } | |
43 ], | |
44 'include_dirs': [ | |
45 '<(DEPTH)', | |
46 '<(SHARED_INTERMEDIATE_DIR)', | |
47 ], | |
48 'direct_dependent_settings': { | |
49 'include_dirs': [ | |
50 '<(DEPTH)', | |
51 '<(SHARED_INTERMEDIATE_DIR)', | |
52 ], | |
53 'variables': { | |
54 'generated_src_dirs': [ | |
55 '<(PRODUCT_DIR)/java_mojo/<(_target_name)/src', | |
56 ], | |
57 }, | |
58 }, | |
59 'hard_dependency': 1, | |
60 } | |
OLD | NEW |