Diff
Modified: trunk/ChangeLog (188238 => 188239)
--- trunk/ChangeLog 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/ChangeLog 2015-08-11 00:09:07 UTC (rev 188239)
@@ -1,3 +1,13 @@
+2015-08-10 Alex Christensen <achristen...@webkit.org>
+
+ Build TestWebKitAPI with CMake on Windows
+ https://bugs.webkit.org/show_bug.cgi?id=147851
+
+ Reviewed by Chris Dumez.
+
+ * Source/cmake/OptionsWindows.cmake:
+ Enable api tests and set USE_SYSTEM_MALLOC to avoid warnings when redefining it.
+
2015-08-06 Alex Christensen <achristen...@webkit.org>
[Win] CMake build fix after r188098.
Modified: trunk/Source/ThirdParty/ChangeLog (188238 => 188239)
--- trunk/Source/ThirdParty/ChangeLog 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Source/ThirdParty/ChangeLog 2015-08-11 00:09:07 UTC (rev 188239)
@@ -1,3 +1,13 @@
+2015-08-10 Alex Christensen <achristen...@webkit.org>
+
+ Build TestWebKitAPI with CMake on Windows
+ https://bugs.webkit.org/show_bug.cgi?id=147851
+
+ Reviewed by Chris Dumez.
+
+ * gtest/CMakeLists.txt:
+ Include DerivedSources to find WTF/WTFHeaderDetection.h.
+
2015-05-26 Dan Bernstein <m...@apple.com>
<rdar://problem/21104551> Update build settings
Modified: trunk/Source/ThirdParty/gtest/CMakeLists.txt (188238 => 188239)
--- trunk/Source/ThirdParty/gtest/CMakeLists.txt 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Source/ThirdParty/gtest/CMakeLists.txt 2015-08-11 00:09:07 UTC (rev 188239)
@@ -9,6 +9,7 @@
"${GTEST_DIR}"
"${GTEST_DIR}/include"
"${_javascript_CORE_DIR}"
+ "${DERIVED_SOURCES_DIR}"
"${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}"
"${WTF_DIR}"
)
Modified: trunk/Source/WebCore/ChangeLog (188238 => 188239)
--- trunk/Source/WebCore/ChangeLog 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Source/WebCore/ChangeLog 2015-08-11 00:09:07 UTC (rev 188239)
@@ -1,3 +1,15 @@
+2015-08-10 Alex Christensen <achristen...@webkit.org>
+
+ Build TestWebKitAPI with CMake on Windows
+ https://bugs.webkit.org/show_bug.cgi?id=147851
+
+ Reviewed by Chris Dumez.
+
+ * PlatformWin.cmake:
+ Remove RenderThemeWin.cpp which is included in RenderingAllInOne.cpp.
+ * WebCorePrefix.h:
+ Include cmakeconfig.h before wtf/Platform.h like we do in _javascript_Core's config.h to avoid warnings and redefining ENABLE_* macros.
+
2015-08-10 Matthew Daiter <mdai...@apple.com>
HTMLMediaElement needs way to find MediaDeviceInfo
Modified: trunk/Source/WebCore/PlatformWin.cmake (188238 => 188239)
--- trunk/Source/WebCore/PlatformWin.cmake 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Source/WebCore/PlatformWin.cmake 2015-08-11 00:09:07 UTC (rev 188239)
@@ -120,8 +120,6 @@
platform/win/WheelEventWin.cpp
platform/win/WidgetWin.cpp
platform/win/WindowMessageBroadcaster.cpp
-
- rendering/RenderThemeWin.cpp
)
list(APPEND WebCore_USER_AGENT_STYLE_SHEETS
Modified: trunk/Source/WebCore/WebCorePrefix.h (188238 => 188239)
--- trunk/Source/WebCore/WebCorePrefix.h 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Source/WebCore/WebCorePrefix.h 2015-08-11 00:09:07 UTC (rev 188239)
@@ -27,6 +27,10 @@
/* Things that need to be defined globally should go into "config.h". */
+#if defined(HAVE_CONFIG_H) && HAVE_CONFIG_H && defined(BUILDING_WITH_CMAKE)
+#include "cmakeconfig.h"
+#endif
+
#include <wtf/Platform.h>
#if defined(__APPLE__)
Modified: trunk/Source/WebKit/ChangeLog (188238 => 188239)
--- trunk/Source/WebKit/ChangeLog 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Source/WebKit/ChangeLog 2015-08-11 00:09:07 UTC (rev 188239)
@@ -1,3 +1,14 @@
+2015-08-10 Alex Christensen <achristen...@webkit.org>
+
+ Build TestWebKitAPI with CMake on Windows
+ https://bugs.webkit.org/show_bug.cgi?id=147851
+
+ Reviewed by Chris Dumez.
+
+ * PlatformWin.cmake:
+ WinCairo libraries conflict with LIBCMT.lib, AppleWin libraries conflict with MSVCRT.lib,
+ so different /NODEFAULTLIB is needed to link WebKit.dll successfully.
+
2015-08-06 Alex Christensen <achristen...@webkit.org>
[Win] Enable all Windows features in CMake
Modified: trunk/Source/WebKit/PlatformWin.cmake (188238 => 188239)
--- trunk/Source/WebKit/PlatformWin.cmake 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Source/WebKit/PlatformWin.cmake 2015-08-11 00:09:07 UTC (rev 188239)
@@ -444,7 +444,11 @@
list(APPEND WebKit_LIBRARIES ${CXX_LIBS})
set(CMAKE_CXX_STANDARD_LIBRARIES "")
-set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /NODEFAULTLIB:LIBCMT")
+if (${WTF_PLATFORM_WIN_CAIRO})
+ set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /NODEFAULTLIB:LIBCMT")
+else ()
+ set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /NODEFAULTLIB:MSVCRT")
+endif ()
# If this directory isn't created before midl runs and attempts to output WebKit.tlb,
# It fails with an unusual error - midl failed - failed to save all changes
Modified: trunk/Source/cmake/OptionsWindows.cmake (188238 => 188239)
--- trunk/Source/cmake/OptionsWindows.cmake 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Source/cmake/OptionsWindows.cmake 2015-08-11 00:09:07 UTC (rev 188239)
@@ -5,6 +5,7 @@
WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_ACCELERATED_2D_CANVAS PUBLIC OFF)
WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_ACCELERATED_OVERFLOW_SCROLLING PUBLIC OFF)
WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_ALLINONE_BUILD PUBLIC ON)
+WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_API_TESTS PUBLIC ON)
WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_ATTACHMENT_ELEMENT PUBLIC ON)
WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_CANVAS_PATH PUBLIC ON)
WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_CANVAS_PROXY PUBLIC OFF)
@@ -94,6 +95,8 @@
WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_XHR_TIMEOUT PUBLIC ON)
WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_XSLT PUBLIC ON)
+WEBKIT_OPTION_DEFAULT_PORT_VALUE(USE_SYSTEM_MALLOC PRIVATE ON)
+
if (${WTF_PLATFORM_WIN_CAIRO})
WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_ENCRYPTED_MEDIA_V2 PUBLIC OFF)
WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_WEBGL PUBLIC ON)
Modified: trunk/Tools/CMakeLists.txt (188238 => 188239)
--- trunk/Tools/CMakeLists.txt 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Tools/CMakeLists.txt 2015-08-11 00:09:07 UTC (rev 188239)
@@ -29,6 +29,7 @@
if (WIN32)
add_subdirectory(DumpRenderTree)
+ add_subdirectory(TestWebKitAPI)
add_subdirectory(WinLauncher)
endif ()
Modified: trunk/Tools/ChangeLog (188238 => 188239)
--- trunk/Tools/ChangeLog 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Tools/ChangeLog 2015-08-11 00:09:07 UTC (rev 188239)
@@ -1,3 +1,28 @@
+2015-08-10 Alex Christensen <achristen...@webkit.org>
+
+ Build TestWebKitAPI with CMake on Windows
+ https://bugs.webkit.org/show_bug.cgi?id=147851
+
+ Reviewed by Chris Dumez.
+
+ * CMakeLists.txt:
+ * TestWebKitAPI/CMakeLists.txt:
+ Removed TestJavaScriptCore because _javascript_Core's API tests are elsewhere and this was just making an empty binary.
+ Surrounded WebKit2-specific features with ENABLE_WEBKIT2 checks.
+ Include directories after the Platform*.cmake is included because HostWindow.h needs to be found in Tools/TestWebKitAPI/win
+ before we look in Source/WebCore/platform, where another file named HostWindow.h exists.
+ * TestWebKitAPI/PlatformEfl.cmake:
+ * TestWebKitAPI/PlatformGTK.cmake:
+ Windows needs all the binaries to be in the same directory to find gtest.dll and the other dlls.
+ I did this without changing the directory structure of the existing EFL and GTK builds.
+ * TestWebKitAPI/PlatformWin.cmake: Added.
+ * TestWebKitAPI/win/main.cpp:
+ (main):
+ (dllLauncherEntryPoint):
+ Added so we can launch TestWebKitAPI executables after finding the AAS directory.
+ * WinLauncher/CMakeLists.txt:
+ AppleWin port needs /NODEFAULTLIB:MSVCRT.
+
2015-08-10 Dewei Zhu <dewei_...@apple.com>
Make cleanup more robust and minor code cleaning in run benchmark script.
Modified: trunk/Tools/TestWebKitAPI/CMakeLists.txt (188238 => 188239)
--- trunk/Tools/TestWebKitAPI/CMakeLists.txt 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Tools/TestWebKitAPI/CMakeLists.txt 2015-08-11 00:09:07 UTC (rev 188239)
@@ -1,38 +1,4 @@
set(TESTWEBKITAPI_DIR "${TOOLS_DIR}/TestWebKitAPI")
-set(TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/TestWebKitAPI")
-
-include_directories(${CMAKE_BINARY_DIR}
- ${TESTWEBKITAPI_DIR}
- ${CMAKE_SOURCE_DIR}/Source
- ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}
- ${DERIVED_SOURCES_WEBCORE_DIR}
- ${_javascript_CORE_DIR}
- ${_javascript_CORE_DIR}/API
- ${_javascript_CORE_DIR}/ForwardingHeaders
- ${THIRDPARTY_DIR}/gtest/include
- ${WEBCORE_DIR}/css
- ${WEBCORE_DIR}/dom
- ${WEBCORE_DIR}/editing
- ${WEBCORE_DIR}/loader/cache
- ${WEBCORE_DIR}/platform
- ${WEBCORE_DIR}/platform/animation
- ${WEBCORE_DIR}/platform/graphics
- ${WEBCORE_DIR}/platform/text
- ${WEBCORE_DIR}/platform/network
- ${WEBCORE_DIR}/platform/network/soup
- ${WEBCORE_DIR}/rendering/style
- ${WEBKIT2_DIR}/Platform/IPC
- ${WEBKIT2_DIR}/Shared
- ${WEBKIT2_DIR}/Shared/API
- ${WEBKIT2_DIR}/Shared/API/c
- ${WEBKIT2_DIR}/Shared/Plugins
- ${WEBKIT2_DIR}/UIProcess
- ${WEBKIT2_DIR}/UIProcess/API
- ${WEBKIT2_DIR}/WebProcess/InjectedBundle
- ${WEBKIT2_DIR}/WebProcess/InjectedBundle/API/c
- ${WTF_DIR}
-)
-
set(test_wtf_LIBRARIES
WTF
gtest
@@ -44,19 +10,28 @@
gtest
)
-set(test_webkit2_api_LIBRARIES
- _javascript_Core
- TestWebKitAPIBase
- WTF
- WebKit2
- gtest
-)
-
set(TestWebKitAPI_LIBRARIES
WTF
- WebKit2
)
+if (ENABLE_WEBKIT2)
+ set(test_webkit2_api_LIBRARIES
+ _javascript_Core
+ TestWebKitAPIBase
+ WTF
+ WebKit2
+ gtest
+ )
+ list(APPEND TestWebKitAPI_LIBRARIES
+ WebKit2
+ )
+else ()
+ list(APPEND TestWebKitAPI_LIBRARIES
+ WebKit
+ )
+endif ()
+
+
set(TestJavaScriptCore_LIBRARIES
_javascript_Core
gtest
@@ -99,41 +74,76 @@
WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
-add_library(TestWebKitAPIInjectedBundle SHARED
- ${bundle_harness_SOURCES}
- ${TESTWEBKITAPI_DIR}/InjectedBundleController.cpp
- ${TESTWEBKITAPI_DIR}/InjectedBundleMain.cpp
- ${TESTWEBKITAPI_DIR}/PlatformUtilities.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/CanHandleRequest_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/DidAssociateFormControls_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/DOMWindowExtensionBasic_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/DOMWindowExtensionNoCache_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/DocumentStartUserScriptAlertCrash_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/GetInjectedBundleInitializationUserDataCallback_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/HitTestResultNodeHandle_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/InjectedBundleBasic_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/InjectedBundleFrameHitTest_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/InjectedBundleInitializationUserDataCallbackWins_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/LoadCanceledNoServerRedirectCallback_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/MouseMoveAfterCrash_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/NewFirstVisuallyNonEmptyLayoutFails_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/NewFirstVisuallyNonEmptyLayoutForImages_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/NewFirstVisuallyNonEmptyLayoutFrames_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/NewFirstVisuallyNonEmptyLayout_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/ParentFrame_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/ResponsivenessTimerDoesntFireEarly_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/ShouldGoToBackForwardListItem_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/TextFieldDidBeginAndEndEditing_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/UserMessage_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/WillLoad_Bundle.cpp
- ${TESTWEBKITAPI_DIR}/Tests/WebKit2/WillSendSubmitEvent_Bundle.cpp
+include_directories(
+ ${TESTWEBKITAPI_DIR}
+ ${CMAKE_BINARY_DIR}
+ ${CMAKE_SOURCE_DIR}/Source
+ ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}
+ ${DERIVED_SOURCES_WEBCORE_DIR}
+ ${_javascript_CORE_DIR}
+ ${_javascript_CORE_DIR}/API
+ ${_javascript_CORE_DIR}/ForwardingHeaders
+ ${THIRDPARTY_DIR}/gtest/include
+ ${WEBCORE_DIR}/css
+ ${WEBCORE_DIR}/dom
+ ${WEBCORE_DIR}/editing
+ ${WEBCORE_DIR}/loader/cache
+ ${WEBCORE_DIR}/platform
+ ${WEBCORE_DIR}/platform/animation
+ ${WEBCORE_DIR}/platform/graphics
+ ${WEBCORE_DIR}/platform/text
+ ${WEBCORE_DIR}/platform/network
+ ${WEBCORE_DIR}/platform/network/soup
+ ${WEBCORE_DIR}/rendering/style
+ ${WEBKIT2_DIR}/Platform/IPC
+ ${WEBKIT2_DIR}/Shared
+ ${WEBKIT2_DIR}/Shared/API
+ ${WEBKIT2_DIR}/Shared/API/c
+ ${WEBKIT2_DIR}/Shared/Plugins
+ ${WEBKIT2_DIR}/UIProcess
+ ${WEBKIT2_DIR}/UIProcess/API
+ ${WEBKIT2_DIR}/WebProcess/InjectedBundle
+ ${WEBKIT2_DIR}/WebProcess/InjectedBundle/API/c
+ ${WTF_DIR}
)
-target_link_libraries(TestWebKitAPIInjectedBundle ${TestWebKitAPI_LIBRARIES})
-add_dependencies(TestWebKitAPIInjectedBundle ${ForwardingHeadersForTestWebKitAPI_NAME})
+if (ENABLE_WEBKIT2)
+ add_library(TestWebKitAPIInjectedBundle SHARED
+ ${bundle_harness_SOURCES}
+ ${TESTWEBKITAPI_DIR}/InjectedBundleController.cpp
+ ${TESTWEBKITAPI_DIR}/InjectedBundleMain.cpp
+ ${TESTWEBKITAPI_DIR}/PlatformUtilities.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/CanHandleRequest_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/DidAssociateFormControls_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/DOMWindowExtensionBasic_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/DOMWindowExtensionNoCache_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/DocumentStartUserScriptAlertCrash_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/GetInjectedBundleInitializationUserDataCallback_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/HitTestResultNodeHandle_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/InjectedBundleBasic_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/InjectedBundleFrameHitTest_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/InjectedBundleInitializationUserDataCallbackWins_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/LoadCanceledNoServerRedirectCallback_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/MouseMoveAfterCrash_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/NewFirstVisuallyNonEmptyLayoutFails_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/NewFirstVisuallyNonEmptyLayoutForImages_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/NewFirstVisuallyNonEmptyLayoutFrames_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/NewFirstVisuallyNonEmptyLayout_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/ParentFrame_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/ResponsivenessTimerDoesntFireEarly_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/ShouldGoToBackForwardListItem_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/TextFieldDidBeginAndEndEditing_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/UserMessage_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/WillLoad_Bundle.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit2/WillSendSubmitEvent_Bundle.cpp
+ )
-get_property(TestWebKitAPIInjectedBundle_PATH TARGET TestWebKitAPIInjectedBundle PROPERTY LOCATION)
+ target_link_libraries(TestWebKitAPIInjectedBundle ${TestWebKitAPI_LIBRARIES})
+ add_dependencies(TestWebKitAPIInjectedBundle ${ForwardingHeadersForTestWebKitAPI_NAME})
+ get_property(TestWebKitAPIInjectedBundle_PATH TARGET TestWebKitAPIInjectedBundle PROPERTY LOCATION)
+endif ()
+
add_definitions(-DGTEST_LINKED_AS_SHARED_LIBRARY=1 -DGTEST_HAS_RTTI=0
-DTEST_WEBKIT2_RESOURCES_DIR=\"${TESTWEBKITAPI_DIR}/Tests/WebKit2\"
-DTEST_INJECTED_BUNDLE_PATH=\"${TestWebKitAPIInjectedBundle_PATH}\"
@@ -151,27 +161,14 @@
)
target_link_libraries(TestWTF ${test_wtf_LIBRARIES})
-add_dependencies(TestWTF ${ForwardingHeadersForTestWebKitAPI_NAME} ${ForwardingNetworkHeadersForTestWebKitAPI_NAME})
-add_test(TestWTF ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WTF/TestWTF)
+add_dependencies(TestWTF WTF ${ForwardingHeadersForTestWebKitAPI_NAME} ${ForwardingNetworkHeadersForTestWebKitAPI_NAME})
+add_test(TestWTF ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY_WTF}/TestWTF)
set_tests_properties(TestWTF PROPERTIES TIMEOUT 60)
- set_target_properties(TestWTF PROPERTIES
- RUNTIME_OUTPUT_DIRECTORY ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WTF
- )
-
-
-add_executable(TestJavaScriptCore
- ${test_main_SOURCES}
- ${TESTWEBKITAPI_DIR}/TestsController.cpp
+set_target_properties(TestWTF PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY_WTF}
)
-target_link_libraries(TestJavaScriptCore ${TestJavaScriptCore_LIBRARIES})
-add_dependencies(TestJavaScriptCore ${ForwardingHeadersForTestWebKitAPI_NAME})
-
-add_test(TestJavaScriptCore ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/_javascript_Core/TestJavaScriptCore)
-set_tests_properties(TestJavaScriptCore PROPERTIES TIMEOUT 60)
-set_target_properties(TestJavaScriptCore PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/_javascript_Core)
-add_dependencies(TestJavaScriptCore _javascript_Core ${ForwardingHeadersForTestWebKitAPI_NAME} ${ForwardingNetworkHeadersForTestWebKitAPI_NAME})
-
+# FIXME: EFL is the only port that separates the WebCore binaries. Each port ought to do closer to the same thing.
foreach (testName ${test_webcore_BINARIES})
add_executable(${testName} ${test_main_SOURCES} ${TESTWEBKITAPI_DIR}/TestsController.cpp ${TESTWEBKITAPI_DIR}/Tests/WebCore/${testName}.cpp)
add_test(${testName} ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WebCore/${testName})
@@ -182,34 +179,36 @@
)
endforeach ()
-add_library(TestWebKitAPIBase
- ${test_main_SOURCES}
- ${webkit2_api_harness_SOURCES}
- ${TESTWEBKITAPI_DIR}/_javascript_Test.cpp
- ${TESTWEBKITAPI_DIR}/PlatformUtilities.cpp
- ${TESTWEBKITAPI_DIR}/TestsController.cpp
-)
+if (ENABLE_WEBKIT2)
+ add_library(TestWebKitAPIBase
+ ${test_main_SOURCES}
+ ${webkit2_api_harness_SOURCES}
+ ${TESTWEBKITAPI_DIR}/_javascript_Test.cpp
+ ${TESTWEBKITAPI_DIR}/PlatformUtilities.cpp
+ ${TESTWEBKITAPI_DIR}/TestsController.cpp
+ )
-add_dependencies(TestWebKitAPIBase WebKit2 ${ForwardingHeadersForTestWebKitAPI_NAME} ${ForwardingNetworkHeadersForTestWebKitAPI_NAME})
+ add_dependencies(TestWebKitAPIBase WebKit2 ${ForwardingHeadersForTestWebKitAPI_NAME} ${ForwardingNetworkHeadersForTestWebKitAPI_NAME})
-foreach (testName ${test_webkit2_api_BINARIES})
- get_filename_component(testBaseName ${testName} NAME)
- add_executable(${testBaseName} ${TESTWEBKITAPI_DIR}/Tests/WebKit2/${testName}.cpp)
- add_test(${testBaseName} ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WebKit2/${testBaseName})
- set_tests_properties(${testBaseName} PROPERTIES TIMEOUT 60)
- target_link_libraries(${testBaseName} ${test_webkit2_api_LIBRARIES})
- set_target_properties(${testBaseName} PROPERTIES
- RUNTIME_OUTPUT_DIRECTORY ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WebKit2
- )
-endforeach ()
+ foreach (testName ${test_webkit2_api_BINARIES})
+ get_filename_component(testBaseName ${testName} NAME)
+ add_executable(${testBaseName} ${TESTWEBKITAPI_DIR}/Tests/WebKit2/${testName}.cpp)
+ add_test(${testBaseName} ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WebKit2/${testBaseName})
+ set_tests_properties(${testBaseName} PROPERTIES TIMEOUT 60)
+ target_link_libraries(${testBaseName} ${test_webkit2_api_LIBRARIES})
+ set_target_properties(${testBaseName} PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WebKit2
+ )
+ endforeach ()
-# We don't run tests that are expected to fail. We could use the WILL_FAIL
-# property, but it reports failure when the test crashes or timeouts and would
-# make the bot red.
-foreach (testName ${test_webkit2_api_fail_BINARIES})
- add_executable(${testName} ${TESTWEBKITAPI_DIR}/Tests/WebKit2/${testName}.cpp)
- target_link_libraries(${testName} ${test_webkit2_api_LIBRARIES})
- set_target_properties(${testName} PROPERTIES
- RUNTIME_OUTPUT_DIRECTORY ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WebKit2/failure
- )
-endforeach ()
+ # We don't run tests that are expected to fail. We could use the WILL_FAIL
+ # property, but it reports failure when the test crashes or timeouts and would
+ # make the bot red.
+ foreach (testName ${test_webkit2_api_fail_BINARIES})
+ add_executable(${testName} ${TESTWEBKITAPI_DIR}/Tests/WebKit2/${testName}.cpp)
+ target_link_libraries(${testName} ${test_webkit2_api_LIBRARIES})
+ set_target_properties(${testName} PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WebKit2/failure
+ )
+ endforeach ()
+endif ()
Modified: trunk/Tools/TestWebKitAPI/PlatformEfl.cmake (188238 => 188239)
--- trunk/Tools/TestWebKitAPI/PlatformEfl.cmake 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Tools/TestWebKitAPI/PlatformEfl.cmake 2015-08-11 00:09:07 UTC (rev 188239)
@@ -1,3 +1,6 @@
+set(TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/TestWebKitAPI")
+set(TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY_WTF "${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WTF")
+
add_custom_target(forwarding-headersEflForTestWebKitAPI
COMMAND ${PERL_EXECUTABLE} ${WEBKIT2_DIR}/Scripts/generate-forwarding-headers.pl --include-path ${TESTWEBKITAPI_DIR} --output ${DERIVED_SOURCES_WEBKIT2_DIR}/include --platform efl --platform CoordinatedGraphics --platform soup
DEPENDS forwarding-headersEflForWebKit2
Modified: trunk/Tools/TestWebKitAPI/PlatformGTK.cmake (188238 => 188239)
--- trunk/Tools/TestWebKitAPI/PlatformGTK.cmake 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Tools/TestWebKitAPI/PlatformGTK.cmake 2015-08-11 00:09:07 UTC (rev 188239)
@@ -1,3 +1,6 @@
+set(TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/TestWebKitAPI")
+set(TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY_WTF "${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/WTF")
+
# This is necessary because it is possible to build TestWebKitAPI with WebKit2
# disabled and this triggers the inclusion of the WebKit2 headers.
add_definitions(-DBUILDING_WEBKIT2__)
Added: trunk/Tools/TestWebKitAPI/PlatformWin.cmake (0 => 188239)
--- trunk/Tools/TestWebKitAPI/PlatformWin.cmake (rev 0)
+++ trunk/Tools/TestWebKitAPI/PlatformWin.cmake 2015-08-11 00:09:07 UTC (rev 188239)
@@ -0,0 +1,96 @@
+set(TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}")
+set(TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY_WTF "${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}")
+add_definitions(-DUSE_CONSOLE_ENTRY_POINT)
+
+set(test_main_SOURCES
+ ${TESTWEBKITAPI_DIR}/win/main.cpp
+)
+
+include_directories(
+ ${DERIVED_SOURCES_DIR}
+ ${DERIVED_SOURCES_DIR}/ForwardingHeaders
+ ${TESTWEBKITAPI_DIR}/win
+)
+
+add_definitions(-DWEBCORE_EXPORT=)
+
+set(test_webcore_LIBRARIES
+ Crypt32
+ Iphlpapi
+ Shlwapi
+ Usp10
+ WebCore
+ WebKit
+ gtest
+)
+
+if (${WTF_PLATFORM_WIN_CAIRO})
+ list(APPEND test_webcore_LIBRARIES
+ cairo
+ curl
+ )
+else ()
+ list(APPEND test_webcore_LIBRARIES
+ CFNetwork
+ CoreMedia
+ WebKitSystemInterface
+ )
+endif ()
+
+add_library(TestWTFLib SHARED
+ ${test_main_SOURCES}
+ ${TestWTF_SOURCES}
+)
+set_target_properties(TestWTFLib PROPERTIES OUTPUT_NAME "TestWTF")
+target_link_libraries(TestWTFLib ${test_wtf_LIBRARIES})
+
+set(test_wtf_LIBRARIES
+ shlwapi
+)
+set(TestWTF_SOURCES
+)
+
+add_library(TestWebCoreLib SHARED
+ ${test_main_SOURCES}
+ ${TESTWEBKITAPI_DIR}/TestsController.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebCore/win/BitmapImage.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebCore/CalculationValue.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebCore/CSSParser.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebCore/LayoutUnit.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebCore/TimeRanges.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebCore/URL.cpp
+)
+
+target_link_libraries(TestWebCoreLib ${test_webcore_LIBRARIES})
+set_target_properties(TestWebCoreLib PROPERTIES OUTPUT_NAME "TestWebCore")
+
+add_executable(TestWebCore
+ ${TOOLS_DIR}/win/DLLLauncher/DLLLauncherMain.cpp
+)
+target_link_libraries(TestWebCore shlwapi)
+
+
+add_test(TestWebCore ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/TestWebCore)
+set_tests_properties(TestWebCore PROPERTIES TIMEOUT 60)
+
+add_library(TestWebKitLib SHARED
+ ${test_main_SOURCES}
+ ${TESTWEBKITAPI_DIR}/TestsController.cpp
+ ${TESTWEBKITAPI_DIR}/Tests/WebKit/win/WebViewDestruction.cpp
+ ${TESTWEBKITAPI_DIR}/win/HostWindow.cpp
+)
+
+target_link_libraries(TestWebKitLib ${test_webcore_LIBRARIES})
+set_target_properties(TestWebKitLib PROPERTIES OUTPUT_NAME "TestWebKit")
+
+add_executable(TestWebKit
+ ${TOOLS_DIR}/win/DLLLauncher/DLLLauncherMain.cpp
+)
+target_link_libraries(TestWebKit shlwapi)
+
+add_test(TestWebKit ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/TestWebKit)
+set_tests_properties(TestWebKit PROPERTIES TIMEOUT 60)
+
+set(test_main_SOURCES
+ ${TOOLS_DIR}/win/DLLLauncher/DLLLauncherMain.cpp
+)
Modified: trunk/Tools/TestWebKitAPI/win/main.cpp (188238 => 188239)
--- trunk/Tools/TestWebKitAPI/win/main.cpp 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Tools/TestWebKitAPI/win/main.cpp 2015-08-11 00:09:07 UTC (rev 188239)
@@ -63,3 +63,8 @@
return passed ? EXIT_SUCCESS : EXIT_FAILURE;
}
+
+extern "C" __declspec(dllexport) int WINAPI dllLauncherEntryPoint(int argc, char** argv)
+{
+ return main(argc, argv);
+}
Modified: trunk/Tools/WinLauncher/CMakeLists.txt (188238 => 188239)
--- trunk/Tools/WinLauncher/CMakeLists.txt 2015-08-10 23:56:51 UTC (rev 188238)
+++ trunk/Tools/WinLauncher/CMakeLists.txt 2015-08-11 00:09:07 UTC (rev 188239)
@@ -40,6 +40,7 @@
CFLite
)
else ()
+ set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /NODEFAULTLIB:MSVCRT")
list(APPEND WinLauncher_LIBRARIES
CoreFoundation
)