Commit d5997868 authored by nbarth@chromium.org's avatar nbarth@chromium.org

IDL build: factor out interface_info actions into GYP templates

Followup to:
IDL build: factor out global constructors action into a GYP template
https://codereview.chromium.org/319933002/

R=haraken

Review URL: https://codereview.chromium.org/328643002

git-svn-id: svn://svn.chromium.org/blink/trunk@176091 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent ceea60e0
...@@ -54,40 +54,18 @@ ...@@ -54,40 +54,18 @@
################################################################################ ################################################################################
{ {
'target_name': 'interfaces_info_individual_core', 'target_name': 'interfaces_info_individual_core',
'type': 'none',
'dependencies': [ 'dependencies': [
'../../core/core_generated.gyp:generated_testing_idls', '../../core/core_generated.gyp:generated_testing_idls',
'core_global_constructors_idls', 'core_global_constructors_idls',
], ],
'actions': [{ 'variables': {
'action_name': 'compute_interfaces_info_individual_core', 'static_idl_files': '<(core_static_idl_files)',
'inputs': [ 'generated_idl_files': '<(core_generated_idl_files)',
'<(bindings_scripts_dir)/compute_interfaces_info_individual.py', 'component_dir': 'core',
'<(bindings_scripts_dir)/utilities.py', 'output_file':
'<(core_static_idl_files_list)',
'<@(core_static_idl_files)',
'<@(core_generated_idl_files)',
],
'outputs': [
'<(bindings_core_output_dir)/InterfacesInfoCoreIndividual.pickle',
],
'action': [
'python',
'<(bindings_scripts_dir)/compute_interfaces_info_individual.py',
'--component-dir',
'core',
'--idl-files-list',
'<(core_static_idl_files_list)',
'--interfaces-info-file',
'<(bindings_core_output_dir)/InterfacesInfoCoreIndividual.pickle', '<(bindings_core_output_dir)/InterfacesInfoCoreIndividual.pickle',
'--write-file-only-if-changed', },
'<(write_file_only_if_changed)', 'includes': ['../../bindings/scripts/interfaces_info_individual.gypi'],
'--',
# Generated files must be passed at command line
'<@(core_generated_idl_files)',
],
'message': 'Computing global information about individual IDL files',
}]
}, },
################################################################################ ################################################################################
], # targets ], # targets
......
...@@ -206,72 +206,36 @@ ...@@ -206,72 +206,36 @@
################################################################################ ################################################################################
{ {
'target_name': 'interfaces_info_individual_modules', 'target_name': 'interfaces_info_individual_modules',
'type': 'none',
'dependencies': [ 'dependencies': [
'modules_core_global_constructors_idls', 'modules_core_global_constructors_idls',
'modules_global_constructors_idls', 'modules_global_constructors_idls',
], ],
'actions': [{ 'variables': {
'action_name': 'compute_interfaces_info_individual_modules', 'static_idl_files': '<(modules_static_idl_files)',
'inputs': [ 'generated_idl_files': '<(modules_generated_idl_files)',
'<(bindings_scripts_dir)/compute_interfaces_info_individual.py', 'component_dir': 'modules',
'<(bindings_scripts_dir)/utilities.py', 'output_file':
'<(modules_static_idl_files_list)',
'<@(modules_static_idl_files)',
'<@(modules_generated_idl_files)',
],
'outputs': [
'<(bindings_modules_output_dir)/InterfacesInfoModulesIndividual.pickle',
],
'action': [
'python',
'<(bindings_scripts_dir)/compute_interfaces_info_individual.py',
'--component-dir',
'modules',
'--idl-files-list',
'<(modules_static_idl_files_list)',
'--interfaces-info-file',
'<(bindings_modules_output_dir)/InterfacesInfoModulesIndividual.pickle', '<(bindings_modules_output_dir)/InterfacesInfoModulesIndividual.pickle',
'--write-file-only-if-changed', },
'<(write_file_only_if_changed)', 'includes': ['../../bindings/scripts/interfaces_info_individual.gypi'],
'--',
# Generated files must be passed at command line
'<@(modules_generated_idl_files)',
],
'message': 'Computing global information about individual IDL files',
}]
}, },
################################################################################ ################################################################################
{ {
# GN version: //third_party/WebKit/Source/bindings/modules:interfaces_info # GN version: //third_party/WebKit/Source/bindings/modules:interfaces_info
'target_name': 'interfaces_info', 'target_name': 'interfaces_info',
'type': 'none',
'dependencies': [ 'dependencies': [
'../core/generated.gyp:interfaces_info_individual_core', '../core/generated.gyp:interfaces_info_individual_core',
'interfaces_info_individual_modules', 'interfaces_info_individual_modules',
], ],
'actions': [{ 'variables': {
'action_name': 'compute_interfaces_info_overall', 'input_files': [
'inputs': [
'<(bindings_scripts_dir)/compute_interfaces_info_overall.py',
'<(bindings_core_output_dir)/InterfacesInfoCoreIndividual.pickle', '<(bindings_core_output_dir)/InterfacesInfoCoreIndividual.pickle',
'<(bindings_modules_output_dir)/InterfacesInfoModulesIndividual.pickle', '<(bindings_modules_output_dir)/InterfacesInfoModulesIndividual.pickle',
], ],
'outputs': [ 'output_file':
'<(bindings_modules_output_dir)/InterfacesInfoModules.pickle',
],
'action': [
'python',
'<(bindings_scripts_dir)/compute_interfaces_info_overall.py',
'--write-file-only-if-changed',
'<(write_file_only_if_changed)',
'--',
'<(bindings_core_output_dir)/InterfacesInfoCoreIndividual.pickle',
'<(bindings_modules_output_dir)/InterfacesInfoModulesIndividual.pickle',
'<(bindings_modules_output_dir)/InterfacesInfoModules.pickle', '<(bindings_modules_output_dir)/InterfacesInfoModules.pickle',
], },
'message': 'Computing overall global information about IDL files', 'includes': ['../../bindings/scripts/interfaces_info_overall.gypi'],
}]
}, },
################################################################################ ################################################################################
], # targets ], # targets
......
# Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
#
# This file is meant to be included into a target to provide an action
# to compute information about individual interfaces defined in a component.
#
# To use this, create a gyp target with the following form:
# {
# 'target_name': 'interfaces_info_individual_component',
# 'dependencies': [
# 'generated_idls_target',
# ],
# 'variables': {
# 'static_idl_files': '<(component_static_idl_files)',
# 'generated_idl_files': '<(component_generated_idl_files)',
# 'component_dir': 'component',
# 'output_file':
# '<(bindings_core_output_dir)/InterfacesInfoComponentIndividual.pickle',
# },
# 'includes': ['path/to/this/gypi/file'],
# },
#
# Required variables:
# static_idl_files - All static .idl files for the component, including
# dependencies and testing.
# generated_idl_files - All generated .idl files for the component.
# (Must be separate from static because build dir not know at gyp time.)
# component_dir - Relative directory for component, e.g., 'core'.
# output_file - Pickle file containing output.
#
# Design document: http://www.chromium.org/developers/design-documents/idl-build
{
'type': 'none',
'actions': [{
'action_name': 'compute_<(_target_name)',
'message': 'Computing global information about individual IDL files for <(_target_name)',
'variables': {
'static_idl_files_list':
'<|(<(_target_name)_static_idl_files_list.tmp <@(static_idl_files))',
},
'inputs': [
'<(bindings_scripts_dir)/compute_interfaces_info_individual.py',
'<(bindings_scripts_dir)/utilities.py',
'<(static_idl_files_list)',
'<@(static_idl_files)',
'<@(generated_idl_files)',
],
'outputs': [
'<(output_file)',
],
'action': [
'python',
'<(bindings_scripts_dir)/compute_interfaces_info_individual.py',
'--component-dir',
'<(component_dir)',
'--idl-files-list',
'<(static_idl_files_list)',
'--interfaces-info-file',
'<(output_file)',
'--write-file-only-if-changed',
'<(write_file_only_if_changed)',
'--',
# Generated files must be passed at command line
'<@(generated_idl_files)',
],
}],
}
# Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
#
# This file is meant to be included into a target to provide an action
# to compute overall information about interfaces defined in a component.
#
# To use this, create a gyp target with the following form:
# {
# 'target_name': 'interfaces_info_component',
# 'dependencies': [
# 'interfaces_info_individual_base_component',
# 'interfaces_info_individual_component',
# ],
# 'variables': {
# 'input_files': [
# '<(bindings_base_component_output_dir)/InterfacesInfoBaseComponentIndividual.pickle',
# '<(bindings_component_output_dir)/InterfacesInfoComponentIndividual.pickle',
# ],
# 'output_file':
# '<(bindings_component_output_dir)/InterfacesInfoComponent.pickle',
# },
# 'includes': ['path/to/this/gypi/file'],
# },
#
# Required variables:
# input_files - Pickle files containing info about individual interfaces, both
# current component and any base components.
# output_file - Pickle file containing output (overall info).
#
# Design document: http://www.chromium.org/developers/design-documents/idl-build
{
'type': 'none',
'actions': [{
'action_name': 'compute_<(_target_name)',
'message': 'Computing overall global information about IDL files for <(_target_name)',
'inputs': [
'<(bindings_scripts_dir)/compute_interfaces_info_overall.py',
'<@(input_files)',
],
'outputs': [
'<(output_file)',
],
'action': [
'python',
'<(bindings_scripts_dir)/compute_interfaces_info_overall.py',
'--write-file-only-if-changed',
'<(write_file_only_if_changed)',
'--',
'<@(input_files)',
'<(output_file)',
],
}],
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment