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

Side by Side Diff: frog/frog.py

Issue 8597016: - Remove uses of the dart_bin binary. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 9 years, 1 month 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
« no previous file with comments | « frog/dart-frog.gyp ('k') | samples/chat/README » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 2 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
3 # for details. All rights reserved. Use of this source code is governed by a 3 # for details. All rights reserved. Use of this source code is governed by a
4 # BSD-style license that can be found in the LICENSE file. 4 # BSD-style license that can be found in the LICENSE file.
5 5
6 """Command line wrapper to run the frog compiler under the Dart VM""" 6 """Command line wrapper to run the frog compiler under the Dart VM"""
7 7
8 # TODO(jimhug): This is a temporary hack to enable running on the VM. We need 8 # TODO(jimhug): This is a temporary hack to enable running on the VM. We need
9 # the ability to get command-line arguments, to return exit codes, and to 9 # the ability to get command-line arguments, to return exit codes, and to
10 # communicate with spawned processes in the VM for this to go away. 10 # communicate with spawned processes in the VM for this to go away.
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 (' '.join(dartArgs), ' '.join(pythonArgs), ' '.join(extraArgs))) 128 (' '.join(dartArgs), ' '.join(pythonArgs), ' '.join(extraArgs)))
129 129
130 if len(extraArgs) != 0: 130 if len(extraArgs) != 0:
131 optionParser.print_help() 131 optionParser.print_help()
132 return 1 132 return 1
133 133
134 dart = GetDart() 134 dart = GetDart()
135 if not exists(dart): 135 if not exists(dart):
136 print("Dart VM not configured in %s," % dart), 136 print("Dart VM not configured in %s," % dart),
137 print "run the following command from the dart directory" 137 print "run the following command from the dart directory"
138 print " tools/build.py -m release dart_bin" 138 print " tools/build.py -m release"
139 return 1 139 return 1
140 140
141 if subprocess.call("node --help >/dev/null 2>&1", shell=True): 141 if subprocess.call("node --help >/dev/null 2>&1", shell=True):
142 if not exists(D8): 142 if not exists(D8):
143 print "No engine available for running JS code." 143 print "No engine available for running JS code."
144 print "See frog/README.txt for instructions." 144 print "See frog/README.txt for instructions."
145 return 1 145 return 1
146 elif 'node' in options.js_cmd: 146 elif 'node' in options.js_cmd:
147 options.js_cmd = D8 147 options.js_cmd = D8
148 148
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 f.close() 220 f.close()
221 result = execute([browser, outhtml]) 221 result = execute([browser, outhtml])
222 222
223 if cleanup: shutil.rmtree(workdir) 223 if cleanup: shutil.rmtree(workdir)
224 if result != 0: 224 if result != 0:
225 return 1 225 return 1
226 return 0 226 return 0
227 227
228 if __name__ == '__main__': 228 if __name__ == '__main__':
229 sys.exit(main(sys.argv)) 229 sys.exit(main(sys.argv))
OLDNEW
« no previous file with comments | « frog/dart-frog.gyp ('k') | samples/chat/README » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698