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 in a consistent manner. | 6 # to build Java 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': 'my-package_java', | 10 # 'target_name': 'my-package_java', |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 'dependencies': [ | 49 'dependencies': [ |
50 '<(DEPTH)/build/build_output_dirs_android.gyp:build_output_dirs' | 50 '<(DEPTH)/build/build_output_dirs_android.gyp:build_output_dirs' |
51 ], | 51 ], |
52 'variables': { | 52 'variables': { |
53 'android_jar': '<(android_sdk)/android.jar', | 53 'android_jar': '<(android_sdk)/android.jar', |
54 'input_jars_paths': [ '<(android_jar)' ], | 54 'input_jars_paths': [ '<(android_jar)' ], |
55 'additional_src_dirs': [], | 55 'additional_src_dirs': [], |
56 'javac_includes': [], | 56 'javac_includes': [], |
57 'jar_name': '<(_target_name).jar', | 57 'jar_name': '<(_target_name).jar', |
58 'jar_path': '<(PRODUCT_DIR)/lib.java/<(jar_name)', | 58 'jar_path': '<(PRODUCT_DIR)/lib.java/<(jar_name)', |
59 'excluded_classes': [ '*/R.class', '*/R##*.class' ], | 59 'jar_excluded_classes': [ '*/R.class', '*/R##*.class' ], |
60 'additional_input_paths': [], | 60 'additional_input_paths': [], |
61 'generated_src_dirs': ['>@(generated_R_dirs)'], | 61 'generated_src_dirs': ['>@(generated_R_dirs)'], |
62 'generated_R_dirs': [], | 62 'generated_R_dirs': [], |
63 'has_java_resources%': 0, | 63 'has_java_resources%': 0, |
64 'java_strings_grd%': '', | 64 'java_strings_grd%': '', |
65 'res_extra_dirs': [], | 65 'res_extra_dirs': [], |
66 'res_extra_files': [], | 66 'res_extra_files': [], |
67 'resource_input_paths': ['>@(res_extra_files)'], | 67 'resource_input_paths': ['>@(res_extra_files)'], |
68 'intermediate_dir': '<(SHARED_INTERMEDIATE_DIR)/<(_target_name)', | 68 'intermediate_dir': '<(SHARED_INTERMEDIATE_DIR)/<(_target_name)', |
69 'classes_dir': '<(intermediate_dir)/classes', | 69 'classes_dir': '<(intermediate_dir)/classes', |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 }, | 163 }, |
164 ], | 164 ], |
165 }], | 165 }], |
166 ], | 166 ], |
167 'actions': [ | 167 'actions': [ |
168 { | 168 { |
169 'action_name': 'javac_<(_target_name)', | 169 'action_name': 'javac_<(_target_name)', |
170 'message': 'Compiling <(_target_name) java sources', | 170 'message': 'Compiling <(_target_name) java sources', |
171 'variables': { | 171 'variables': { |
172 'all_src_dirs': [ | 172 'all_src_dirs': [ |
173 '>@(java_in_dir)/src', | 173 '>(java_in_dir)/src', |
174 '>@(additional_src_dirs)', | 174 '>@(additional_src_dirs)', |
175 '>@(generated_src_dirs)', | 175 '>@(generated_src_dirs)', |
176 ], | 176 ], |
177 }, | 177 }, |
178 'inputs': [ | 178 'inputs': [ |
179 '<(DEPTH)/build/android/pylib/build_utils.py', | 179 '<(DEPTH)/build/android/pylib/build_utils.py', |
180 '<(DEPTH)/build/android/javac.py', | 180 '<(DEPTH)/build/android/javac.py', |
181 '>!@(find >(java_in_dir) >(additional_src_dirs) -name "*.java")', | 181 '>!@(find >(java_in_dir) >(additional_src_dirs) -name "*.java")', |
182 '>@(input_jars_paths)', | 182 '>@(input_jars_paths)', |
183 '>@(additional_input_paths)', | 183 '>@(additional_input_paths)', |
(...skipping 21 matching lines...) Expand all Loading... |
205 '<(DEPTH)/build/android/jar.py', | 205 '<(DEPTH)/build/android/jar.py', |
206 '<(compile_stamp)', | 206 '<(compile_stamp)', |
207 ], | 207 ], |
208 'outputs': [ | 208 'outputs': [ |
209 '<(jar_path)', | 209 '<(jar_path)', |
210 ], | 210 ], |
211 'action': [ | 211 'action': [ |
212 'python', '<(DEPTH)/build/android/jar.py', | 212 'python', '<(DEPTH)/build/android/jar.py', |
213 '--classes-dir=<(classes_dir)', | 213 '--classes-dir=<(classes_dir)', |
214 '--jar-path=<(jar_path)', | 214 '--jar-path=<(jar_path)', |
215 '--excluded-classes=<(excluded_classes)', | 215 '--excluded-classes=<(jar_excluded_classes)', |
216 | 216 |
217 # TODO(newt): remove this once http://crbug.com/177552 is fixed in ninja
. | 217 # TODO(newt): remove this once http://crbug.com/177552 is fixed in ninja
. |
218 '--ignore=>!(echo \'>(_inputs)\' | md5sum)', | 218 '--ignore=>!(echo \'>(_inputs)\' | md5sum)', |
219 ] | 219 ] |
220 }, | 220 }, |
221 ], | 221 ], |
222 } | 222 } |
OLD | NEW |