WEBKIT_FRAMEWORK should not modify file-global include directories
authormcatanzaro@igalia.com <mcatanzaro@igalia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 17 Jan 2018 23:18:17 +0000 (23:18 +0000)
committermcatanzaro@igalia.com <mcatanzaro@igalia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 17 Jan 2018 23:18:17 +0000 (23:18 +0000)
https://bugs.webkit.org/show_bug.cgi?id=181656

Reviewed by Konstantin Tokarev.

.:

Only modify the system include directories of the target passed to WEBKIT_FRAMEWORK.

* Source/cmake/WebKitMacros.cmake:

Source/WebCore:

* CMakeLists.txt:
* PlatformWPE.cmake:

Source/WebKit:

* PlatformGTK.cmake:
* PlatformWPE.cmake:

Tools:

* TestWebKitAPI/PlatformWPE.cmake:
* TestWebKitAPI/glib/CMakeLists.txt:

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

ChangeLog
Source/WebCore/CMakeLists.txt
Source/WebCore/ChangeLog
Source/WebCore/PlatformWPE.cmake
Source/WebKit/ChangeLog
Source/WebKit/PlatformGTK.cmake
Source/WebKit/PlatformWPE.cmake
Source/cmake/WebKitMacros.cmake
Tools/ChangeLog
Tools/TestWebKitAPI/PlatformWPE.cmake
Tools/TestWebKitAPI/glib/CMakeLists.txt

index a60a781..1a87ced 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2018-01-17  Michael Catanzaro  <mcatanzaro@igalia.com>
+
+        WEBKIT_FRAMEWORK should not modify file-global include directories
+        https://bugs.webkit.org/show_bug.cgi?id=181656
+
+        Reviewed by Konstantin Tokarev.
+
+        Only modify the system include directories of the target passed to WEBKIT_FRAMEWORK.
+
+        * Source/cmake/WebKitMacros.cmake:
+
 2018-01-17  Carlos Garcia Campos  <cgarcia@igalia.com>
 
         Unreviewed. Update OptionsGTK.cmake and NEWS for 2.19.6 release.
index c9f84cd..d59345a 100644 (file)
@@ -1949,6 +1949,7 @@ endif ()
 add_library(WebCoreTestSupport ${WebCoreTestSupport_LIBRARY_TYPE} ${WebCoreTestSupport_SOURCES})
 add_dependencies(WebCoreTestSupport WebCore WebCoreTestSupportBindings)
 target_include_directories(WebCoreTestSupport PUBLIC ${WebCoreTestSupport_INCLUDE_DIRECTORIES} ${WebCore_INCLUDE_DIRECTORIES})
+target_include_directories(WebCoreTestSupport SYSTEM PUBLIC ${WebCore_SYSTEM_INCLUDE_DIRECTORIES})
 target_link_libraries(WebCoreTestSupport ${WebCoreTestSupport_LIBRARIES})
 
 if (WebCoreTestSupport_OUTPUT_NAME)
index 08e68b7..071aaaf 100644 (file)
@@ -1,5 +1,15 @@
 2018-01-17  Michael Catanzaro  <mcatanzaro@igalia.com>
 
+        WEBKIT_FRAMEWORK should not modify file-global include directories
+        https://bugs.webkit.org/show_bug.cgi?id=181656
+
+        Reviewed by Konstantin Tokarev.
+
+        * CMakeLists.txt:
+        * PlatformWPE.cmake:
+
+2018-01-17  Michael Catanzaro  <mcatanzaro@igalia.com>
+
         [GTK] Try even harder not to static link WTF into libwebkit2gtk
         https://bugs.webkit.org/show_bug.cgi?id=181751
 
index e8145fa..c918558 100644 (file)
@@ -76,7 +76,7 @@ list(APPEND WebCore_LIBRARIES
     ${WPE_LIBRARIES}
 )
 
