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

Side by Side Diff: build/android/gyp/write_build_config.py

Issue 512923002: Add support for Android aidl and support for gyp's java_in_dir (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 3 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
« no previous file with comments | « build/android/gyp/aidl.py ('k') | build/config/android/internal_rules.gni » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # 2 #
3 # Copyright 2014 The Chromium Authors. All rights reserved. 3 # Copyright 2014 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 """Writes a build_config file. 7 """Writes a build_config file.
8 8
9 The build_config file for a target is a json file containing information about 9 The build_config file for a target is a json file containing information about
10 how to build that target based on the target's dependencies. This includes 10 how to build that target based on the target's dependencies. This includes
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 build_utils.CheckOptions(options, parser, required_options) 104 build_utils.CheckOptions(options, parser, required_options)
105 105
106 possible_deps_config_paths = build_utils.ParseGypList( 106 possible_deps_config_paths = build_utils.ParseGypList(
107 options.possible_deps_configs) 107 options.possible_deps_configs)
108 108
109 109
110 allow_unknown_deps = options.type == 'android_apk' 110 allow_unknown_deps = options.type == 'android_apk'
111 unknown_deps = [ 111 unknown_deps = [
112 c for c in possible_deps_config_paths if not os.path.exists(c)] 112 c for c in possible_deps_config_paths if not os.path.exists(c)]
113 if unknown_deps and not allow_unknown_deps: 113 if unknown_deps and not allow_unknown_deps:
114 raise Exception('Unknown deps: ' + unknown_deps) 114 raise Exception('Unknown deps: ' + str(unknown_deps))
115 115
116 direct_deps_config_paths = [ 116 direct_deps_config_paths = [
117 c for c in possible_deps_config_paths if not c in unknown_deps] 117 c for c in possible_deps_config_paths if not c in unknown_deps]
118 all_deps_config_paths = GetAllDepsConfigsInOrder(direct_deps_config_paths) 118 all_deps_config_paths = GetAllDepsConfigsInOrder(direct_deps_config_paths)
119 119
120 direct_deps_configs = [GetDepConfig(p) for p in direct_deps_config_paths] 120 direct_deps_configs = [GetDepConfig(p) for p in direct_deps_config_paths]
121 all_deps_configs = [GetDepConfig(p) for p in all_deps_config_paths] 121 all_deps_configs = [GetDepConfig(p) for p in all_deps_config_paths]
122 122
123 direct_library_deps = DepsOfType('android_library', direct_deps_configs) 123 direct_library_deps = DepsOfType('android_library', direct_deps_configs)
124 all_resources_deps = DepsOfType('android_resources', all_deps_configs) 124 all_resources_deps = DepsOfType('android_resources', all_deps_configs)
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
188 build_utils.WriteJson(config, options.build_config, only_if_changed=True) 188 build_utils.WriteJson(config, options.build_config, only_if_changed=True)
189 189
190 if options.depfile: 190 if options.depfile:
191 build_utils.WriteDepfile( 191 build_utils.WriteDepfile(
192 options.depfile, 192 options.depfile,
193 all_deps_config_paths + build_utils.GetPythonDependencies()) 193 all_deps_config_paths + build_utils.GetPythonDependencies())
194 194
195 195
196 if __name__ == '__main__': 196 if __name__ == '__main__':
197 sys.exit(main(sys.argv[1:])) 197 sys.exit(main(sys.argv[1:]))
OLDNEW
« no previous file with comments | « build/android/gyp/aidl.py ('k') | build/config/android/internal_rules.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698