1 cmake_minimum_required(VERSION 2.8.12)
4 set(JavaScriptCore_INCLUDE_DIRECTORIES
6 "${JAVASCRIPTCORE_DIR}"
7 "${JAVASCRIPTCORE_DIR}/.."
8 "${JAVASCRIPTCORE_DIR}/API"
9 "${JAVASCRIPTCORE_DIR}/ForwardingHeaders"
10 "${JAVASCRIPTCORE_DIR}/assembler"
11 "${JAVASCRIPTCORE_DIR}/b3"
12 "${JAVASCRIPTCORE_DIR}/b3/air"
13 "${JAVASCRIPTCORE_DIR}/bindings"
14 "${JAVASCRIPTCORE_DIR}/builtins"
15 "${JAVASCRIPTCORE_DIR}/bytecode"
16 "${JAVASCRIPTCORE_DIR}/bytecompiler"
17 "${JAVASCRIPTCORE_DIR}/dfg"
18 "${JAVASCRIPTCORE_DIR}/disassembler"
19 "${JAVASCRIPTCORE_DIR}/ftl"
20 "${JAVASCRIPTCORE_DIR}/heap"
21 "${JAVASCRIPTCORE_DIR}/debugger"
22 "${JAVASCRIPTCORE_DIR}/inspector"
23 "${JAVASCRIPTCORE_DIR}/inspector/agents"
24 "${JAVASCRIPTCORE_DIR}/inspector/augmentable"
25 "${JAVASCRIPTCORE_DIR}/inspector/remote"
26 "${JAVASCRIPTCORE_DIR}/interpreter"
27 "${JAVASCRIPTCORE_DIR}/jit"
28 "${JAVASCRIPTCORE_DIR}/llint"
29 "${JAVASCRIPTCORE_DIR}/llvm"
30 "${JAVASCRIPTCORE_DIR}/parser"
31 "${JAVASCRIPTCORE_DIR}/profiler"
32 "${JAVASCRIPTCORE_DIR}/replay"
33 "${JAVASCRIPTCORE_DIR}/runtime"
34 "${JAVASCRIPTCORE_DIR}/tools"
35 "${JAVASCRIPTCORE_DIR}/wasm"
36 "${JAVASCRIPTCORE_DIR}/yarr"
37 "${DERIVED_SOURCES_DIR}"
38 "${DERIVED_SOURCES_DIR}/ForwardingHeaders"
39 "${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}"
40 "${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector"
43 set(JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES
47 set(JavaScriptCore_SOURCES
49 API/JSCTestRunnerUtils.cpp
50 API/JSCallbackConstructor.cpp
51 API/JSCallbackFunction.cpp
52 API/JSCallbackObject.cpp
56 API/JSProfilerPrivate.cpp
60 API/JSWeakObjectMapRefPrivate.cpp
61 API/OpaqueJSString.cpp
63 assembler/ARMAssembler.cpp
64 assembler/LinkBuffer.cpp
65 assembler/MacroAssembler.cpp
66 assembler/MacroAssemblerARM.cpp
67 assembler/MacroAssemblerARMv7.cpp
68 assembler/MacroAssemblerPrinter.cpp
69 assembler/MacroAssemblerX86Common.cpp
71 b3/air/AirAllocateStack.cpp
73 b3/air/AirBasicBlock.cpp
74 b3/air/AirCCallSpecial.cpp
76 b3/air/AirEliminateDeadCode.cpp
77 b3/air/AirFixPartialRegisterStalls.cpp
78 b3/air/AirGenerate.cpp
79 b3/air/AirGenerated.cpp
80 b3/air/AirHandleCalleeSaves.cpp
81 b3/air/AirInsertionSet.cpp
83 b3/air/AirIteratedRegisterCoalescing.cpp
84 b3/air/AirOptimizeBlockOrder.cpp
85 b3/air/AirPhaseScope.cpp
86 b3/air/AirRegisterPriority.cpp
87 b3/air/AirReportUsedRegisters.cpp
88 b3/air/AirSimplifyCFG.cpp
90 b3/air/AirSpillEverything.cpp
91 b3/air/AirStackSlot.cpp
93 b3/air/AirTmpWidth.cpp
94 b3/air/AirValidate.cpp
96 b3/B3ArgumentRegValue.cpp
98 b3/B3BlockInsertionSet.cpp
100 b3/B3CheckSpecial.cpp
103 b3/B3Commutativity.cpp
105 b3/B3Const32Value.cpp
106 b3/B3Const64Value.cpp
107 b3/B3ConstDoubleValue.cpp
108 b3/B3ConstFloatValue.cpp
109 b3/B3ConstrainedValue.cpp
110 b3/B3ControlValue.cpp
113 b3/B3FrequencyClass.cpp
116 b3/B3InsertionSet.cpp
118 b3/B3LowerMacrosAfterOptimizations.cpp
122 b3/B3MoveConstants.cpp
123 b3/B3OpaqueByproducts.cpp
126 b3/B3PatchpointSpecial.cpp
127 b3/B3PatchpointValue.cpp
131 b3/B3ReduceDoubleToFloat.cpp
132 b3/B3ReduceStrength.cpp
133 b3/B3StackmapGenerationParams.cpp
134 b3/B3StackmapSpecial.cpp
135 b3/B3StackmapValue.cpp
136 b3/B3StackSlotKind.cpp
137 b3/B3StackSlotValue.cpp
142 b3/B3UpsilonValue.cpp
149 bindings/ScriptFunctionCall.cpp
150 bindings/ScriptObject.cpp
151 bindings/ScriptValue.cpp
153 builtins/BuiltinExecutables.cpp
155 bytecode/AdaptiveInferredPropertyValueWatchpointBase.cpp
156 bytecode/ArrayAllocationProfile.cpp
157 bytecode/ArrayProfile.cpp
158 bytecode/BytecodeBasicBlock.cpp
159 bytecode/BytecodeIntrinsicRegistry.cpp
160 bytecode/BytecodeLivenessAnalysis.cpp
161 bytecode/CallEdge.cpp
162 bytecode/CallLinkInfo.cpp
163 bytecode/CallLinkStatus.cpp
164 bytecode/CallMode.cpp
165 bytecode/CallVariant.cpp
166 bytecode/CodeBlock.cpp
167 bytecode/CodeBlockHash.cpp
168 bytecode/CodeBlockJettisoningWatchpoint.cpp
169 bytecode/CodeOrigin.cpp
170 bytecode/CodeType.cpp
171 bytecode/ComplexGetStatus.cpp
172 bytecode/DataFormat.cpp
173 bytecode/DFGExitProfile.cpp
174 bytecode/DeferredCompilationCallback.cpp
175 bytecode/DeferredSourceDump.cpp
176 bytecode/ExecutionCounter.cpp
177 bytecode/ExitKind.cpp
178 bytecode/ExitingJITType.cpp
179 bytecode/GetByIdStatus.cpp
180 bytecode/GetByIdVariant.cpp
181 bytecode/InlineCallFrame.cpp
182 bytecode/InlineCallFrameSet.cpp
183 bytecode/JumpTable.cpp
184 bytecode/LazyOperandValueProfile.cpp
185 bytecode/MethodOfGettingAValueProfile.cpp
186 bytecode/ObjectPropertyCondition.cpp
187 bytecode/ObjectPropertyConditionSet.cpp
189 bytecode/PolymorphicAccess.cpp
190 bytecode/PreciseJumpTargets.cpp
191 bytecode/PropertyCondition.cpp
192 bytecode/PutByIdFlags.cpp
193 bytecode/PutByIdStatus.cpp
194 bytecode/PutByIdVariant.cpp
195 bytecode/ReduceWhitespace.cpp
196 bytecode/SamplingTool.cpp
197 bytecode/SpecialPointer.cpp
198 bytecode/SpeculatedType.cpp
199 bytecode/StructureSet.cpp
200 bytecode/StructureStubClearingWatchpoint.cpp
201 bytecode/StructureStubInfo.cpp
202 bytecode/ToThisStatus.cpp
203 bytecode/TrackedReferences.cpp
204 bytecode/UnlinkedCodeBlock.cpp
205 bytecode/UnlinkedFunctionExecutable.cpp
206 bytecode/UnlinkedInstructionStream.cpp
207 bytecode/ValueProfile.cpp
208 bytecode/ValueRecovery.cpp
209 bytecode/VariableWriteFireDetail.cpp
210 bytecode/VirtualRegister.cpp
211 bytecode/Watchpoint.cpp
213 bytecompiler/BytecodeGenerator.cpp
214 bytecompiler/NodesCodegen.cpp
216 debugger/Debugger.cpp
217 debugger/DebuggerCallFrame.cpp
218 debugger/DebuggerScope.cpp
220 dfg/DFGAbstractHeap.cpp
221 dfg/DFGAbstractValue.cpp
222 dfg/DFGAdaptiveInferredPropertyValueWatchpoint.cpp
223 dfg/DFGAdaptiveStructureWatchpoint.cpp
224 dfg/DFGArgumentsEliminationPhase.cpp
225 dfg/DFGArgumentsUtilities.cpp
228 dfg/DFGAtTailAbstractState.cpp
229 dfg/DFGAvailability.cpp
230 dfg/DFGAvailabilityMap.cpp
231 dfg/DFGBackwardsPropagationPhase.cpp
232 dfg/DFGBasicBlock.cpp
233 dfg/DFGBlockInsertionSet.cpp
235 dfg/DFGByteCodeParser.cpp
237 dfg/DFGCFGSimplificationPhase.cpp
238 dfg/DFGCPSRethreadingPhase.cpp
240 dfg/DFGCapabilities.cpp
241 dfg/DFGCleanUpPhase.cpp
242 dfg/DFGClobberSet.cpp
243 dfg/DFGClobberize.cpp
244 dfg/DFGClobbersExitState.cpp
245 dfg/DFGCombinedLiveness.cpp
247 dfg/DFGCommonData.cpp
248 dfg/DFGCompilationKey.cpp
249 dfg/DFGCompilationMode.cpp
250 dfg/DFGConstantFoldingPhase.cpp
251 dfg/DFGConstantHoistingPhase.cpp
252 dfg/DFGCopyBarrierOptimizationPhase.cpp
253 dfg/DFGCriticalEdgeBreakingPhase.cpp
255 dfg/DFGDesiredIdentifiers.cpp
256 dfg/DFGDesiredTransitions.cpp
257 dfg/DFGDesiredWatchpoints.cpp
258 dfg/DFGDesiredWeakReferences.cpp
259 dfg/DFGDisassembler.cpp
264 dfg/DFGFailedFinalizer.cpp
266 dfg/DFGFixupPhase.cpp
267 dfg/DFGFlushFormat.cpp
269 dfg/DFGLiveCatchVariablePreservationPhase.cpp
270 dfg/DFGFrozenValue.cpp
271 dfg/DFGFunctionWhitelist.cpp
273 dfg/DFGGraphSafepoint.cpp
274 dfg/DFGHeapLocation.cpp
275 dfg/DFGInPlaceAbstractState.cpp
276 dfg/DFGInferredTypeCheck.cpp
277 dfg/DFGInsertionSet.cpp
278 dfg/DFGIntegerCheckCombiningPhase.cpp
279 dfg/DFGIntegerRangeOptimizationPhase.cpp
280 dfg/DFGInvalidationPointInjectionPhase.cpp
282 dfg/DFGJITCompiler.cpp
283 dfg/DFGJITFinalizer.cpp
284 dfg/DFGJumpReplacement.cpp
286 dfg/DFGLazyJSValue.cpp
288 dfg/DFGLivenessAnalysisPhase.cpp
289 dfg/DFGLongLivedState.cpp
290 dfg/DFGLoopPreHeaderCreationPhase.cpp
291 dfg/DFGMaximalFlushInsertionPhase.cpp
293 dfg/DFGMinifiedGraph.cpp
294 dfg/DFGMinifiedNode.cpp
295 dfg/DFGMovHintRemovalPhase.cpp
296 dfg/DFGMultiGetByOffsetData.cpp
297 dfg/DFGNaturalLoops.cpp
300 dfg/DFGNodeOrigin.cpp
301 dfg/DFGOSRAvailabilityAnalysisPhase.cpp
303 dfg/DFGOSREntrypointCreationPhase.cpp
305 dfg/DFGOSRExitBase.cpp
306 dfg/DFGOSRExitCompiler.cpp
307 dfg/DFGOSRExitCompiler32_64.cpp
308 dfg/DFGOSRExitCompiler64.cpp
309 dfg/DFGOSRExitCompilerCommon.cpp
310 dfg/DFGOSRExitFuzz.cpp
311 dfg/DFGOSRExitJumpPlaceholder.cpp
312 dfg/DFGOSRExitPreparation.cpp
313 dfg/DFGObjectAllocationSinkingPhase.cpp
314 dfg/DFGObjectMaterializationData.cpp
315 dfg/DFGOperations.cpp
316 dfg/DFGPhantomInsertionPhase.cpp
318 dfg/DFGPhiChildren.cpp
320 dfg/DFGPrePostNumbering.cpp
321 dfg/DFGPredictionInjectionPhase.cpp
322 dfg/DFGPredictionPropagationPhase.cpp
323 dfg/DFGPromotedHeapLocation.cpp
325 dfg/DFGPutStackSinkingPhase.cpp
326 dfg/DFGSSACalculator.cpp
327 dfg/DFGSSAConversionPhase.cpp
328 dfg/DFGSSALoweringPhase.cpp
330 dfg/DFGSpeculativeJIT.cpp
331 dfg/DFGSpeculativeJIT32_64.cpp
332 dfg/DFGSpeculativeJIT64.cpp
333 dfg/DFGStackLayoutPhase.cpp
334 dfg/DFGStaticExecutionCountEstimationPhase.cpp
335 dfg/DFGStoreBarrierInsertionPhase.cpp
336 dfg/DFGStrengthReductionPhase.cpp
337 dfg/DFGStructureAbstractValue.cpp
338 dfg/DFGStructureRegistrationPhase.cpp
339 dfg/DFGThreadData.cpp
341 dfg/DFGTierUpCheckInjectionPhase.cpp
342 dfg/DFGTransition.cpp
343 dfg/DFGTypeCheckHoistingPhase.cpp
344 dfg/DFGUnificationPhase.cpp
347 dfg/DFGValueSource.cpp
348 dfg/DFGValueStrength.cpp
349 dfg/DFGVarargsForwardingPhase.cpp
350 dfg/DFGVariableAccessData.cpp
351 dfg/DFGVariableAccessDataDump.cpp
352 dfg/DFGVariableEvent.cpp
353 dfg/DFGVariableEventStream.cpp
354 dfg/DFGVirtualRegisterAllocationPhase.cpp
355 dfg/DFGWatchpointCollectionPhase.cpp
358 disassembler/ARM64Disassembler.cpp
359 disassembler/ARMv7Disassembler.cpp
360 disassembler/Disassembler.cpp
361 disassembler/LLVMDisassembler.cpp
362 disassembler/X86Disassembler.cpp
364 disassembler/ARM64/A64DOpcode.cpp
366 disassembler/ARMv7/ARMv7DOpcode.cpp
368 heap/CodeBlockSet.cpp
369 heap/ConservativeRoots.cpp
374 heap/EdenGCActivityCallback.cpp
375 heap/FullGCActivityCallback.cpp
376 heap/GCActivityCallback.cpp
381 heap/HeapHelperPool.cpp
382 heap/HeapStatistics.cpp
384 heap/HeapVerifier.cpp
385 heap/IncrementalSweeper.cpp
386 heap/JITStubRoutineSet.cpp
387 heap/LiveObjectList.cpp
388 heap/MachineStackMarker.cpp
390 heap/MarkedAllocator.cpp
396 heap/WeakHandleOwner.cpp
398 heap/WriteBarrierBuffer.cpp
399 heap/WriteBarrierSupport.cpp
401 inspector/ConsoleMessage.cpp
402 inspector/ContentSearchUtilities.cpp
403 inspector/EventLoop.cpp
404 inspector/IdentifiersFactory.cpp
405 inspector/InjectedScript.cpp
406 inspector/InjectedScriptBase.cpp
407 inspector/InjectedScriptHost.cpp
408 inspector/InjectedScriptManager.cpp
409 inspector/InjectedScriptModule.cpp
410 inspector/InspectorAgentRegistry.cpp
411 inspector/InspectorFrontendRouter.cpp
412 inspector/InspectorBackendDispatcher.cpp
413 inspector/InspectorValues.cpp
414 inspector/JSGlobalObjectConsoleClient.cpp
415 inspector/JSGlobalObjectInspectorController.cpp
416 inspector/JSGlobalObjectScriptDebugServer.cpp
417 inspector/JSInjectedScriptHost.cpp
418 inspector/JSInjectedScriptHostPrototype.cpp
419 inspector/JSJavaScriptCallFrame.cpp
420 inspector/JSJavaScriptCallFramePrototype.cpp
421 inspector/JavaScriptCallFrame.cpp
422 inspector/PerGlobalObjectWrapperWorld.cpp
423 inspector/ScriptArguments.cpp
424 inspector/ScriptCallFrame.cpp
425 inspector/ScriptCallStack.cpp
426 inspector/ScriptCallStackFactory.cpp
427 inspector/ScriptDebugServer.cpp
429 inspector/agents/InspectorAgent.cpp
430 inspector/agents/InspectorConsoleAgent.cpp
431 inspector/agents/InspectorDebuggerAgent.cpp
432 inspector/agents/InspectorHeapAgent.cpp
433 inspector/agents/InspectorRuntimeAgent.cpp
434 inspector/agents/InspectorScriptProfilerAgent.cpp
435 inspector/agents/JSGlobalObjectConsoleAgent.cpp
436 inspector/agents/JSGlobalObjectDebuggerAgent.cpp
437 inspector/agents/JSGlobalObjectRuntimeAgent.cpp
439 interpreter/AbstractPC.cpp
440 interpreter/CallFrame.cpp
441 interpreter/Interpreter.cpp
442 interpreter/JSStack.cpp
443 interpreter/ProtoCallFrame.cpp
444 interpreter/StackVisitor.cpp
446 jit/AssemblyHelpers.cpp
448 jit/CachedRecovery.cpp
449 jit/CallFrameShuffleData.cpp
450 jit/CallFrameShuffler.cpp
451 jit/CallFrameShuffler32_64.cpp
452 jit/CallFrameShuffler64.cpp
453 jit/ExecutableAllocationFuzz.cpp
454 jit/ExecutableAllocator.cpp
455 jit/ExecutableAllocatorFixedVMPool.cpp
456 jit/GCAwareJITStubRoutine.cpp
458 jit/HostCallReturnValue.cpp
459 jit/IntrinsicEmitter.cpp
461 jit/JITAddGenerator.cpp
462 jit/JITArithmetic.cpp
463 jit/JITArithmetic32_64.cpp
464 jit/JITBitAndGenerator.cpp
465 jit/JITBitOrGenerator.cpp
466 jit/JITBitXorGenerator.cpp
470 jit/JITDisassembler.cpp
471 jit/JITDivGenerator.cpp
472 jit/JITExceptions.cpp
473 jit/JITInlineCacheGenerator.cpp
474 jit/JITLeftShiftGenerator.cpp
475 jit/JITMulGenerator.cpp
477 jit/JITOpcodes32_64.cpp
478 jit/JITOperations.cpp
479 jit/JITPropertyAccess.cpp
480 jit/JITPropertyAccess32_64.cpp
481 jit/JITRightShiftGenerator.cpp
482 jit/JITStubRoutine.cpp
483 jit/JITSubGenerator.cpp
485 jit/JITToDFGDeferredCompilationCallback.cpp
486 jit/PolymorphicCallStubRoutine.cpp
488 jit/RegisterAtOffset.cpp
489 jit/RegisterAtOffsetList.cpp
492 jit/ScratchRegisterAllocator.cpp
493 jit/SetupVarargsFrame.cpp
494 jit/TempRegisterSet.cpp
495 jit/ThunkGenerators.cpp
498 parser/ModuleAnalyzer.cpp
500 parser/NodesAnalyzeModule.cpp
502 parser/ParserArena.cpp
503 parser/SourceCode.cpp
504 parser/SourceProvider.cpp
505 parser/SourceProviderCache.cpp
506 parser/VariableEnvironment.cpp
508 profiler/LegacyProfiler.cpp
510 profiler/ProfileGenerator.cpp
511 profiler/ProfileNode.cpp
512 profiler/ProfilerBytecode.cpp
513 profiler/ProfilerBytecodeSequence.cpp
514 profiler/ProfilerBytecodes.cpp
515 profiler/ProfilerCompilation.cpp
516 profiler/ProfilerCompilationKind.cpp
517 profiler/ProfilerCompiledBytecode.cpp
518 profiler/ProfilerDatabase.cpp
519 profiler/ProfilerJettisonReason.cpp
520 profiler/ProfilerOSRExit.cpp
521 profiler/ProfilerOSRExitSite.cpp
522 profiler/ProfilerOrigin.cpp
523 profiler/ProfilerOriginStack.cpp
524 profiler/ProfilerProfiledBytecodes.cpp
526 tools/CodeProfile.cpp
527 tools/CodeProfiling.cpp
528 tools/FunctionOverrides.cpp
530 tools/JSDollarVMPrototype.cpp
532 wasm/JSWASMModule.cpp
533 wasm/WASMFunctionParser.cpp
534 wasm/WASMModuleParser.cpp
537 yarr/RegularExpression.cpp
538 yarr/YarrCanonicalizeUCS2.cpp
539 yarr/YarrInterpreter.cpp
542 yarr/YarrSyntaxChecker.cpp
545 set(JavaScriptCore_RUNTIME_SOURCES
547 runtime/ArrayBuffer.cpp
548 runtime/ArrayBufferNeuteringWatchpoint.cpp
549 runtime/ArrayBufferView.cpp
550 runtime/ArrayConstructor.cpp
551 runtime/ArrayIteratorPrototype.cpp
552 runtime/ArrayPrototype.cpp
553 runtime/BasicBlockLocation.cpp
554 runtime/BooleanConstructor.cpp
555 runtime/BooleanObject.cpp
556 runtime/BooleanPrototype.cpp
558 runtime/ClonedArguments.cpp
559 runtime/CodeCache.cpp
560 runtime/CodeSpecializationKind.cpp
561 runtime/CommonIdentifiers.cpp
562 runtime/CommonSlowPaths.cpp
563 runtime/CommonSlowPathsExceptions.cpp
564 runtime/CompilationResult.cpp
565 runtime/Completion.cpp
566 runtime/ConsoleClient.cpp
567 runtime/ConsolePrototype.cpp
568 runtime/ConstantMode.cpp
569 runtime/ConstructData.cpp
570 runtime/ControlFlowProfiler.cpp
571 runtime/CustomGetterSetter.cpp
573 runtime/DateConstructor.cpp
574 runtime/DateConversion.cpp
575 runtime/DateInstance.cpp
576 runtime/DatePrototype.cpp
577 runtime/DirectArguments.cpp
578 runtime/DirectArgumentsOffset.cpp
579 runtime/DumpContext.cpp
581 runtime/ErrorConstructor.cpp
582 runtime/ErrorHandlingScope.cpp
583 runtime/ErrorInstance.cpp
584 runtime/ErrorPrototype.cpp
585 runtime/Exception.cpp
586 runtime/ExceptionFuzz.cpp
587 runtime/ExceptionHelpers.cpp
588 runtime/Executable.cpp
589 runtime/FunctionConstructor.cpp
590 runtime/FunctionExecutableDump.cpp
591 runtime/FunctionHasExecutedCache.cpp
592 runtime/FunctionPrototype.cpp
593 runtime/FunctionRareData.cpp
594 runtime/GeneratorFrame.cpp
595 runtime/GeneratorFunctionConstructor.cpp
596 runtime/GeneratorFunctionPrototype.cpp
597 runtime/GeneratorPrototype.cpp
598 runtime/GetterSetter.cpp
599 runtime/Identifier.cpp
600 runtime/IndexingType.cpp
601 runtime/InferredType.cpp
602 runtime/InferredTypeTable.cpp
603 runtime/InferredValue.cpp
604 runtime/InitializeThreading.cpp
605 runtime/InspectorInstrumentationObject.cpp
606 runtime/InternalFunction.cpp
607 runtime/IntlCollator.cpp
608 runtime/IntlCollatorConstructor.cpp
609 runtime/IntlCollatorPrototype.cpp
610 runtime/IntlDateTimeFormat.cpp
611 runtime/IntlDateTimeFormatConstructor.cpp
612 runtime/IntlDateTimeFormatPrototype.cpp
613 runtime/IntlNumberFormat.cpp
614 runtime/IntlNumberFormatConstructor.cpp
615 runtime/IntlNumberFormatPrototype.cpp
616 runtime/IntlObject.cpp
617 runtime/IteratorOperations.cpp
618 runtime/IteratorPrototype.cpp
619 runtime/JSAPIValueWrapper.cpp
621 runtime/JSArrayBuffer.cpp
622 runtime/JSArrayBufferConstructor.cpp
623 runtime/JSArrayBufferPrototype.cpp
624 runtime/JSArrayBufferView.cpp
625 runtime/JSArrayIterator.cpp
626 runtime/JSArrowFunction.cpp
627 runtime/JSBoundFunction.cpp
628 runtime/JSCJSValue.cpp
631 runtime/JSConsole.cpp
632 runtime/JSDataView.cpp
633 runtime/JSDataViewPrototype.cpp
634 runtime/JSDateMath.cpp
635 runtime/JSEnvironmentRecord.cpp
636 runtime/JSFunction.cpp
637 runtime/JSGeneratorFunction.cpp
638 runtime/JSGlobalLexicalEnvironment.cpp
639 runtime/JSGlobalObject.cpp
640 runtime/JSGlobalObjectDebuggable.cpp
641 runtime/JSGlobalObjectFunctions.cpp
642 runtime/JSInternalPromise.cpp
643 runtime/JSInternalPromiseConstructor.cpp
644 runtime/JSInternalPromiseDeferred.cpp
645 runtime/JSInternalPromisePrototype.cpp
647 runtime/JSLexicalEnvironment.cpp
650 runtime/JSMapIterator.cpp
651 runtime/JSModuleEnvironment.cpp
652 runtime/JSModuleNamespaceObject.cpp
653 runtime/JSModuleRecord.cpp
654 runtime/JSNativeStdFunction.cpp
655 runtime/JSNotAnObject.cpp
656 runtime/JSONObject.cpp
658 runtime/JSPromise.cpp
659 runtime/JSPromiseConstructor.cpp
660 runtime/JSPromiseDeferred.cpp
661 runtime/JSPromisePrototype.cpp
662 runtime/JSPropertyNameEnumerator.cpp
663 runtime/JSPropertyNameIterator.cpp
666 runtime/JSSegmentedVariableObject.cpp
668 runtime/JSSetIterator.cpp
670 runtime/JSStringIterator.cpp
671 runtime/JSStringJoiner.cpp
672 runtime/JSSymbolTableObject.cpp
673 runtime/JSTemplateRegistryKey.cpp
674 runtime/JSTypedArrayConstructors.cpp
675 runtime/JSTypedArrayPrototypes.cpp
676 runtime/JSTypedArrayViewConstructor.cpp
677 runtime/JSTypedArrayViewPrototype.cpp
678 runtime/JSTypedArrays.cpp
679 runtime/JSWeakMap.cpp
680 runtime/JSWeakSet.cpp
681 runtime/JSWithScope.cpp
682 runtime/JSWrapperObject.cpp
683 runtime/LiteralParser.cpp
685 runtime/MapConstructor.cpp
686 runtime/MapIteratorPrototype.cpp
687 runtime/MapPrototype.cpp
688 runtime/MathCommon.cpp
689 runtime/MathObject.cpp
690 runtime/MemoryStatistics.cpp
691 runtime/ModuleLoaderObject.cpp
692 runtime/NativeErrorConstructor.cpp
693 runtime/NativeErrorPrototype.cpp
694 runtime/NativeStdFunctionCell.cpp
695 runtime/NullGetterFunction.cpp
696 runtime/NullSetterFunction.cpp
697 runtime/NumberConstructor.cpp
698 runtime/NumberObject.cpp
699 runtime/NumberPrototype.cpp
700 runtime/ObjectConstructor.cpp
701 runtime/ObjectPrototype.cpp
702 runtime/Operations.cpp
704 runtime/PropertyDescriptor.cpp
705 runtime/PropertySlot.cpp
706 runtime/PropertyTable.cpp
707 runtime/PrototypeMap.cpp
708 runtime/ReflectObject.cpp
710 runtime/RegExpCache.cpp
711 runtime/RegExpCachedResult.cpp
712 runtime/RegExpConstructor.cpp
713 runtime/RegExpMatchesArray.cpp
714 runtime/RegExpObject.cpp
715 runtime/RegExpPrototype.cpp
716 runtime/RuntimeType.cpp
717 runtime/SamplingCounter.cpp
718 runtime/ScopeOffset.cpp
719 runtime/ScopedArguments.cpp
720 runtime/ScopedArgumentsTable.cpp
721 runtime/SetConstructor.cpp
722 runtime/SetIteratorPrototype.cpp
723 runtime/SetPrototype.cpp
724 runtime/SimpleTypedArrayController.cpp
725 runtime/SmallStrings.cpp
726 runtime/SparseArrayValueMap.cpp
727 runtime/StrictEvalActivation.cpp
728 runtime/StringConstructor.cpp
729 runtime/StringIteratorPrototype.cpp
730 runtime/StringObject.cpp
731 runtime/StringPrototype.cpp
732 runtime/StringRecursionChecker.cpp
733 runtime/Structure.cpp
734 runtime/StructureChain.cpp
735 runtime/StructureIDTable.cpp
736 runtime/StructureRareData.cpp
738 runtime/SymbolConstructor.cpp
739 runtime/SymbolObject.cpp
740 runtime/SymbolPrototype.cpp
741 runtime/SymbolTable.cpp
742 runtime/TemplateRegistry.cpp
743 runtime/TestRunnerUtils.cpp
744 runtime/TypeLocationCache.cpp
745 runtime/TypeProfiler.cpp
746 runtime/TypeProfilerLog.cpp
748 runtime/TypedArrayController.cpp
749 runtime/TypedArrayType.cpp
750 runtime/TypeofType.cpp
752 runtime/VMEntryScope.cpp
753 runtime/VarOffset.cpp
755 runtime/WeakMapConstructor.cpp
756 runtime/WeakMapData.cpp
757 runtime/WeakMapPrototype.cpp
758 runtime/WeakSetConstructor.cpp
759 runtime/WeakSetPrototype.cpp
762 list(APPEND JavaScriptCore_SOURCES
763 ${JavaScriptCore_RUNTIME_SOURCES}
766 set(JavaScriptCore_OBJECT_LUT_SOURCES
767 runtime/ArrayConstructor.cpp
768 runtime/ArrayIteratorPrototype.cpp
769 runtime/BooleanPrototype.cpp
770 runtime/DateConstructor.cpp
771 runtime/DatePrototype.cpp
772 runtime/ErrorPrototype.cpp
773 runtime/GeneratorPrototype.cpp
774 runtime/InspectorInstrumentationObject.cpp
775 runtime/IntlCollatorConstructor.cpp
776 runtime/IntlCollatorPrototype.cpp
777 runtime/IntlDateTimeFormatConstructor.cpp
778 runtime/IntlDateTimeFormatPrototype.cpp
779 runtime/IntlNumberFormatConstructor.cpp
780 runtime/IntlNumberFormatPrototype.cpp
781 runtime/JSDataViewPrototype.cpp
782 runtime/JSGlobalObject.cpp
783 runtime/JSInternalPromiseConstructor.cpp
784 runtime/JSONObject.cpp
785 runtime/JSPromiseConstructor.cpp
786 runtime/JSPromisePrototype.cpp
787 runtime/ModuleLoaderObject.cpp
788 runtime/NumberConstructor.cpp
789 runtime/NumberPrototype.cpp
790 runtime/ObjectConstructor.cpp
791 runtime/ReflectObject.cpp
792 runtime/RegExpConstructor.cpp
793 runtime/RegExpPrototype.cpp
794 runtime/StringConstructor.cpp
795 runtime/StringIteratorPrototype.cpp
796 runtime/SymbolConstructor.cpp
797 runtime/SymbolPrototype.cpp
800 set(JavaScriptCore_LIBRARIES
802 ${ICU_I18N_LIBRARIES}
805 set(JavaScriptCore_SCRIPTS_SOURCES_DIR "${JAVASCRIPTCORE_DIR}/Scripts")
807 # Globbing relies on the fact that generator-specific file names are prefixed with their directory.
808 # Top-level scripts should have a file extension, since they are invoked during the build.
810 set(JavaScriptCore_SCRIPTS_SOURCES_PATHS
811 ${JavaScriptCore_SCRIPTS_SOURCES_DIR}/*.pl
812 ${JavaScriptCore_SCRIPTS_SOURCES_DIR}/*.py
813 ${JavaScriptCore_SCRIPTS_SOURCES_DIR}/builtins/builtins*.py
816 # Force JavaScriptCore to run scripts from the same staging path as WebCore.
817 set(JavaScriptCore_SCRIPTS_DIR "${DERIVED_SOURCES_DIR}/ForwardingHeaders/JavaScriptCore/Scripts")
819 file(MAKE_DIRECTORY ${JavaScriptCore_SCRIPTS_DIR})
821 # The directory flattening performed below mirrors what the Mac port does with private headers.
823 file(GLOB JavaScriptCore_SCRIPTS_SOURCES ${JavaScriptCore_SCRIPTS_SOURCES_PATHS})
825 foreach (_file ${JavaScriptCore_SCRIPTS_SOURCES})
826 get_filename_component(_script "${_file}" NAME)
828 OUTPUT ${JavaScriptCore_SCRIPTS_DIR}/${_script}
829 MAIN_DEPENDENCY ${_file}
830 WORKING_DIRECTORY ${DERIVED_SOURCES_DIR}
831 COMMAND ${CMAKE_COMMAND} -E copy_if_different ${_file} ${JavaScriptCore_SCRIPTS_DIR}/${_script}
833 list(APPEND JavaScriptCore_SCRIPTS ${JavaScriptCore_SCRIPTS_DIR}/${_script})
838 disassembler/udis86/ud_opcode.py
839 disassembler/udis86/ud_optable.py
843 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/udis86_itab.c ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/udis86_itab.h
844 DEPENDS ${UDIS_GEN_DEP}
845 WORKING_DIRECTORY ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}
846 COMMAND ${PYTHON_EXECUTABLE} ${JAVASCRIPTCORE_DIR}/disassembler/udis86/itab.py ${JAVASCRIPTCORE_DIR}/disassembler/udis86/optable.xml
849 list(APPEND JavaScriptCore_INCLUDE_DIRECTORIES
850 ${JAVASCRIPTCORE_DIR}/disassembler/udis86
852 list(APPEND JavaScriptCore_HEADERS
853 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/udis86_itab.h
855 list(APPEND JavaScriptCore_SOURCES
856 disassembler/UDis86Disassembler.cpp
858 disassembler/udis86/udis86.c
859 disassembler/udis86/udis86_decode.c
860 disassembler/udis86/udis86_input.c
861 disassembler/udis86/udis86_itab_holder.c
862 disassembler/udis86/udis86_syn-att.c
863 disassembler/udis86/udis86_syn-intel.c
864 disassembler/udis86/udis86_syn.c
869 llint/LowLevelInterpreter.asm
870 llint/LowLevelInterpreter32_64.asm
871 llint/LowLevelInterpreter64.asm
878 offlineasm/backends.rb
881 offlineasm/instructions.rb
883 offlineasm/offsets.rb
886 offlineasm/registers.rb
888 offlineasm/self_hash.rb
889 offlineasm/settings.rb
891 offlineasm/transform.rb
896 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/Bytecodes.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InitBytecodes.asm
897 MAIN_DEPENDENCY ${JAVASCRIPTCORE_DIR}/generate-bytecode-files
898 DEPENDS ${JAVASCRIPTCORE_DIR}/generate-bytecode-files bytecode/BytecodeList.json
899 COMMAND ${PYTHON_EXECUTABLE} ${JAVASCRIPTCORE_DIR}/generate-bytecode-files --bytecodes_h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/Bytecodes.h --init_bytecodes_asm ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InitBytecodes.asm ${JAVASCRIPTCORE_DIR}/bytecode/BytecodeList.json
903 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredOffsets.h
904 MAIN_DEPENDENCY ${JAVASCRIPTCORE_DIR}/offlineasm/generate_offset_extractor.rb
905 DEPENDS ${LLINT_ASM} ${OFFLINE_ASM} ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InitBytecodes.asm
906 COMMAND ${RUBY_EXECUTABLE} ${JAVASCRIPTCORE_DIR}/offlineasm/generate_offset_extractor.rb -I${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/ ${JAVASCRIPTCORE_DIR}/llint/LowLevelInterpreter.asm ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredOffsets.h
909 # We add the header files directly to the ADD_EXECUTABLE call instead of setting the
910 # OBJECT_DEPENDS property in LLIntOffsetsExtractor.cpp because generate_offset_extractor.rb and
911 # generate-bytecode-files may not regenerate the .h files in case the hash it calculates does not change.
912 # In this case, if some of the dependencies specified in the ADD_CUSTOM_COMMANDs above have
913 # changed the command will always be called because the mtime of the .h files will
914 # always be older than that of their dependencies.
915 # Additionally, setting the OBJECT_DEPENDS property will make the .h files a Makefile
916 # dependency of both LLIntOffsetsExtractor and LLIntOffsetsExtractor.cpp, so the command will
917 # actually be run multiple times!
918 add_executable(LLIntOffsetsExtractor
919 ${JAVASCRIPTCORE_DIR}/llint/LLIntOffsetsExtractor.cpp
920 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredOffsets.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/Bytecodes.h
922 target_link_libraries(LLIntOffsetsExtractor WTF)
924 # The build system will execute asm.rb every time LLIntOffsetsExtractor's mtime is newer than
925 # LLIntAssembly.h's mtime. The problem we have here is: asm.rb has some built-in optimization
926 # that generates a checksum of the LLIntOffsetsExtractor binary, if the checksum of the new
927 # LLIntOffsetsExtractor matches, no output is generated. To make this target consistent and avoid
928 # running this command for every build, we artificially update LLIntAssembly.h's mtime (using touch)
929 # after every asm.rb run.
931 set(LLIntOutput LowLevelInterpreterWin.asm)
933 set(LLIntOutput LLIntAssembly.h)
937 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/${LLIntOutput}
938 MAIN_DEPENDENCY ${JAVASCRIPTCORE_DIR}/offlineasm/asm.rb
939 DEPENDS LLIntOffsetsExtractor ${LLINT_ASM} ${OFFLINE_ASM} ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InitBytecodes.asm
940 COMMAND ${RUBY_EXECUTABLE} ${JAVASCRIPTCORE_DIR}/offlineasm/asm.rb -I${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/ ${JAVASCRIPTCORE_DIR}/llint/LowLevelInterpreter.asm $<TARGET_FILE:LLIntOffsetsExtractor> ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/${LLIntOutput}
941 COMMAND ${CMAKE_COMMAND} -E touch_nocreate ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/${LLIntOutput}
942 WORKING_DIRECTORY ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}
945 # The explanation for not making LLIntAssembly.h part of the OBJECT_DEPENDS property of some of
946 # the .cpp files below is similar to the one in the previous comment. However, since these .cpp
947 # files are used to build JavaScriptCore itself, we can just add LLIntAssembly.h to JSC_HEADERS
948 # since it is used in the add_library() call at the end of this file.
950 enable_language(ASM_MASM)
951 list(APPEND JavaScriptCore_SOURCES
952 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LowLevelInterpreterWin.asm
954 # Win32 needs /safeseh with assembly, but Win64 does not.
955 if (CMAKE_SIZEOF_VOID_P EQUAL 4)
956 set_source_files_properties(${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LowLevelInterpreterWin.asm
957 PROPERTIES COMPILE_FLAGS "/safeseh"
961 list(APPEND JavaScriptCore_HEADERS
962 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntAssembly.h
966 list(APPEND JavaScriptCore_SOURCES
969 llint/LLIntEntrypoint.cpp
970 llint/LLIntExceptions.cpp
971 llint/LLIntSlowPaths.cpp
972 llint/LLIntThunks.cpp
973 llint/LowLevelInterpreter.cpp
978 if (NOT LLVM_STATIC_LIBRARIES)
979 message(FATAL_ERROR "No LLVM libs found, but FTL is enabled. Stopping build.")
982 # Configure llvmForJSC.so
983 set(llvmForJSC_SOURCES
984 llvm/library/LLVMAnchor.cpp
985 llvm/library/LLVMExports.cpp
986 llvm/library/LLVMOverrides.cpp
988 set(llvmForJSC_INCLUDE_DIRECTORIES
990 "${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}"
994 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/WebKitLLVMLibraryToken.h
995 DEPENDS ${LLVM_STATIC_LIBRARIES}
996 COMMAND ${CMAKE_COMMAND} -E touch ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/WebKitLLVMLibraryToken.h
999 WEBKIT_WRAP_SOURCELIST(${llvmForJSC_SOURCES})
1000 add_library(llvmForJSC SHARED ${llvmForJSC_SOURCES} ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/WebKitLLVMLibraryToken.h)
1001 target_link_libraries(llvmForJSC ${LLVM_STATIC_LIBRARIES} ${LLVM_SYSTEM_LIBRARIES})
1002 if (NOT CMAKE_SYSTEM_NAME MATCHES "Darwin")
1003 ADD_TARGET_PROPERTIES(llvmForJSC LINK_FLAGS "-Wl,--version-script=${JAVASCRIPTCORE_DIR}/llvm/library/libllvmForJSC.version")
1006 # Added extra items for JavaScriptCore
1007 list(APPEND JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES
1008 ${LLVM_INCLUDE_DIRS}
1011 list(APPEND JavaScriptCore_SOURCES
1012 dfg/DFGToFTLDeferredCompilationCallback.cpp
1013 dfg/DFGToFTLForOSREntryDeferredCompilationCallback.cpp
1015 disassembler/LLVMDisassembler.cpp
1016 disassembler/X86Disassembler.cpp
1018 ftl/FTLAbstractHeap.cpp
1019 ftl/FTLAbstractHeapRepository.cpp
1020 ftl/FTLAvailableRecovery.cpp
1021 ftl/FTLB3Compile.cpp
1023 ftl/FTLCapabilities.cpp
1024 ftl/FTLCommonValues.cpp
1026 ftl/FTLCompileBinaryOp.cpp
1027 ftl/FTLDWARFDebugLineInfo.cpp
1028 ftl/FTLDWARFRegister.cpp
1029 ftl/FTLDataSection.cpp
1030 ftl/FTLExceptionHandlerManager.cpp
1031 ftl/FTLExitArgument.cpp
1032 ftl/FTLExitArgumentForOperand.cpp
1033 ftl/FTLExitPropertyValue.cpp
1034 ftl/FTLExitThunkGenerator.cpp
1035 ftl/FTLExitTimeObjectMaterialization.cpp
1036 ftl/FTLExitValue.cpp
1038 ftl/FTLForOSREntryJITCode.cpp
1039 ftl/FTLInlineCacheSize.cpp
1040 ftl/FTLIntrinsicRepository.cpp
1042 ftl/FTLJITFinalizer.cpp
1044 ftl/FTLJSCallBase.cpp
1045 ftl/FTLJSCallVarargs.cpp
1046 ftl/FTLJSTailCall.cpp
1047 ftl/FTLLazySlowPath.cpp
1050 ftl/FTLLowerDFGToLLVM.cpp
1053 ftl/FTLOSRExitCompiler.cpp
1054 ftl/FTLOSRExitHandle.cpp
1055 ftl/FTLOperations.cpp
1057 ftl/FTLRecoveryOpcode.cpp
1058 ftl/FTLSaveRestore.cpp
1059 ftl/FTLSlowPathCall.cpp
1060 ftl/FTLSlowPathCallKey.cpp
1061 ftl/FTLStackMaps.cpp
1064 ftl/FTLUnwindInfo.cpp
1065 ftl/FTLValueRange.cpp
1067 llvm/InitializeLLVM.cpp
1068 llvm/InitializeLLVMLinux.cpp
1069 llvm/InitializeLLVMPOSIX.cpp
1074 set(HASH_LUT_GENERATOR ${CMAKE_CURRENT_SOURCE_DIR}/create_hash_table)
1075 macro(GENERATE_HASH_LUT _input _output)
1078 MAIN_DEPENDENCY ${HASH_LUT_GENERATOR}
1080 COMMAND ${PERL_EXECUTABLE} ${HASH_LUT_GENERATOR} ${_input} > ${_output}
1082 list(APPEND JavaScriptCore_HEADERS ${_output})
1083 ADD_SOURCE_DEPENDENCIES(${_input} ${_output})
1086 # GENERATOR 1-A: LUT creator
1088 foreach (_file ${JavaScriptCore_OBJECT_LUT_SOURCES})
1089 get_filename_component(_name ${_file} NAME_WE)
1090 GENERATE_HASH_LUT(${CMAKE_CURRENT_SOURCE_DIR}/${_file} ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/${_name}.lut.h)
1093 set(JavaScriptCore_FORWARDING_HEADERS_DIRECTORIES
1116 inspector/augmentable
1120 # GENERATOR 1-B: particular LUT creator (for 1 file only)
1121 GENERATE_HASH_LUT(${CMAKE_CURRENT_SOURCE_DIR}/parser/Keywords.table ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/Lexer.lut.h)
1123 #GENERATOR: "RegExpJitTables.h": tables used by Yarr
1125 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/RegExpJitTables.h
1126 MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/create_regex_tables
1127 COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/create_regex_tables > ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/RegExpJitTables.h
1129 ADD_SOURCE_DEPENDENCIES(${CMAKE_CURRENT_SOURCE_DIR}/yarr/YarrPattern.cpp ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/RegExpJitTables.h)
1132 #GENERATOR: "KeywordLookup.h": keyword decision tree used by the lexer
1134 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/KeywordLookup.h
1135 MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/KeywordLookupGenerator.py
1136 DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/parser/Keywords.table
1137 COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/KeywordLookupGenerator.py ${CMAKE_CURRENT_SOURCE_DIR}/parser/Keywords.table > ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/KeywordLookup.h
1139 ADD_SOURCE_DEPENDENCIES(${CMAKE_CURRENT_SOURCE_DIR}/parser/Lexer.cpp ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/KeywordLookup.h)
1142 # Inspector Interfaces
1144 set(JavaScriptCore_INSPECTOR_SCRIPTS_DIR "${JAVASCRIPTCORE_DIR}/inspector/scripts")
1146 set(JavaScriptCore_INSPECTOR_PROTOCOL_SCRIPTS
1147 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/generate-inspector-protocol-bindings.py
1148 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/cpp_generator.py
1149 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/cpp_generator_templates.py
1150 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/generate_js_backend_commands.py
1151 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/generate_cpp_backend_dispatcher_header.py
1152 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/generate_cpp_backend_dispatcher_implementation.py
1153 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/generate_cpp_frontend_dispatcher_header.py
1154 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/generate_cpp_frontend_dispatcher_implementation.py
1155 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/generate_cpp_protocol_types_header.py
1156 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/generate_cpp_protocol_types_implementation.py
1157 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/generator.py
1158 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/generator_templates.py
1159 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/__init__.py
1160 ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/codegen/models.py
1163 set(JavaScriptCore_INSPECTOR_DOMAINS
1164 ${JAVASCRIPTCORE_DIR}/inspector/protocol/ApplicationCache.json
1165 ${JAVASCRIPTCORE_DIR}/inspector/protocol/CSS.json
1166 ${JAVASCRIPTCORE_DIR}/inspector/protocol/Console.json
1167 ${JAVASCRIPTCORE_DIR}/inspector/protocol/DOM.json
1168 ${JAVASCRIPTCORE_DIR}/inspector/protocol/DOMDebugger.json
1169 ${JAVASCRIPTCORE_DIR}/inspector/protocol/DOMStorage.json
1170 ${JAVASCRIPTCORE_DIR}/inspector/protocol/Database.json
1171 ${JAVASCRIPTCORE_DIR}/inspector/protocol/Debugger.json
1172 ${JAVASCRIPTCORE_DIR}/inspector/protocol/GenericTypes.json
1173 ${JAVASCRIPTCORE_DIR}/inspector/protocol/Heap.json
1174 ${JAVASCRIPTCORE_DIR}/inspector/protocol/Inspector.json
1175 ${JAVASCRIPTCORE_DIR}/inspector/protocol/LayerTree.json
1176 ${JAVASCRIPTCORE_DIR}/inspector/protocol/Network.json
1177 ${JAVASCRIPTCORE_DIR}/inspector/protocol/OverlayTypes.json
1178 ${JAVASCRIPTCORE_DIR}/inspector/protocol/Page.json
1179 ${JAVASCRIPTCORE_DIR}/inspector/protocol/Runtime.json
1180 ${JAVASCRIPTCORE_DIR}/inspector/protocol/ScriptProfiler.json
1181 ${JAVASCRIPTCORE_DIR}/inspector/protocol/Timeline.json
1184 if (ENABLE_INDEXED_DATABASE)
1185 list(APPEND JavaScriptCore_INSPECTOR_DOMAINS
1186 ${JAVASCRIPTCORE_DIR}/inspector/protocol/IndexedDB.json
1190 if (ENABLE_WEB_REPLAY)
1191 list(APPEND JavaScriptCore_INSPECTOR_DOMAINS
1192 ${JAVASCRIPTCORE_DIR}/inspector/protocol/Replay.json
1197 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/CombinedDomains.json
1198 MAIN_DEPENDENCY ${JavaScriptCore_SCRIPTS_DIR}/generate-combined-inspector-json.py
1199 DEPENDS ${JavaScriptCore_INSPECTOR_DOMAINS}
1200 COMMAND ${PYTHON_EXECUTABLE} ${JavaScriptCore_SCRIPTS_DIR}/generate-combined-inspector-json.py ${JavaScriptCore_INSPECTOR_DOMAINS} > ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/CombinedDomains.json
1203 # Inspector Backend Dispatchers, Frontend Dispatchers, Type Builders
1204 file(MAKE_DIRECTORY ${DERIVED_SOURCES_WEBINSPECTORUI_DIR}/UserInterface/Protocol)
1205 file(MAKE_DIRECTORY ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector)
1207 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorBackendDispatchers.cpp
1208 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorBackendDispatchers.h
1209 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorFrontendDispatchers.cpp
1210 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorFrontendDispatchers.h
1211 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorProtocolObjects.cpp
1212 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorProtocolObjects.h
1213 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorBackendCommands.js
1214 MAIN_DEPENDENCY ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/CombinedDomains.json
1215 DEPENDS ${JavaScriptCore_INSPECTOR_PROTOCOL_SCRIPTS}
1216 COMMAND ${PYTHON_EXECUTABLE} ${JavaScriptCore_INSPECTOR_SCRIPTS_DIR}/generate-inspector-protocol-bindings.py --outputDir "${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector" --framework JavaScriptCore ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/CombinedDomains.json
1221 set(BUILTINS_GENERATOR_SCRIPTS
1222 ${JavaScriptCore_SCRIPTS_DIR}/builtins.py
1223 ${JavaScriptCore_SCRIPTS_DIR}/builtins_generator.py
1224 ${JavaScriptCore_SCRIPTS_DIR}/builtins_model.py
1225 ${JavaScriptCore_SCRIPTS_DIR}/builtins_templates.py
1226 ${JavaScriptCore_SCRIPTS_DIR}/builtins_generate_combined_header.py
1227 ${JavaScriptCore_SCRIPTS_DIR}/builtins_generate_combined_implementation.py
1228 ${JavaScriptCore_SCRIPTS_DIR}/builtins_generate_separate_header.py
1229 ${JavaScriptCore_SCRIPTS_DIR}/builtins_generate_separate_implementation.py
1230 ${JavaScriptCore_SCRIPTS_DIR}/generate-js-builtins.py
1231 ${JavaScriptCore_SCRIPTS_DIR}/lazywriter.py
1234 set(JavaScriptCore_BUILTINS_SOURCES
1235 ${JAVASCRIPTCORE_DIR}/builtins/ArrayConstructor.js
1236 ${JAVASCRIPTCORE_DIR}/builtins/ArrayIteratorPrototype.js
1237 ${JAVASCRIPTCORE_DIR}/builtins/ArrayPrototype.js
1238 ${JAVASCRIPTCORE_DIR}/builtins/FunctionPrototype.js
1239 ${JAVASCRIPTCORE_DIR}/builtins/GeneratorPrototype.js
1240 ${JAVASCRIPTCORE_DIR}/builtins/GlobalObject.js
1241 ${JAVASCRIPTCORE_DIR}/builtins/InspectorInstrumentationObject.js
1242 ${JAVASCRIPTCORE_DIR}/builtins/InternalPromiseConstructor.js
1243 ${JAVASCRIPTCORE_DIR}/builtins/IteratorPrototype.js
1244 ${JAVASCRIPTCORE_DIR}/builtins/ModuleLoaderObject.js
1245 ${JAVASCRIPTCORE_DIR}/builtins/NumberPrototype.js
1246 ${JAVASCRIPTCORE_DIR}/builtins/ObjectConstructor.js
1247 ${JAVASCRIPTCORE_DIR}/builtins/PromiseConstructor.js
1248 ${JAVASCRIPTCORE_DIR}/builtins/PromiseOperations.js
1249 ${JAVASCRIPTCORE_DIR}/builtins/PromisePrototype.js
1250 ${JAVASCRIPTCORE_DIR}/builtins/ReflectObject.js
1251 ${JAVASCRIPTCORE_DIR}/builtins/StringConstructor.js
1252 ${JAVASCRIPTCORE_DIR}/builtins/StringIteratorPrototype.js
1253 ${JAVASCRIPTCORE_DIR}/builtins/TypedArrayConstructor.js
1254 ${JAVASCRIPTCORE_DIR}/builtins/TypedArrayPrototype.js
1258 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/AirOpcode.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/AirOpcodeGenerated.h
1259 MAIN_DEPENDENCY ${JAVASCRIPTCORE_DIR}/b3/air/AirOpcode.opcodes
1260 DEPENDS ${JAVASCRIPTCORE_DIR}/b3/air/opcode_generator.rb
1261 COMMAND ${RUBY_EXECUTABLE} ${JAVASCRIPTCORE_DIR}/b3/air/opcode_generator.rb ${JAVASCRIPTCORE_DIR}/b3/air/AirOpcode.opcodes VERBATIM
1262 WORKING_DIRECTORY ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}
1265 list(APPEND JavaScriptCore_SOURCES
1266 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/AirOpcode.h
1267 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/AirOpcodeGenerated.h
1271 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/JSCBuiltins.cpp ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/JSCBuiltins.h
1272 MAIN_DEPENDENCY ${JavaScriptCore_SCRIPTS_DIR}/generate-js-builtins.py
1273 DEPENDS ${JavaScriptCore_BUILTINS_SOURCES} ${BUILTINS_GENERATOR_SCRIPTS}
1274 COMMAND ${PYTHON_EXECUTABLE} ${JavaScriptCore_SCRIPTS_DIR}/generate-js-builtins.py --framework JavaScriptCore --output-directory ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR} --combined ${JavaScriptCore_BUILTINS_SOURCES}
1277 list(APPEND JavaScriptCore_SOURCES
1278 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorBackendDispatchers.cpp
1279 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorFrontendDispatchers.cpp
1280 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorProtocolObjects.cpp
1281 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/JSCBuiltins.cpp
1284 list(APPEND JavaScriptCore_HEADERS
1285 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorBackendDispatchers.h
1286 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorFrontendDispatchers.h
1287 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorProtocolObjects.h
1288 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/JSCBuiltins.h
1292 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InjectedScriptSource.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InjectedScriptSource.min.js
1293 MAIN_DEPENDENCY ${JAVASCRIPTCORE_DIR}/inspector/InjectedScriptSource.js
1294 DEPENDS ${JavaScriptCore_SCRIPTS_DIR}/xxd.pl ${JavaScriptCore_SCRIPTS_DIR}/jsmin.py
1295 COMMAND ${CMAKE_COMMAND} -E echo "//# sourceURL=__WebInspectorInjectedScript__" > ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InjectedScriptSource.min.js
1296 COMMAND ${PYTHON_EXECUTABLE} ${JavaScriptCore_SCRIPTS_DIR}/jsmin.py < ${JAVASCRIPTCORE_DIR}/inspector/InjectedScriptSource.js >> ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InjectedScriptSource.min.js
1297 COMMAND ${PERL_EXECUTABLE} ${JavaScriptCore_SCRIPTS_DIR}/xxd.pl InjectedScriptSource_js ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InjectedScriptSource.min.js ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InjectedScriptSource.h
1300 list(APPEND JavaScriptCore_HEADERS ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InjectedScriptSource.h)
1302 # Web Replay inputs generator
1303 if (ENABLE_WEB_REPLAY)
1304 set(JavaScript_WEB_REPLAY_INPUTS ${CMAKE_CURRENT_SOURCE_DIR}/replay/JSInputs.json)
1306 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/JSReplayInputs.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/JSReplayInputs.cpp
1307 MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/replay/scripts/CodeGeneratorReplayInputs.py
1308 DEPENDS ${JavaScript_WEB_REPLAY_INPUTS}
1309 COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/replay/scripts/CodeGeneratorReplayInputs.py --outputDir ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/ --framework JavaScriptCore ${JavaScript_WEB_REPLAY_INPUTS}
1312 list(APPEND JavaScriptCore_SOURCES
1313 replay/EncodedValue.cpp
1314 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/JSReplayInputs.cpp
1316 list(APPEND JavaScriptCore_HEADERS ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/JSReplayInputs.h)
1320 elseif (WTF_CPU_ARM64)
1321 elseif (WTF_CPU_HPPA)
1322 elseif (WTF_CPU_PPC)
1323 elseif (WTF_CPU_PPC64)
1324 elseif (WTF_CPU_PPC64LE)
1325 elseif (WTF_CPU_S390)
1326 elseif (WTF_CPU_S390X)
1327 elseif (WTF_CPU_MIPS)
1328 elseif (WTF_CPU_SH4)
1329 elseif (WTF_CPU_X86)
1330 elseif (WTF_CPU_X86_64)
1331 if (MSVC AND ENABLE_JIT)
1333 OUTPUT ${DERIVED_SOURCES_DIR}/JITStubsMSVC64.obj
1334 MAIN_DEPENDENCY ${JAVASCRIPTCORE_DIR}/jit/JITStubsMSVC64.asm
1335 COMMAND ml64 -nologo -c -Fo ${DERIVED_SOURCES_DIR}/JITStubsMSVC64.obj ${JAVASCRIPTCORE_DIR}/jit/JITStubsMSVC64.asm
1338 list(APPEND JavaScriptCore_SOURCES ${DERIVED_SOURCES_DIR}/JITStubsMSVC64.obj)
1341 message(FATAL_ERROR "Unknown CPU")
1345 WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
1347 WEBKIT_CREATE_FORWARDING_HEADERS(JavaScriptCore DIRECTORIES ${JavaScriptCore_FORWARDING_HEADERS_DIRECTORIES} FILES ${JavaScriptCore_FORWARDING_HEADERS_FILES})
1350 add_subdirectory(shell)
1352 WEBKIT_WRAP_SOURCELIST(${JavaScriptCore_SOURCES})
1353 include_directories(${JavaScriptCore_INCLUDE_DIRECTORIES})
1354 include_directories(SYSTEM ${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES})
1355 add_library(JavaScriptCore ${JavaScriptCore_LIBRARY_TYPE} ${JavaScriptCore_HEADERS} ${JavaScriptCore_SOURCES})
1356 target_link_libraries(JavaScriptCore ${JavaScriptCore_LIBRARIES})
1357 set_target_properties(JavaScriptCore PROPERTIES COMPILE_DEFINITIONS "BUILDING_JavaScriptCore")
1358 set_target_properties(JavaScriptCore PROPERTIES FOLDER "JavaScriptCore")
1360 if (JavaScriptCore_POST_BUILD_COMMAND)
1361 add_custom_command(TARGET JavaScriptCore POST_BUILD COMMAND ${JavaScriptCore_POST_BUILD_COMMAND} VERBATIM)
1364 if (JavaScriptCore_OUTPUT_NAME)
1365 set_target_properties(JavaScriptCore PROPERTIES OUTPUT_NAME ${JavaScriptCore_OUTPUT_NAME})
1368 if (${JavaScriptCore_LIBRARY_TYPE} STREQUAL "SHARED")
1369 POPULATE_LIBRARY_VERSION(JAVASCRIPTCORE)
1370 set_target_properties(JavaScriptCore PROPERTIES VERSION ${JAVASCRIPTCORE_VERSION} SOVERSION ${JAVASCRIPTCORE_VERSION_MAJOR})
1371 install(TARGETS JavaScriptCore DESTINATION "${LIB_INSTALL_DIR}")
1375 add_dependencies(JavaScriptCore llvmForJSC)
1378 # Force staging of shared scripts, even if they aren't directly used to build JavaScriptCore.
1380 add_custom_target(stageSharedScripts DEPENDS ${JavaScriptCore_SCRIPTS})
1381 add_dependencies(JavaScriptCore stageSharedScripts)
1383 WEBKIT_FRAMEWORK(JavaScriptCore)