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

Side by Side Diff: build/java_apk.gypi

Issue 11189010: Make resource directory option in gyp template optional. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 months 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 | « no previous file | 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 15 matching lines...) Expand all
26 # content/shell/android/java/content_shell_apk.xml 26 # content/shell/android/java/content_shell_apk.xml
27 # content/shell/android/java/src/chromium/base/Foo.java 27 # content/shell/android/java/src/chromium/base/Foo.java
28 # content/shell/android/java/src/chromium/base/Bar.java 28 # content/shell/android/java/src/chromium/base/Bar.java
29 # 29 #
30 # Required variables: 30 # Required variables:
31 # package_name - Used to name the intermediate output directory and in the 31 # package_name - Used to name the intermediate output directory and in the
32 # names of some output files. 32 # names of some output files.
33 # apk_name - The final apk will be named <apk_name>-debug.apk (or -release) 33 # apk_name - The final apk will be named <apk_name>-debug.apk (or -release)
34 # java_in_dir - The top-level java directory. The src should be in 34 # java_in_dir - The top-level java directory. The src should be in
35 # <java_in_dir>/src. 35 # <java_in_dir>/src.
36 # resource_dir - The directory for resources. 36 # resource_dir - The directory for resources.
cjhopman 2012/10/16 20:27:12 Update this, resource_dir is no longer required.
37 # Optional/automatic variables: 37 # Optional/automatic variables:
38 # additional_input_paths - These paths will be included in the 'inputs' list to 38 # additional_input_paths - These paths will be included in the 'inputs' list to
39 # ensure that this target is rebuilt when one of these paths changes. 39 # ensure that this target is rebuilt when one of these paths changes.
40 # additional_src_dirs - Additional directories with .java files to be compiled 40 # additional_src_dirs - Additional directories with .java files to be compiled
41 # and included in the output of this target. 41 # and included in the output of this target.
42 # asset_location - The directory where assets are located (default: 42 # asset_location - The directory where assets are located (default:
43 # <PRODUCT_DIR>/<package_name>/assets). 43 # <PRODUCT_DIR>/<package_name>/assets).
44 # generated_src_dirs - Same as additional_src_dirs except used for .java files 44 # generated_src_dirs - Same as additional_src_dirs except used for .java files
45 # that are generated at build time. This should be set automatically by a 45 # that are generated at build time. This should be set automatically by a
46 # target's dependencies. The .java files in these directories are not 46 # target's dependencies. The .java files in these directories are not
(...skipping 12 matching lines...) Expand all
59 'additional_input_paths': [], 59 'additional_input_paths': [],
60 'input_jars_paths': [], 60 'input_jars_paths': [],
61 'additional_src_dirs': [], 61 'additional_src_dirs': [],
62 'generated_src_dirs': [], 62 'generated_src_dirs': [],
63 'app_manifest_version_name%': '<(android_app_version_name)', 63 'app_manifest_version_name%': '<(android_app_version_name)',
64 'app_manifest_version_code%': '<(android_app_version_code)', 64 'app_manifest_version_code%': '<(android_app_version_code)',
65 'proguard_enabled%': 'false', 65 'proguard_enabled%': 'false',
66 'proguard_flags%': '', 66 'proguard_flags%': '',
67 'native_libs_paths': [], 67 'native_libs_paths': [],
68 'manifest_package_name%': 'unknown.package.name', 68 'manifest_package_name%': 'unknown.package.name',
69 'resource_dir%':'',
69 }, 70 },
70 'sources': [ 71 'sources': [
71 '<@(native_libs_paths)' 72 '<@(native_libs_paths)'
72 ], 73 ],
73 'rules': [ 74 'rules': [
74 { 75 {
75 'rule_name': 'copy_and_strip_native_libraries', 76 'rule_name': 'copy_and_strip_native_libraries',
76 'extension': 'so', 77 'extension': 'so',
77 'variables': { 78 'variables': {
78 'stripped_library_path': '<(PRODUCT_DIR)/<(package_name)/libs/<(android_ app_abi)/<(RULE_INPUT_ROOT).so', 79 'stripped_library_path': '<(PRODUCT_DIR)/<(package_name)/libs/<(android_ app_abi)/<(RULE_INPUT_ROOT).so',
(...skipping 20 matching lines...) Expand all
99 'action_name': 'ant_<(package_name)_apk', 100 'action_name': 'ant_<(package_name)_apk',
100 'message': 'Building <(package_name) apk.', 101 'message': 'Building <(package_name) apk.',
101 'inputs': [ 102 'inputs': [
102 '<(java_in_dir)/AndroidManifest.xml', 103 '<(java_in_dir)/AndroidManifest.xml',
103 '<(DEPTH)/build/android/ant/chromium-apk.xml', 104 '<(DEPTH)/build/android/ant/chromium-apk.xml',
104 '<(DEPTH)/build/android/ant/common.xml', 105 '<(DEPTH)/build/android/ant/common.xml',
105 '<(DEPTH)/build/android/ant/sdk-targets.xml', 106 '<(DEPTH)/build/android/ant/sdk-targets.xml',
106 # If there is a separate find for additional_src_dirs, it will find the 107 # If there is a separate find for additional_src_dirs, it will find the
107 # wrong .java files when additional_src_dirs is empty. 108 # wrong .java files when additional_src_dirs is empty.
108 '>!@(find >(java_in_dir) >(additional_src_dirs) -name "*.java")', 109 '>!@(find >(java_in_dir) >(additional_src_dirs) -name "*.java")',
109 '<!@(find <(java_in_dir)/<(resource_dir) -name "*")',
110 '>@(input_jars_paths)', 110 '>@(input_jars_paths)',
111 '>@(native_libs_paths)', 111 '>@(native_libs_paths)',
112 '>@(additional_input_paths)', 112 '>@(additional_input_paths)',
113 ], 113 ],
114 'conditions': [
115 ['"<(resource_dir)"!=""', {
116 'inputs': ['<!@(find <(java_in_dir)/<(resource_dir) -name "*")']
cjhopman 2012/10/16 20:27:12 Nit: indentation
117 },
118 ]
119 ],
114 'outputs': [ 120 'outputs': [
115 # TODO(cjhopman): Apks are built with a -debug suffix even when they are 121 # TODO(cjhopman): Apks are built with a -debug suffix even when they are
116 # built in release. This should be fixed. 122 # built in release. This should be fixed.
117 '<(PRODUCT_DIR)/apks/<(apk_name)-debug.apk', 123 '<(PRODUCT_DIR)/apks/<(apk_name)-debug.apk',
118 ], 124 ],
119 'action': [ 125 'action': [
120 'ant', 126 'ant',
121 '-DAPP_ABI=<(android_app_abi)', 127 '-DAPP_ABI=<(android_app_abi)',
122 '-DANDROID_GDBSERVER=<(android_gdbserver)', 128 '-DANDROID_GDBSERVER=<(android_gdbserver)',
123 '-DANDROID_SDK=<(android_sdk)', 129 '-DANDROID_SDK=<(android_sdk)',
(...skipping 21 matching lines...) Expand all
145 '-buildfile', 151 '-buildfile',
146 '<(DEPTH)/build/android/ant/chromium-apk.xml', 152 '<(DEPTH)/build/android/ant/chromium-apk.xml',
147 153
148 # Specify CONFIGURATION_NAME as the target for ant to build. The 154 # Specify CONFIGURATION_NAME as the target for ant to build. The
149 # buildfile will then build the appropriate SDK tools target. 155 # buildfile will then build the appropriate SDK tools target.
150 '<(CONFIGURATION_NAME)', 156 '<(CONFIGURATION_NAME)',
151 ] 157 ]
152 }, 158 },
153 ], 159 ],
154 } 160 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698