--- ./Tools/MiniBrowser/gtk/CMakeLists.txt.orig	2019-08-05 09:37:14.540345025 +0200
+++ ./Tools/MiniBrowser/gtk/CMakeLists.txt	2019-08-05 09:37:25.348345357 +0200
@@ -59,7 +59,7 @@
 add_definitions(-DGDK_VERSION_MIN_REQUIRED=GDK_VERSION_3_6)
 
 include_directories(${MiniBrowser_INCLUDE_DIRECTORIES})
-include_directories(SYSTEM ${MiniBrowser_SYSTEM_INCLUDE_DIRECTORIES})
+include_directories(${MiniBrowser_SYSTEM_INCLUDE_DIRECTORIES})
 add_executable(MiniBrowser ${MiniBrowser_SOURCES})
 target_link_libraries(MiniBrowser ${MiniBrowser_LIBRARIES})
 
--- ./Tools/TestWebKitAPI/glib/CMakeLists.txt.orig	2019-08-05 09:37:35.632345673 +0200
+++ ./Tools/TestWebKitAPI/glib/CMakeLists.txt	2019-08-05 09:37:49.932346112 +0200
@@ -95,7 +95,7 @@
 )
 
 include_directories(${WebKitGLibAPITests_INCLUDE_DIRECTORIES})
-include_directories(SYSTEM ${WebKitGLibAPITests_SYSTEM_INCLUDE_DIRECTORIES})
+include_directories(${WebKitGLibAPITests_SYSTEM_INCLUDE_DIRECTORIES})
 
 add_library(WebKitGLibAPITestsCore STATIC ${WebKitGLibAPITests_SOURCES})
 target_link_libraries(WebKitGLibAPITestsCore WebKit)
@@ -161,7 +161,7 @@
     )
     target_compile_definitions(${test_name} PUBLIC QT_NO_KEYWORDS=1)
     target_link_libraries(${test_name} ${WPEQtAPITest_LIBRARIES})
-    target_include_directories(${test_name} SYSTEM PRIVATE ${WPEQtAPITests_INCLUDE_DIRECTORIES})
+    target_include_directories(${test_name} PRIVATE ${WPEQtAPITests_INCLUDE_DIRECTORIES})
     target_include_directories(${test_name} PRIVATE
       ${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_SOURCE_DIR}/Source/WebKit/UIProcess/API/wpe/qt)
 endmacro()
--- ./Tools/TestWebKitAPI/PlatformJSCOnly.cmake.orig	2019-08-05 09:30:13.544332093 +0200
+++ ./Tools/TestWebKitAPI/PlatformJSCOnly.cmake	2019-08-05 09:30:20.548332308 +0200
@@ -6,7 +6,7 @@
 )
 
 if (LOWERCASE_EVENT_LOOP_TYPE STREQUAL "glib")
