| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 # Pre-caching steps used internally by the IDL compiler | 5 # Pre-caching steps used internally by the IDL compiler |
| 6 # | 6 # |
| 7 # Design doc: http://www.chromium.org/developers/design-documents/idl-build | 7 # Design doc: http://www.chromium.org/developers/design-documents/idl-build |
| 8 | 8 |
| 9 { | 9 { |
| 10 'includes': [ | 10 'includes': [ |
| 11 'scripts.gypi', | 11 'scripts.gypi', |
| 12 '../bindings.gypi', | 12 '../bindings.gypi', |
| 13 '../templates/templates.gypi', | 13 '../templates/templates.gypi', |
| 14 ], | 14 ], |
| 15 | 15 |
| 16 'targets': [ | 16 'targets': [ |
| 17 ################################################################################ | 17 ################################################################################ |
| 18 { | 18 { |
| 19 # A separate pre-caching step is *not required* to use lex/parse table | 19 # A separate pre-caching step is *not required* to use lex/parse table |
| 20 # caching in PLY, as the caches are concurrency-safe. | 20 # caching in PLY, as the caches are concurrency-safe. |
| 21 # However, pre-caching ensures that all compiler processes use the cached | 21 # However, pre-caching ensures that all compiler processes use the cached |
| 22 # files (hence maximizing speed), instead of early processes building the | 22 # files (hence maximizing speed), instead of early processes building the |
| 23 # tables themselves (as they've not yet been written when they start). | 23 # tables themselves (as they've not yet been written when they start). |
| 24 # |
| 25 # GN version: //third_party/WebKit/Source/bindings/scripts:cached_lex_yacc_t
ables |
| 24 'target_name': 'cached_lex_yacc_tables', | 26 'target_name': 'cached_lex_yacc_tables', |
| 25 'type': 'none', | 27 'type': 'none', |
| 26 'actions': [{ | 28 'actions': [{ |
| 27 'action_name': 'cache_lex_yacc_tables', | 29 'action_name': 'cache_lex_yacc_tables', |
| 28 'inputs': [ | 30 'inputs': [ |
| 29 '<@(idl_lexer_parser_files)', | 31 '<@(idl_lexer_parser_files)', |
| 30 ], | 32 ], |
| 31 'outputs': [ | 33 'outputs': [ |
| 32 '<(bindings_scripts_output_dir)/lextab.py', | 34 '<(bindings_scripts_output_dir)/lextab.py', |
| 33 '<(bindings_scripts_output_dir)/parsetab.pickle', | 35 '<(bindings_scripts_output_dir)/parsetab.pickle', |
| 34 ], | 36 ], |
| 35 'action': [ | 37 'action': [ |
| 36 'python', | 38 'python', |
| 37 'blink_idl_parser.py', | 39 'blink_idl_parser.py', |
| 38 '<(bindings_scripts_output_dir)', | 40 '<(bindings_scripts_output_dir)', |
| 39 ], | 41 ], |
| 40 'message': 'Caching PLY lex & yacc lex/parse tables', | 42 'message': 'Caching PLY lex & yacc lex/parse tables', |
| 41 }], | 43 }], |
| 42 }, | 44 }, |
| 43 ################################################################################ | 45 ################################################################################ |
| 44 { | 46 { |
| 45 # A separate pre-caching step is *required* to use bytecode caching in | 47 # A separate pre-caching step is *required* to use bytecode caching in |
| 46 # Jinja (which improves speed significantly), as the bytecode cache is | 48 # Jinja (which improves speed significantly), as the bytecode cache is |
| 47 # not concurrency-safe on write; details in code_generator_v8.py. | 49 # not concurrency-safe on write; details in code_generator_v8.py. |
| 50 # |
| 51 # GN version: //third_party/WebKit/Source/bindings/scripts:cached_jinja_temp
lates |
| 48 'target_name': 'cached_jinja_templates', | 52 'target_name': 'cached_jinja_templates', |
| 49 'type': 'none', | 53 'type': 'none', |
| 50 'actions': [{ | 54 'actions': [{ |
| 51 'action_name': 'cache_jinja_templates', | 55 'action_name': 'cache_jinja_templates', |
| 52 'inputs': [ | 56 'inputs': [ |
| 53 '<@(jinja_module_files)', | 57 '<@(jinja_module_files)', |
| 54 'code_generator_v8.py', | 58 'code_generator_v8.py', |
| 55 '<@(code_generator_template_files)', | 59 '<@(code_generator_template_files)', |
| 56 ], | 60 ], |
| 57 'outputs': [ | 61 'outputs': [ |
| 58 '<(bindings_scripts_output_dir)/cached_jinja_templates.stamp', # Dummy
to track dependency | 62 '<(bindings_scripts_output_dir)/cached_jinja_templates.stamp', # Dummy
to track dependency |
| 59 ], | 63 ], |
| 60 'action': [ | 64 'action': [ |
| 61 'python', | 65 'python', |
| 62 'code_generator_v8.py', | 66 'code_generator_v8.py', |
| 63 '<(bindings_scripts_output_dir)', | 67 '<(bindings_scripts_output_dir)', |
| 64 '<(bindings_scripts_output_dir)/cached_jinja_templates.stamp', | 68 '<(bindings_scripts_output_dir)/cached_jinja_templates.stamp', |
| 65 ], | 69 ], |
| 66 'message': 'Caching bytecode of Jinja templates', | 70 'message': 'Caching bytecode of Jinja templates', |
| 67 }], | 71 }], |
| 68 }, | 72 }, |
| 69 ################################################################################ | 73 ################################################################################ |
| 70 ], # targets | 74 ], # targets |
| 71 } | 75 } |
| OLD | NEW |