1 | # Copyright (C) 2006-2021 Apple Inc. All rights reserved.
|
---|
2 | #
|
---|
3 | # Redistribution and use in source and binary forms, with or without
|
---|
4 | # modification, are permitted provided that the following conditions
|
---|
5 | # are met:
|
---|
6 | #
|
---|
7 | # 1. Redistributions of source code must retain the above copyright
|
---|
8 | # notice, this list of conditions and the following disclaimer.
|
---|
9 | # 2. Redistributions in binary form must reproduce the above copyright
|
---|
10 | # notice, this list of conditions and the following disclaimer in the
|
---|
11 | # documentation and/or other materials provided with the distribution.
|
---|
12 | # 3. Neither the name of Apple Inc. ("Apple") nor the names of
|
---|
13 | # its contributors may be used to endorse or promote products derived
|
---|
14 | # from this software without specific prior written permission.
|
---|
15 | #
|
---|
16 | # THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
|
---|
17 | # EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
---|
18 | # WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
---|
19 | # DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY
|
---|
20 | # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
---|
21 | # (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
|
---|
22 | # LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
---|
23 | # ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
---|
24 | # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
---|
25 | # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
---|
26 |
|
---|
27 | # Workaround for rdar://84212106.
|
---|
28 | find_tool = $(realpath $(shell xcrun --sdk $(SDK_NAME) -f $(1)))
|
---|
29 |
|
---|
30 | PYTHON := $(call find_tool,python3)
|
---|
31 | PERL := perl
|
---|
32 | RUBY := ruby
|
---|
33 | DELETE := rm -f
|
---|
34 |
|
---|
35 | ifneq ($(SDKROOT),)
|
---|
36 | SDK_FLAGS = -isysroot $(SDKROOT)
|
---|
37 | endif
|
---|
38 |
|
---|
39 | ifeq ($(USE_LLVM_TARGET_TRIPLES_FOR_CLANG),YES)
|
---|
40 | WK_CURRENT_ARCH = $(word 1, $(ARCHS))
|
---|
41 | TARGET_TRIPLE_FLAGS = -target $(WK_CURRENT_ARCH)-$(LLVM_TARGET_TRIPLE_VENDOR)-$(LLVM_TARGET_TRIPLE_OS_VERSION)$(LLVM_TARGET_TRIPLE_SUFFIX)
|
---|
42 | endif
|
---|
43 |
|
---|
44 | FRAMEWORK_FLAGS := $(shell echo $(BUILT_PRODUCTS_DIR) $(FRAMEWORK_SEARCH_PATHS) $(SYSTEM_FRAMEWORK_SEARCH_PATHS) | $(PERL) -e 'print "-F " . join(" -F ", split(" ", <>));')
|
---|
45 | HEADER_FLAGS := $(shell echo $(BUILT_PRODUCTS_DIR) $(HEADER_SEARCH_PATHS) $(SYSTEM_HEADER_SEARCH_PATHS) | $(PERL) -e 'print "-I" . join(" -I", split(" ", <>));')
|
---|
46 |
|
---|
47 | platform_h_compiler_command = $(CC) -std=c++2a -x c++ $(1) $(SDK_FLAGS) $(TARGET_TRIPLE_FLAGS) $(FRAMEWORK_FLAGS) $(HEADER_FLAGS) -include "wtf/Platform.h" /dev/null
|
---|
48 |
|
---|
49 | FEATURE_AND_PLATFORM_DEFINES := $(shell $(call platform_h_compiler_command,-E -P -dM) | $(PERL) -ne "print if s/\#define ((HAVE_|USE_|ENABLE_|WTF_PLATFORM_)\w+) 1/\1/")
|
---|
50 |
|
---|
51 | PLATFORM_HEADER_DIR := $(realpath $(BUILT_PRODUCTS_DIR)/usr/local/include)
|
---|
52 | PLATFORM_HEADER_DEPENDENCIES := $(filter $(PLATFORM_HEADER_DIR)/%,$(realpath $(shell $(call platform_h_compiler_command,-M) | $(PERL) -e "local \$$/; my (\$$target, \$$deps) = split(/:/, <>); print split(/\\\\/, \$$deps);")))
|
---|
53 | FEATURE_AND_PLATFORM_DEFINE_DEPENDENCIES = DerivedSources.make $(PLATFORM_HEADER_DEPENDENCIES)
|
---|
54 |
|
---|
55 | # --------
|
---|
56 |
|
---|
57 | VPATH = \
|
---|
58 | $(JavaScriptCore) \
|
---|
59 | $(JavaScriptCore)/parser \
|
---|
60 | $(JavaScriptCore)/runtime \
|
---|
61 | $(JavaScriptCore)/interpreter \
|
---|
62 | $(JavaScriptCore)/jit \
|
---|
63 | $(JavaScriptCore)/builtins \
|
---|
64 | $(JavaScriptCore)/wasm/js \
|
---|
65 | #
|
---|
66 |
|
---|
67 | JavaScriptCore_SCRIPTS_DIR = $(JavaScriptCore)/Scripts
|
---|
68 |
|
---|
69 | .PHONY : all
|
---|
70 | all : \
|
---|
71 | InjectedScriptSource.h \
|
---|
72 | JSCBuiltins.h \
|
---|
73 | Lexer.lut.h \
|
---|
74 | KeywordLookup.h \
|
---|
75 | RegExpJitTables.h \
|
---|
76 | UnicodePatternTables.h \
|
---|
77 | yarr/YarrCanonicalizeUnicode.cpp \
|
---|
78 | WasmOps.h \
|
---|
79 | WasmB3IRGeneratorInlines.h \
|
---|
80 | #
|
---|
81 |
|
---|
82 | # JavaScript builtins.
|
---|
83 |
|
---|
84 | BUILTINS_GENERATOR_SCRIPTS = \
|
---|
85 | $(JavaScriptCore_SCRIPTS_DIR)/wkbuiltins/__init__.py \
|
---|
86 | $(JavaScriptCore_SCRIPTS_DIR)/wkbuiltins/wkbuiltins.py \
|
---|
87 | $(JavaScriptCore_SCRIPTS_DIR)/wkbuiltins/builtins_generator.py \
|
---|
88 | $(JavaScriptCore_SCRIPTS_DIR)/wkbuiltins/builtins_model.py \
|
---|
89 | $(JavaScriptCore_SCRIPTS_DIR)/wkbuiltins/builtins_templates.py \
|
---|
90 | $(JavaScriptCore_SCRIPTS_DIR)/wkbuiltins/builtins_generate_combined_header.py \
|
---|
91 | $(JavaScriptCore_SCRIPTS_DIR)/wkbuiltins/builtins_generate_combined_implementation.py \
|
---|
92 | $(JavaScriptCore_SCRIPTS_DIR)/wkbuiltins/builtins_generate_separate_header.py \
|
---|
93 | $(JavaScriptCore_SCRIPTS_DIR)/wkbuiltins/builtins_generate_separate_implementation.py \
|
---|
94 | ${JavaScriptCore_SCRIPTS_DIR}/wkbuiltins/builtins_generate_wrapper_header.py \
|
---|
95 | ${JavaScriptCore_SCRIPTS_DIR}/wkbuiltins/builtins_generate_wrapper_implementation.py \
|
---|
96 | ${JavaScriptCore_SCRIPTS_DIR}/wkbuiltins/builtins_generate_internals_wrapper_header.py \
|
---|
97 | ${JavaScriptCore_SCRIPTS_DIR}/wkbuiltins/builtins_generate_internals_wrapper_implementation.py \
|
---|
98 | $(JavaScriptCore_SCRIPTS_DIR)/generate-js-builtins.py \
|
---|
99 | $(JavaScriptCore_SCRIPTS_DIR)/lazywriter.py \
|
---|
100 | #
|
---|
101 |
|
---|
102 | JavaScriptCore_BUILTINS_SOURCES = \
|
---|
103 | $(JavaScriptCore)/builtins/AsyncFromSyncIteratorPrototype.js \
|
---|
104 | $(JavaScriptCore)/builtins/ArrayConstructor.js \
|
---|
105 | $(JavaScriptCore)/builtins/ArrayIteratorPrototype.js \
|
---|
106 | $(JavaScriptCore)/builtins/ArrayPrototype.js \
|
---|
107 | $(JavaScriptCore)/builtins/AsyncIteratorPrototype.js \
|
---|
108 | $(JavaScriptCore)/builtins/AsyncFunctionPrototype.js \
|
---|
109 | $(JavaScriptCore)/builtins/AsyncGeneratorPrototype.js \
|
---|
110 | $(JavaScriptCore)/builtins/DatePrototype.js \
|
---|
111 | $(JavaScriptCore)/builtins/FunctionPrototype.js \
|
---|
112 | $(JavaScriptCore)/builtins/GeneratorPrototype.js \
|
---|
113 | $(JavaScriptCore)/builtins/GlobalObject.js \
|
---|
114 | $(JavaScriptCore)/builtins/GlobalOperations.js \
|
---|
115 | $(JavaScriptCore)/builtins/InternalPromiseConstructor.js \
|
---|
116 | $(JavaScriptCore)/builtins/IteratorHelpers.js \
|
---|
117 | $(JavaScriptCore)/builtins/IteratorPrototype.js \
|
---|
118 | $(JavaScriptCore)/builtins/MapIteratorPrototype.js \
|
---|
119 | $(JavaScriptCore)/builtins/MapPrototype.js \
|
---|
120 | $(JavaScriptCore)/builtins/ModuleLoader.js \
|
---|
121 | $(JavaScriptCore)/builtins/NumberConstructor.js \
|
---|
122 | $(JavaScriptCore)/builtins/ObjectConstructor.js \
|
---|
123 | $(JavaScriptCore)/builtins/PromiseConstructor.js \
|
---|
124 | $(JavaScriptCore)/builtins/PromiseOperations.js \
|
---|
125 | $(JavaScriptCore)/builtins/PromisePrototype.js \
|
---|
126 | $(JavaScriptCore)/builtins/ReflectObject.js \
|
---|
127 | $(JavaScriptCore)/builtins/RegExpPrototype.js \
|
---|
128 | ${JavaScriptCore}/builtins/RegExpStringIteratorPrototype.js \
|
---|
129 | $(JavaScriptCore)/builtins/SetIteratorPrototype.js \
|
---|
130 | $(JavaScriptCore)/builtins/SetPrototype.js \
|
---|
131 | $(JavaScriptCore)/builtins/ShadowRealmPrototype.js \
|
---|
132 | $(JavaScriptCore)/builtins/StringConstructor.js \
|
---|
133 | $(JavaScriptCore)/builtins/StringIteratorPrototype.js \
|
---|
134 | $(JavaScriptCore)/builtins/StringPrototype.js \
|
---|
135 | $(JavaScriptCore)/builtins/TypedArrayConstructor.js \
|
---|
136 | $(JavaScriptCore)/builtins/TypedArrayPrototype.js \
|
---|
137 | $(JavaScriptCore)/builtins/WebAssembly.js \
|
---|
138 | #
|
---|
139 |
|
---|
140 | # The combined output file depends on the contents of builtins and generator scripts, so
|
---|
141 | # adding, modifying, or removing builtins or scripts will trigger regeneration of files.
|
---|
142 |
|
---|
143 | JavaScriptCore_BUILTINS_DEPENDENCIES_LIST : $(JavaScriptCore_SCRIPTS_DIR)/UpdateContents.py DerivedSources.make
|
---|
144 | $(PYTHON) $(JavaScriptCore_SCRIPTS_DIR)/UpdateContents.py '$(JavaScriptCore_BUILTINS_SOURCES) $(BUILTINS_GENERATOR_SCRIPTS)' $@
|
---|
145 |
|
---|
146 | JSCBuiltins.h: $(BUILTINS_GENERATOR_SCRIPTS) $(JavaScriptCore_BUILTINS_SOURCES) JavaScriptCore_BUILTINS_DEPENDENCIES_LIST
|
---|
147 | $(PYTHON) $(JavaScriptCore_SCRIPTS_DIR)/generate-js-builtins.py --combined --output-directory . --framework JavaScriptCore $(JavaScriptCore_BUILTINS_SOURCES)
|
---|
148 |
|
---|
149 | # Perfect hash lookup tables for JavaScript classes.
|
---|
150 |
|
---|
151 | OBJECT_LUT_HEADERS = \
|
---|
152 | AsyncFromSyncIteratorPrototype.lut.h \
|
---|
153 | ArrayConstructor.lut.h \
|
---|
154 | AsyncGeneratorPrototype.lut.h \
|
---|
155 | BigIntConstructor.lut.h \
|
---|
156 | BigIntPrototype.lut.h \
|
---|
157 | BooleanPrototype.lut.h \
|
---|
158 | DateConstructor.lut.h \
|
---|
159 | DatePrototype.lut.h \
|
---|
160 | ErrorPrototype.lut.h \
|
---|
161 | GeneratorPrototype.lut.h \
|
---|
162 | IntlCollatorConstructor.lut.h \
|
---|
163 | IntlCollatorPrototype.lut.h \
|
---|
164 | IntlDateTimeFormatConstructor.lut.h \
|
---|
165 | IntlDateTimeFormatPrototype.lut.h \
|
---|
166 | IntlDisplayNamesConstructor.lut.h \
|
---|
167 | IntlDisplayNamesPrototype.lut.h \
|
---|
168 | IntlListFormatConstructor.lut.h \
|
---|
169 | IntlListFormatPrototype.lut.h \
|
---|
170 | IntlLocalePrototype.lut.h \
|
---|
171 | IntlNumberFormatConstructor.lut.h \
|
---|
172 | IntlNumberFormatPrototype.lut.h \
|
---|
173 | IntlObject.lut.h \
|
---|
174 | IntlPluralRulesConstructor.lut.h \
|
---|
175 | IntlPluralRulesPrototype.lut.h \
|
---|
176 | IntlRelativeTimeFormatConstructor.lut.h \
|
---|
177 | IntlRelativeTimeFormatPrototype.lut.h \
|
---|
178 | IntlSegmentIteratorPrototype.lut.h \
|
---|
179 | IntlSegmenterConstructor.lut.h \
|
---|
180 | IntlSegmenterPrototype.lut.h \
|
---|
181 | IntlSegmentsPrototype.lut.h \
|
---|
182 | JSDataViewPrototype.lut.h \
|
---|
183 | JSGlobalObject.lut.h \
|
---|
184 | JSInternalPromiseConstructor.lut.h \
|
---|
185 | JSModuleLoader.lut.h \
|
---|
186 | JSONObject.lut.h \
|
---|
187 | JSPromiseConstructor.lut.h \
|
---|
188 | JSPromisePrototype.lut.h \
|
---|
189 | JSWebAssembly.lut.h \
|
---|
190 | MapPrototype.lut.h \
|
---|
191 | NumberConstructor.lut.h \
|
---|
192 | NumberPrototype.lut.h \
|
---|
193 | ObjectConstructor.lut.h \
|
---|
194 | ReflectObject.lut.h \
|
---|
195 | RegExpConstructor.lut.h \
|
---|
196 | SetPrototype.lut.h \
|
---|
197 | ShadowRealmPrototype.lut.h \
|
---|
198 | StringConstructor.lut.h \
|
---|
199 | StringPrototype.lut.h \
|
---|
200 | SymbolConstructor.lut.h \
|
---|
201 | SymbolPrototype.lut.h \
|
---|
202 | TemporalCalendarConstructor.lut.h \
|
---|
203 | TemporalCalendarPrototype.lut.h \
|
---|
204 | TemporalDurationConstructor.lut.h \
|
---|
205 | TemporalDurationPrototype.lut.h \
|
---|
206 | TemporalInstantConstructor.lut.h \
|
---|
207 | TemporalInstantPrototype.lut.h \
|
---|
208 | TemporalNow.lut.h \
|
---|
209 | TemporalObject.lut.h \
|
---|
210 | TemporalPlainTimeConstructor.lut.h \
|
---|
211 | TemporalPlainTimePrototype.lut.h \
|
---|
212 | TemporalTimeZoneConstructor.lut.h \
|
---|
213 | TemporalTimeZonePrototype.lut.h \
|
---|
214 | WebAssemblyCompileErrorConstructor.lut.h \
|
---|
215 | WebAssemblyCompileErrorPrototype.lut.h \
|
---|
216 | WebAssemblyExceptionConstructor.lut.h \
|
---|
217 | WebAssemblyExceptionPrototype.lut.h \
|
---|
218 | WebAssemblyGlobalConstructor.lut.h \
|
---|
219 | WebAssemblyGlobalPrototype.lut.h \
|
---|
220 | WebAssemblyInstanceConstructor.lut.h \
|
---|
221 | WebAssemblyInstancePrototype.lut.h \
|
---|
222 | WebAssemblyLinkErrorConstructor.lut.h \
|
---|
223 | WebAssemblyLinkErrorPrototype.lut.h \
|
---|
224 | WebAssemblyMemoryConstructor.lut.h \
|
---|
225 | WebAssemblyMemoryPrototype.lut.h \
|
---|
226 | WebAssemblyModuleConstructor.lut.h \
|
---|
227 | WebAssemblyModulePrototype.lut.h \
|
---|
228 | WebAssemblyRuntimeErrorConstructor.lut.h \
|
---|
229 | WebAssemblyRuntimeErrorPrototype.lut.h \
|
---|
230 | WebAssemblyTableConstructor.lut.h \
|
---|
231 | WebAssemblyTablePrototype.lut.h \
|
---|
232 | WebAssemblyTagConstructor.lut.h \
|
---|
233 | WebAssemblyTagPrototype.lut.h \
|
---|
234 | #
|
---|
235 |
|
---|
236 | $(OBJECT_LUT_HEADERS): %.lut.h : %.cpp $(JavaScriptCore)/create_hash_table
|
---|
237 | $(PERL) $(JavaScriptCore)/create_hash_table $< > $@
|
---|
238 |
|
---|
239 | Lexer.lut.h: Keywords.table $(JavaScriptCore)/create_hash_table
|
---|
240 | $(PERL) $(JavaScriptCore)/create_hash_table $< > $@
|
---|
241 |
|
---|
242 | # character tables for Yarr
|
---|
243 |
|
---|
244 | RegExpJitTables.h: yarr/create_regex_tables
|
---|
245 | $(PYTHON) $^ > $@
|
---|
246 |
|
---|
247 | KeywordLookup.h: KeywordLookupGenerator.py Keywords.table
|
---|
248 | $(PYTHON) $^ > $@
|
---|
249 |
|
---|
250 | # Bytecode files
|
---|
251 |
|
---|
252 | BYTECODE_FILES = \
|
---|
253 | Bytecodes.h \
|
---|
254 | BytecodeIndices.h \
|
---|
255 | BytecodeStructs.h \
|
---|
256 | InitBytecodes.asm \
|
---|
257 | WasmLLIntGeneratorInlines.h \
|
---|
258 | InitWasm.asm \
|
---|
259 | BytecodeDumperGenerated.cpp \
|
---|
260 | #
|
---|
261 | BYTECODE_FILES_PATTERNS = $(subst .,%,$(BYTECODE_FILES))
|
---|
262 |
|
---|
263 | all : $(BYTECODE_FILES)
|
---|
264 |
|
---|
265 | $(BYTECODE_FILES_PATTERNS): $(wildcard $(JavaScriptCore)/generator/*.rb) $(JavaScriptCore)/bytecode/BytecodeList.rb $(JavaScriptCore)/wasm/wasm.json
|
---|
266 | $(RUBY) $(JavaScriptCore)/generator/main.rb $(JavaScriptCore)/bytecode/BytecodeList.rb \
|
---|
267 | --bytecode_structs_h BytecodeStructs.h \
|
---|
268 | --init_bytecodes_asm InitBytecodes.asm \
|
---|
269 | --bytecodes_h Bytecodes.h \
|
---|
270 | --bytecode_indices_h BytecodeIndices.h \
|
---|
271 | --wasm_json $(JavaScriptCore)/wasm/wasm.json \
|
---|
272 | --wasm_llint_generator_h WasmLLIntGeneratorInlines.h \
|
---|
273 | --init_wasm_llint InitWasm.asm \
|
---|
274 | --bytecode_dumper BytecodeDumperGenerated.cpp \
|
---|
275 |
|
---|
276 | # Inspector interfaces
|
---|
277 |
|
---|
278 | INSPECTOR_DOMAINS := \
|
---|
279 | $(JavaScriptCore)/inspector/protocol/Animation.json \
|
---|
280 | $(JavaScriptCore)/inspector/protocol/ApplicationCache.json \
|
---|
281 | $(JavaScriptCore)/inspector/protocol/Audit.json \
|
---|
282 | $(JavaScriptCore)/inspector/protocol/Browser.json \
|
---|
283 | $(JavaScriptCore)/inspector/protocol/CPUProfiler.json \
|
---|
284 | $(JavaScriptCore)/inspector/protocol/CSS.json \
|
---|
285 | $(JavaScriptCore)/inspector/protocol/Canvas.json \
|
---|
286 | $(JavaScriptCore)/inspector/protocol/Console.json \
|
---|
287 | $(JavaScriptCore)/inspector/protocol/DOM.json \
|
---|
288 | $(JavaScriptCore)/inspector/protocol/DOMDebugger.json \
|
---|
289 | $(JavaScriptCore)/inspector/protocol/DOMStorage.json \
|
---|
290 | $(JavaScriptCore)/inspector/protocol/Database.json \
|
---|
291 | $(JavaScriptCore)/inspector/protocol/Debugger.json \
|
---|
292 | $(JavaScriptCore)/inspector/protocol/GenericTypes.json \
|
---|
293 | $(JavaScriptCore)/inspector/protocol/Heap.json \
|
---|
294 | $(JavaScriptCore)/inspector/protocol/IndexedDB.json \
|
---|
295 | $(JavaScriptCore)/inspector/protocol/Inspector.json \
|
---|
296 | $(JavaScriptCore)/inspector/protocol/LayerTree.json \
|
---|
297 | $(JavaScriptCore)/inspector/protocol/Memory.json \
|
---|
298 | $(JavaScriptCore)/inspector/protocol/Network.json \
|
---|
299 | $(JavaScriptCore)/inspector/protocol/Page.json \
|
---|
300 | $(JavaScriptCore)/inspector/protocol/Recording.json \
|
---|
301 | $(JavaScriptCore)/inspector/protocol/Runtime.json \
|
---|
302 | $(JavaScriptCore)/inspector/protocol/ScriptProfiler.json \
|
---|
303 | $(JavaScriptCore)/inspector/protocol/Security.json \
|
---|
304 | $(JavaScriptCore)/inspector/protocol/ServiceWorker.json \
|
---|
305 | $(JavaScriptCore)/inspector/protocol/Target.json \
|
---|
306 | $(JavaScriptCore)/inspector/protocol/Timeline.json \
|
---|
307 | $(JavaScriptCore)/inspector/protocol/Worker.json \
|
---|
308 | #
|
---|
309 |
|
---|
310 | INSPECTOR_GENERATOR_SCRIPTS = \
|
---|
311 | $(JavaScriptCore)/inspector/scripts/codegen/__init__.py \
|
---|
312 | $(JavaScriptCore)/inspector/scripts/codegen/cpp_generator_templates.py \
|
---|
313 | $(JavaScriptCore)/inspector/scripts/codegen/cpp_generator.py \
|
---|
314 | $(JavaScriptCore)/inspector/scripts/codegen/generate_cpp_backend_dispatcher_header.py \
|
---|
315 | $(JavaScriptCore)/inspector/scripts/codegen/generate_cpp_backend_dispatcher_implementation.py \
|
---|
316 | $(JavaScriptCore)/inspector/scripts/codegen/generate_cpp_frontend_dispatcher_header.py \
|
---|
317 | $(JavaScriptCore)/inspector/scripts/codegen/generate_cpp_frontend_dispatcher_implementation.py \
|
---|
318 | $(JavaScriptCore)/inspector/scripts/codegen/generate_cpp_protocol_types_header.py \
|
---|
319 | $(JavaScriptCore)/inspector/scripts/codegen/generate_cpp_protocol_types_implementation.py \
|
---|
320 | $(JavaScriptCore)/inspector/scripts/codegen/generate_js_backend_commands.py \
|
---|
321 | $(JavaScriptCore)/inspector/scripts/codegen/generator_templates.py \
|
---|
322 | $(JavaScriptCore)/inspector/scripts/codegen/generator.py \
|
---|
323 | $(JavaScriptCore)/inspector/scripts/codegen/models.py \
|
---|
324 | $(JavaScriptCore)/inspector/scripts/codegen/preprocess.pl \
|
---|
325 | $(JavaScriptCore)/inspector/scripts/generate-inspector-protocol-bindings.py \
|
---|
326 | $(JavaScriptCore_SCRIPTS_DIR)/generate-combined-inspector-json.py \
|
---|
327 | #
|
---|
328 |
|
---|
329 | # TODO: Is there some way to not hardcode this? Can we get it from
|
---|
330 | # generate-inspector-protocol-bindings.py and ./CombinedDomains.json?
|
---|
331 | INSPECTOR_DISPATCHER_FILES = \
|
---|
332 | inspector/InspectorAlternateBackendDispatchers.h \
|
---|
333 | inspector/InspectorBackendDispatchers.cpp \
|
---|
334 | inspector/InspectorBackendDispatchers.h \
|
---|
335 | inspector/InspectorFrontendDispatchers.cpp \
|
---|
336 | inspector/InspectorFrontendDispatchers.h \
|
---|
337 | inspector/InspectorProtocolObjects.cpp \
|
---|
338 | inspector/InspectorProtocolObjects.h \
|
---|
339 | #
|
---|
340 | INSPECTOR_DISPATCHER_FILES_PATTERNS = $(subst .,%,$(INSPECTOR_DISPATCHER_FILES))
|
---|
341 |
|
---|
342 | all : $(INSPECTOR_DISPATCHER_FILES) inspector/InspectorBackendCommands.js
|
---|
343 |
|
---|
344 | # The combined JSON file depends on the actual set of domains and their file contents, so that
|
---|
345 | # adding, modifying, or removing domains will trigger regeneration of inspector files.
|
---|
346 |
|
---|
347 | .PHONY: force
|
---|
348 | EnabledInspectorDomains : $(JavaScriptCore_SCRIPTS_DIR)/UpdateContents.py force
|
---|
349 | $(PYTHON) $(JavaScriptCore_SCRIPTS_DIR)/UpdateContents.py '$(INSPECTOR_DOMAINS)' $@
|
---|
350 |
|
---|
351 | CombinedDomains.json : $(JavaScriptCore_SCRIPTS_DIR)/generate-combined-inspector-json.py $(INSPECTOR_DOMAINS) EnabledInspectorDomains
|
---|
352 | $(PYTHON) $(JavaScriptCore_SCRIPTS_DIR)/generate-combined-inspector-json.py $(INSPECTOR_DOMAINS) > ./CombinedDomains.json
|
---|
353 |
|
---|
354 | # Inspector Backend Dispatchers, Frontend Dispatchers, Type Builders
|
---|
355 | $(INSPECTOR_DISPATCHER_FILES_PATTERNS) : CombinedDomains.json $(INSPECTOR_GENERATOR_SCRIPTS)
|
---|
356 | $(PYTHON) $(JavaScriptCore)/inspector/scripts/generate-inspector-protocol-bindings.py --framework JavaScriptCore --outputDir inspector ./CombinedDomains.json
|
---|
357 |
|
---|
358 | inspector/InspectorBackendCommands.js : CombinedDomains.json $(INSPECTOR_GENERATOR_SCRIPTS) $(FEATURE_AND_PLATFORM_DEFINE_DEPENDENCIES)
|
---|
359 | $(PYTHON) $(JavaScriptCore)/inspector/scripts/generate-inspector-protocol-bindings.py --framework WebInspectorUI --outputDir inspector ./CombinedDomains.json
|
---|
360 | @echo Pre-processing InspectorBackendCommands...
|
---|
361 | $(PERL) $(JavaScriptCore)/inspector/scripts/codegen/preprocess.pl --input inspector/InspectorBackendCommands.js.in --defines "$(FEATURE_AND_PLATFORM_DEFINES)" --output inspector/InspectorBackendCommands.js
|
---|
362 | $(DELETE) inspector/InspectorBackendCommands.js.in
|
---|
363 |
|
---|
364 | InjectedScriptSource.h : inspector/InjectedScriptSource.js $(JavaScriptCore_SCRIPTS_DIR)/jsmin.py $(JavaScriptCore_SCRIPTS_DIR)/xxd.pl
|
---|
365 | echo "//# sourceURL=__InjectedScript_InjectedScriptSource.js" > ./InjectedScriptSource.min.js
|
---|
366 | $(PYTHON) $(JavaScriptCore_SCRIPTS_DIR)/jsmin.py < $(JavaScriptCore)/inspector/InjectedScriptSource.js >> ./InjectedScriptSource.min.js
|
---|
367 | $(PERL) $(JavaScriptCore_SCRIPTS_DIR)/xxd.pl InjectedScriptSource_js ./InjectedScriptSource.min.js InjectedScriptSource.h
|
---|
368 | $(DELETE) InjectedScriptSource.min.js
|
---|
369 |
|
---|
370 | AIR_OPCODE_FILES = \
|
---|
371 | AirOpcode.h \
|
---|
372 | AirOpcodeUtils.h \
|
---|
373 | AirOpcodeGenerated.h \
|
---|
374 | #
|
---|
375 | AIR_OPCODE_FILES_PATTERNS = $(subst .,%,$(AIR_OPCODE_FILES))
|
---|
376 |
|
---|
377 | all : $(AIR_OPCODE_FILES)
|
---|
378 |
|
---|
379 | $(AIR_OPCODE_FILES_PATTERNS) : $(JavaScriptCore)/b3/air/opcode_generator.rb $(JavaScriptCore)/b3/air/AirOpcode.opcodes
|
---|
380 | $(RUBY) $^
|
---|
381 |
|
---|
382 | UnicodePatternTables.h: $(JavaScriptCore)/yarr/generateYarrUnicodePropertyTables.py $(JavaScriptCore)/yarr/hasher.py $(JavaScriptCore)/ucd/DerivedBinaryProperties.txt $(JavaScriptCore)/ucd/DerivedCoreProperties.txt $(JavaScriptCore)/ucd/DerivedNormalizationProps.txt $(JavaScriptCore)/ucd/PropList.txt $(JavaScriptCore)/ucd/PropertyAliases.txt $(JavaScriptCore)/ucd/PropertyValueAliases.txt $(JavaScriptCore)/ucd/ScriptExtensions.txt $(JavaScriptCore)/ucd/Scripts.txt $(JavaScriptCore)/ucd/UnicodeData.txt $(JavaScriptCore)/ucd/emoji-data.txt
|
---|
383 | $(PYTHON) $(JavaScriptCore)/yarr/generateYarrUnicodePropertyTables.py $(JavaScriptCore)/ucd ./UnicodePatternTables.h
|
---|
384 |
|
---|
385 | yarr/YarrCanonicalizeUnicode.cpp: $(JavaScriptCore)/yarr/generateYarrCanonicalizeUnicode $(JavaScriptCore)/ucd/CaseFolding.txt
|
---|
386 | $(PYTHON) $(JavaScriptCore)/yarr/generateYarrCanonicalizeUnicode $(JavaScriptCore)/ucd/CaseFolding.txt ./yarr/YarrCanonicalizeUnicode.cpp
|
---|
387 |
|
---|
388 | WasmOps.h: $(JavaScriptCore)/wasm/generateWasmOpsHeader.py $(JavaScriptCore)/wasm/generateWasm.py $(JavaScriptCore)/wasm/wasm.json
|
---|
389 | $(PYTHON) $(JavaScriptCore)/wasm/generateWasmOpsHeader.py $(JavaScriptCore)/wasm/wasm.json ./WasmOps.h
|
---|
390 |
|
---|
391 | WasmB3IRGeneratorInlines.h: $(JavaScriptCore)/wasm/generateWasmB3IRGeneratorInlinesHeader.py $(JavaScriptCore)/wasm/generateWasm.py $(JavaScriptCore)/wasm/wasm.json
|
---|
392 | $(PYTHON) $(JavaScriptCore)/wasm/generateWasmB3IRGeneratorInlinesHeader.py $(JavaScriptCore)/wasm/wasm.json ./WasmB3IRGeneratorInlines.h
|
---|
393 |
|
---|
394 | # Dynamically-defined targets are listed below. Static targets belong up top.
|
---|
395 |
|
---|
396 | all : \
|
---|
397 | $(OBJECT_LUT_HEADERS) \
|
---|
398 | #
|
---|