[CMake][WTF] Mirror XCode header directories
authordon.olmstead@sony.com <don.olmstead@sony.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 3 Apr 2019 23:08:44 +0000 (23:08 +0000)
committerdon.olmstead@sony.com <don.olmstead@sony.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 3 Apr 2019 23:08:44 +0000 (23:08 +0000)
https://bugs.webkit.org/show_bug.cgi?id=191662

Reviewed by Konstantin Tokarev.

.:

Add WTF_FRAMEWORK_HEADERS_DIR to place WTF headers into. Add frameworks/WTF.cmake
which creates an interface target which will populate dependencies for consumers.
This file is added here to support AppleWin internal builds which invoke CMake on
each directory.

* Source/cmake/WebKitFS.cmake:
* Source/cmake/frameworks/WTF.cmake: Added.

Source/JavaScriptCore:

Use WTFFramework as a dependency and include frameworks/WTF.cmake for AppleWin internal
builds.

* CMakeLists.txt:
* shell/CMakeLists.txt:

Source/WebCore:

Use WTFFramework as a dependency and include frameworks/WTF.cmake for AppleWin internal
builds.

* CMakeLists.txt:
* PlatformWin.cmake:

Source/WebDriver:

Use WTFFramework as a dependency.

* CMakeLists.txt:

Source/WebKit:

Use WTFFramework as a dependency and include frameworks/WTF.cmake for AppleWin internal
builds.

* CMakeLists.txt:

Source/WebKitLegacy:

Use WTFFramework as a dependency and include frameworks/WTF.cmake for AppleWin internal
builds.

* CMakeLists.txt:
* PlatformWin.cmake:

Source/WebKitLegacy/win:

* WebKitQuartzCoreAdditions/CMakeLists.txt:

Source/WTF:

Rename WTF forwarding header target to WTFFramework and update the install location
to WTF_FRAMEWORK_HEADERS_DIR.

* wtf/CMakeLists.txt:

Tools:

Use WTFFramework as a dependency and include frameworks/WTF.cmake for AppleWin internal
builds.

* CMakeLists.txt:
* DumpRenderTree/CMakeLists.txt:
* DumpRenderTree/PlatformWin.cmake:
* MiniBrowser/win/CMakeLists.txt:
* TestWebKitAPI/CMakeLists.txt:
* TestWebKitAPI/PlatformWin.cmake:
* WebKitTestRunner/PlatformGTK.cmake:
* WebKitTestRunner/PlatformWin.cmake:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@243833 268f45cc-cd09-0410-ab3c-d52691b4dbfc

29 files changed:
ChangeLog
Source/JavaScriptCore/CMakeLists.txt
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/shell/CMakeLists.txt
Source/WTF/ChangeLog
Source/WTF/wtf/CMakeLists.txt
Source/WebCore/CMakeLists.txt
Source/WebCore/ChangeLog
Source/WebCore/PlatformWin.cmake
Source/WebDriver/CMakeLists.txt
Source/WebDriver/ChangeLog
Source/WebKit/CMakeLists.txt
Source/WebKit/ChangeLog
Source/WebKitLegacy/CMakeLists.txt
Source/WebKitLegacy/ChangeLog
Source/WebKitLegacy/PlatformWin.cmake
Source/WebKitLegacy/win/ChangeLog
Source/WebKitLegacy/win/WebKitQuartzCoreAdditions/CMakeLists.txt
Source/cmake/WebKitFS.cmake
Source/cmake/frameworks/WTF.cmake [new file with mode: 0644]
Tools/CMakeLists.txt
Tools/ChangeLog
Tools/DumpRenderTree/CMakeLists.txt
Tools/DumpRenderTree/PlatformWin.cmake
Tools/MiniBrowser/win/CMakeLists.txt
Tools/TestWebKitAPI/CMakeLists.txt
Tools/TestWebKitAPI/PlatformWin.cmake
Tools/WebKitTestRunner/PlatformGTK.cmake
Tools/WebKitTestRunner/PlatformWin.cmake

index 87672de..2789abd 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,18 @@
+2019-04-03  Don Olmstead  <don.olmstead@sony.com>
+
+        [CMake][WTF] Mirror XCode header directories
+        https://bugs.webkit.org/show_bug.cgi?id=191662
+
+        Reviewed by Konstantin Tokarev.
+
+        Add WTF_FRAMEWORK_HEADERS_DIR to place WTF headers into. Add frameworks/WTF.cmake
+        which creates an interface target which will populate dependencies for consumers.
+        This file is added here to support AppleWin internal builds which invoke CMake on
+        each directory.
+
+        * Source/cmake/WebKitFS.cmake:
+        * Source/cmake/frameworks/WTF.cmake: Added.
+
 2019-04-03  Myles C. Maxfield  <mmaxfield@apple.com>
 
         Remove support for -apple-trailing-word
