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

Side by Side Diff: pylib/gyp/xcode_ninja.py

Issue 376603002: This CL adds support for extension in GYP. (Closed) Base URL: https://chromium.googlesource.com/external/gyp.git@master
Patch Set: oops Created 6 years, 5 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 | « pylib/gyp/xcode_emulation.py ('k') | pylib/gyp/xcodeproj_file.py » ('j') | 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) 2014 Google Inc. All rights reserved. 1 # Copyright (c) 2014 Google Inc. 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 """Xcode-ninja wrapper project file generator. 5 """Xcode-ninja wrapper project file generator.
6 6
7 This updates the data structures passed to the Xcode gyp generator to build 7 This updates the data structures passed to the Xcode gyp generator to build
8 with ninja instead. The Xcode project itself is transformed into a list of 8 with ninja instead. The Xcode project itself is transformed into a list of
9 executable targets, each with a build step to build with ninja, and a target 9 executable targets, each with a build step to build with ninja, and a target
10 with every source and resource file. This appears to sidestep some of the 10 with every source and resource file. This appears to sidestep some of the
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 old_xcode_settings = old_spec['configurations'][config]['xcode_settings'] 83 old_xcode_settings = old_spec['configurations'][config]['xcode_settings']
84 if 'IPHONEOS_DEPLOYMENT_TARGET' in old_xcode_settings: 84 if 'IPHONEOS_DEPLOYMENT_TARGET' in old_xcode_settings:
85 new_xcode_settings['CODE_SIGNING_REQUIRED'] = "NO" 85 new_xcode_settings['CODE_SIGNING_REQUIRED'] = "NO"
86 new_xcode_settings['IPHONEOS_DEPLOYMENT_TARGET'] = \ 86 new_xcode_settings['IPHONEOS_DEPLOYMENT_TARGET'] = \
87 old_xcode_settings['IPHONEOS_DEPLOYMENT_TARGET'] 87 old_xcode_settings['IPHONEOS_DEPLOYMENT_TARGET']
88 ninja_target['configurations'][config] = {} 88 ninja_target['configurations'][config] = {}
89 ninja_target['configurations'][config]['xcode_settings'] = \ 89 ninja_target['configurations'][config]['xcode_settings'] = \
90 new_xcode_settings 90 new_xcode_settings
91 91
92 ninja_target['mac_bundle'] = old_spec.get('mac_bundle', 0) 92 ninja_target['mac_bundle'] = old_spec.get('mac_bundle', 0)
93 ninja_target['ios_app_extension'] = old_spec.get('ios_app_extension', 0)
93 ninja_target['type'] = old_spec['type'] 94 ninja_target['type'] = old_spec['type']
94 if ninja_toplevel: 95 if ninja_toplevel:
95 ninja_target['actions'] = [ 96 ninja_target['actions'] = [
96 { 97 {
97 'action_name': 'Compile and copy %s via ninja' % target_name, 98 'action_name': 'Compile and copy %s via ninja' % target_name,
98 'inputs': [], 99 'inputs': [],
99 'outputs': [], 100 'outputs': [],
100 'action': [ 101 'action': [
101 'env', 102 'env',
102 'PATH=%s' % os.environ['PATH'], 103 'PATH=%s' % os.environ['PATH'],
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 new_data[sources_gyp] = {} 249 new_data[sources_gyp] = {}
249 new_data[sources_gyp]['targets'] = [] 250 new_data[sources_gyp]['targets'] = []
250 new_data[sources_gyp]['included_files'] = [] 251 new_data[sources_gyp]['included_files'] = []
251 new_data[sources_gyp]['xcode_settings'] = \ 252 new_data[sources_gyp]['xcode_settings'] = \
252 data[orig_gyp].get('xcode_settings', {}) 253 data[orig_gyp].get('xcode_settings', {})
253 new_data[sources_gyp]['targets'].append(new_data_target) 254 new_data[sources_gyp]['targets'].append(new_data_target)
254 255
255 # Write workspace to file. 256 # Write workspace to file.
256 _WriteWorkspace(main_gyp, sources_gyp) 257 _WriteWorkspace(main_gyp, sources_gyp)
257 return (new_target_list, new_target_dicts, new_data) 258 return (new_target_list, new_target_dicts, new_data)
OLDNEW
« no previous file with comments | « pylib/gyp/xcode_emulation.py ('k') | pylib/gyp/xcodeproj_file.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698