-    include_directories(SYSTEM
+    include_directories(
         ${GLIB_INCLUDE_DIRS}
     )
     list(APPEND TestWTF_SOURCES
--- ./Tools/TestWebKitAPI/PlatformGTK.cmake.orig	2019-08-05 09:29:47.984331308 +0200
+++ ./Tools/TestWebKitAPI/PlatformGTK.cmake	2019-08-05 09:29:57.020331585 +0200
@@ -22,7 +22,7 @@
     ${WEBKIT_DIR}/UIProcess/API/gtk
 )
 
-include_directories(SYSTEM
+include_directories(
     ${GDK3_INCLUDE_DIRS}
     ${GLIB_INCLUDE_DIRS}
     ${GSTREAMER_INCLUDE_DIRS}
--- ./Source/WebDriver/CMakeLists.txt.orig	2019-08-05 09:37:59.296346400 +0200
+++ ./Source/WebDriver/CMakeLists.txt	2019-08-05 09:38:05.940346604 +0200
@@ -42,7 +42,7 @@
 WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
 
 include_directories(${WebDriver_INCLUDE_DIRECTORIES})
-include_directories(SYSTEM ${WebDriver_SYSTEM_INCLUDE_DIRECTORIES})
+include_directories(${WebDriver_SYSTEM_INCLUDE_DIRECTORIES})
 add_executable(WebDriver ${WebDriver_SOURCES})
 target_link_libraries(WebDriver ${WebDriver_LIBRARIES})
 
--- ./Source/WebKit/PlatformGTK.cmake.orig	2019-08-05 09:33:16.360337709 +0200
+++ ./Source/WebKit/PlatformGTK.cmake	2019-08-05 09:33:41.168338471 +0200
@@ -665,7 +665,7 @@
     target_include_directories(WebKitPluginProcess2 PRIVATE
         ${WebKitCommonIncludeDirectories}
     )
-    target_include_directories(WebKitPluginProcess2 SYSTEM PRIVATE
+    target_include_directories(WebKitPluginProcess2 PRIVATE
          ${WebKitCommonSystemIncludeDirectories}
          ${GTK2_INCLUDE_DIRS}
          ${GDK2_INCLUDE_DIRS}
@@ -705,7 +705,7 @@
     "${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}"
 )
 
-target_include_directories(webkit2gtkinjectedbundle SYSTEM PRIVATE
+target_include_directories(webkit2gtkinjectedbundle PRIVATE
     ${WebKit_SYSTEM_INCLUDE_DIRECTORIES}
 )
 
--- ./Source/cmake/WebKitMacros.cmake.orig	2019-08-05 09:35:29.196341789 +0200
+++ ./Source/cmake/WebKitMacros.cmake	2019-08-05 09:35:38.300342069 +0200
@@ -152,7 +152,7 @@
         ${${_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}_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}")
--- ./Source/cmake/WebKitCompilerFlags.cmake.orig	2019-08-05 09:34:01.300339089 +0200
+++ ./Source/cmake/WebKitCompilerFlags.cmake	2019-08-05 09:35:19.180341481 +0200
@@ -216,31 +216,6 @@
 set(CODE_GENERATOR_PREPROCESSOR "\"${CMAKE_CXX_COMPILER}\" ${CODE_GENERATOR_PREPROCESSOR_ARGUMENTS}")
 set(CODE_GENERATOR_PREPROCESSOR_WITH_LINEMARKERS "\"${CMAKE_CXX_COMPILER}\" ${CODE_GENERATOR_PREPROCESSOR_WITH_LINEMARKERS_ARGUMENTS}")
 
-
-# Ensure that the default include system directories are added to the list of CMake implicit includes.
-# This workarounds an issue that happens when using GCC 6 and using system includes (-isystem).
-# For more details check: https://bugs.webkit.org/show_bug.cgi?id=161697
-macro(DETERMINE_GCC_SYSTEM_INCLUDE_DIRS _lang _compiler _flags _result)
-    file(WRITE "${CMAKE_BINARY_DIR}/CMakeFiles/dummy" "\n")
-    separate_arguments(_buildFlags UNIX_COMMAND "${_flags}")
-    execute_process(COMMAND ${_compiler} ${_buildFlags} -v -E -x ${_lang} -dD dummy
-                    WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/CMakeFiles OUTPUT_QUIET
-                    ERROR_VARIABLE _gccOutput)
-    file(REMOVE "${CMAKE_BINARY_DIR}/CMakeFiles/dummy")
-    if ("${_gccOutput}" MATCHES "> search starts here[^\n]+\n *(.+) *\n *End of (search) list")
-        set(${_result} ${CMAKE_MATCH_1})
-        string(REPLACE "\n" " " ${_result} "${${_result}}")
-        separate_arguments(${_result})
-    endif ()
-endmacro()
-
-if (COMPILER_IS_GCC_OR_CLANG)
-   DETERMINE_GCC_SYSTEM_INCLUDE_DIRS("c" "${CMAKE_C_COMPILER}" "${CMAKE_C_FLAGS}" SYSTEM_INCLUDE_DIRS)
-   set(CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES ${CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES} ${SYSTEM_INCLUDE_DIRS})
-   DETERMINE_GCC_SYSTEM_INCLUDE_DIRS("c++" "${CMAKE_CXX_COMPILER}" "${CMAKE_CXX_FLAGS}" SYSTEM_INCLUDE_DIRS)
-   set(CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES ${CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES} ${SYSTEM_INCLUDE_DIRS})
-endif ()
-
 if (COMPILER_IS_GCC_OR_CLANG)
     set(ATOMIC_TEST_SOURCE "
         #include <atomic>
--- ./Source/JavaScriptCore/CMakeLists.txt.orig	2019-08-05 09:39:00.468348279 +0200
+++ ./Source/JavaScriptCore/CMakeLists.txt	2019-08-05 09:39:08.728348533 +0200
@@ -1283,13 +1283,13 @@
     ${JavaScriptCore_INCLUDE_DIRECTORIES}
     ${JavaScriptCore_PRIVATE_INCLUDE_DIRECTORIES}
 )
-target_include_directories(LLIntSettingsExtractor SYSTEM PRIVATE ${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES})
+target_include_directories(LLIntSettingsExtractor PRIVATE ${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES})
 
 target_include_directories(LLIntOffsetsExtractor PRIVATE
     ${JavaScriptCore_INCLUDE_DIRECTORIES}
     ${JavaScriptCore_PRIVATE_INCLUDE_DIRECTORIES}
 )
-target_include_directories(LLIntOffsetsExtractor SYSTEM PRIVATE ${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES})
+target_include_directories(LLIntOffsetsExtractor PRIVATE ${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES})
 
 add_subdirectory(shell)
 
--- ./Source/JavaScriptCore/shell/CMakeLists.txt.orig	2019-08-05 09:38:28.744347304 +0200
+++ ./Source/JavaScriptCore/shell/CMakeLists.txt	2019-08-05 09:38:34.484347481 +0200
@@ -36,7 +36,7 @@
 WEBKIT_WRAP_SOURCELIST(${JSC_SOURCES})
 WEBKIT_WRAP_SOURCELIST(${TESTAPI_SOURCES})
 include_directories(./ ${JavaScriptCore_INCLUDE_DIRECTORIES} ${JavaScriptCore_PRIVATE_INCLUDE_DIRECTORIES})
-include_directories(SYSTEM ${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES})
+include_directories(${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES})
 add_executable(jsc ${JSC_SOURCES})
 target_link_libraries(jsc ${JSC_LIBRARIES})
 
--- ./Source/WebCore/CMakeLists.txt.orig	2019-08-05 09:39:20.148348883 +0200
+++ ./Source/WebCore/CMakeLists.txt	2019-08-05 09:39:43.724349608 +0200
@@ -2104,7 +2104,7 @@
 # paths of WebCore.
 add_library(WebCoreHeaderInterface INTERFACE)
 target_include_directories(WebCoreHeaderInterface INTERFACE ${WebCore_INCLUDE_DIRECTORIES})
-target_include_directories(WebCoreHeaderInterface SYSTEM INTERFACE ${WebCore_SYSTEM_INCLUDE_DIRECTORIES})
+target_include_directories(WebCoreHeaderInterface INTERFACE ${WebCore_SYSTEM_INCLUDE_DIRECTORIES})
 target_link_libraries(WebCoreHeaderInterface INTERFACE ${WebCore_LIBRARIES})
 
 if (MSVC)
@@ -2114,7 +2114,7 @@
 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_include_directories(WebCoreTestSupport PUBLIC ${WebCore_SYSTEM_INCLUDE_DIRECTORIES})
 target_link_libraries(WebCoreTestSupport ${WebCoreTestSupport_LIBRARIES})
 
 if (WebCoreTestSupport_OUTPUT_NAME)
--- ./Source/WebCore/PlatformGTK.cmake.orig	2019-08-05 09:35:55.792342606 +0200
+++ ./Source/WebCore/PlatformGTK.cmake	2019-08-05 09:36:19.120343323 +0200
@@ -164,7 +164,7 @@
     target_include_directories(WebCorePlatformGTK2 PRIVATE
         ${WebCore_INCLUDE_DIRECTORIES}
     )
-    target_include_directories(WebCorePlatformGTK2 SYSTEM PRIVATE
+    target_include_directories(WebCorePlatformGTK2 PRIVATE
         ${WebCore_SYSTEM_INCLUDE_DIRECTORIES}
         ${GTK2_INCLUDE_DIRS}
         ${GDK2_INCLUDE_DIRS}
@@ -190,7 +190,7 @@
 target_include_directories(WebCorePlatformGTK PRIVATE
     ${WebCore_INCLUDE_DIRECTORIES}
 )
-target_include_directories(WebCorePlatformGTK SYSTEM PRIVATE
+target_include_directories(WebCorePlatformGTK PRIVATE
     ${WebCore_SYSTEM_INCLUDE_DIRECTORIES}
     ${GTK_INCLUDE_DIRS}
     ${GDK_INCLUDE_DIRS}
@@ -206,7 +206,7 @@
     "${WEBCORE_DIR}/bindings/gobject/"
 )
 
-include_directories(SYSTEM
+include_directories(
     ${WebCore_SYSTEM_INCLUDE_DIRECTORIES}
 )
 