index 244e46b..e8c56f0 100644 (file)
@@ -1,5 +1,6 @@
 cmake_minimum_required(VERSION 2.8.12)
 include(WebKitCommon)
+include(frameworks/WTF)
 set_property(DIRECTORY . PROPERTY FOLDER "JavaScriptCore")
 
 list(APPEND JavaScriptCore_UNIFIED_SOURCE_LIST_FILES
@@ -117,7 +118,7 @@ set(JavaScriptCore_OBJECT_LUT_SOURCES
 )
 
 set(JavaScriptCore_LIBRARIES
-    WTF${DEBUG_SUFFIX}
+    WTFFramework
     ${ICU_I18N_LIBRARIES}
 )
 
@@ -297,9 +298,9 @@ add_executable(LLIntOffsetsExtractor
     ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredOffsets.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/Bytecodes.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/BytecodeStructs.h
 )
 
-target_link_libraries(LLIntSettingsExtractor WTF)
+target_link_libraries(LLIntSettingsExtractor WTFFramework)
 add_dependencies(LLIntSettingsExtractor JavaScriptCoreForwardingHeaders)
-target_link_libraries(LLIntOffsetsExtractor WTF)
+target_link_libraries(LLIntOffsetsExtractor WTFFramework)
 add_dependencies(LLIntOffsetsExtractor JavaScriptCoreForwardingHeaders)
 
 # The build system will execute asm.rb every time LLIntOffsetsExtractor's mtime is newer than
index 4c56808..80fba1b 100644 (file)
@@ -1,3 +1,16 @@
+2019-04-03  Don Olmstead  <don.olmstead@sony.com>
+
+        [CMake][WTF] Mirror XCode header directories
+        https://bugs.webkit.org/show_bug.cgi?id=191662
+
+        Reviewed by Konstantin Tokarev.
+
+        Use WTFFramework as a dependency and include frameworks/WTF.cmake for AppleWin internal
+        builds.
+
+        * CMakeLists.txt:
+        * shell/CMakeLists.txt:
+
 2019-04-03  Yusuke Suzuki  <ysuzuki@apple.com>
 
         [JSC] Add FuzzerAgent, which has a hooks to get feedback & inject fuzz data into JSC
index aa7ce64..aaada69 100644 (file)
@@ -5,7 +5,7 @@ set(JSC_SOURCES
 set(JSC_LIBRARIES
     ${CMAKE_DL_LIBS}
     JavaScriptCore${DEBUG_SUFFIX}
-    WTF${DEBUG_SUFFIX}
+    WTFFramework
 )
 
 if (WTF_OS_MAC_OS_X)
index 309b8a0..71a8692 100644 (file)
@@ -1,3 +1,15 @@
+2019-04-03  Don Olmstead  <don.olmstead@sony.com>
+
+        [CMake][WTF] Mirror XCode header directories
+        https://bugs.webkit.org/show_bug.cgi?id=191662
+
+        Reviewed by Konstantin Tokarev.
+
+        Rename WTF forwarding header target to WTFFramework and update the install location
+        to WTF_FRAMEWORK_HEADERS_DIR.
+
+        * wtf/CMakeLists.txt:
+
 2019-04-03  Joseph Pecoraro  <pecoraro@apple.com>
 
         Web Inspector: Remote Inspector indicate callback should always happen on the main thread
index 8c1583f..0391098 100644 (file)
@@ -502,7 +502,8 @@ WEBKIT_WRAP_SOURCELIST(${WTF_SOURCES})
 WEBKIT_FRAMEWORK(WTF)
 
 WEBKIT_MAKE_FORWARDING_HEADERS(WTF
-    DESTINATION ${FORWARDING_HEADERS_DIR}/wtf
+    TARGET_NAME WTFFrameworkHeaders
+    DESTINATION ${WTF_FRAMEWORK_HEADERS_DIR}/wtf
     FILES ${WTF_PUBLIC_HEADERS}
 )
 
index bd10389..3a62f7d 100644 (file)
@@ -2,6 +2,7 @@ cmake_minimum_required(VERSION 2.8.12)
 
 include(WebKitCommon)
 include(WebCoreMacros.cmake)
+include(frameworks/WTF)
 
 set_property(DIRECTORY . PROPERTY FOLDER "WebCore")
 
index c5d1d4a..4a937b7 100644 (file)
@@ -1,3 +1,16 @@
+2019-04-03  Don Olmstead  <don.olmstead@sony.com>
+
+        [CMake][WTF] Mirror XCode header directories
+        https://bugs.webkit.org/show_bug.cgi?id=191662
+
+        Reviewed by Konstantin Tokarev.
+
+        Use WTFFramework as a dependency and include frameworks/WTF.cmake for AppleWin internal
+        builds.
+
+        * CMakeLists.txt:
+        * PlatformWin.cmake:
+
 2019-04-03  Said Abou-Hallawa  <sabouhallawa@apple.com>
 
         Remove SVG properties tear-off objects
index 5cc49ca..14126a5 100644 (file)
@@ -365,8 +365,8 @@ set(WebCore_OUTPUT_NAME
     WebCore${DEBUG_SUFFIX}
 )
 
-list(APPEND WebCore_LIBRARIES WTF${DEBUG_SUFFIX})
+list(APPEND WebCore_LIBRARIES WTFFramework)
 if (TARGET libEGL)
     list(APPEND WebCore_LIBRARIES libEGL)
 endif ()
-list(APPEND WebCoreTestSupport_LIBRARIES WTF${DEBUG_SUFFIX})
+list(APPEND WebCoreTestSupport_LIBRARIES WTFFramework)
index 72ea2e2..4c483d5 100644 (file)
@@ -17,7 +17,7 @@ set(WebDriver_SOURCES
 )
 
 set(WebDriver_LIBRARIES
-    WTF
+    WTFFramework
 )
 
 set(WebDriver_SCRIPTS
index 217cb45..085550e 100644 (file)
@@ -1,3 +1,14 @@
+2019-04-03  Don Olmstead  <don.olmstead@sony.com>
+
+        [CMake][WTF] Mirror XCode header directories
+        https://bugs.webkit.org/show_bug.cgi?id=191662
+
+        Reviewed by Konstantin Tokarev.
+
+        Use WTFFramework as a dependency.
+
+        * CMakeLists.txt:
+
 2019-03-04  Karl Leplat  <karl.leplat_ext@softathome.com>
 
         WebDriver: fix String not terminated with null caracter
index c436113..42e7603 100644 (file)
@@ -1,4 +1,5 @@
 include(WebKitCommon)
+include(frameworks/WTF)
 
 set_property(DIRECTORY . PROPERTY FOLDER "WebKit")
 
index c88bed6..c0cb03c 100644 (file)
@@ -1,3 +1,15 @@
+2019-04-03  Don Olmstead  <don.olmstead@sony.com>
+
+        [CMake][WTF] Mirror XCode header directories
+        https://bugs.webkit.org/show_bug.cgi?id=191662
+
+        Reviewed by Konstantin Tokarev.
+
+        Use WTFFramework as a dependency and include frameworks/WTF.cmake for AppleWin internal
+        builds.
+
+        * CMakeLists.txt:
+
 2019-04-03  Alex Christensen  <achristensen@webkit.org>
 
         Add SPI to disable legacy TLS fallback
index 7fb8058..dda807b 100644 (file)
@@ -1,5 +1,6 @@
 cmake_minimum_required(VERSION 2.8.12)
 include(WebKitCommon)
+include(frameworks/WTF)
 set_property(DIRECTORY . PROPERTY FOLDER "WebKitLegacy")
 
 set(WebKitLegacy_SOURCES
index a50cbdd..d7680c3 100644 (file)
@@ -1,3 +1,16 @@
+2019-04-03  Don Olmstead  <don.olmstead@sony.com>
+
+        [CMake][WTF] Mirror XCode header directories
+        https://bugs.webkit.org/show_bug.cgi?id=191662
+
+        Reviewed by Konstantin Tokarev.
+
+        Use WTFFramework as a dependency and include frameworks/WTF.cmake for AppleWin internal
+        builds.
+
+        * CMakeLists.txt:
+        * PlatformWin.cmake:
+
 2019-04-02  Fujii Hironori  <Hironori.Fujii@sony.com>
 
         [CMake] WEBKIT_MAKE_FORWARDING_HEADERS shouldn't use POST_BUILD to copy generated headers
index dc2d703..0d29401 100644 (file)
@@ -34,7 +34,7 @@ else ()
     )
 endif ()
 
-list(APPEND WebKitLegacy_LIBRARIES PRIVATE WTF${DEBUG_SUFFIX})
+list(APPEND WebKitLegacy_LIBRARIES PRIVATE WTFFramework)
 
 add_custom_command(
     OUTPUT ${DERIVED_SOURCES_WEBKITLEGACY_DIR}/WebKitVersion.h
index 67150d8..394f9b6 100644 (file)
@@ -1,3 +1,12 @@
+2019-04-03  Don Olmstead  <don.olmstead@sony.com>
+
+        [CMake][WTF] Mirror XCode header directories
+        https://bugs.webkit.org/show_bug.cgi?id=191662
+
+        Reviewed by Konstantin Tokarev.
+
+        * WebKitQuartzCoreAdditions/CMakeLists.txt:
+
 2019-03-29  Cathie Chen  <cathiechen@igalia.com>
 
         Implement ResizeObserver.
index ed8fac5..535d8b4 100644 (file)
@@ -59,7 +59,7 @@ add_library(WebKitQuartzCoreAdditions SHARED ${WebKitQuartzCoreAdditions_SOURCES
 set_target_properties(WebKitQuartzCoreAdditions PROPERTIES OUTPUT_NAME WebKitQuartzCoreAdditions${DEBUG_SUFFIX})
 target_link_libraries(WebKitQuartzCoreAdditions
     D3d9
-    WTF${DEBUG_SUFFIX}
+    WTFFramework
     CoreFoundation${DEBUG_SUFFIX}
     CoreGraphics${DEBUG_SUFFIX}
     QuartzCore${DEBUG_SUFFIX}
index 9ddc981..0a7414e 100644 (file)
@@ -39,8 +39,12 @@ set(DERIVED_SOURCES_WEBKIT_DIR "${CMAKE_BINARY_DIR}/DerivedSources/WebKit")
 set(DERIVED_SOURCES_WEBINSPECTORUI_DIR "${CMAKE_BINARY_DIR}/DerivedSources/WebInspectorUI")
 set(DERIVED_SOURCES_WTF_DIR "${CMAKE_BINARY_DIR}/DerivedSources/WTF")
 
+set(WTF_FRAMEWORK_HEADERS_DIR ${CMAKE_BINARY_DIR}/FrameworkHeaders/WTF.framework/Headers)
+
 set(FORWARDING_HEADERS_DIR ${DERIVED_SOURCES_DIR}/ForwardingHeaders)
 
+file(MAKE_DIRECTORY ${WTF_FRAMEWORK_HEADERS_DIR}/wtf)
+
 file(MAKE_DIRECTORY ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR})
 file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/Source/JavaScriptCore/runtime)
 
diff --git a/Source/cmake/frameworks/WTF.cmake b/Source/cmake/frameworks/WTF.cmake
new file mode 100644 (file)
index 0000000..c0ef77b
--- /dev/null
@@ -0,0 +1,15 @@
+if (NOT TARGET WTFFramework)
+    add_library(WTFFramework INTERFACE)
+
+    if (WIN32 AND INTERNAL_BUILD)
+        target_link_libraries(WTFFramework INTERFACE WTF${DEBUG_SUFFIX})
+    else ()
+        target_include_directories(WTFFramework INTERFACE
+            ${WTF_INCLUDE_DIRECTORIES}
+            ${WTF_FRAMEWORK_HEADERS_DIR}
+        )
+        target_include_directories(WTFFramework SYSTEM INTERFACE ${WTF_SYSTEM_INCLUDE_DIRECTORIES})
+        target_link_libraries(WTFFramework INTERFACE WTF ${WTF_LIBRARIES})
+        add_dependencies(WTFFramework WTFFrameworkHeaders)
+    endif ()
+endif ()
index 5d32367..516649c 100644 (file)
@@ -1,4 +1,5 @@
 set_property(DIRECTORY . PROPERTY FOLDER "Tools")
+include(frameworks/WTF)
 
 # Individual subdirectories are added in the port's cmake file
 WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
index 414334f..cf8ae1c 100644 (file)
@@ -1,3 +1,22 @@
+2019-04-03  Don Olmstead  <don.olmstead@sony.com>
+
+        [CMake][WTF] Mirror XCode header directories
+        https://bugs.webkit.org/show_bug.cgi?id=191662
+
+        Reviewed by Konstantin Tokarev.
+
+        Use WTFFramework as a dependency and include frameworks/WTF.cmake for AppleWin internal
+        builds.
+
+        * CMakeLists.txt:
+        * DumpRenderTree/CMakeLists.txt:
+        * DumpRenderTree/PlatformWin.cmake:
+        * MiniBrowser/win/CMakeLists.txt:
+        * TestWebKitAPI/CMakeLists.txt:
+        * TestWebKitAPI/PlatformWin.cmake:
+        * WebKitTestRunner/PlatformGTK.cmake:
+        * WebKitTestRunner/PlatformWin.cmake:
+
 2019-04-03  Aakash Jain  <aakash_jain@apple.com>
 
         [ews-app] Status bubble should not display certain infrastructure status messages
index bb46f24..ff91f12 100644 (file)
@@ -66,7 +66,7 @@ set(TestNetscapePlugIn_SOURCES
 
 set(TestNetscapePlugIn_LIBRARIES
     JavaScriptCore
-    WTF
+    WTFFramework
     WebCoreTestSupport
 )
 
index 5c5c3f9..e81be4a 100644 (file)
@@ -70,7 +70,7 @@ list(APPEND DumpRenderTree_INCLUDE_DIRECTORIES
 )
 
 list(APPEND DumpRenderTree_LIBRARIES
-    WTF
+    WTFFramework
     WebKitLegacy
     shlwapi
 )
index 7fa2f3e..a43cd69 100644 (file)
@@ -24,7 +24,7 @@ set(MiniBrowser_SOURCES
 
 set(MiniBrowser_LIBRARIES
     DbgHelp
-    WTF
+    WTFFramework
     WebKitLegacy
     WebKitLegacyGUID
     comctl32
index 4509208..9953060 100644 (file)
@@ -1,23 +1,23 @@
 set(TESTWEBKITAPI_DIR "${TOOLS_DIR}/TestWebKitAPI")
+
 set(test_wtf_LIBRARIES
-    WTF${DEBUG_SUFFIX}
+    WTFFramework
     gtest
 )
 
 set(test_webcore_LIBRARIES
-    WTF${DEBUG_SUFFIX}
+    WTFFramework
     WebCore${DEBUG_SUFFIX}
     gtest
 )
 
 set(TestWebKitAPI_LIBRARIES
-    WTF${DEBUG_SUFFIX}
+    WTFFramework
 )
 
 set(TestWebKitAPI_DEPENDENCIES
     JavaScriptCoreForwardingHeaders
     JavaScriptCorePrivateForwardingHeaders
-    WTFForwardingHeaders
 )
 
 if (ENABLE_WEBCORE)
@@ -28,7 +28,7 @@ if (ENABLE_WEBKIT)
     set(test_webkit_api_LIBRARIES
         JavaScriptCore
         TestWebKitAPIBase
-        WTF
+        WTFFramework
         WebKit
         gtest
     )
@@ -88,7 +88,7 @@ if (ENABLE_WEBKIT)
 
     set(TestWebKitAPIBase_LIBRARIES
         JavaScriptCore
-        WTF
+        WTFFramework
         WebKit
         gtest
     )
@@ -246,7 +246,7 @@ if (ENABLE_WEBKIT)
     )
 
     target_link_libraries(TestWebKitAPIInjectedBundle ${TestWebKitAPI_LIBRARIES})
-    add_dependencies(TestWebKitAPIInjectedBundle WTF ${TestWebKitAPI_DEPENDENCIES})
+    add_dependencies(TestWebKitAPIInjectedBundle ${TestWebKitAPI_DEPENDENCIES})
 
     if (COMPILER_IS_GCC_OR_CLANG)
         WEBKIT_ADD_TARGET_CXX_FLAGS(TestWebKitAPIInjectedBundle -Wno-dangling-else
@@ -271,7 +271,7 @@ add_executable(TestWTF
 if (WIN32)
     add_dependencies(TestWTF TestWTFLib)
 else ()
-    add_dependencies(TestWTF WTF ${TestWebKitAPI_DEPENDENCIES})
+    add_dependencies(TestWTF ${TestWebKitAPI_DEPENDENCIES})
 endif ()
 
 target_link_libraries(TestWTF ${test_wtf_LIBRARIES})
index b49c92e..47c5131 100644 (file)
@@ -147,6 +147,7 @@ if (${WTF_PLATFORM_WIN_CAIRO})
 endif ()
 
 set(test_webkitlegacy_LIBRARIES
+    WTFFramework
     WebCoreTestSupport
     WebKitLegacy${DEBUG_SUFFIX}
     gtest
index b0af11e..3094a5b 100644 (file)
@@ -29,7 +29,7 @@ list(APPEND WebKitTestRunner_LIBRARIES
     ${CAIRO_LIBRARIES}
     ${GTK3_LIBRARIES}
     ${GLIB_LIBRARIES}
-    WTF
+    WTFFramework
     WebCore
     WebCorePlatformGTK
 )
index f244cd6..fecfd82 100644 (file)
@@ -36,7 +36,7 @@ set(WebKitTestRunnerLib_LIBRARIES
 )
 
 list(APPEND WebKitTestRunner_LIBRARIES
-    WTF
+    WTFFramework
     WebKit
 )