-list(APPEND WebCore_INCLUDE_DIRECTORIES
+list(APPEND WebCore_SYSTEM_INCLUDE_DIRECTORIES
     ${CAIRO_INCLUDE_DIRS}
     ${GIO_UNIX_INCLUDE_DIRS}
     ${GLIB_INCLUDE_DIRS}
index e97b6ab..1c37047 100644 (file)
@@ -1,3 +1,13 @@
+2018-01-17  Michael Catanzaro  <mcatanzaro@igalia.com>
+
+        WEBKIT_FRAMEWORK should not modify file-global include directories
+        https://bugs.webkit.org/show_bug.cgi?id=181656
+
+        Reviewed by Konstantin Tokarev.
+
+        * PlatformGTK.cmake:
+        * PlatformWPE.cmake:
+
 2018-01-17  Youenn Fablet  <youenn@apple.com>
 
         Put fetch request keepAlive behind a runtime flag
index 93c978d..12711cb 100644 (file)
@@ -1060,22 +1060,21 @@ list(APPEND PluginProcess_SOURCES
 )
 
 # Commands for building the built-in injected bundle.
-include_directories(
-    "${WEBKIT_DIR}/Platform"
-    "${WEBKIT_DIR}/Shared"
-    "${WEBKIT_DIR}/Shared/API/c"
-    "${WEBKIT_DIR}/UIProcess/API/C"
-    "${WEBKIT_DIR}/WebProcess/InjectedBundle"
-    "${WEBKIT_DIR}/WebProcess/InjectedBundle/API/c"
+add_library(webkit2gtkinjectedbundle MODULE "${WEBKIT_DIR}/WebProcess/InjectedBundle/API/glib/WebKitInjectedBundleMain.cpp")
+ADD_WEBKIT_PREFIX_HEADER(webkit2gtkinjectedbundle)
+target_link_libraries(webkit2gtkinjectedbundle WebKit)
+
+target_include_directories(webkit2gtkinjectedbundle PRIVATE
+    ${WebKit_INCLUDE_DIRECTORIES}
     "${DERIVED_SOURCES_DIR}/InjectedBundle"
     "${FORWARDING_HEADERS_DIR}"
     "${FORWARDING_HEADERS_WEBKIT2GTK_DIR}"
     "${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}"
 )
 
-add_library(webkit2gtkinjectedbundle MODULE "${WEBKIT_DIR}/WebProcess/InjectedBundle/API/glib/WebKitInjectedBundleMain.cpp")
-ADD_WEBKIT_PREFIX_HEADER(webkit2gtkinjectedbundle)
-target_link_libraries(webkit2gtkinjectedbundle WebKit)
+target_include_directories(webkit2gtkinjectedbundle SYSTEM PRIVATE
+    ${WebKit_SYSTEM_INCLUDE_DIRECTORIES}
+)
 
 if (COMPILER_IS_GCC_OR_CLANG)
     WEBKIT_ADD_TARGET_CXX_FLAGS(webkit2gtkinjectedbundle -Wno-unused-parameter)
index 023e790..8b107a9 100644 (file)
@@ -481,6 +481,9 @@ add_library(WPEInjectedBundle MODULE "${WEBKIT_DIR}/WebProcess/InjectedBundle/AP
 ADD_WEBKIT_PREFIX_HEADER(WPEInjectedBundle)
 target_link_libraries(WPEInjectedBundle WebKit)
 
+target_include_directories(WPEInjectedBundle PRIVATE ${WebKit_INCLUDE_DIRECTORIES})
+target_include_directories(WPEInjectedBundle SYSTEM PRIVATE ${WebKit_SYSTEM_INCLUDE_DIRECTORIES})
+
 install(FILES "${CMAKE_BINARY_DIR}/wpe-webkit.pc"
     DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig"
     COMPONENT "Development"
index 7e69557..a1e7e8f 100644 (file)
@@ -129,12 +129,12 @@ macro(WEBKIT_FRAMEWORK_DECLARE _target)
 endmacro()
 
 macro(WEBKIT_FRAMEWORK _target)
-    include_directories(SYSTEM ${${_target}_SYSTEM_INCLUDE_DIRECTORIES})
     target_sources(${_target} PRIVATE
         ${${_target}_HEADERS}
         ${${_target}_SOURCES}
     )
     target_include_directories(${_target} PUBLIC "$<BUILD_INTERFACE:${${_target}_INCLUDE_DIRECTORIES}>")
+    target_include_directories(${_target} SYSTEM PRIVATE "$<BUILD_INTERFACE:${${_target}_SYSTEM_INCLUDE_DIRECTORIES}>")
     target_include_directories(${_target} PRIVATE "$<BUILD_INTERFACE:${${_target}_PRIVATE_INCLUDE_DIRECTORIES}>")
     target_link_libraries(${_target} ${${_target}_LIBRARIES})
     set_target_properties(${_target} PROPERTIES COMPILE_DEFINITIONS "BUILDING_${_target}")
index d553578..ba39352 100644 (file)
@@ -1,3 +1,13 @@
+2018-01-17  Michael Catanzaro  <mcatanzaro@igalia.com>
+
+        WEBKIT_FRAMEWORK should not modify file-global include directories
+        https://bugs.webkit.org/show_bug.cgi?id=181656
+
+        Reviewed by Konstantin Tokarev.
+
+        * TestWebKitAPI/PlatformWPE.cmake:
+        * TestWebKitAPI/glib/CMakeLists.txt:
+
 2018-01-17  Alicia Boya GarcĂ­a  <aboya@igalia.com>
 
         Unreviewed, mark Alicia as committer in contributors.json
index c4f4bb0..96a357f 100644 (file)
@@ -19,6 +19,7 @@ include_directories(
 )
 
 include_directories(SYSTEM
+    ${CAIRO_INCLUDE_DIRS}
     ${GLIB_INCLUDE_DIRS}
     ${LIBSOUP_INCLUDE_DIRS}
 )
index eb2bea0..8506f0a 100644 (file)
@@ -15,6 +15,7 @@ set(WebKitGLibAPITests_INCLUDE_DIRECTORIES
 )
 
 set(WebKitGLibAPITests_SYSTEM_INCLUDE_DIRECTORIES
+    ${CAIRO_INCLUDE_DIRS}
     ${GLIB_INCLUDE_DIRS}
     ${GSTREAMER_INCLUDE_DIRS}
     ${LIBSOUP_INCLUDE_DIRS}