Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(32)

Side by Side Diff: build/java_apk.gypi

Issue 11411049: Enable Android APKs to be build with R.java in a custom package. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « build/android/ant/empty/res/.keep ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 Android APKs in a consistent manner. 6 # to build Android APKs 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_apk', 10 # 'target_name': 'my_package_apk',
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 # input_jars_paths - The path to jars to be included in the classpath. This 50 # input_jars_paths - The path to jars to be included in the classpath. This
51 # should be filled automatically by depending on the appropriate targets. 51 # should be filled automatically by depending on the appropriate targets.
52 # is_test_apk - Set to 1 if building a test apk. This prevents resources from 52 # is_test_apk - Set to 1 if building a test apk. This prevents resources from
53 # dependencies from being re-included. 53 # dependencies from being re-included.
54 # native_libs_paths - The path to any native library to be included in this 54 # native_libs_paths - The path to any native library to be included in this
55 # target. This should be a path in <(SHARED_LIB_DIR). A stripped copy of 55 # target. This should be a path in <(SHARED_LIB_DIR). A stripped copy of
56 # the library will be included in the apk and symbolic links to the 56 # the library will be included in the apk and symbolic links to the
57 # unstripped copy will be added to <(android_product_out) to enable native 57 # unstripped copy will be added to <(android_product_out) to enable native
58 # debugging. 58 # debugging.
59 # resource_dir - The directory for resources. 59 # resource_dir - The directory for resources.
60 # R_package - A custom Java package to generate the resource file R.java in.
61 # By default, the package given in AndroidManifest.xml will be used.
60 62
61 { 63 {
62 'variables': { 64 'variables': {
63 'asset_location%': '', 65 'asset_location%': '',
64 'additional_input_paths': [], 66 'additional_input_paths': [],
65 'input_jars_paths': [], 67 'input_jars_paths': [],
66 'additional_src_dirs': [], 68 'additional_src_dirs': [],
67 'generated_src_dirs': [], 69 'generated_src_dirs': [],
68 'app_manifest_version_name%': '<(android_app_version_name)', 70 'app_manifest_version_name%': '<(android_app_version_name)',
69 'app_manifest_version_code%': '<(android_app_version_code)', 71 'app_manifest_version_code%': '<(android_app_version_code)',
70 'proguard_enabled%': 'false', 72 'proguard_enabled%': 'false',
71 'proguard_flags%': '', 73 'proguard_flags%': '',
72 'native_libs_paths': [], 74 'native_libs_paths': [],
73 'manifest_package_name%': 'unknown.package.name', 75 'jar_name%': 'chromium_apk_<(package_name).jar',
74 'resource_dir%':'', 76 'resource_dir%':'',
75 'jar_name%': 'chromium_apk_<(package_name).jar', 77 'R_package%':'',
76 'additional_res_dirs': [], 78 'additional_res_dirs': [],
77 'additional_res_packages': [], 79 'additional_res_packages': [],
78 'is_test_apk%': 0, 80 'is_test_apk%': 0,
79 }, 81 },
80 'sources': [ 82 'sources': [
81 '<@(native_libs_paths)' 83 '<@(native_libs_paths)'
82 ], 84 ],
83 # Pass the jar path to the apk's "fake" jar target. This would be better as 85 # Pass the jar path to the apk's "fake" jar target. This would be better as
84 # direct_dependent_settings, but a variable set by a direct_dependent_settings 86 # direct_dependent_settings, but a variable set by a direct_dependent_settings
85 # cannot be lifted in a dependent to all_dependent_settings. 87 # cannot be lifted in a dependent to all_dependent_settings.
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 '-Dbasedir=<(java_in_dir)', 172 '-Dbasedir=<(java_in_dir)',
171 '-buildfile', 173 '-buildfile',
172 '<(DEPTH)/build/android/ant/chromium-apk.xml', 174 '<(DEPTH)/build/android/ant/chromium-apk.xml',
173 175
174 # Specify CONFIGURATION_NAME as the target for ant to build. The 176 # Specify CONFIGURATION_NAME as the target for ant to build. The
175 # buildfile will then build the appropriate SDK tools target. 177 # buildfile will then build the appropriate SDK tools target.
176 '<(CONFIGURATION_NAME)', 178 '<(CONFIGURATION_NAME)',
177 ] 179 ]
178 }, 180 },
179 ], 181 ],
182 'conditions': [
183 ['R_package != ""', {
184 'variables': {
185 # We generate R.java in package R_package (in addition to the package
186 # listed in the AndroidManifest.xml, which is unavoidable).
187 'additional_res_dirs': ['<(DEPTH)/build/android/ant/empty/res'],
188 'additional_res_packages': ['<(R_package)'],
189 },
190 }],
191 ],
180 } 192 }
OLDNEW
« no previous file with comments | « build/android/ant/empty/res/.keep ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698