OLD | NEW |
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 # This file is meant to be included into a target to provide a rule | 5 # This file is meant to be included into a target to provide a rule |
6 # to build Java aidl files in a consistent manner. | 6 # to build Java aidl files in a consistent manner. |
7 # | 7 # |
8 # To use this, create a gyp target with the following form: | 8 # To use this, create a gyp target with the following form: |
9 # { | 9 # { |
10 # 'target_name': 'aidl_aidl-file-name', | 10 # 'target_name': 'aidl_aidl-file-name', |
(...skipping 17 matching lines...) Expand all Loading... |
28 # ... | 28 # ... |
29 # | 29 # |
30 # Optional variables: | 30 # Optional variables: |
31 # aidl_import_include - This should be an absolute path to your java src folder | 31 # aidl_import_include - This should be an absolute path to your java src folder |
32 # that contains the classes that are imported by your aidl files. | 32 # that contains the classes that are imported by your aidl files. |
33 # | 33 # |
34 # TODO(cjhopman): dependents need to rebuild when this target's inputs have chan
ged. | 34 # TODO(cjhopman): dependents need to rebuild when this target's inputs have chan
ged. |
35 | 35 |
36 { | 36 { |
37 'variables': { | 37 'variables': { |
| 38 'aidl_path%': '<(android_sdk_tools)/aidl', |
38 'intermediate_dir': '<(SHARED_INTERMEDIATE_DIR)/<(_target_name)/aidl', | 39 'intermediate_dir': '<(SHARED_INTERMEDIATE_DIR)/<(_target_name)/aidl', |
39 'aidl_import_include%': '', | 40 'aidl_import_include%': '', |
40 'additional_aidl_arguments': [], | 41 'additional_aidl_arguments': [], |
41 'additional_aidl_input_paths': [], | 42 'additional_aidl_input_paths': [], |
42 }, | 43 }, |
43 'direct_dependent_settings': { | 44 'direct_dependent_settings': { |
44 'variables': { | 45 'variables': { |
45 'generated_src_dirs': ['<(intermediate_dir)/'], | 46 'generated_src_dirs': ['<(intermediate_dir)/'], |
46 }, | 47 }, |
47 }, | 48 }, |
(...skipping 11 matching lines...) Expand all Loading... |
59 'extension': 'aidl', | 60 'extension': 'aidl', |
60 'inputs': [ | 61 'inputs': [ |
61 '<(android_sdk)/framework.aidl', | 62 '<(android_sdk)/framework.aidl', |
62 '<(aidl_interface_file)', | 63 '<(aidl_interface_file)', |
63 '<@(additional_aidl_input_paths)', | 64 '<@(additional_aidl_input_paths)', |
64 ], | 65 ], |
65 'outputs': [ | 66 'outputs': [ |
66 '<(intermediate_dir)/<(RULE_INPUT_ROOT).java', | 67 '<(intermediate_dir)/<(RULE_INPUT_ROOT).java', |
67 ], | 68 ], |
68 'action': [ | 69 'action': [ |
69 '<(android_sdk_tools)/aidl', | 70 '<(aidl_path)', |
70 '-p<(android_sdk)/framework.aidl', | 71 '-p<(android_sdk)/framework.aidl', |
71 '-p<(aidl_interface_file)', | 72 '-p<(aidl_interface_file)', |
72 '<@(additional_aidl_arguments)', | 73 '<@(additional_aidl_arguments)', |
73 '<(RULE_INPUT_PATH)', | 74 '<(RULE_INPUT_PATH)', |
74 '<(intermediate_dir)/<(RULE_INPUT_ROOT).java', | 75 '<(intermediate_dir)/<(RULE_INPUT_ROOT).java', |
75 ], | 76 ], |
76 }, | 77 }, |
77 ], | 78 ], |
78 } | 79 } |
OLD | NEW |