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