OLD | NEW |
1 #!/usr/bin/python | 1 #!/usr/bin/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 """This is the entry point to create Dart APIs from the IDL database.""" | 6 """This is the entry point to create Dart APIs from the IDL database.""" |
7 | 7 |
8 import dartgenerator | 8 import dartgenerator |
9 import database | 9 import database |
10 import logging.config | 10 import logging.config |
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
139 if 'frog' in systems: | 139 if 'frog' in systems: |
140 _logger.info('Copy dom_frog to frog/') | 140 _logger.info('Copy dom_frog to frog/') |
141 subprocess.call(['cd .. ; ../tools/copy_dart.py frog dom_frog.dart'], | 141 subprocess.call(['cd .. ; ../tools/copy_dart.py frog dom_frog.dart'], |
142 shell=True); | 142 shell=True); |
143 | 143 |
144 if 'htmlfrog' in systems: | 144 if 'htmlfrog' in systems: |
145 _logger.info('Copy html_frog to ../html/frog/') | 145 _logger.info('Copy html_frog to ../html/frog/') |
146 subprocess.call(['cd ../../html ; ../tools/copy_dart.py frog html_frog.dart'
], | 146 subprocess.call(['cd ../../html ; ../tools/copy_dart.py frog html_frog.dart'
], |
147 shell=True); | 147 shell=True); |
148 | 148 |
| 149 if 'htmldartium' in systems: |
| 150 _logger.info('Copy html_dartium to ../html/dartium/') |
| 151 subprocess.call(['cd ../../html ; ../tools/copy_dart.py dartium html_dartium
.dart'], |
| 152 shell=True); |
| 153 |
149 def main(): | 154 def main(): |
150 parser = optparse.OptionParser() | 155 parser = optparse.OptionParser() |
151 parser.add_option('--systems', dest='systems', | 156 parser.add_option('--systems', dest='systems', |
152 action='store', type='string', | 157 action='store', type='string', |
153 default='frog,dummy,wrapping', | 158 default='frog,dummy,wrapping', |
154 help='Systems to generate (frog, native, dummy, ' | 159 help='Systems to generate (frog, native, dummy, ' |
155 'htmlfrog, htmldartium)') | 160 'htmlfrog, htmldartium)') |
156 parser.add_option('--output-dir', dest='output_dir', | 161 parser.add_option('--output-dir', dest='output_dir', |
157 action='store', type='string', | 162 action='store', type='string', |
158 default=None, | 163 default=None, |
(...skipping 25 matching lines...) Expand all Loading... |
184 # Copy dummy DOM where dartc build expects it. | 189 # Copy dummy DOM where dartc build expects it. |
185 if 'dummy' in systems: | 190 if 'dummy' in systems: |
186 # TODO(sra): Make other tools pick this up directly, or do a copy_dart into | 191 # TODO(sra): Make other tools pick this up directly, or do a copy_dart into |
187 # a specific directory. | 192 # a specific directory. |
188 source = os.path.join(output_dir, 'dom_dummy.dart') | 193 source = os.path.join(output_dir, 'dom_dummy.dart') |
189 target = os.path.join(output_dir, 'dom.dart') | 194 target = os.path.join(output_dir, 'dom.dart') |
190 shutil.copyfile(source, target) | 195 shutil.copyfile(source, target) |
191 | 196 |
192 if __name__ == '__main__': | 197 if __name__ == '__main__': |
193 sys.exit(main()) | 198 sys.exit(main()) |
OLD | NEW |