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: runtime/tools/create_snapshot_file.py

Issue 8588040: Add a mid-sized integration test for the Dart Embedding Api which (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
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # 2 #
3 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 3 # Copyright (c) 2011, 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 # Script to create snapshot files. 7 # Script to create snapshot files.
8 8
9 import getopt 9 import getopt
10 import optparse 10 import optparse
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 command = [ options.executable ] + script_args 115 command = [ options.executable ] + script_args
116 if options.verbose: 116 if options.verbose:
117 print ' '.join(command) 117 print ' '.join(command)
118 pipe = subprocess.Popen(command, 118 pipe = subprocess.Popen(command,
119 stdout=subprocess.PIPE, 119 stdout=subprocess.PIPE,
120 stderr=subprocess.PIPE) 120 stderr=subprocess.PIPE)
121 out, error = pipe.communicate() 121 out, error = pipe.communicate()
122 if (pipe.returncode != 0): 122 if (pipe.returncode != 0):
123 print out, error 123 print out, error
124 print "Snapshot generation failed" 124 print "Snapshot generation failed"
125 print "(Command was: '", ' '.join(command), "')"
125 return -1 126 return -1
126 127
127 if not makeFile(options.output, options.input_cc, options.output_bin): 128 if not makeFile(options.output, options.input_cc, options.output_bin):
128 print "Unable to generate snapshot in C buffer form" 129 print "Unable to generate snapshot in C buffer form"
129 return -1 130 return -1
130 131
131 return 0 132 return 0
132 133
133 if __name__ == '__main__': 134 if __name__ == '__main__':
134 sys.exit(Main()) 135 sys.exit(Main())
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698