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

Side by Side Diff: build/gyp_chromium

Issue 149163005: Work on GN iOS build. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 10 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
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 2
3 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 3 # Copyright (c) 2012 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 # This script is wrapper for Chromium that adds some support for how GYP 7 # This script is wrapper for Chromium that adds some support for how GYP
8 # is invoked by Chromium beyond what can be done in the gclient hooks. 8 # is invoked by Chromium beyond what can be done in the gclient hooks.
9 9
10 import glob 10 import glob
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 ('asan', '1', 'is_asan=true'), 215 ('asan', '1', 'is_asan=true'),
216 ('lsan', '1', 'is_lsan=true'), 216 ('lsan', '1', 'is_lsan=true'),
217 ('msan', '1', 'is_msan=true'), 217 ('msan', '1', 'is_msan=true'),
218 ('tsan', '1', 'is_tsan=true'), 218 ('tsan', '1', 'is_tsan=true'),
219 ] 219 ]
220 for i in remap_cases: 220 for i in remap_cases:
221 if i[0] in vars_dict and vars_dict[i[0]] == i[1]: 221 if i[0] in vars_dict and vars_dict[i[0]] == i[1]:
222 gn_args += ' ' + i[2] 222 gn_args += ' ' + i[2]
223 223
224 # These string arguments get passed directly as GN strings. 224 # These string arguments get passed directly as GN strings.
225 for v in ['android_src', 'windows_sdk_path', 'arm_float_abi']: 225 for v in ['android_src', 'arm_float_abi', 'ios_deployment_target',
226 'ios_sdk_path', 'windows_sdk_path']:
226 if v in vars_dict: 227 if v in vars_dict:
227 gn_args += ' ' + v + '=' + EscapeStringForGN(vars_dict[v]) 228 gn_args += ' ' + v + '=' + EscapeStringForGN(vars_dict[v])
228 229
229 # gomadir is renamed goma_dir in the GN build. 230 # gomadir is renamed goma_dir in the GN build.
230 if 'gomadir' in vars_dict: 231 if 'gomadir' in vars_dict:
231 gn_args += ' goma_dir=%s' % EscapeStringForGN(vars_dict['gomadir']) 232 gn_args += ' goma_dir=%s' % EscapeStringForGN(vars_dict['gomadir'])
232 233
234 # Clear the "use_ios_simulator" flag if the ios_sdk_path is set and is
235 # not a simulator SDK. This duplicates code done in GYP's xcode emulation.
236 if 'ios_sdk_path' in vars_dict:
237 if not os.path.basename(vars_dict['ios_sdk_path']).lower().startswith(
238 'iphonesimulator'):
239 gn_args += ' use_ios_simulator=false'
240
241
233 # These arguments get passed directly as integers (avoiding the quoting and 242 # These arguments get passed directly as integers (avoiding the quoting and
234 # escaping of the string ones above). 243 # escaping of the string ones above).
235 for v in ['arm_version']: 244 for v in ['arm_version']:
236 if v in vars_dict: 245 if v in vars_dict:
237 gn_args += ' %s=%s' % (v, vars_dict[v]) 246 gn_args += ' %s=%s' % (v, vars_dict[v])
238 247
239 # Some other flags come from GYP environment variables. 248 # Some other flags come from GYP environment variables.
240 gyp_msvs_version = os.environ.get('GYP_MSVS_VERSION', '') 249 gyp_msvs_version = os.environ.get('GYP_MSVS_VERSION', '')
241 if gyp_msvs_version: 250 if gyp_msvs_version:
242 gn_args += ' visual_studio_version=' + EscapeStringForGN(gyp_msvs_version) 251 gn_args += ' visual_studio_version=' + EscapeStringForGN(gyp_msvs_version)
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
427 args.extend( 436 args.extend(
428 ['-I' + i for i in additional_include_files(supplemental_includes, args)]) 437 ['-I' + i for i in additional_include_files(supplemental_includes, args)])
429 438
430 args.extend(['-D', 'gyp_output_dir=' + GetOutputDirectory()]) 439 args.extend(['-D', 'gyp_output_dir=' + GetOutputDirectory()])
431 440
432 print 'Updating projects from gyp files...' 441 print 'Updating projects from gyp files...'
433 sys.stdout.flush() 442 sys.stdout.flush()
434 443
435 # Off we go... 444 # Off we go...
436 sys.exit(gyp.main(args)) 445 sys.exit(gyp.main(args))
OLDNEW
« build/config/BUILDCONFIG.gn ('K') | « build/config/mac/BUILD.gn ('k') | tools/gn/args.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698