| OLD | NEW |
| 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 script is wrapper for Chromium that adds some support for how GYP | 5 """This script is wrapper for Chromium that adds some support for how GYP |
| 6 is invoked by Chromium beyond what can be done in the gclient hooks. | 6 is invoked by Chromium beyond what can be done in the gclient hooks. |
| 7 """ | 7 """ |
| 8 | 8 |
| 9 import argparse | 9 import argparse |
| 10 import gc | 10 import gc |
| (...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 312 args.append('--check') | 312 args.append('--check') |
| 313 | 313 |
| 314 args.extend( | 314 args.extend( |
| 315 ['-I' + i for i in additional_include_files(supplemental_includes, args)]) | 315 ['-I' + i for i in additional_include_files(supplemental_includes, args)]) |
| 316 | 316 |
| 317 args.extend(['-D', 'gyp_output_dir=' + GetOutputDirectory()]) | 317 args.extend(['-D', 'gyp_output_dir=' + GetOutputDirectory()]) |
| 318 | 318 |
| 319 mac_toolchain_dir = mac_toolchain.GetToolchainDirectory() | 319 mac_toolchain_dir = mac_toolchain.GetToolchainDirectory() |
| 320 if mac_toolchain_dir: | 320 if mac_toolchain_dir: |
| 321 args.append('-Gmac_toolchain_dir=' + mac_toolchain_dir) | 321 args.append('-Gmac_toolchain_dir=' + mac_toolchain_dir) |
| 322 mac_toolchain.SetToolchainEnvironment() |
| 322 | 323 |
| 323 # TODO(crbug.com/432967) - We are eventually going to switch GYP off | 324 # TODO(crbug.com/432967) - We are eventually going to switch GYP off |
| 324 # by default for all Chromium builds, so this list of configurations | 325 # by default for all Chromium builds, so this list of configurations |
| 325 # will get broader and broader. | 326 # will get broader and broader. |
| 326 running_as_hook = '--running-as-hook' | 327 running_as_hook = '--running-as-hook' |
| 327 if (running_as_hook in args and | 328 if (running_as_hook in args and |
| 328 os.environ.get('GYP_CHROMIUM_NO_ACTION', None) != '0' and | 329 os.environ.get('GYP_CHROMIUM_NO_ACTION', None) != '0' and |
| 329 (sys.platform.startswith('linux') and not gyp_vars_dict)): | 330 (sys.platform.startswith('linux') and not gyp_vars_dict)): |
| 330 print 'GYP is now disabled in this configuration by default in runhooks.\n' | 331 print 'GYP is now disabled in this configuration by default in runhooks.\n' |
| 331 print 'If you really want to run this, either run ' | 332 print 'If you really want to run this, either run ' |
| (...skipping 16 matching lines...) Expand all Loading... |
| 348 if vs2013_runtime_dll_dirs: | 349 if vs2013_runtime_dll_dirs: |
| 349 x64_runtime, x86_runtime = vs2013_runtime_dll_dirs | 350 x64_runtime, x86_runtime = vs2013_runtime_dll_dirs |
| 350 vs_toolchain.CopyVsRuntimeDlls( | 351 vs_toolchain.CopyVsRuntimeDlls( |
| 351 os.path.join(chrome_src, GetOutputDirectory()), | 352 os.path.join(chrome_src, GetOutputDirectory()), |
| 352 (x86_runtime, x64_runtime)) | 353 (x86_runtime, x64_runtime)) |
| 353 | 354 |
| 354 sys.exit(gyp_rc) | 355 sys.exit(gyp_rc) |
| 355 | 356 |
| 356 if __name__ == '__main__': | 357 if __name__ == '__main__': |
| 357 sys.exit(main()) | 358 sys.exit(main()) |
| OLD | NEW |