DFG::AbstractValue::validateOSREntry is wrong when isHeapTop and the incoming value...
[WebKit-https.git] / Source / JavaScriptCore / shell / CMakeLists.txt
1 set(JSC_SOURCES
2     ../jsc.cpp
3 )
4
5 set(JSC_LIBRARIES
6     ${CMAKE_DL_LIBS}
7     JavaScriptCore${DEBUG_SUFFIX}
8     WTF${DEBUG_SUFFIX}
9 )
10
11 if (WTF_OS_MAC_OS_X)
12     list(APPEND JSC_LIBRARIES edit)
13 endif ()
14
15 if ("${JavaScriptCore_LIBRARY_TYPE}" MATCHES "STATIC")
16     add_definitions(-DSTATICALLY_LINKED_WITH_JavaScriptCore)
17 endif ()
18
19 set(TESTAPI_SOURCES
20     ../API/tests/CompareAndSwapTest.cpp
21     ../API/tests/CustomGlobalObjectClassTest.c
22     ../API/tests/ExecutionTimeLimitTest.cpp
23     ../API/tests/FunctionOverridesTest.cpp
24     ../API/tests/GlobalContextWithFinalizerTest.cpp
25     ../API/tests/JSONParseTest.cpp
26     ../API/tests/JSObjectGetProxyTargetTest.cpp
27     ../API/tests/MultithreadedMultiVMExecutionTest.cpp
28     ../API/tests/PingPongStackOverflowTest.cpp
29     ../API/tests/TypedArrayCTest.cpp
30     ../API/tests/testapi.c
31     ../API/tests/testapi.cpp
32 )
33
34 WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
35
36 WEBKIT_WRAP_SOURCELIST(${JSC_SOURCES})
37 WEBKIT_WRAP_SOURCELIST(${TESTAPI_SOURCES})
38 include_directories(./ ${JavaScriptCore_INCLUDE_DIRECTORIES} ${JavaScriptCore_PRIVATE_INCLUDE_DIRECTORIES})
39 include_directories(SYSTEM ${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES})
40 add_executable(jsc ${JSC_SOURCES})
41 target_link_libraries(jsc ${JSC_LIBRARIES})
42
43 if (JSC_OUTPUT_NAME)
44     set_target_properties(jsc PROPERTIES OUTPUT_NAME ${JSC_OUTPUT_NAME})
45 endif ()
46
47 if (JSC_LINK_FLAGS)
48     WEBKIT_ADD_TARGET_PROPERTIES(jsc LINK_FLAGS "${JSC_LINK_FLAGS}")
49 endif ()
50
51 if (SHOULD_INSTALL_JS_SHELL)
52     install(TARGETS jsc DESTINATION "${LIBEXEC_INSTALL_DIR}")
53 endif ()
54
55 if (TARGET jscLib)
56     add_dependencies(jsc jscLib)
57 endif ()
58
59 set(TESTMASM_SOURCES
60     ../assembler/testmasm.cpp
61 )
62
63 set(TESTB3_SOURCES
64     ../b3/testb3.cpp
65 )
66
67 set(TESTAIR_SOURCES
68     ../b3/air/testair.cpp
69 )
70
71 set(TESTDFG_SOURCES
72     ../dfg/testdfg.cpp
73 )
74
75 if (DEVELOPER_MODE AND NOT WIN32)
76     add_executable(testmasm ${TESTMASM_SOURCES})
77     target_link_libraries(testmasm ${JSC_LIBRARIES})
78
79     add_executable(testb3 ${TESTB3_SOURCES})
80     target_link_libraries(testb3 ${JSC_LIBRARIES})
81
82     add_executable(testair ${TESTAIR_SOURCES})
83     target_link_libraries(testair ${JSC_LIBRARIES})
84
85     add_executable(testdfg ${TESTDFG_SOURCES})
86     target_link_libraries(testdfg ${JSC_LIBRARIES})
87
88     add_executable(testapi ${TESTAPI_SOURCES})
89     target_link_libraries(testapi ${JSC_LIBRARIES})
90 endif ()
91
92 file(COPY
93     "${JAVASCRIPTCORE_DIR}/API/tests/testapi.js"
94     DESTINATION
95     ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/testapiScripts
96 )
97 file(COPY
98     "${JAVASCRIPTCORE_DIR}/API/tests/testapi-function-overrides.js"
99     DESTINATION
100     ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/testapiScripts
101 )