Created
April 15, 2016 16:59
-
-
Save annulen/d2decbf43f90b88a72f88cd6b9990e31 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/Source/WebCore/PlatformQt.cmake b/Source/WebCore/PlatformQt.cmake | |
index fc04f46..e380b94 100644 | |
--- a/Source/WebCore/PlatformQt.cmake | |
+++ b/Source/WebCore/PlatformQt.cmake | |
@@ -169,15 +169,19 @@ if (USE_QT_MULTIMEDIA) | |
) | |
endif () | |
-qt5_add_resources(WebCore_SOURCES | |
- WebCore.qrc | |
-) | |
- | |
-if (ENABLE_INSPECTOR_UI) | |
- include(${CMAKE_SOURCE_DIR}/Source/WebInspectorUI/PlatformQt.cmake) | |
- list(APPEND WebCore_SOURCES | |
- ${DERIVED_SOURCES_WEBINSPECTORUI_DIR}/qrc_WebInspector.cpp | |
+# Do it in the WebCore to support SHARED_CORE since WebKitWidgets won't load WebKit in that case. | |
+# This should match the opposite statement in WebKit/PlatformQt.cmake | |
+if (NOT WIN32) | |
+ qt5_add_resources(WebCore_SOURCES | |
+ WebCore.qrc | |
) | |
+ | |
+ if (ENABLE_INSPECTOR_UI) | |
+ include("${CMAKE_SOURCE_DIR}/Source/WebInspectorUI/PlatformQt.cmake") | |
+ list(APPEND WebCore_SOURCES | |
+ "${DERIVED_SOURCES_WEBINSPECTORUI_DIR}/qrc_WebInspector.cpp" | |
+ ) | |
+ endif () | |
endif () | |
# Note: Qt5Network_INCLUDE_DIRS includes Qt5Core_INCLUDE_DIRS | |
diff --git a/Source/WebKit/PlatformQt.cmake b/Source/WebKit/PlatformQt.cmake | |
index f202b3b..871d216 100644 | |
--- a/Source/WebKit/PlatformQt.cmake | |
+++ b/Source/WebKit/PlatformQt.cmake | |
@@ -232,6 +232,21 @@ if (ENABLE_VIDEO) | |
) | |
endif () | |
+# Resources have to be included directly in the final binary for MSVC. | |
+# The linker won't pick them from a static library since they aren't referenced. | |
+if (NOT WIN32) | |
+ qt5_add_resources(WebKit_SOURCES | |
+ "${WEBCORE_DIR}/WebCore.qrc" | |
+ ) | |
+ | |
+ if (ENABLE_INSPECTOR_UI) | |
+ include("${CMAKE_SOURCE_DIR}/Source/WebInspectorUI/PlatformQt.cmake") | |
+ list(APPEND WebCore_SOURCES | |
+ "${DERIVED_SOURCES_WEBINSPECTORUI_DIR}/qrc_WebInspector.cpp" | |
+ ) | |
+ endif () | |
+endif () | |
+ | |
WEBKIT_CREATE_FORWARDING_HEADERS(QtWebKit DIRECTORIES qt/Api) | |
ecm_generate_headers( |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment