[CMake] WebKitFS.cmake depends on options set in Option cmake files that are included...
[WebKit-https.git] / Source / WebKit / PlatformMac.cmake
1 add_definitions("-ObjC++ -std=c++14")
2 find_library(APPLICATIONSERVICES_LIBRARY ApplicationServices)
3 find_library(CARBON_LIBRARY Carbon)
4 find_library(QUARTZ_LIBRARY Quartz)
5 find_library(AVFOUNDATION_LIBRARY AVFoundation)
6 find_library(AVFAUDIO_LIBRARY AVFAudio HINTS ${AVFOUNDATION_LIBRARY}/Versions/*/Frameworks)
7 add_definitions(-iframework ${QUARTZ_LIBRARY}/Frameworks)
8 add_definitions(-iframework ${CARBON_LIBRARY}/Frameworks)
9 add_definitions(-iframework ${APPLICATIONSERVICES_LIBRARY}/Versions/Current/Frameworks)
10 add_definitions(-DWK_XPC_SERVICE_SUFFIX=".Development")
11
12 list(APPEND WebKit2_LIBRARIES
13     PRIVATE WebKit
14     ${APPLICATIONSERVICES_LIBRARY}
15 )
16
17 if (NOT AVFAUDIO_LIBRARY-NOTFOUND)
18     list(APPEND WebKit2_LIBRARIES ${AVFAUDIO_LIBRARY})
19 endif ()
20
21 list(APPEND WebKit2_SOURCES
22     DatabaseProcess/mac/DatabaseProcessMac.mm
23
24     NetworkProcess/CustomProtocols/Cocoa/LegacyCustomProtocolManagerCocoa.mm
25
26     NetworkProcess/Downloads/PendingDownload.cpp
27
28     NetworkProcess/Downloads/cocoa/DownloadCocoa.mm
29
30     NetworkProcess/Downloads/mac/DownloadMac.mm
31
32     NetworkProcess/cache/NetworkCacheCodersCocoa.cpp
33     NetworkProcess/cache/NetworkCacheDataCocoa.mm
34     NetworkProcess/cache/NetworkCacheIOChannelCocoa.mm
35
36     NetworkProcess/cocoa/NetworkDataTaskCocoa.mm
37     NetworkProcess/cocoa/NetworkProcessCocoa.mm
38     NetworkProcess/cocoa/NetworkSessionCocoa.mm
39
40     NetworkProcess/mac/NetworkLoadMac.mm
41     NetworkProcess/mac/NetworkProcessMac.mm
42     NetworkProcess/mac/RemoteNetworkingContext.mm
43
44     Platform/IPC/mac/ConnectionMac.mm
45     Platform/IPC/mac/MachMessage.cpp
46
47     Platform/cf/ModuleCF.cpp
48
49     Platform/cg/CGUtilities.cpp
50
51     Platform/classifier/ResourceLoadStatisticsClassifier.cpp
52
53     Platform/classifier/cocoa/ResourceLoadStatisticsClassifierCocoa.cpp
54
55     Platform/foundation/LoggingFoundation.mm
56
57     Platform/cocoa/SharedMemoryCocoa.cpp
58
59     Platform/mac/LayerHostingContext.mm
60     Platform/mac/MachUtilities.cpp
61     Platform/mac/MenuUtilities.mm
62     Platform/mac/StringUtilities.mm
63
64     Platform/unix/EnvironmentUtilities.cpp
65
66     PluginProcess/mac/PluginControllerProxyMac.mm
67     PluginProcess/mac/PluginProcessMac.mm
68     PluginProcess/mac/PluginProcessShim.mm
69
70     Shared/APIWebArchive.mm
71     Shared/APIWebArchiveResource.mm
72
73     Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm
74
75     Shared/API/Cocoa/RemoteObjectInvocation.mm
76     Shared/API/Cocoa/RemoteObjectRegistry.mm
77     Shared/API/Cocoa/WKBrowsingContextHandle.mm
78     Shared/API/Cocoa/WKRemoteObject.mm
79     Shared/API/Cocoa/WKRemoteObjectCoder.mm
80     Shared/API/Cocoa/WebKit.m
81     Shared/API/Cocoa/_WKFrameHandle.mm
82     Shared/API/Cocoa/_WKHitTestResult.mm
83     Shared/API/Cocoa/_WKNSFileManagerExtras.mm
84     Shared/API/Cocoa/_WKRemoteObjectInterface.mm
85     Shared/API/Cocoa/_WKRemoteObjectRegistry.mm
86
87     Shared/API/c/cf/WKErrorCF.cpp
88     Shared/API/c/cf/WKStringCF.mm
89     Shared/API/c/cf/WKURLCF.mm
90
91     Shared/API/c/cg/WKImageCG.cpp
92
93     Shared/API/c/mac/WKCertificateInfoMac.mm
94     Shared/API/c/mac/WKObjCTypeWrapperRef.mm
95     Shared/API/c/mac/WKURLRequestNS.mm
96     Shared/API/c/mac/WKURLResponseNS.mm
97     Shared/API/c/mac/WKWebArchive.cpp
98     Shared/API/c/mac/WKWebArchiveResource.cpp
99
100     Shared/Authentication/mac/AuthenticationManager.mac.mm
101
102     Shared/Cocoa/APIDataCocoa.mm
103     Shared/Cocoa/APIObject.mm
104     Shared/Cocoa/ChildProcessCocoa.mm
105     Shared/Cocoa/CompletionHandlerCallChecker.mm
106     Shared/Cocoa/DataDetectionResult.mm
107     Shared/Cocoa/LoadParametersCocoa.mm
108     Shared/Cocoa/WKNSArray.mm
109     Shared/Cocoa/WKNSData.mm
110     Shared/Cocoa/WKNSDictionary.mm
111     Shared/Cocoa/WKNSError.mm
112     Shared/Cocoa/WKNSNumber.mm
113     Shared/Cocoa/WKNSString.mm
114     Shared/Cocoa/WKNSURL.mm
115     Shared/Cocoa/WKNSURLExtras.mm
116     Shared/Cocoa/WKNSURLRequest.mm
117     Shared/Cocoa/WKObject.mm
118     Shared/Cocoa/WebErrorsCocoa.mm
119     Shared/Cocoa/WebKit2InitializeCocoa.mm
120
121     Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm
122     Shared/Plugins/Netscape/mac/PluginInformationMac.mm
123
124     Shared/Plugins/mac/PluginSandboxProfile.mm
125
126     Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp
127
128     Shared/cf/ArgumentCodersCF.cpp
129
130     Shared/cg/ShareableBitmapCG.cpp
131
132     Shared/mac/ArgumentCodersMac.mm
133     Shared/mac/AttributedString.mm
134     Shared/mac/ChildProcessMac.mm
135     Shared/mac/CodeSigning.mm
136     Shared/mac/ColorSpaceData.mm
137     Shared/mac/CookieStorageShim.mm
138     Shared/mac/CookieStorageShimLibrary.cpp
139     Shared/mac/HangDetectionDisablerMac.mm
140     Shared/mac/NativeWebGestureEventMac.mm
141     Shared/mac/NativeWebKeyboardEventMac.mm
142     Shared/mac/NativeWebMouseEventMac.mm
143     Shared/mac/NativeWebWheelEventMac.mm
144     Shared/mac/ObjCObjectGraph.mm
145     Shared/mac/PDFKitImports.mm
146     Shared/mac/PasteboardTypes.mm
147     Shared/mac/PrintInfoMac.mm
148     Shared/mac/RemoteLayerBackingStore.mm
149     Shared/mac/RemoteLayerBackingStoreCollection.mm
150     Shared/mac/RemoteLayerTreePropertyApplier.mm
151     Shared/mac/RemoteLayerTreeTransaction.mm
152     Shared/mac/SandboxExtensionMac.mm
153     Shared/mac/SandboxInitialiationParametersMac.mm
154     Shared/mac/SandboxUtilities.mm
155     Shared/mac/SecItemRequestData.cpp
156     Shared/mac/SecItemResponseData.cpp
157     Shared/mac/SecItemShim.cpp
158     Shared/mac/WebCoreArgumentCodersMac.mm
159     Shared/mac/WebEventFactory.mm
160     Shared/mac/WebGestureEvent.cpp
161     Shared/mac/WebHitTestResultData.mm
162     Shared/mac/WebMemorySampler.mac.mm
163
164     UIProcess/HighPerformanceGraphicsUsageSampler.cpp
165     UIProcess/PerActivityStateCPUUsageSampler.cpp
166     UIProcess/WebContextMenuListenerProxy.cpp
167     UIProcess/WebResourceLoadStatisticsStore.cpp
168     UIProcess/WebResourceLoadStatisticsTelemetry.cpp
169
170     UIProcess/Automation/WebAutomationSession.cpp
171
172     UIProcess/Automation/cocoa/WebAutomationSessionCocoa.mm
173
174     UIProcess/Automation/mac/WebAutomationSessionMac.mm
175
176     UIProcess/API/APIUserScript.cpp
177     UIProcess/API/APIUserStyleSheet.cpp
178     UIProcess/API/APIWebsiteDataRecord.cpp
179
180     UIProcess/API/C/mac/WKContextPrivateMac.mm
181     UIProcess/API/C/mac/WKPagePrivateMac.mm
182
183     UIProcess/API/Cocoa/APIContentRuleListStoreCocoa.mm
184     UIProcess/API/Cocoa/APISerializedScriptValueCocoa.mm
185     UIProcess/API/Cocoa/APIWebsiteDataStoreCocoa.mm
186     UIProcess/API/Cocoa/LegacyBundleForClass.mm
187     UIProcess/API/Cocoa/WKBackForwardList.mm
188     UIProcess/API/Cocoa/WKBackForwardListItem.mm
189     UIProcess/API/Cocoa/WKBrowsingContextController.mm
190     UIProcess/API/Cocoa/WKBrowsingContextGroup.mm
191     UIProcess/API/Cocoa/WKConnection.mm
192     UIProcess/API/Cocoa/WKContentRuleList.mm
193     UIProcess/API/Cocoa/WKContentRuleListStore.mm
194     UIProcess/API/Cocoa/WKError.mm
195     UIProcess/API/Cocoa/WKFrameInfo.mm
196     UIProcess/API/Cocoa/WKHTTPCookieStore.mm
197     UIProcess/API/Cocoa/WKMenuItemIdentifiers.mm
198     UIProcess/API/Cocoa/WKNSURLAuthenticationChallenge.mm
199     UIProcess/API/Cocoa/WKNavigation.mm
200     UIProcess/API/Cocoa/WKNavigationAction.mm
201     UIProcess/API/Cocoa/WKNavigationData.mm
202     UIProcess/API/Cocoa/WKNavigationResponse.mm
203     UIProcess/API/Cocoa/WKOpenPanelParameters.mm
204     UIProcess/API/Cocoa/WKPreferences.mm
205     UIProcess/API/Cocoa/WKPreviewActionItem.mm
206     UIProcess/API/Cocoa/WKPreviewActionItemIdentifiers.mm
207     UIProcess/API/Cocoa/WKPreviewElementInfo.mm
208     UIProcess/API/Cocoa/WKProcessGroup.mm
209     UIProcess/API/Cocoa/WKProcessPool.mm
210     UIProcess/API/Cocoa/WKScriptMessage.mm
211     UIProcess/API/Cocoa/WKSecurityOrigin.mm
212     UIProcess/API/Cocoa/WKTypeRefWrapper.mm
213     UIProcess/API/Cocoa/WKURLSchemeTask.mm
214     UIProcess/API/Cocoa/WKUserContentController.mm
215     UIProcess/API/Cocoa/WKUserScript.mm
216     UIProcess/API/Cocoa/WKWebView.mm
217     UIProcess/API/Cocoa/WKWebViewConfiguration.mm
218     UIProcess/API/Cocoa/WKWebsiteDataRecord.mm
219     UIProcess/API/Cocoa/WKWebsiteDataStore.mm
220     UIProcess/API/Cocoa/WKWindowFeatures.mm
221     UIProcess/API/Cocoa/_WKActivatedElementInfo.mm
222     UIProcess/API/Cocoa/_WKAutomationSession.mm
223     UIProcess/API/Cocoa/_WKContextMenuElementInfo.mm
224     UIProcess/API/Cocoa/_WKDownload.mm
225     UIProcess/API/Cocoa/_WKElementAction.mm
226     UIProcess/API/Cocoa/_WKErrorRecoveryAttempting.mm
227     UIProcess/API/Cocoa/_WKExperimentalFeature.mm
228     UIProcess/API/Cocoa/_WKLinkIconParameters.mm
229     UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm
230     UIProcess/API/Cocoa/_WKRemoteWebInspectorViewController.mm
231     UIProcess/API/Cocoa/_WKSessionState.mm
232     UIProcess/API/Cocoa/_WKThumbnailView.mm
233     UIProcess/API/Cocoa/_WKUserContentExtensionStore.mm
234     UIProcess/API/Cocoa/_WKUserContentFilter.mm
235     UIProcess/API/Cocoa/_WKUserContentWorld.mm
236     UIProcess/API/Cocoa/_WKUserInitiatedAction.mm
237     UIProcess/API/Cocoa/_WKUserStyleSheet.mm
238     UIProcess/API/Cocoa/_WKVisitedLinkProvider.mm
239     UIProcess/API/Cocoa/_WKVisitedLinkStore.mm
240     UIProcess/API/Cocoa/_WKWebsiteDataSize.mm
241     UIProcess/API/Cocoa/_WKWebsiteDataStore.mm
242     UIProcess/API/Cocoa/_WKWebsitePolicies.mm
243
244     UIProcess/API/mac/WKView.mm
245
246     UIProcess/Cocoa/AutomationClient.mm
247     UIProcess/Cocoa/AutomationSessionClient.mm
248     UIProcess/Cocoa/DiagnosticLoggingClient.mm
249     UIProcess/Cocoa/DownloadClient.mm
250     UIProcess/Cocoa/FindClient.mm
251     UIProcess/Cocoa/FullscreenClient.mm
252     UIProcess/Cocoa/IconLoadingDelegate.mm
253     UIProcess/Cocoa/LegacyCustomProtocolManagerClient.mm
254     UIProcess/Cocoa/NavigationState.mm
255     UIProcess/Cocoa/RemoteLayerTreeScrollingPerformanceData.mm
256     UIProcess/Cocoa/SessionStateCoding.mm
257     UIProcess/Cocoa/UIDelegate.mm
258     UIProcess/Cocoa/VersionChecks.mm
259     UIProcess/Cocoa/ViewGestureController.cpp
260     UIProcess/Cocoa/WKReloadFrameErrorRecoveryAttempter.mm
261     UIProcess/Cocoa/WKWebViewContentProviderRegistry.mm
262     UIProcess/Cocoa/WebPageProxyCocoa.mm
263     UIProcess/Cocoa/WebPasteboardProxyCocoa.mm
264     UIProcess/Cocoa/WebProcessPoolCocoa.mm
265     UIProcess/Cocoa/WebProcessProxyCocoa.mm
266     UIProcess/Cocoa/WebResourceLoadStatisticsStoreCocoa.mm
267     UIProcess/Cocoa/WebURLSchemeHandlerCocoa.mm
268     UIProcess/Cocoa/WebViewImpl.mm
269
270     UIProcess/Launcher/mac/ProcessLauncherMac.mm
271
272     UIProcess/Network/mac/NetworkProcessProxyMac.mm
273
274     UIProcess/Plugins/mac/PluginInfoStoreMac.mm
275     UIProcess/Plugins/mac/PluginProcessManagerMac.mm
276     UIProcess/Plugins/mac/PluginProcessProxyMac.mm
277
278     UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp
279     UIProcess/Scrolling/RemoteScrollingTree.cpp
280
281     UIProcess/WebStorage/StorageManager.cpp
282
283     UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm
284
285     UIProcess/mac/CorrectionPanel.mm
286     UIProcess/mac/LegacySessionStateCoding.cpp
287     UIProcess/mac/PageClientImpl.mm
288     UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm
289     UIProcess/mac/RemoteLayerTreeHost.mm
290     UIProcess/mac/RemoteWebInspectorProxyMac.mm
291     UIProcess/mac/SecItemShimProxy.cpp
292     UIProcess/mac/ServicesController.mm
293     UIProcess/mac/TextCheckerMac.mm
294     UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm
295     UIProcess/mac/ViewGestureControllerMac.mm
296     UIProcess/mac/ViewSnapshotStore.mm
297     UIProcess/mac/WKFullKeyboardAccessWatcher.mm
298     UIProcess/mac/WKFullScreenWindowController.mm
299     UIProcess/mac/WKImmediateActionController.mm
300     UIProcess/mac/WKPrintingView.mm
301     UIProcess/mac/WKSharingServicePickerDelegate.mm
302     UIProcess/mac/WKTextFinderClient.mm
303     UIProcess/mac/WKTextInputWindowController.mm
304     UIProcess/mac/WKViewLayoutStrategy.mm
305     UIProcess/mac/WKWebInspectorWKWebView.mm
306     UIProcess/mac/WebColorPickerMac.mm
307     UIProcess/mac/WebContextMenuProxyMac.mm
308     UIProcess/mac/WebCookieManagerProxyMac.mm
309     UIProcess/mac/WebInspectorProxyMac.mm
310     UIProcess/mac/WebPageProxyMac.mm
311     UIProcess/mac/WebPopupMenuProxyMac.mm
312     UIProcess/mac/WebPreferencesMac.mm
313     UIProcess/mac/WebProcessProxyMac.mm
314     UIProcess/mac/WindowServerConnection.mm
315
316     WebProcess/Cookies/mac/WebCookieManagerMac.mm
317
318     WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.mm
319     WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFrame.mm
320     WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInHitTestResult.mm
321     WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandle.mm
322     WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInPageGroup.mm
323     WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInRangeHandle.mm
324     WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInScriptWorld.mm
325
326     WebProcess/InjectedBundle/API/mac/WKDOMDocument.mm
327     WebProcess/InjectedBundle/API/mac/WKDOMElement.mm
328     WebProcess/InjectedBundle/API/mac/WKDOMInternals.mm
329     WebProcess/InjectedBundle/API/mac/WKDOMNode.mm
330     WebProcess/InjectedBundle/API/mac/WKDOMRange.mm
331     WebProcess/InjectedBundle/API/mac/WKDOMText.mm
332     WebProcess/InjectedBundle/API/mac/WKDOMTextIterator.mm
333     WebProcess/InjectedBundle/API/mac/WKWebProcessPlugIn.mm
334     WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm
335
336     WebProcess/InjectedBundle/mac/InjectedBundleMac.mm
337
338     WebProcess/MediaCache/WebMediaKeyStorageManager.cpp
339
340     WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm
341     WebProcess/Plugins/Netscape/mac/PluginProxyMac.mm
342
343     WebProcess/Plugins/PDF/PDFPlugin.mm
344     WebProcess/Plugins/PDF/PDFPluginAnnotation.mm
345     WebProcess/Plugins/PDF/PDFPluginChoiceAnnotation.mm
346     WebProcess/Plugins/PDF/PDFPluginPasswordField.mm
347     WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm
348
349     WebProcess/Scrolling/RemoteScrollingCoordinator.mm
350
351     WebProcess/WebCoreSupport/WebPasteboardOverrides.cpp
352     WebProcess/WebCoreSupport/WebValidationMessageClient.cpp
353
354     WebProcess/WebCoreSupport/mac/WebAlternativeTextClient.cpp
355     WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm
356     WebProcess/WebCoreSupport/mac/WebDragClientMac.mm
357     WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm
358     WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm
359     WebProcess/WebCoreSupport/mac/WebPopupMenuMac.mm
360     WebProcess/WebCoreSupport/mac/WebSystemInterface.mm
361
362     WebProcess/WebPage/ViewGestureGeometryCollector.cpp
363
364     WebProcess/WebPage/Cocoa/RemoteLayerTreeDisplayRefreshMonitor.mm
365     WebProcess/WebPage/Cocoa/WebPageCocoa.mm
366
367     WebProcess/WebPage/mac/GraphicsLayerCARemote.cpp
368     WebProcess/WebPage/mac/PageBannerMac.mm
369     WebProcess/WebPage/mac/PlatformCAAnimationRemote.mm
370     WebProcess/WebPage/mac/PlatformCALayerRemote.cpp
371     WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.mm
372     WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.cpp
373     WebProcess/WebPage/mac/RemoteLayerTreeContext.mm
374     WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm
375     WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm
376     WebProcess/WebPage/mac/WKAccessibilityWebPageObjectBase.mm
377     WebProcess/WebPage/mac/WKAccessibilityWebPageObjectMac.mm
378     WebProcess/WebPage/mac/WebInspectorUIMac.mm
379     WebProcess/WebPage/mac/WebPageMac.mm
380
381     WebProcess/cocoa/WebProcessCocoa.mm
382
383     WebProcess/mac/SecItemShimLibrary.mm
384 )
385
386 list(APPEND WebKit2_INCLUDE_DIRECTORIES
387     "${PAL_DIR}"
388     "${WEBKIT2_DIR}/NetworkProcess/cocoa"
389     "${WEBKIT2_DIR}/NetworkProcess/mac"
390     "${WEBKIT2_DIR}/PluginProcess/mac"
391     "${WEBKIT2_DIR}/UIProcess/mac"
392     "${WEBKIT2_DIR}/UIProcess/API/C/mac"
393     "${WEBKIT2_DIR}/UIProcess/API/Cocoa"
394     "${WEBKIT2_DIR}/UIProcess/API/mac"
395     "${WEBKIT2_DIR}/UIProcess/Cocoa"
396     "${WEBKIT2_DIR}/UIProcess/Launcher/mac"
397     "${WEBKIT2_DIR}/UIProcess/Scrolling"
398     "${WEBKIT2_DIR}/UIProcess/ios"
399     "${WEBKIT2_DIR}/Platform/cg"
400     "${WEBKIT2_DIR}/Platform/classifier"
401     "${WEBKIT2_DIR}/Platform/classifier/cocoa"
402     "${WEBKIT2_DIR}/Platform/mac"
403     "${WEBKIT2_DIR}/Platform/unix"
404     "${WEBKIT2_DIR}/Platform/spi/Cocoa"
405     "${WEBKIT2_DIR}/Platform/spi/mac"
406     "${WEBKIT2_DIR}/Platform/IPC/mac"
407     "${WEBKIT2_DIR}/Platform/spi/Cocoa"
408     "${WEBKIT2_DIR}/Shared/API/Cocoa"
409     "${WEBKIT2_DIR}/Shared/API/c/cf"
410     "${WEBKIT2_DIR}/Shared/API/c/cg"
411     "${WEBKIT2_DIR}/Shared/API/c/mac"
412     "${WEBKIT2_DIR}/Shared/cf"
413     "${WEBKIT2_DIR}/Shared/Cocoa"
414     "${WEBKIT2_DIR}/Shared/EntryPointUtilities/mac/XPCService"
415     "${WEBKIT2_DIR}/Shared/mac"
416     "${WEBKIT2_DIR}/Shared/Plugins/mac"
417     "${WEBKIT2_DIR}/Shared/Scrolling"
418     "${WEBKIT2_DIR}/WebProcess/cocoa"
419     "${WEBKIT2_DIR}/WebProcess/mac"
420     "${WEBKIT2_DIR}/WebProcess/InjectedBundle/API/Cocoa"
421     "${WEBKIT2_DIR}/WebProcess/InjectedBundle/API/mac"
422     "${WEBKIT2_DIR}/WebProcess/Plugins/PDF"
423     "${WEBKIT2_DIR}/WebProcess/Plugins/Netscape/mac"
424     "${WEBKIT2_DIR}/WebProcess/Scrolling"
425     "${WEBKIT2_DIR}/WebProcess/WebPage/Cocoa"
426     "${WEBKIT2_DIR}/WebProcess/WebPage/mac"
427     "${WEBKIT2_DIR}/WebProcess/WebCoreSupport/mac"
428     "${FORWARDING_HEADERS_DIR}/WebCore"
429     "${DERIVED_SOURCES_WEBCORE_DIR}"
430 )
431
432 set(XPCService_SOURCES
433     Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.mm
434     Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.mm
435 )
436
437 set(WebProcess_SOURCES
438     WebProcess/EntryPoint/mac/XPCService/WebContentServiceEntryPoint.mm
439     ${XPCService_SOURCES}
440 )
441
442 set(PluginProcess_SOURCES
443     PluginProcess/EntryPoint/mac/XPCService/PluginServiceEntryPoint.mm
444     ${XPCService_SOURCES}
445 )
446
447 list(APPEND NetworkProcess_SOURCES
448     NetworkProcess/EntryPoint/mac/XPCService/NetworkServiceEntryPoint.mm
449     ${XPCService_SOURCES}
450 )
451
452 list(APPEND StorageProcess_SOURCES
453     DatabaseProcess/EntryPoint/mac/XPCService/DatabaseServiceEntryPoint.mm
454     ${XPCService_SOURCES}
455 )
456
457 # FIXME: These should not have Development in production builds.
458 set(WebKit2_WebProcess_OUTPUT_NAME com.apple.WebKit.WebContent.Development)
459 set(WebKit2_NetworkProcess_OUTPUT_NAME com.apple.WebKit.Networking.Development)
460
461 add_definitions("-include WebKit2Prefix.h")
462
463 set(WebKit2_FORWARDING_HEADERS_FILES
464     Shared/API/c/WKDiagnosticLoggingResultType.h
465
466     UIProcess/API/C/WKPageDiagnosticLoggingClient.h
467     UIProcess/API/C/WKPageNavigationClient.h
468     UIProcess/API/C/WKPageRenderingProgressEvents.h
469 )
470
471 list(APPEND WebKit2_MESSAGES_IN_FILES
472     Shared/API/Cocoa/RemoteObjectRegistry.messages.in
473
474     UIProcess/Cocoa/ViewGestureController.messages.in
475     UIProcess/Cocoa/WebVideoFullscreenManagerProxy.messages.in
476
477     UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.messages.in
478     UIProcess/mac/SecItemShimProxy.messages.in
479
480     WebProcess/Scrolling/RemoteScrollingCoordinator.messages.in
481     WebProcess/WebPage/ViewGestureGeometryCollector.messages.in
482 )
483
484 set(WebKit2_FORWARDING_HEADERS_DIRECTORIES
485     Platform
486     Shared
487
488     NetworkProcess/Downloads
489
490     Platform/IPC
491
492     Shared/API
493     Shared/Cocoa
494
495     Shared/API/Cocoa
496     Shared/API/c
497
498     Shared/API/c/cf
499     Shared/API/c/mac
500
501     UIProcess/Cocoa
502
503     UIProcess/API/C
504
505     UIProcess/API/C/Cocoa
506     UIProcess/API/C/mac
507     UIProcess/API/cpp
508
509     WebProcess/WebPage
510
511     WebProcess/InjectedBundle/API/Cocoa
512     WebProcess/InjectedBundle/API/c
513     WebProcess/InjectedBundle/API/mac
514 )
515
516 WEBKIT_CREATE_FORWARDING_HEADERS(WebKit FILES ${WebKit2_FORWARDING_HEADERS_FILES} DIRECTORIES ${WebKit2_FORWARDING_HEADERS_DIRECTORIES})
517
518 # This is needed right now to import ObjC headers instead of including them.
519 # FIXME: Forwarding headers should be copies of actual headers.
520 file(GLOB ObjCHeaders UIProcess/API/Cocoa/*.h)
521 foreach (_file ${ObjCHeaders})
522     get_filename_component(_name ${_file} NAME)
523     if (NOT EXISTS ${FORWARDING_HEADERS_DIR}/WebKit/${_name})
524         file(WRITE ${FORWARDING_HEADERS_DIR}/WebKit/${_name} "#import <WebKit2/UIProcess/API/Cocoa/${_name}>")
525     endif ()
526 endforeach ()
527
528 # FIXME: Forwarding headers should be complete copies of the header.
529 set(WebKitLegacyForwardingHeaders
530     DOM.h
531     DOMCore.h
532     DOMElement.h
533     DOMException.h
534     DOMObject.h
535     DOMPrivate.h
536     WebApplicationCache.h
537     WebCache.h
538     WebCoreStatistics.h
539     WebDOMOperations.h
540     WebDOMOperationsPrivate.h
541     WebDataSource.h
542     WebDataSourcePrivate.h
543     WebDefaultPolicyDelegate.h
544     WebDeviceOrientation.h
545     WebDeviceOrientationProviderMock.h
546     WebDocument.h
547     WebDocumentPrivate.h
548     WebDynamicScrollBarsView.h
549     WebEditingDelegate.h
550     WebFrame.h
551     WebFramePrivate.h
552     WebFrameViewPrivate.h
553     WebGeolocationPosition.h
554     WebHTMLRepresentation.h
555     WebHTMLView.h
556     WebHTMLViewPrivate.h
557     WebHistory.h
558     WebHistoryItem.h
559     WebHistoryItemPrivate.h
560     WebHistoryPrivate.h
561     WebIconDatabasePrivate.h
562     WebInspectorPrivate.h
563     WebKitNSStringExtras.h
564     WebNSURLExtras.h
565     WebNavigationData.h
566     WebNotification.h
567     WebPluginDatabase.h
568     WebPolicyDelegate.h
569     WebPolicyDelegatePrivate.h
570     WebPreferenceKeysPrivate.h
571     WebPreferences.h
572     WebPreferencesPrivate.h
573     WebQuotaManager.h
574     WebScriptWorld.h
575     WebSecurityOriginPrivate.h
576     WebTypesInternal.h
577     WebUIDelegate.h
578     WebUIDelegatePrivate.h
579     WebView.h
580     WebViewPrivate
581     WebViewPrivate.h
582 )
583 foreach (_file ${WebKitLegacyForwardingHeaders})
584     file(WRITE ${FORWARDING_HEADERS_DIR}/WebKit/${_file} "#import <WebKitLegacy/${_file}>")
585 endforeach ()
586
587 set(ObjCForwardingHeaders
588     DOMAbstractView.h
589     DOMAttr.h
590     DOMBeforeLoadEvent.h
591     DOMBlob.h
592     DOMCDATASection.h
593     DOMCSSCharsetRule.h
594     DOMCSSFontFaceRule.h
595     DOMCSSImportRule.h
596     DOMCSSKeyframeRule.h
597     DOMCSSKeyframesRule.h
598     DOMCSSMediaRule.h
599     DOMCSSPageRule.h
600     DOMCSSPrimitiveValue.h
601     DOMCSSRule.h
602     DOMCSSRuleList.h
603     DOMCSSStyleDeclaration.h
604     DOMCSSStyleRule.h
605     DOMCSSStyleSheet.h
606     DOMCSSSupportsRule.h
607     DOMCSSUnknownRule.h
608     DOMCSSValue.h
609     DOMCSSValueList.h
610     DOMCharacterData.h
611     DOMComment.h
612     DOMCounter.h
613     DOMDOMImplementation.h
614     DOMDOMNamedFlowCollection.h
615     DOMDOMTokenList.h
616     DOMDocument.h
617     DOMDocumentFragment.h
618     DOMDocumentType.h
619     DOMElement.h
620     DOMEntity.h
621     DOMEntityReference.h
622     DOMEvent.h
623     DOMEventException.h
624     DOMEventListener.h
625     DOMEventTarget.h
626     DOMFile.h
627     DOMFileList.h
628     DOMHTMLAnchorElement.h
629     DOMHTMLAppletElement.h
630     DOMHTMLAreaElement.h
631     DOMHTMLBRElement.h
632     DOMHTMLBaseElement.h
633     DOMHTMLBaseFontElement.h
634     DOMHTMLBodyElement.h
635     DOMHTMLButtonElement.h
636     DOMHTMLCanvasElement.h
637     DOMHTMLCollection.h
638     DOMHTMLDListElement.h
639     DOMHTMLDirectoryElement.h
640     DOMHTMLDivElement.h
641     DOMHTMLDocument.h
642     DOMHTMLElement.h
643     DOMHTMLEmbedElement.h
644     DOMHTMLFieldSetElement.h
645     DOMHTMLFontElement.h
646     DOMHTMLFormElement.h
647     DOMHTMLFrameElement.h
648     DOMHTMLFrameSetElement.h
649     DOMHTMLHRElement.h
650     DOMHTMLHeadElement.h
651     DOMHTMLHeadingElement.h
652     DOMHTMLHtmlElement.h
653     DOMHTMLIFrameElement.h
654     DOMHTMLImageElement.h
655     DOMHTMLInputElement.h
656     DOMHTMLInputElementPrivate.h
657     DOMHTMLLIElement.h
658     DOMHTMLLabelElement.h
659     DOMHTMLLegendElement.h
660     DOMHTMLLinkElement.h
661     DOMHTMLMapElement.h
662     DOMHTMLMarqueeElement.h
663     DOMHTMLMediaElement.h
664     DOMHTMLMenuElement.h
665     DOMHTMLMetaElement.h
666     DOMHTMLModElement.h
667     DOMHTMLOListElement.h
668     DOMHTMLObjectElement.h
669     DOMHTMLOptGroupElement.h
670     DOMHTMLOptionElement.h
671     DOMHTMLOptionsCollection.h
672     DOMHTMLParagraphElement.h
673     DOMHTMLParamElement.h
674     DOMHTMLPreElement.h
675     DOMHTMLQuoteElement.h
676     DOMHTMLScriptElement.h
677     DOMHTMLSelectElement.h
678     DOMHTMLStyleElement.h
679     DOMHTMLTableCaptionElement.h
680     DOMHTMLTableCellElement.h
681     DOMHTMLTableColElement.h
682     DOMHTMLTableElement.h
683     DOMHTMLTableRowElement.h
684     DOMHTMLTableSectionElement.h
685     DOMHTMLTextAreaElement.h
686     DOMHTMLTitleElement.h
687     DOMHTMLUListElement.h
688     DOMHTMLVideoElement.h
689     DOMImplementation.h
690     DOMKeyboardEvent.h
691     DOMMediaError.h
692     DOMMediaList.h
693     DOMMessageEvent.h
694     DOMMessagePort.h
695     DOMMouseEvent.h
696     DOMMutationEvent.h
697     DOMNamedNodeMap.h
698     DOMNode.h
699     DOMNodeFilter.h
700     DOMNodeIterator.h
701     DOMNodeList.h
702     DOMOverflowEvent.h
703     DOMProcessingInstruction.h
704     DOMProgressEvent.h
705     DOMRGBColor.h
706     DOMRange.h
707     DOMRangeException.h
708     DOMRect.h
709     DOMStyleSheet.h
710     DOMStyleSheetList.h
711     DOMText.h
712     DOMTextEvent.h
713     DOMTimeRanges.h
714     DOMTreeWalker.h
715     DOMUIEvent.h
716     DOMValidityState.h
717     DOMWebKitCSSFilterValue.h
718     DOMWebKitCSSRegionRule.h
719     DOMWebKitCSSTransformValue.h
720     DOMWebKitNamedFlow.h
721     DOMWheelEvent.h
722     DOMXPathException.h
723     DOMXPathExpression.h
724     DOMXPathNSResolver.h
725     DOMXPathResult.h
726 )
727 foreach (_file ${ObjCForwardingHeaders})
728     file(WRITE ${FORWARDING_HEADERS_DIR}/WebKit/${_file} "#import <WebKitLegacy/${_file}>")
729 endforeach ()
730
731 list(APPEND WebKit2_AUTOMATION_PROTOCOL_GENERATOR_EXTRA_FLAGS
732     --platform=macOS
733 )
734
735 # FIXME: These should not be necessary.
736 file(WRITE ${FORWARDING_HEADERS_DIR}/WebKit/WKImageCG.h "#import <WebKit2/Shared/API/c/cg/WKImageCG.h>")
737 file(WRITE ${FORWARDING_HEADERS_DIR}/WebKit/WebStorageManagerPrivate.h "#import <WebKit/mac/Storage/WebStorageManagerPrivate.h>")
738 file(WRITE ${FORWARDING_HEADERS_DIR}/WebKit/WebDatabaseManagerPrivate.h "#import <WebKit/mac/Storage/WebDatabaseManagerPrivate.h>")
739
740 set(CMAKE_SHARED_LINKER_FLAGS ${CMAKE_SHARED_LINKER_FLAGS} "-compatibility_version 1 -current_version ${WEBKIT_MAC_VERSION}")
741
742 set(WebKit2_OUTPUT_NAME WebKit)