| OLD | NEW | 
|---|
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python | 
| 2 # | 2 # | 
| 3 # Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file | 3 # Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file | 
| 4 # for details. All rights reserved. Use of this source code is governed by a | 4 # for details. All rights reserved. Use of this source code is governed by a | 
| 5 # BSD-style license that can be found in the LICENSE file. | 5 # BSD-style license that can be found in the LICENSE file. | 
| 6 # | 6 # | 
| 7 | 7 | 
| 8 import optparse | 8 import optparse | 
| 9 import os | 9 import os | 
| 10 import re | 10 import re | 
| (...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 401 | 401 | 
| 402 | 402 | 
| 403 def RunGN(target_os, mode, arch): | 403 def RunGN(target_os, mode, arch): | 
| 404   gn_os = 'host' if target_os == HOST_OS else target_os | 404   gn_os = 'host' if target_os == HOST_OS else target_os | 
| 405   gn_command = [ | 405   gn_command = [ | 
| 406     'python', | 406     'python', | 
| 407     os.path.join(DART_ROOT, 'tools', 'gn.py'), | 407     os.path.join(DART_ROOT, 'tools', 'gn.py'), | 
| 408     '-m', mode, | 408     '-m', mode, | 
| 409     '-a', arch, | 409     '-a', arch, | 
| 410     '--os', gn_os, | 410     '--os', gn_os, | 
| 411     '--check', |  | 
| 412     '-v', | 411     '-v', | 
| 413   ] | 412   ] | 
| 414   process = subprocess.Popen(gn_command) | 413   process = subprocess.Popen(gn_command) | 
| 415   process.wait() | 414   process.wait() | 
| 416   if process.returncode != 0: | 415   if process.returncode != 0: | 
| 417     print ("Tried to run GN, but it failed. Try running it manually: \n\t$ " + | 416     print ("Tried to run GN, but it failed. Try running it manually: \n\t$ " + | 
| 418            ' '.join(gn_command)) | 417            ' '.join(gn_command)) | 
| 419 | 418 | 
| 420 def BuildNinjaCommand(options, target, target_os, mode, arch): | 419 def BuildNinjaCommand(options, target, target_os, mode, arch): | 
| 421   out_dir = utils.GetBuildRoot(HOST_OS, mode, arch, target_os) | 420   out_dir = utils.GetBuildRoot(HOST_OS, mode, arch, target_os) | 
| (...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 597           else: | 596           else: | 
| 598             if BuildOneConfig(options, target, target_os, | 597             if BuildOneConfig(options, target, target_os, | 
| 599                               mode, arch, cross_build) != 0: | 598                               mode, arch, cross_build) != 0: | 
| 600               return 1 | 599               return 1 | 
| 601 | 600 | 
| 602   return 0 | 601   return 0 | 
| 603 | 602 | 
| 604 | 603 | 
| 605 if __name__ == '__main__': | 604 if __name__ == '__main__': | 
| 606   sys.exit(Main()) | 605   sys.exit(Main()) | 
| OLD | NEW | 
|---|