• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2016 the V8 project authors. All rights reserved.
2# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
5{
6  'variables': {
7    'inspector_protocol_path': '<(V8_ROOT)/third_party/inspector_protocol',
8    'inspector_protocol_files': [
9      '<(inspector_protocol_path)/lib/base_string_adapter_cc.template',
10      '<(inspector_protocol_path)/lib/base_string_adapter_h.template',
11      '<(inspector_protocol_path)/lib/Forward_h.template',
12      '<(inspector_protocol_path)/lib/Object_cpp.template',
13      '<(inspector_protocol_path)/lib/Object_h.template',
14      '<(inspector_protocol_path)/lib/Protocol_cpp.template',
15      '<(inspector_protocol_path)/lib/ValueConversions_h.template',
16      '<(inspector_protocol_path)/lib/Values_cpp.template',
17      '<(inspector_protocol_path)/lib/Values_h.template',
18      '<(inspector_protocol_path)/templates/Exported_h.template',
19      '<(inspector_protocol_path)/templates/Imported_h.template',
20      '<(inspector_protocol_path)/templates/TypeBuilder_cpp.template',
21      '<(inspector_protocol_path)/templates/TypeBuilder_h.template',
22      '<(inspector_protocol_path)/code_generator.py',
23    ],
24    'inspector_path': '<(V8_ROOT)/src/inspector',
25    'inspector_generated_output_root': '<(SHARED_INTERMEDIATE_DIR)/inspector-generated-output-root',
26    'inspector_generated_sources': [
27      '<(inspector_generated_output_root)/src/inspector/protocol/Forward.h',
28      '<(inspector_generated_output_root)/src/inspector/protocol/Protocol.cpp',
29      '<(inspector_generated_output_root)/src/inspector/protocol/Protocol.h',
30      '<(inspector_generated_output_root)/src/inspector/protocol/Console.cpp',
31      '<(inspector_generated_output_root)/src/inspector/protocol/Console.h',
32      '<(inspector_generated_output_root)/src/inspector/protocol/Debugger.cpp',
33      '<(inspector_generated_output_root)/src/inspector/protocol/Debugger.h',
34      '<(inspector_generated_output_root)/src/inspector/protocol/HeapProfiler.cpp',
35      '<(inspector_generated_output_root)/src/inspector/protocol/HeapProfiler.h',
36      '<(inspector_generated_output_root)/src/inspector/protocol/Profiler.cpp',
37      '<(inspector_generated_output_root)/src/inspector/protocol/Profiler.h',
38      '<(inspector_generated_output_root)/src/inspector/protocol/Runtime.cpp',
39      '<(inspector_generated_output_root)/src/inspector/protocol/Runtime.h',
40      '<(inspector_generated_output_root)/src/inspector/protocol/Schema.cpp',
41      '<(inspector_generated_output_root)/src/inspector/protocol/Schema.h',
42      '<(inspector_generated_output_root)/include/inspector/Debugger.h',
43      '<(inspector_generated_output_root)/include/inspector/Runtime.h',
44      '<(inspector_generated_output_root)/include/inspector/Schema.h',
45    ],
46
47    'inspector_all_sources': [
48      '<(V8_ROOT)/include/v8-inspector.h',
49      '<(V8_ROOT)/include/v8-inspector-protocol.h',
50      '<(V8_ROOT)/src/inspector/custom-preview.cc',
51      '<(V8_ROOT)/src/inspector/custom-preview.h',
52      '<(V8_ROOT)/src/inspector/injected-script.cc',
53      '<(V8_ROOT)/src/inspector/injected-script.h',
54      '<(V8_ROOT)/src/inspector/inspected-context.cc',
55      '<(V8_ROOT)/src/inspector/inspected-context.h',
56      '<(V8_ROOT)/src/inspector/remote-object-id.cc',
57      '<(V8_ROOT)/src/inspector/remote-object-id.h',
58      '<(V8_ROOT)/src/inspector/search-util.cc',
59      '<(V8_ROOT)/src/inspector/search-util.h',
60      '<(V8_ROOT)/src/inspector/string-16.cc',
61      '<(V8_ROOT)/src/inspector/string-16.h',
62      '<(V8_ROOT)/src/inspector/string-util.cc',
63      '<(V8_ROOT)/src/inspector/string-util.h',
64      '<(V8_ROOT)/src/inspector/test-interface.cc',
65      '<(V8_ROOT)/src/inspector/test-interface.h',
66      '<(V8_ROOT)/src/inspector/v8-console.cc',
67      '<(V8_ROOT)/src/inspector/v8-console.h',
68      '<(V8_ROOT)/src/inspector/v8-console-agent-impl.cc',
69      '<(V8_ROOT)/src/inspector/v8-console-agent-impl.h',
70      '<(V8_ROOT)/src/inspector/v8-console-message.cc',
71      '<(V8_ROOT)/src/inspector/v8-console-message.h',
72      '<(V8_ROOT)/src/inspector/v8-debugger.cc',
73      '<(V8_ROOT)/src/inspector/v8-debugger.h',
74      '<(V8_ROOT)/src/inspector/v8-debugger-agent-impl.cc',
75      '<(V8_ROOT)/src/inspector/v8-debugger-agent-impl.h',
76      '<(V8_ROOT)/src/inspector/v8-debugger-script.cc',
77      '<(V8_ROOT)/src/inspector/v8-debugger-script.h',
78      '<(V8_ROOT)/src/inspector/v8-heap-profiler-agent-impl.cc',
79      '<(V8_ROOT)/src/inspector/v8-heap-profiler-agent-impl.h',
80      '<(V8_ROOT)/src/inspector/v8-inspector-impl.cc',
81      '<(V8_ROOT)/src/inspector/v8-inspector-impl.h',
82      '<(V8_ROOT)/src/inspector/v8-inspector-session-impl.cc',
83      '<(V8_ROOT)/src/inspector/v8-inspector-session-impl.h',
84      '<(V8_ROOT)/src/inspector/v8-profiler-agent-impl.cc',
85      '<(V8_ROOT)/src/inspector/v8-profiler-agent-impl.h',
86      '<(V8_ROOT)/src/inspector/v8-regex.cc',
87      '<(V8_ROOT)/src/inspector/v8-regex.h',
88      '<(V8_ROOT)/src/inspector/v8-runtime-agent-impl.cc',
89      '<(V8_ROOT)/src/inspector/v8-runtime-agent-impl.h',
90      '<(V8_ROOT)/src/inspector/v8-schema-agent-impl.cc',
91      '<(V8_ROOT)/src/inspector/v8-schema-agent-impl.h',
92      '<(V8_ROOT)/src/inspector/v8-stack-trace-impl.cc',
93      '<(V8_ROOT)/src/inspector/v8-stack-trace-impl.h',
94      '<(V8_ROOT)/src/inspector/v8-value-utils.cc',
95      '<(V8_ROOT)/src/inspector/v8-value-utils.h',
96      '<(V8_ROOT)/src/inspector/value-mirror.cc',
97      '<(V8_ROOT)/src/inspector/value-mirror.h',
98      # Flat merge `third_party/inspector_protocol:inspector_string_conversions`
99      '<(inspector_path)/v8-string-conversions.cc',
100      '<(inspector_path)/v8-string-conversions.h',
101      # Flat merge `third_party/inspector_protocal:crdtp_platform`
102      '<(inspector_protocol_path)/crdtp/json_platform.h',
103      '<(inspector_protocol_path)/crdtp/json_platform_v8.cc',
104      # Flat merge `third_party/inspector_protocol:crdtp`
105      '<(inspector_protocol_path)/crdtp/cbor.cc',
106      '<(inspector_protocol_path)/crdtp/cbor.h',
107      '<(inspector_protocol_path)/crdtp/dispatch.cc',
108      '<(inspector_protocol_path)/crdtp/dispatch.h',
109      '<(inspector_protocol_path)/crdtp/error_support.cc',
110      '<(inspector_protocol_path)/crdtp/error_support.h',
111      '<(inspector_protocol_path)/crdtp/export.h',
112      '<(inspector_protocol_path)/crdtp/find_by_first.h',
113      '<(inspector_protocol_path)/crdtp/glue.h',
114      '<(inspector_protocol_path)/crdtp/json.cc',
115      '<(inspector_protocol_path)/crdtp/json.h',
116      '<(inspector_protocol_path)/crdtp/parser_handler.h',
117      '<(inspector_protocol_path)/crdtp/serializable.cc',
118      '<(inspector_protocol_path)/crdtp/serializable.h',
119      '<(inspector_protocol_path)/crdtp/serializer_traits.h',
120      '<(inspector_protocol_path)/crdtp/span.cc',
121      '<(inspector_protocol_path)/crdtp/span.h',
122      '<(inspector_protocol_path)/crdtp/status.cc',
123      '<(inspector_protocol_path)/crdtp/status.h',
124    ],
125    'v8_inspector_js_protocol': '<(V8_ROOT)/include/js_protocol.pdl',
126  },
127  'include_dirs': [
128    '<(inspector_generated_output_root)',
129    '<(inspector_protocol_path)',
130  ],
131  'actions': [
132    {
133      'action_name': 'protocol_compatibility',
134      'inputs': [
135        '<(v8_inspector_js_protocol)',
136      ],
137      'outputs': [
138        '<@(inspector_generated_output_root)/src/js_protocol.stamp',
139      ],
140      'action': [
141        'python',
142        '<(inspector_protocol_path)/check_protocol_compatibility.py',
143        '--stamp', '<@(_outputs)',
144        '<@(_inputs)',
145      ],
146      'message': 'Checking inspector protocol compatibility',
147    },
148    {
149      'action_name': 'protocol_generated_sources',
150      'inputs': [
151        '<(v8_inspector_js_protocol)',
152        '<(inspector_path)/inspector_protocol_config.json',
153        '<@(inspector_protocol_files)',
154      ],
155      'outputs': [
156        '<@(inspector_generated_sources)',
157      ],
158      'process_outputs_as_sources': 1,
159      'action': [
160        'python',
161        '<(inspector_protocol_path)/code_generator.py',
162        '--jinja_dir', '<(V8_ROOT)/third_party',
163        '--output_base', '<(inspector_generated_output_root)/src/inspector',
164        '--config', '<(inspector_path)/inspector_protocol_config.json',
165        '--inspector_protocol_dir', '<(inspector_protocol_path)',
166      ],
167      'message': 'Generating inspector protocol sources from protocol json',
168    },
169  ],
170}
171