Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(240)

Unified Diff: Source/bindings/derived_sources.gyp

Issue 17572008: WIP IDL compiler rewrite (Closed) Base URL: https://chromium.googlesource.com/chromium/blink@master
Patch Set: Branch: const + primitive type readonly attributes Created 7 years, 4 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/bindings/scripts/code_generator_idl_reader.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/derived_sources.gyp
diff --git a/Source/bindings/derived_sources.gyp b/Source/bindings/derived_sources.gyp
index d0535478b39baa5f8d3459104fc0feb7b8622c52..7f477ac1a2501b37c6a523457ed64efe918e8201 100644
--- a/Source/bindings/derived_sources.gyp
+++ b/Source/bindings/derived_sources.gyp
@@ -55,13 +55,44 @@
'<@(deprecated_perl_webcore_test_support_idl_files)',
'<@(python_webcore_test_support_idl_files)',
],
+ 'compiler_module_files': [
+ 'scripts/idl_compiler.py',
+ '<(DEPTH)/third_party/ply/lex.py',
+ '<(DEPTH)/third_party/ply/yacc.py',
+ '<(DEPTH)/tools/idl_parser/idl_lexer.py',
+ '<(DEPTH)/tools/idl_parser/idl_node.py',
+ '<(DEPTH)/tools/idl_parser/idl_parser.py',
+ 'scripts/blink_idl_lexer.py',
+ 'scripts/blink_idl_parser.py',
+ 'scripts/code_generator_v8.py',
+ 'scripts/idl_definitions.py',
+ 'scripts/idl_definitions_builder.py',
+ 'scripts/idl_reader.py',
+ 'scripts/idl_validator.py',
+ 'scripts/interface_dependency_resolver.py',
+ 'scripts/v8_attributes.py',
+ 'scripts/v8_constructors.py',
+ 'scripts/v8_functions.py',
+ 'scripts/v8_includes.py',
+ 'scripts/v8_interface.py',
+ 'scripts/v8_interface_header.py',
+ 'scripts/v8_special_accessors.py',
+ 'scripts/v8_types.py',
+ 'scripts/v8_utilities.py',
+ 'scripts/v8_values.py',
+ ],
'code_generator_template_files': [
+ 'templates/attributes.cpp',
'templates/callback_interface.cpp',
'templates/callback_interface.h',
+ 'templates/constants.cpp',
+ 'templates/constructors.cpp',
'templates/interface.cpp',
'templates/interface.h',
+ 'templates/interface_wip.cpp',
+ 'templates/interface_wip.h',
+ 'templates/macros.cpp',
],
-
'bindings_output_dir': '<(SHARED_INTERMEDIATE_DIR)/blink/bindings',
'generated_global_constructors_idl_files': [
'<(SHARED_INTERMEDIATE_DIR)/blink/WindowConstructors.idl',
@@ -162,8 +193,90 @@
'message': 'Resolving partial interfaces dependencies in all IDL files',
}]
},
+ #{
+ # 'target_name': 'deprecated_perl_bindings_sources',
+ # 'type': 'none',
+ # # The 'binding' rule generates .h files, so mark as hard_dependency, per:
+ # # https://code.google.com/p/gyp/wiki/InputFormatReference#Linking_Dependencies
+ # 'hard_dependency': 1,
+ # 'dependencies': [
+ # 'interface_dependencies',
+ # '../core/core_derived_sources.gyp:generate_test_support_idls',
+ # ],
+ # 'sources': [
+ # '<@(deprecated_perl_idl_files)',
+ # '<@(deprecated_perl_webcore_test_support_idl_files)',
+ # ],
+ # 'rules': [{
+ # 'rule_name': 'deprecated_perl_binding',
+ # 'extension': 'idl',
+ # 'msvs_external_rule': 1,
+ # 'inputs': [
+ # 'scripts/deprecated_generate_bindings.pl',
+ # 'scripts/deprecated_code_generator_v8.pm',
+ # 'scripts/deprecated_idl_parser.pm',
+ # 'scripts/deprecated_idl_serializer.pm',
+ # '../core/scripts/preprocessor.pm',
+ # 'scripts/IDLAttributes.txt',
+ # # FIXME: If the dependency structure changes, we rebuild all files,
+ # # since we're not computing dependencies file-by-file in the build.
+ # '<(SHARED_INTERMEDIATE_DIR)/blink/InterfaceDependencies.txt',
+ # # FIXME: Similarly, if any partial interface changes, rebuild
+ # # everything, since every IDL potentially depends on them, because
+ # # we're not computing dependencies file-by-file.
+ # #
+ # # If a new partial interface is added, need to regyp to update these
+ # # dependencies, as these are computed statically at gyp runtime.
+ # '<!@pymod_do_main(list_idl_files_with_partial_interface <@(perl_and_python_idl_files))',
+ # # Generated IDLs are all partial interfaces, hence everything
+ # # potentially depends on them.
+ # '<@(generated_global_constructors_idl_files)',
+ # ],
+ # 'outputs': [
+ # '<(bindings_output_dir)/V8<(RULE_INPUT_ROOT).cpp',
+ # '<(bindings_output_dir)/V8<(RULE_INPUT_ROOT).h',
+ # ],
+ # 'variables': {
+ # # IDL include paths. The generator will search recursively for IDL
+ # # files under these locations.
+ # 'generator_include_dirs': [
+ # '--include', '../core',
+ # '--include', '../modules',
+ # '--include', '<(SHARED_INTERMEDIATE_DIR)/blink',
+ # ],
+ # # Hook for embedders to specify extra directories to find IDL files.
+ # 'extra_blink_generator_include_dirs%': [],
+ # },
+ # 'msvs_cygwin_shell': 0,
+ # # sanitize-win-build-log.sed uses a regex which matches this command
+ # # line (Perl script + .idl file being processed).
+ # # Update that regex if command line changes (other than changing flags)
+ # 'action': [
+ # '<(perl_exe)',
+ # '-w',
+ # '-Iscripts',
+ # '-I../core/scripts',
+ # '-I<(DEPTH)/third_party/JSON/out/lib/perl5',
+ # 'scripts/deprecated_generate_bindings.pl',
+ # '--outputDir',
+ # '<(bindings_output_dir)',
+ # '--idlAttributesFile',
+ # 'scripts/IDLAttributes.txt',
+ # '<@(generator_include_dirs)',
+ # '<@(extra_blink_generator_include_dirs)',
+ # '--interfaceDependenciesFile',
+ # '<(SHARED_INTERMEDIATE_DIR)/blink/InterfaceDependencies.txt',
+ # '--additionalIdlFiles',
+ # '<(deprecated_perl_webcore_test_support_idl_files)',
+ # '<@(preprocessor)',
+ # '<@(write_file_only_if_changed)',
+ # '<(RULE_INPUT_PATH)',
+ # ],
+ # 'message': 'Generating binding from <(RULE_INPUT_PATH)',
+ # }],
+ #},
{
- 'target_name': 'deprecated_perl_bindings_sources',
+ 'target_name': 'python_bindings_sources',
'type': 'none',
# The 'binding' rule generates .h files, so mark as hard_dependency, per:
# https://code.google.com/p/gyp/wiki/InputFormatReference#Linking_Dependencies
@@ -175,86 +288,6 @@
'sources': [
'<@(deprecated_perl_idl_files)',
'<@(deprecated_perl_webcore_test_support_idl_files)',
- ],
- 'rules': [{
- 'rule_name': 'deprecated_perl_binding',
- 'extension': 'idl',
- 'msvs_external_rule': 1,
- 'inputs': [
- 'scripts/deprecated_generate_bindings.pl',
- 'scripts/deprecated_code_generator_v8.pm',
- 'scripts/deprecated_idl_parser.pm',
- 'scripts/deprecated_idl_serializer.pm',
- '../core/scripts/preprocessor.pm',
- 'scripts/IDLAttributes.txt',
- # FIXME: If the dependency structure changes, we rebuild all files,
- # since we're not computing dependencies file-by-file in the build.
- '<(SHARED_INTERMEDIATE_DIR)/blink/InterfaceDependencies.txt',
- # FIXME: Similarly, if any partial interface changes, rebuild
- # everything, since every IDL potentially depends on them, because
- # we're not computing dependencies file-by-file.
- #
- # If a new partial interface is added, need to regyp to update these
- # dependencies, as these are computed statically at gyp runtime.
- '<!@pymod_do_main(list_idl_files_with_partial_interface <@(perl_and_python_idl_files))',
- # Generated IDLs are all partial interfaces, hence everything
- # potentially depends on them.
- '<@(generated_global_constructors_idl_files)',
- ],
- 'outputs': [
- '<(bindings_output_dir)/V8<(RULE_INPUT_ROOT).cpp',
- '<(bindings_output_dir)/V8<(RULE_INPUT_ROOT).h',
- ],
- 'variables': {
- # IDL include paths. The generator will search recursively for IDL
- # files under these locations.
- 'generator_include_dirs': [
- '--include', '../core',
- '--include', '../modules',
- '--include', '<(SHARED_INTERMEDIATE_DIR)/blink',
- ],
- # Hook for embedders to specify extra directories to find IDL files.
- 'extra_blink_generator_include_dirs%': [],
- },
- 'msvs_cygwin_shell': 0,
- # sanitize-win-build-log.sed uses a regex which matches this command
- # line (Perl script + .idl file being processed).
- # Update that regex if command line changes (other than changing flags)
- 'action': [
- '<(perl_exe)',
- '-w',
- '-Iscripts',
- '-I../core/scripts',
- '-I<(DEPTH)/third_party/JSON/out/lib/perl5',
- 'scripts/deprecated_generate_bindings.pl',
- '--outputDir',
- '<(bindings_output_dir)',
- '--idlAttributesFile',
- 'scripts/IDLAttributes.txt',
- '<@(generator_include_dirs)',
- '<@(extra_blink_generator_include_dirs)',
- '--interfaceDependenciesFile',
- '<(SHARED_INTERMEDIATE_DIR)/blink/InterfaceDependencies.txt',
- '--additionalIdlFiles',
- '<(deprecated_perl_webcore_test_support_idl_files)',
- '<@(preprocessor)',
- '<@(write_file_only_if_changed)',
- '<(RULE_INPUT_PATH)',
- ],
- 'message': 'Generating binding from <(RULE_INPUT_PATH)',
- }],
- },
- {
- 'target_name': 'python_bindings_sources',
- 'type': 'none',
- # The 'binding' rule generates .h files, so mark as hard_dependency, per:
- # https://code.google.com/p/gyp/wiki/InputFormatReference#Linking_Dependencies
- 'hard_dependency': 1,
- 'dependencies': [
- 'interface_dependencies',
- '../core/core_derived_sources.gyp:generate_test_support_idls',
- ],
- 'sources': [
'<@(python_idl_files)',
'<@(python_webcore_test_support_idl_files)',
],
@@ -263,22 +296,9 @@
'extension': 'idl',
'msvs_external_rule': 1,
'inputs': [
- 'scripts/idl_compiler.py',
- '<(DEPTH)/third_party/ply/lex.py',
- '<(DEPTH)/third_party/ply/yacc.py',
- '<(DEPTH)/tools/idl_parser/idl_lexer.py',
- '<(DEPTH)/tools/idl_parser/idl_node.py',
- '<(DEPTH)/tools/idl_parser/idl_parser.py',
- 'scripts/blink_idl_lexer.py',
- 'scripts/blink_idl_parser.py',
- 'scripts/code_generator_v8.py',
- 'scripts/idl_definitions.py',
- 'scripts/idl_definitions_builder.py',
- 'scripts/idl_reader.py',
- 'scripts/idl_validator.py',
- 'scripts/interface_dependency_resolver.py',
- 'scripts/IDLAttributes.txt',
+ '<@(compiler_module_files)',
'<@(code_generator_template_files)',
+ 'scripts/IDLAttributes.txt',
# FIXME: If the dependency structure changes, we rebuild all files,
# since we're not computing dependencies file-by-file in the build.
'<(SHARED_INTERMEDIATE_DIR)/blink/InterfaceDependencies.txt',
@@ -297,6 +317,7 @@
'variables': {
# IDL include paths. The generator will search recursively for IDL
# files under these locations.
+ # FIXME: this should be done by the parser
'generator_include_dirs': [
'--include', '../core',
'--include', '../modules',
@@ -333,7 +354,7 @@
'type': 'none',
'dependencies': [
'interface_dependencies',
- 'deprecated_perl_bindings_sources',
+ # 'deprecated_perl_bindings_sources',
'python_bindings_sources',
],
'actions': [{
« no previous file with comments | « no previous file | Source/bindings/scripts/code_generator_idl_reader.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698