Chromium Code Reviews| Index: dart/frog/scripts/bootstrap/frog_bootstrap_wrapper.py |
| diff --git a/dart/frog/scripts/bootstrap/frog_bootstrap_wrapper.py b/dart/frog/scripts/bootstrap/frog_bootstrap_wrapper.py |
| index f61d8b5e0d0aeaec164dbcb9df68a54d36e23db3..5510b688deff478bd257f309567e61f1be0b9325 100644 |
| --- a/dart/frog/scripts/bootstrap/frog_bootstrap_wrapper.py |
| +++ b/dart/frog/scripts/bootstrap/frog_bootstrap_wrapper.py |
| @@ -11,6 +11,7 @@ HOME = os.path.join(HOME, os.pardir, os.pardir) |
| END_SCRIPT = ''' |
| VM = '%s' |
| +VM_FLAGS = '%s' |
| if __name__ == '__main__': |
| sys.exit(main(sys.argv)) |
| ''' |
| @@ -23,13 +24,16 @@ def main(args): |
| vm = vm + '.exe' |
| frog = os.path.join(product_dir, 'frog', 'bin', 'frog') |
| - # TODO(ngeoffray): Create a script that will run the VM in production mode. |
| - # if js_out.find('Release') != -1: |
| shutil.copy(os.path.join(HOME, 'scripts', 'bootstrap', 'frog_wrapper.py'), |
| frog) |
| + if 'Release' in product_dir: |
|
kasperl
2012/02/07 09:07:55
Maybe add a comment here that explains why we run
ahe
2012/02/07 09:14:29
Done.
|
| + vm_flags = '--vm_flags=--enable_asserts --enable_type_checks' |
| + else: |
| + vm_flags = '' |
| + |
| with open(frog, 'a+') as f: |
| - f.write(END_SCRIPT % vm) |
| + f.write(END_SCRIPT % (vm, vm_flags)) |
| os.chmod(frog, stat.S_IXUSR | stat.S_IXGRP | stat.S_IRUSR | |
| stat.S_IRGRP | stat.S_IWUSR) |