| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 | 5 |
| 6 """A tool to build chrome, executed by buildbot. | 6 """A tool to build chrome, executed by buildbot. |
| 7 | 7 |
| 8 When this is run, the current directory (cwd) should be the outer build | 8 When this is run, the current directory (cwd) should be the outer build |
| 9 directory (e.g., chrome-release/build/). | 9 directory (e.g., chrome-release/build/). |
| 10 | 10 |
| (...skipping 711 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 722 | 722 |
| 723 goma_teardown(options, env) | 723 goma_teardown(options, env) |
| 724 | 724 |
| 725 return result | 725 return result |
| 726 | 726 |
| 727 def main_ninja(options, args): | 727 def main_ninja(options, args): |
| 728 """Interprets options, clobbers object files, and calls ninja.""" | 728 """Interprets options, clobbers object files, and calls ninja.""" |
| 729 | 729 |
| 730 # Prepare environment. | 730 # Prepare environment. |
| 731 env = EchoDict(os.environ) | 731 env = EchoDict(os.environ) |
| 732 env.setdefault('NINJA_STATUS', '[%s/%t | %e] ') |
| 732 orig_compiler = options.compiler | 733 orig_compiler = options.compiler |
| 733 goma_ready = goma_setup(options, env) | 734 goma_ready = goma_setup(options, env) |
| 734 if not goma_ready: | 735 if not goma_ready: |
| 735 assert options.compiler not in ('goma', 'goma-clang') | 736 assert options.compiler not in ('goma', 'goma-clang') |
| 736 assert options.goma_dir is None | 737 assert options.goma_dir is None |
| 737 | 738 |
| 738 # ninja is different from all the other build systems in that it requires | 739 # ninja is different from all the other build systems in that it requires |
| 739 # most configuration to be done at gyp time. This is why this function does | 740 # most configuration to be done at gyp time. This is why this function does |
| 740 # less than the other comparable functions in this file. | 741 # less than the other comparable functions in this file. |
| 741 print 'chdir to %s' % options.src_dir | 742 print 'chdir to %s' % options.src_dir |
| (...skipping 493 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1235 options.target_output_dir = get_target_build_dir(options.build_tool, | 1236 options.target_output_dir = get_target_build_dir(options.build_tool, |
| 1236 options.src_dir, options.target, 'iphoneos' in args) | 1237 options.src_dir, options.target, 'iphoneos' in args) |
| 1237 options.clobber = (options.clobber or | 1238 options.clobber = (options.clobber or |
| 1238 landmines_triggered(options.target_output_dir)) | 1239 landmines_triggered(options.target_output_dir)) |
| 1239 | 1240 |
| 1240 return main(options, args) | 1241 return main(options, args) |
| 1241 | 1242 |
| 1242 | 1243 |
| 1243 if '__main__' == __name__: | 1244 if '__main__' == __name__: |
| 1244 sys.exit(real_main()) | 1245 sys.exit(real_main()) |
| OLD | NEW |