OLD | NEW |
(Empty) | |
| 1 { |
| 2 'variables': { |
| 3 'global_dart_output_dir': '<(SHARED_INTERMEDIATE_DIR)/blink/bindings/dart', |
| 4 'dart_dir': '../../../../../../dart', |
| 5 'dart_lib_dir': '<(dart_dir)/sdk/lib', |
| 6 'resources_dir': 'resources', |
| 7 'build_dir': '../../../build', |
| 8 'core_dir': '../../../core', |
| 9 'modules_dir': '../../../modules', |
| 10 'core_gyp_dir': '<(core_dir)', |
| 11 'scripts_dir': '../../dart/gyp/scripts', |
| 12 |
| 13 'bindings_core_dart_stamp_file': '<(SHARED_INTERMEDIATE_DIR)/blink/bindings/
core/dart/core.stamp', |
| 14 |
| 15 # Share with Source/core/core.gyp somehow. |
| 16 # Note: that SVG exclusions are not applicable for Dartium. |
| 17 'bindings_idl_files': [ |
| 18 '<@(core_idl_files)', |
| 19 '<@(core_dependency_idl_files)', |
| 20 '<@(modules_idl_files)', |
| 21 '<@(modules_dependency_idl_files)', |
| 22 '<(modules_dir)/geolocation/NavigatorGeolocation.idl', |
| 23 # Add some interfaces which are missing for JS, but necessary for Dart. |
| 24 '<(core_dir)/svg/SVGFilterPrimitiveStandardAttributes.idl', |
| 25 '<(core_dir)/svg/SVGFitToViewBox.idl', |
| 26 '<(core_dir)/svg/SVGTests.idl', |
| 27 ], |
| 28 |
| 29 'bindings_idl_files!': [ |
| 30 # Custom bindings in bindings/core/v8/custom exist for these. |
| 31 '<(core_dir)/dom/EventListener.idl', |
| 32 |
| 33 '<(core_dir)/page/AbstractView.idl', |
| 34 |
| 35 # FIXME: I don't know why these are excluded, either. |
| 36 # Someone (me?) should figure it out and add appropriate comments. |
| 37 '<(core_dir)/css/CSSUnknownRule.idl', |
| 38 ], |
| 39 |
| 40 'enable_dart_native_extensions%': '<(enable_dart_native_extensions)', |
| 41 'additional_webcore_include_dirs': [ |
| 42 '.', |
| 43 'custom', |
| 44 '<(dart_dir)runtime', |
| 45 '<(dart_dir)runtime/include', |
| 46 '<(SHARED_INTERMEDIATE_DIR)/blink/bindings/dart', |
| 47 ], |
| 48 }, |
| 49 'targets': [ |
| 50 { |
| 51 'target_name': 'dart_debug_hooks_source', |
| 52 'type': 'none', |
| 53 'actions': [ |
| 54 { |
| 55 'action_name': 'generateDartDebugHooksSource', |
| 56 'inputs': [ |
| 57 'DartDebugHooks.js', |
| 58 ], |
| 59 'outputs': [ |
| 60 '<(SHARED_INTERMEDIATE_DIR)/blink/DartDebugHooksSource.h', |
| 61 ], |
| 62 'action': [ |
| 63 'python', |
| 64 '<(build_dir)/scripts/xxd.py', |
| 65 'DartDebugHooksSource_js', |
| 66 '<@(_inputs)', |
| 67 '<@(_outputs)' |
| 68 ], |
| 69 'message': 'Generating DartDebugHooksSource.h from DartDebugHooks.js', |
| 70 }, |
| 71 ] |
| 72 }, |
| 73 { |
| 74 'target_name': 'gen_dart_blink', |
| 75 'type': 'none', |
| 76 'actions': [ |
| 77 { |
| 78 'action_name': 'generateDartBlinkLibrary', |
| 79 'inputs': [ |
| 80 # Only includes main IDL files from core and modules (exclude |
| 81 # dependencies and testing, for which bindings are not included in |
| 82 # aggregate bindings). |
| 83 '<@(core_idl_files)', |
| 84 '<@(modules_idl_files)', |
| 85 '<@(core_dictionary_idl_files)', |
| 86 '<@(modules_dictionary_idl_files)', |
| 87 '<(bindings_core_dart_stamp_file)', |
| 88 '<(bindings_modules_dart_stamp_file)', |
| 89 '<@(dart_code_generator_template_files)', |
| 90 '<@(dart_idl_compiler_files)', |
| 91 '<@(idl_compiler_files)', |
| 92 ], |
| 93 'outputs': [ |
| 94 '<(global_dart_output_dir)/_blink_dartium.dart', |
| 95 ], |
| 96 'action': [ |
| 97 'python', |
| 98 '-S', # skip 'import site' to speed up startup |
| 99 '../../dart/scripts/compiler.py', |
| 100 '--generate-dart-blink', |
| 101 '<(bindings_core_dart_output_dir)', |
| 102 '<(core_idl_files_list)', |
| 103 '<(core_dictionary_idl_files_list)', |
| 104 '--generate-dart-blink', |
| 105 '<(bindings_modules_dart_output_dir)', |
| 106 '<(modules_idl_files_list)', |
| 107 '<(modules_dictionary_idl_files_list)', |
| 108 '--output-directory', |
| 109 '<(global_dart_output_dir)', |
| 110 ], |
| 111 'message': 'Generating dart:_blink library', |
| 112 }, |
| 113 ] |
| 114 }, |
| 115 { |
| 116 'target_name': 'dart_snapshot', |
| 117 'type': 'none', |
| 118 'hard_dependency': 1, |
| 119 'dependencies': [ |
| 120 '<(dart_dir)/runtime/dart-runtime.gyp:gen_snapshot#host', |
| 121 'gen_dart_blink', |
| 122 ], |
| 123 'variables': { |
| 124 'idls_list_temp_file': '<|(idls_list_temp_file.tmp <@(bindings_idl_files
))', |
| 125 'output_path': '<(SHARED_INTERMEDIATE_DIR)/blink/bindings/dart', |
| 126 'dart_html_lib_dir': '<(dart_dir)/tools/dom', |
| 127 'dart_html_lib_deps': '<!(python <@(scripts_dir)/dart_html_lib_deps.py <
(dart_html_lib_dir))', |
| 128 }, |
| 129 'sources': [ |
| 130 # '<!@(cat <(idls_list_temp_file))', |
| 131 ], |
| 132 'actions': [ |
| 133 # FIXME: We need an action to generate: |
| 134 # - Dart*.[h|cpp] |
| 135 # - blink_DartResolver.cpp |
| 136 { |
| 137 'action_name': 'generate_dart_class_ids', |
| 138 'inputs': [ |
| 139 # Only includes main IDL files from core and modules (exclude |
| 140 # dependencies and testing, for which bindings are not included in |
| 141 # aggregate bindings). |
| 142 '<@(core_idl_files)', |
| 143 '<@(modules_idl_files)', |
| 144 '<(bindings_core_dart_stamp_file)', |
| 145 '<(bindings_modules_dart_stamp_file)', |
| 146 '<@(dart_code_generator_template_files)', |
| 147 '<@(dart_idl_compiler_files)', |
| 148 '<@(idl_compiler_files)', |
| 149 ], |
| 150 'outputs': [ |
| 151 '<@(dart_class_id_files)', |
| 152 ], |
| 153 'action': [ |
| 154 'python', |
| 155 '-S', # skip 'import site' to speed up startup |
| 156 '../../dart/scripts/compiler.py', |
| 157 '--generate-globals', |
| 158 '<(bindings_core_dart_output_dir)', |
| 159 '<(core_idl_files_list)', |
| 160 '--generate-globals', |
| 161 '<(bindings_modules_dart_output_dir)', |
| 162 '<(modules_idl_files_list)', |
| 163 '--output-directory', |
| 164 '<(global_dart_output_dir)', |
| 165 ], |
| 166 'message': 'Generating Dart class id table', |
| 167 }, |
| 168 { |
| 169 'action_name': 'build_dart_snapshot', |
| 170 'variables': { |
| 171 'output_path': '<(SHARED_INTERMEDIATE_DIR)/blink/bindings/dart', |
| 172 'pure_libs': [ |
| 173 '<(global_dart_output_dir)/_blink_dartium.dart', |
| 174 '<(dart_dir)/runtime/bin/vmserviceio_dartium.dart', |
| 175 '<(dart_lib_dir)/html/html_common/html_common.dart', |
| 176 '<(dart_lib_dir)/js/dartium/js_dartium.dart', |
| 177 '<(dart_lib_dir)/html/dartium/html_dartium.dart', |
| 178 '<(dart_lib_dir)/indexed_db/dartium/indexed_db_dartium.dart', |
| 179 '<(dart_lib_dir)/svg/dartium/svg_dartium.dart', |
| 180 '<(dart_lib_dir)/web_audio/dartium/web_audio_dartium.dart', |
| 181 '<(dart_lib_dir)/web_gl/dartium/web_gl_dartium.dart', |
| 182 '<(dart_lib_dir)/web_sql/dartium/web_sql_dartium.dart', |
| 183 ], |
| 184 }, |
| 185 'inputs': [ |
| 186 '<@(scripts_dir)/build_dart_snapshot.py', |
| 187 '<(resources_dir)/DartSnapshot.bytes.template', |
| 188 '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)gen_snapshot<(EXECUTABLE_SUFFIX)
', |
| 189 # FIXME: libs below can consist of more than a single file. Ideally,
we should |
| 190 # track that somehow. |
| 191 # FIXME: We need blink_dartium.dart here. |
| 192 '<@(pure_libs)', |
| 193 '<@(dart_html_lib_deps)', |
| 194 ], |
| 195 'outputs': [ |
| 196 '<(output_path)/DartSnapshot.bytes', |
| 197 ], |
| 198 'action': [ |
| 199 'python', |
| 200 '<@(scripts_dir)/build_dart_snapshot.py', |
| 201 '<(dart_dir)', |
| 202 '<(resources_dir)/DartSnapshot.bytes.template', |
| 203 '<(output_path)', |
| 204 '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)gen_snapshot<(EXECUTABLE_SUFFIX)
', |
| 205 '<@(pure_libs)', |
| 206 ], |
| 207 }, |
| 208 ], |
| 209 }, |
| 210 ], |
| 211 } |
OLD | NEW |