Add UIDelegatePrivate SPI corresponding to WKPageUIClient.showPage
[WebKit-https.git] / Source / WebKitLegacy / PlatformWin.cmake
1 if (${WTF_PLATFORM_WIN_CAIRO})
2     add_definitions(-DUSE_CAIRO=1 -DUSE_CURL=1 -DWEBKIT_EXPORTS=1)
3     list(APPEND WebKit_INCLUDE_DIRECTORIES
4         ${CAIRO_INCLUDE_DIRS}
5         "${WEBKIT_LIBRARIES_DIR}/include"
6         "${WEBKIT_LIBRARIES_DIR}/include/sqlite"
7         "${WEBCORE_DIR}/platform/graphics/cairo"
8     )
9     list(APPEND WebKit_SOURCES_Classes
10         win/WebDownloadCURL.cpp
11         win/WebURLAuthenticationChallengeSenderCURL.cpp
12     )
13     list(APPEND WebKit_LIBRARIES
14         ${OPENSSL_LIBRARIES}
15         PRIVATE mfuuid.lib
16         PRIVATE strmiids.lib
17     )
18 else ()
19     list(APPEND WebKit_SOURCES_Classes
20         win/WebDownloadCFNet.cpp
21         win/WebURLAuthenticationChallengeSenderCFNet.cpp
22     )
23     list(APPEND WebKit_LIBRARIES
24         PRIVATE CFNetwork${DEBUG_SUFFIX}
25         PRIVATE CoreFoundation${DEBUG_SUFFIX}
26         PRIVATE CoreGraphics${DEBUG_SUFFIX}
27         PRIVATE CoreText${DEBUG_SUFFIX}
28         PRIVATE QuartzCore${DEBUG_SUFFIX}
29         PRIVATE SQLite3${DEBUG_SUFFIX}
30         PRIVATE WebKitSystemInterface${DEBUG_SUFFIX}
31         PRIVATE libdispatch${DEBUG_SUFFIX}
32         PRIVATE libicuin${DEBUG_SUFFIX}
33         PRIVATE libicuuc${DEBUG_SUFFIX}
34         PRIVATE libxml2${DEBUG_SUFFIX}
35         PRIVATE libxslt${DEBUG_SUFFIX}
36         PRIVATE zdll${DEBUG_SUFFIX}
37     )
38 endif ()
39
40 list(APPEND WebKit_LIBRARIES PRIVATE WTF${DEBUG_SUFFIX})
41
42 add_custom_command(
43     OUTPUT ${DERIVED_SOURCES_WEBKIT_DIR}/WebKitVersion.h
44     MAIN_DEPENDENCY ${WEBKIT_DIR}/scripts/generate-webkitversion.pl
45     DEPENDS ${WEBKIT_DIR}/mac/Configurations/Version.xcconfig
46     COMMAND ${PERL_EXECUTABLE} ${WEBKIT_DIR}/scripts/generate-webkitversion.pl --config ${WEBKIT_DIR}/mac/Configurations/Version.xcconfig --outputDir ${DERIVED_SOURCES_WEBKIT_DIR}
47     VERBATIM)
48 list(APPEND WebKit_SOURCES ${DERIVED_SOURCES_WEBKIT_DIR}/WebKitVersion.h)
49
50 list(APPEND WebKit_INCLUDE_DIRECTORIES
51     "${CMAKE_BINARY_DIR}/../include/private"
52     "${CMAKE_BINARY_DIR}/../include/private/JavaScriptCore"
53     "${CMAKE_BINARY_DIR}/../include/private/WebCore"
54     "${WEBKIT_DIR}/win"
55     "${WEBKIT_DIR}/win/plugins"
56     "${WEBKIT_DIR}/win/WebCoreSupport"
57     "${DERIVED_SOURCES_WEBKIT_DIR}/include"
58     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces"
59     "${FORWARDING_HEADERS_DIR}/ANGLE"
60     "${FORWARDING_HEADERS_DIR}/ANGLE/include"
61     "${FORWARDING_HEADERS_DIR}/ANGLE/include/egl"
62     "${FORWARDING_HEADERS_DIR}/ANGLE/include/khr"
63     "${DERIVED_SOURCES_DIR}/WebKit"
64 )
65
66 list(APPEND WebKit_INCLUDES
67     win/CFDictionaryPropertyBag.h
68     win/COMEnumVariant.h
69     win/COMPropertyBag.h
70     win/COMVariantSetter.h
71     win/CodeAnalysisConfig.h
72     win/DOMCSSClasses.h
73     win/DOMCoreClasses.h
74     win/DOMEventsClasses.h
75     win/DOMHTMLClasses.h
76     win/DefaultDownloadDelegate.h
77     win/DefaultPolicyDelegate.h
78     win/ForEachCoClass.h
79     win/FullscreenVideoController.h
80     win/MarshallingHelpers.h
81     win/MemoryStream.h
82     win/ProgIDMacros.h
83     win/WebActionPropertyBag.h
84     win/WebApplicationCache.h
85     win/WebArchive.h
86     win/WebBackForwardList.h
87     win/WebCache.h
88     win/WebCachedFramePlatformData.h
89     win/WebCoreStatistics.h
90     win/WebDataSource.h
91     win/WebDatabaseManager.h
92     win/WebDocumentLoader.h
93     win/WebDownload.h
94     win/WebDropSource.h
95     win/WebElementPropertyBag.h
96     win/WebError.h
97     win/WebFrame.h
98     win/WebFramePolicyListener.h
99     win/WebGeolocationPolicyListener.h
100     win/WebGeolocationPosition.h
101     win/WebHTMLRepresentation.h
102     win/WebHistory.h
103     win/WebHistoryItem.h
104     win/WebJavaScriptCollector.h
105     win/WebKitCOMAPI.h
106     win/WebKitClassFactory.h
107     win/WebKitDLL.h
108     win/WebKitGraphics.h
109     win/WebKitLogging.h
110     win/WebKitStatistics.h
111     win/WebKitStatisticsPrivate.h
112     win/WebKitSystemBits.h
113     win/WebLocalizableStrings.h
114     win/WebMutableURLRequest.h
115     win/WebNavigationData.h
116     win/WebNotification.h
117     win/WebNotificationCenter.h
118     win/WebPreferenceKeysPrivate.h
119     win/WebPreferences.h
120     win/WebResource.h
121     win/WebScriptObject.h
122     win/WebScriptWorld.h
123     win/WebSecurityOrigin.h
124     win/WebSerializedJSValue.h
125     win/WebTextRenderer.h
126     win/WebURLAuthenticationChallenge.h
127     win/WebURLAuthenticationChallengeSender.h
128     win/WebURLCredential.h
129     win/WebURLProtectionSpace.h
130     win/WebURLResponse.h
131     win/WebUserContentURLPattern.h
132     win/WebView.h
133     win/WebWorkersPrivate.h
134 )
135
136 list(APPEND WebKit_SOURCES_Classes
137     cf/WebCoreSupport/WebInspectorClientCF.cpp
138
139     win/AccessibleBase.cpp
140     win/AccessibleDocument.cpp
141     win/AccessibleImage.cpp
142     win/AccessibleTextImpl.cpp
143     win/BackForwardList.cpp
144     win/CFDictionaryPropertyBag.cpp
145     win/DOMCSSClasses.cpp
146     win/DOMCoreClasses.cpp
147     win/DOMEventsClasses.cpp
148     win/DOMHTMLClasses.cpp
149     win/DefaultDownloadDelegate.cpp
150     win/DefaultPolicyDelegate.cpp
151     win/ForEachCoClass.cpp
152     win/FullscreenVideoController.cpp
153     win/MarshallingHelpers.cpp
154     win/MemoryStream.cpp
155     win/WebActionPropertyBag.cpp
156     win/WebApplicationCache.cpp
157     win/WebArchive.cpp
158     win/WebBackForwardList.cpp
159     win/WebCache.cpp
160     win/WebCoreStatistics.cpp
161     win/WebDataSource.cpp
162     win/WebDatabaseManager.cpp
163     win/WebDocumentLoader.cpp
164     win/WebDownload.cpp
165     win/WebDropSource.cpp
166     win/WebElementPropertyBag.cpp
167     win/WebError.cpp
168     win/WebFrame.cpp
169     win/WebFramePolicyListener.cpp
170     win/WebGeolocationPolicyListener.cpp
171     win/WebGeolocationPosition.cpp
172     win/WebHTMLRepresentation.cpp
173     win/WebHistory.cpp
174     win/WebHistoryItem.cpp
175     win/WebInspector.cpp
176     win/WebJavaScriptCollector.cpp
177     win/WebKitCOMAPI.cpp
178     win/WebKitClassFactory.cpp
179     win/WebKitDLL.cpp
180     win/WebKitLogging.cpp
181     win/WebKitMessageLoop.cpp
182     win/WebKitStatistics.cpp
183     win/WebKitSystemBits.cpp
184     win/WebLocalizableStrings.cpp
185     win/WebMutableURLRequest.cpp
186     win/WebNavigationData.cpp
187     win/WebNodeHighlight.cpp
188     win/WebNotification.cpp
189     win/WebNotificationCenter.cpp
190     win/WebPreferences.cpp
191     win/WebResource.cpp
192     win/WebScriptObject.cpp
193     win/WebScriptWorld.cpp
194     win/WebSecurityOrigin.cpp
195     win/WebSerializedJSValue.cpp
196     win/WebTextRenderer.cpp
197     win/WebURLAuthenticationChallenge.cpp
198     win/WebURLAuthenticationChallengeSender.cpp
199     win/WebURLCredential.cpp
200     win/WebURLProtectionSpace.cpp
201     win/WebURLResponse.cpp
202     win/WebUserContentURLPattern.cpp
203     win/WebView.cpp
204     win/WebWorkersPrivate.cpp
205
206     win/plugins/PluginDatabase.cpp
207     win/plugins/PluginDatabaseWin.cpp
208     win/plugins/PluginDebug.cpp
209     win/plugins/PluginMainThreadScheduler.cpp
210     win/plugins/PluginMessageThrottlerWin.cpp
211     win/plugins/PluginPackage.cpp
212     win/plugins/PluginPackageWin.cpp
213     win/plugins/PluginStream.cpp
214     win/plugins/PluginView.cpp
215     win/plugins/PluginViewWin.cpp
216     win/plugins/npapi.cpp
217
218     win/storage/WebDatabaseProvider.cpp
219 )
220
221 list(APPEND WebKit_SOURCES_WebCoreSupport
222     win/WebCoreSupport/AcceleratedCompositingContext.cpp
223     win/WebCoreSupport/EmbeddedWidget.cpp
224     win/WebCoreSupport/EmbeddedWidget.h
225     win/WebCoreSupport/WebChromeClient.cpp
226     win/WebCoreSupport/WebChromeClient.h
227     win/WebCoreSupport/WebContextMenuClient.cpp
228     win/WebCoreSupport/WebContextMenuClient.h
229     win/WebCoreSupport/WebDesktopNotificationsDelegate.cpp
230     win/WebCoreSupport/WebDesktopNotificationsDelegate.h
231     win/WebCoreSupport/WebDragClient.cpp
232     win/WebCoreSupport/WebDragClient.h
233     win/WebCoreSupport/WebEditorClient.cpp
234     win/WebCoreSupport/WebEditorClient.h
235     win/WebCoreSupport/WebFrameLoaderClient.cpp
236     win/WebCoreSupport/WebFrameLoaderClient.h
237     win/WebCoreSupport/WebFrameNetworkingContext.cpp
238     win/WebCoreSupport/WebFrameNetworkingContext.h
239     win/WebCoreSupport/WebGeolocationClient.cpp
240     win/WebCoreSupport/WebGeolocationClient.h
241     win/WebCoreSupport/WebInspectorClient.cpp
242     win/WebCoreSupport/WebInspectorClient.h
243     win/WebCoreSupport/WebInspectorDelegate.cpp
244     win/WebCoreSupport/WebInspectorDelegate.h
245     win/WebCoreSupport/WebPlatformStrategies.cpp
246     win/WebCoreSupport/WebPlatformStrategies.h
247     win/WebCoreSupport/WebPluginInfoProvider.cpp
248     win/WebCoreSupport/WebPluginInfoProvider.h
249     win/WebCoreSupport/WebVisitedLinkStore.cpp
250     win/WebCoreSupport/WebVisitedLinkStore.h
251 )
252
253 if (CMAKE_SIZEOF_VOID_P EQUAL 8)
254     enable_language(ASM_MASM)
255     if (MSVC)
256         set(MASM_EXECUTABLE ml64)
257         set(MASM_FLAGS /c /Fo)
258         add_custom_command(
259             OUTPUT ${DERIVED_SOURCES_WEBKIT_DIR}/PaintHooks.obj
260             MAIN_DEPENDENCY win/plugins/PaintHooks.asm
261             COMMAND ${MASM_EXECUTABLE} ${MASM_FLAGS}
262                 ${DERIVED_SOURCES_WEBKIT_DIR}/PaintHooks.obj
263                 ${CMAKE_CURRENT_SOURCE_DIR}/win/plugins/PaintHooks.asm
264             VERBATIM)
265         list(APPEND WebKit_SOURCES
266             ${DERIVED_SOURCES_WEBKIT_DIR}/PaintHooks.obj
267         )
268     else ()
269         list(APPEND WebKit_SOURCES
270             win/plugins/PaintHooks.asm
271         )
272     endif ()
273 endif ()
274
275 list(APPEND WebKit_SOURCES ${WebKit_INCLUDES} ${WebKit_SOURCES_Classes} ${WebKit_SOURCES_WebCoreSupport})
276
277 source_group(Includes FILES ${WebKit_INCLUDES})
278 source_group(Classes FILES ${WebKit_SOURCES_Classes})
279 source_group(WebCoreSupport FILES ${WebKit_SOURCES_WebCoreSupport})
280
281 # Build the COM interface:
282 macro(GENERATE_INTERFACE _infile _defines _depends)
283     get_filename_component(_filewe ${_infile} NAME_WE)
284     add_custom_command(
285         OUTPUT  ${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/${_filewe}.h
286         MAIN_DEPENDENCY ${_infile}
287         DEPENDS ${_depends}
288         COMMAND midl.exe /I "${CMAKE_CURRENT_SOURCE_DIR}/win/Interfaces" /I "${CMAKE_CURRENT_SOURCE_DIR}/win/Interfaces/Accessible2" /I "${DERIVED_SOURCES_WEBKIT_DIR}/include" /I "${CMAKE_CURRENT_SOURCE_DIR}/win" /WX /char signed /env win32 /tlb "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${_filewe}.tlb" /out "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces" /h "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/${_filewe}.h" /iid "${_filewe}_i.c" ${_defines} "${CMAKE_CURRENT_SOURCE_DIR}/${_infile}"
289         VERBATIM)
290     set_source_files_properties(${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/${_filewe}.h PROPERTIES GENERATED TRUE)
291     set_source_files_properties(${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/${_filewe}_i.c PROPERTIES GENERATED TRUE)
292 endmacro()
293
294 set(MIDL_DEFINES /D\ \"__PRODUCTION__=01\")
295
296 set(WEBKIT_IDL_DEPENDENCIES
297     win/Interfaces/AccessibleComparable.idl
298     win/Interfaces/DOMCSS.idl
299     win/Interfaces/DOMCore.idl
300     win/Interfaces/DOMEvents.idl
301     win/Interfaces/DOMExtensions.idl
302     win/Interfaces/DOMHTML.idl
303     win/Interfaces/DOMPrivate.idl
304     win/Interfaces/DOMRange.idl
305     win/Interfaces/DOMWindow.idl
306     win/Interfaces/IGEN_DOMObject.idl
307     win/Interfaces/IWebArchive.idl
308     win/Interfaces/IWebBackForwardList.idl
309     win/Interfaces/IWebBackForwardListPrivate.idl
310     win/Interfaces/IWebCache.idl
311     win/Interfaces/IWebCoreStatistics.idl
312     win/Interfaces/IWebDataSource.idl
313     win/Interfaces/IWebDatabaseManager.idl
314     win/Interfaces/IWebDesktopNotificationsDelegate.idl
315     win/Interfaces/IWebDocument.idl
316     win/Interfaces/IWebDownload.idl
317     win/Interfaces/IWebEditingDelegate.idl
318     win/Interfaces/IWebEmbeddedView.idl
319     win/Interfaces/IWebError.idl
320     win/Interfaces/IWebErrorPrivate.idl
321     win/Interfaces/IWebFormDelegate.idl
322     win/Interfaces/IWebFrame.idl
323     win/Interfaces/IWebFrameLoadDelegate.idl
324     win/Interfaces/IWebFrameLoadDelegatePrivate.idl
325     win/Interfaces/IWebFrameLoadDelegatePrivate2.idl
326     win/Interfaces/IWebFramePrivate.idl
327     win/Interfaces/IWebFrameView.idl
328     win/Interfaces/IWebGeolocationPolicyListener.idl
329     win/Interfaces/IWebGeolocationPosition.idl
330     win/Interfaces/IWebGeolocationProvider.idl
331     win/Interfaces/IWebHTMLRepresentation.idl
332     win/Interfaces/IWebHTTPURLResponse.idl
333     win/Interfaces/IWebHistory.idl
334     win/Interfaces/IWebHistoryDelegate.idl
335     win/Interfaces/IWebHistoryItem.idl
336     win/Interfaces/IWebHistoryItemPrivate.idl
337     win/Interfaces/IWebHistoryPrivate.idl
338     win/Interfaces/IWebInspector.idl
339     win/Interfaces/IWebInspectorPrivate.idl
340     win/Interfaces/IWebJavaScriptCollector.idl
341     win/Interfaces/IWebKitStatistics.idl
342     win/Interfaces/IWebMutableURLRequest.idl
343     win/Interfaces/IWebMutableURLRequestPrivate.idl
344     win/Interfaces/IWebNavigationData.idl
345     win/Interfaces/IWebNotification.idl
346     win/Interfaces/IWebNotificationCenter.idl
347     win/Interfaces/IWebNotificationObserver.idl
348     win/Interfaces/IWebPolicyDelegate.idl
349     win/Interfaces/IWebPolicyDelegatePrivate.idl
350     win/Interfaces/IWebPreferences.idl
351     win/Interfaces/IWebPreferencesPrivate.idl
352     win/Interfaces/IWebResource.idl
353     win/Interfaces/IWebResourceLoadDelegate.idl
354     win/Interfaces/IWebResourceLoadDelegatePrivate.idl
355     win/Interfaces/IWebResourceLoadDelegatePrivate2.idl
356     win/Interfaces/IWebScriptObject.idl
357     win/Interfaces/IWebScriptWorld.idl
358     win/Interfaces/IWebSecurityOrigin.idl
359     win/Interfaces/IWebSerializedJSValue.idl
360     win/Interfaces/IWebSerializedJSValuePrivate.idl
361     win/Interfaces/IWebTextRenderer.idl
362     win/Interfaces/IWebUIDelegate.idl
363     win/Interfaces/IWebUIDelegate2.idl
364     win/Interfaces/IWebUIDelegatePrivate.idl
365     win/Interfaces/IWebURLAuthenticationChallenge.idl
366     win/Interfaces/IWebURLRequest.idl
367     win/Interfaces/IWebURLResponse.idl
368     win/Interfaces/IWebURLResponsePrivate.idl
369     win/Interfaces/IWebUndoManager.idl
370     win/Interfaces/IWebUndoTarget.idl
371     win/Interfaces/IWebUserContentURLPattern.idl
372     win/Interfaces/IWebView.idl
373     win/Interfaces/IWebViewPrivate.idl
374     win/Interfaces/IWebWorkersPrivate.idl
375     win/Interfaces/JavaScriptCoreAPITypes.idl
376     win/Interfaces/WebKit.idl
377     win/Interfaces/WebScrollbarTypes.idl
378
379     win/Interfaces/Accessible2/Accessible2.idl
380     win/Interfaces/Accessible2/Accessible2_2.idl
381     win/Interfaces/Accessible2/AccessibleApplication.idl
382     win/Interfaces/Accessible2/AccessibleEditableText.idl
383     win/Interfaces/Accessible2/AccessibleRelation.idl
384     win/Interfaces/Accessible2/AccessibleStates.idl
385     win/Interfaces/Accessible2/AccessibleText.idl
386     win/Interfaces/Accessible2/AccessibleText2.idl
387     win/Interfaces/Accessible2/IA2CommonTypes.idl
388     "${DERIVED_SOURCES_WEBKIT_DIR}/include/autoversion.h"
389 )
390
391 add_custom_command(
392     OUTPUT ${DERIVED_SOURCES_WEBKIT_DIR}/include/autoversion.h
393     WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
394     COMMAND ${PERL_EXECUTABLE} ${WEBKIT_LIBRARIES_DIR}/tools/scripts/auto-version.pl ${DERIVED_SOURCES_WEBKIT_DIR}
395     VERBATIM)
396
397 GENERATE_INTERFACE(win/Interfaces/WebKit.idl ${MIDL_DEFINES} "${WEBKIT_IDL_DEPENDENCIES}")
398 GENERATE_INTERFACE(win/Interfaces/Accessible2/AccessibleApplication.idl ${MIDL_DEFINES} "${WEBKIT_IDL_DEPENDENCIES}")
399 GENERATE_INTERFACE(win/Interfaces/Accessible2/Accessible2.idl ${MIDL_DEFINES} "${WEBKIT_IDL_DEPENDENCIES}")
400 GENERATE_INTERFACE(win/Interfaces/Accessible2/Accessible2_2.idl ${MIDL_DEFINES} "${WEBKIT_IDL_DEPENDENCIES}")
401 GENERATE_INTERFACE(win/Interfaces/Accessible2/AccessibleRelation.idl ${MIDL_DEFINES} "${WEBKIT_IDL_DEPENDENCIES}")
402 GENERATE_INTERFACE(win/Interfaces/Accessible2/AccessibleStates.idl ${MIDL_DEFINES} "${WEBKIT_IDL_DEPENDENCIES}")
403 GENERATE_INTERFACE(win/Interfaces/Accessible2/IA2CommonTypes.idl ${MIDL_DEFINES} "${WEBKIT_IDL_DEPENDENCIES}")
404 GENERATE_INTERFACE(win/Interfaces/Accessible2/AccessibleEditableText.idl ${MIDL_DEFINES} "${WEBKIT_IDL_DEPENDENCIES}")
405 GENERATE_INTERFACE(win/Interfaces/Accessible2/AccessibleText.idl ${MIDL_DEFINES} "${WEBKIT_IDL_DEPENDENCIES}")
406 GENERATE_INTERFACE(win/Interfaces/Accessible2/AccessibleText2.idl ${MIDL_DEFINES} "${WEBKIT_IDL_DEPENDENCIES}")
407
408 add_library(WebKitGUID STATIC
409     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/WebKit.h"
410     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleApplication.h"
411     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/Accessible2.h"
412     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/Accessible2_2.h"
413     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleRelation.h"
414     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleStates.h"
415     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/IA2CommonTypes.h"
416     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleEditableText.h"
417     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleText.h"
418     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleText2.h"
419     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/WebKit_i.c"
420     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleApplication_i.c"
421     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/Accessible2_i.c"
422     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/Accessible2_2_i.c"
423     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleRelation_i.c"
424     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleEditableText_i.c"
425     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleText_i.c"
426     "${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/AccessibleText2_i.c"
427 )
428 set_target_properties(WebKitGUID PROPERTIES OUTPUT_NAME WebKitGUID${DEBUG_SUFFIX})
429
430 list(APPEND WebKit_LIBRARIES
431     PRIVATE Comctl32
432     PRIVATE Comsupp
433     PRIVATE Crypt32
434     PRIVATE D2d1
435     PRIVATE Dwrite
436     PRIVATE dxguid
437     PRIVATE Iphlpapi
438     PRIVATE Psapi
439     PRIVATE Rpcrt4
440     PRIVATE Shlwapi
441     PRIVATE Usp10
442     PRIVATE Version
443     PRIVATE Winmm
444     PRIVATE WebKitGUID${DEBUG_SUFFIX}
445     PRIVATE WebCoreDerivedSources${DEBUG_SUFFIX}
446     PRIVATE WindowsCodecs
447 )
448
449 if (ENABLE_GRAPHICS_CONTEXT_3D)
450     list(APPEND WebKit_LIBRARIES
451         libANGLE${DEBUG_SUFFIX}
452         libEGL${DEBUG_SUFFIX}
453         libGLESv2${DEBUG_SUFFIX}
454     )
455 endif ()
456
457 set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /SUBSYSTEM:WINDOWS")
458 set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /SUBSYSTEM:WINDOWS")
459
460 # We need the webkit libraries to come before the system default libraries to prevent symbol conflicts with uuid.lib.
461 # To do this we add system default libs as webkit libs and zero out system default libs.
462 string(REPLACE " " "\;" CXX_LIBS ${CMAKE_CXX_STANDARD_LIBRARIES})
463 list(APPEND WebKit_LIBRARIES ${CXX_LIBS})
464 set(CMAKE_CXX_STANDARD_LIBRARIES "")
465
466 set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /NODEFAULTLIB:MSVCRT /NODEFAULTLIB:MSVCRTD")
467
468 # If this directory isn't created before midl runs and attempts to output WebKit.tlb,
469 # It fails with an unusual error - midl failed - failed to save all changes
470 file(MAKE_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY})
471 file(MAKE_DIRECTORY ${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces)
472
473 set(WebKitGUID_PRE_BUILD_COMMAND "${CMAKE_BINARY_DIR}/DerivedSources/WebKit/preBuild.cmd")
474 file(WRITE "${WebKitGUID_PRE_BUILD_COMMAND}" "@xcopy /y /d /f \"${CMAKE_CURRENT_SOURCE_DIR}/win/WebKitCOMAPI.h\" \"${FORWARDING_HEADERS_DIR}/WebKit\" >nul 2>nul\n@xcopy /y /d /f \"${CMAKE_CURRENT_SOURCE_DIR}/win/CFDictionaryPropertyBag.h\" \"${FORWARDING_HEADERS_DIR}/WebKit\" >nul 2>nul\n")
475 file(MAKE_DIRECTORY ${FORWARDING_HEADERS_DIR}/WebKit)
476 add_custom_command(TARGET WebKitGUID PRE_BUILD COMMAND ${WebKitGUID_PRE_BUILD_COMMAND} VERBATIM)
477
478 set(WebKitGUID_POST_BUILD_COMMAND "${CMAKE_BINARY_DIR}/DerivedSources/WebKit/postBuild.cmd")
479 file(WRITE "${WebKitGUID_POST_BUILD_COMMAND}" "@xcopy /y /d /f \"${DERIVED_SOURCES_WEBKIT_DIR}/Interfaces/*.h\" \"${FORWARDING_HEADERS_DIR}/WebKit\" >nul 2>nul")
480 add_custom_command(TARGET WebKitGUID POST_BUILD COMMAND ${WebKitGUID_POST_BUILD_COMMAND} VERBATIM)
481
482 set(WebKit_OUTPUT_NAME
483     WebKit${DEBUG_SUFFIX}
484 )