Remove DATABASE_PROCESS build flag.
[WebKit-https.git] / Source / WebKit / CMakeLists.txt
1 include(WebKitCommon)
2
3 set_property(DIRECTORY . PROPERTY FOLDER "WebKit2")
4
5 set(WebKit2_INCLUDE_DIRECTORIES
6     "${WEBKIT2_DIR}"
7     "${WEBKIT2_DIR}/DatabaseProcess"
8     "${WEBKIT2_DIR}/DatabaseProcess/IndexedDB"
9     "${WEBKIT2_DIR}/NetworkProcess"
10     "${WEBKIT2_DIR}/NetworkProcess/CustomProtocols"
11     "${WEBKIT2_DIR}/NetworkProcess/Downloads"
12     "${WEBKIT2_DIR}/NetworkProcess/FileAPI"
13     "${WEBKIT2_DIR}/NetworkProcess/cache"
14     "${WEBKIT2_DIR}/NetworkProcess/capture"
15     "${WEBKIT2_DIR}/NetworkProcess/webrtc"
16     "${WEBKIT2_DIR}/Platform"
17     "${WEBKIT2_DIR}/Platform/IPC"
18     "${WEBKIT2_DIR}/PluginProcess"
19     "${WEBKIT2_DIR}/Shared"
20     "${WEBKIT2_DIR}/Shared/API"
21     "${WEBKIT2_DIR}/Shared/API/c"
22     "${WEBKIT2_DIR}/Shared/Authentication"
23     "${WEBKIT2_DIR}/Shared/CoreIPCSupport"
24     "${WEBKIT2_DIR}/Shared/Databases"
25     "${WEBKIT2_DIR}/Shared/Databases/IndexedDB"
26     "${WEBKIT2_DIR}/Shared/FileAPI"
27     "${WEBKIT2_DIR}/Shared/Gamepad"
28     "${WEBKIT2_DIR}/Shared/Plugins"
29     "${WEBKIT2_DIR}/Shared/Plugins/Netscape"
30     "${WEBKIT2_DIR}/Shared/Plugins/Netscape/x11"
31     "${WEBKIT2_DIR}/Shared/WebsiteData"
32     "${WEBKIT2_DIR}/UIProcess"
33     "${WEBKIT2_DIR}/UIProcess/API"
34     "${WEBKIT2_DIR}/UIProcess/API/C"
35     "${WEBKIT2_DIR}/UIProcess/API/cpp"
36     "${WEBKIT2_DIR}/UIProcess/ApplePay"
37     "${WEBKIT2_DIR}/UIProcess/Authentication"
38     "${WEBKIT2_DIR}/UIProcess/Automation"
39     "${WEBKIT2_DIR}/UIProcess/Databases"
40     "${WEBKIT2_DIR}/UIProcess/Downloads"
41     "${WEBKIT2_DIR}/UIProcess/Gamepad"
42     "${WEBKIT2_DIR}/UIProcess/Launcher"
43     "${WEBKIT2_DIR}/UIProcess/Network"
44     "${WEBKIT2_DIR}/UIProcess/Network/CustomProtocols"
45     "${WEBKIT2_DIR}/UIProcess/Notifications"
46     "${WEBKIT2_DIR}/UIProcess/Plugins"
47     "${WEBKIT2_DIR}/UIProcess/Storage"
48     "${WEBKIT2_DIR}/UIProcess/UserContent"
49     "${WEBKIT2_DIR}/UIProcess/WebsiteData"
50     "${WEBKIT2_DIR}/WebProcess"
51     "${WEBKIT2_DIR}/WebProcess/ApplePay"
52     "${WEBKIT2_DIR}/WebProcess/ApplicationCache"
53     "${WEBKIT2_DIR}/WebProcess/Automation"
54     "${WEBKIT2_DIR}/WebProcess/Cookies"
55     "${WEBKIT2_DIR}/WebProcess/Databases"
56     "${WEBKIT2_DIR}/WebProcess/Databases/IndexedDB"
57     "${WEBKIT2_DIR}/WebProcess/FileAPI"
58     "${WEBKIT2_DIR}/WebProcess/FullScreen"
59     "${WEBKIT2_DIR}/WebProcess/Gamepad"
60     "${WEBKIT2_DIR}/WebProcess/Geolocation"
61     "${WEBKIT2_DIR}/WebProcess/IconDatabase"
62     "${WEBKIT2_DIR}/WebProcess/InjectedBundle"
63     "${WEBKIT2_DIR}/WebProcess/InjectedBundle/API"
64     "${WEBKIT2_DIR}/WebProcess/InjectedBundle/API/c"
65     "${WEBKIT2_DIR}/WebProcess/InjectedBundle/DOM"
66     "${WEBKIT2_DIR}/WebProcess/Launching"
67     "${WEBKIT2_DIR}/WebProcess/MediaCache"
68     "${WEBKIT2_DIR}/WebProcess/MediaStream"
69     "${WEBKIT2_DIR}/WebProcess/Network"
70     "${WEBKIT2_DIR}/WebProcess/Network/webrtc"
71     "${WEBKIT2_DIR}/WebProcess/Notifications"
72     "${WEBKIT2_DIR}/WebProcess/OriginData"
73     "${WEBKIT2_DIR}/WebProcess/Plugins"
74     "${WEBKIT2_DIR}/WebProcess/Plugins/Netscape"
75     "${WEBKIT2_DIR}/WebProcess/ResourceCache"
76     "${WEBKIT2_DIR}/WebProcess/Storage"
77     "${WEBKIT2_DIR}/WebProcess/UserContent"
78     "${WEBKIT2_DIR}/WebProcess/WebCoreSupport"
79     "${WEBKIT2_DIR}/WebProcess/WebPage"
80     "${DERIVED_SOURCES_WEBKIT2_DIR}"
81     "${DERIVED_SOURCES_WEBKIT2_DIR}/include"
82     "${CMAKE_SOURCE_DIR}/WebKitLibraries"
83 )
84
85 set(PROTOCOL_GENERATOR_SCRIPTS_DIR "${JAVASCRIPTCORE_DIR}/inspector/scripts")
86
87 set(WebKit2_SYSTEM_INCLUDE_DIRECTORIES
88     ${ICU_INCLUDE_DIRS}
89 )
90
91 if (ENABLE_GRAPHICS_CONTEXT_3D)
92     list(APPEND WebKit2_INCLUDE_DIRECTORIES
93         "${THIRDPARTY_DIR}/ANGLE"
94         "${THIRDPARTY_DIR}/ANGLE/include/KHR"
95     )
96 endif ()
97
98 set(WebKit2_SOURCES
99     DatabaseProcess/DatabaseProcess.cpp
100     DatabaseProcess/DatabaseToWebProcessConnection.cpp
101
102     DatabaseProcess/IndexedDB/WebIDBConnectionToClient.cpp
103
104     NetworkProcess/CustomProtocols/LegacyCustomProtocolManager.cpp
105
106     NetworkProcess/Downloads/BlobDownloadClient.cpp
107     NetworkProcess/Downloads/Download.cpp
108     NetworkProcess/Downloads/DownloadManager.cpp
109     NetworkProcess/Downloads/PendingDownload.cpp
110
111     NetworkProcess/FileAPI/NetworkBlobRegistry.cpp
112
113     NetworkProcess/NetworkConnectionToWebProcess.cpp
114     NetworkProcess/NetworkDataTask.cpp
115     NetworkProcess/NetworkDataTaskBlob.cpp
116     NetworkProcess/NetworkLoad.cpp
117     NetworkProcess/NetworkProcess.cpp
118     NetworkProcess/NetworkProcessCreationParameters.cpp
119     NetworkProcess/NetworkProcessPlatformStrategies.cpp
120     NetworkProcess/NetworkResourceLoadParameters.cpp
121     NetworkProcess/NetworkResourceLoader.cpp
122     NetworkProcess/NetworkSession.cpp
123     NetworkProcess/NetworkSocketStream.cpp
124
125     NetworkProcess/cache/NetworkCache.cpp
126     NetworkProcess/cache/NetworkCacheBlobStorage.cpp
127     NetworkProcess/cache/NetworkCacheCoders.cpp
128     NetworkProcess/cache/NetworkCacheData.cpp
129     NetworkProcess/cache/NetworkCacheEntry.cpp
130     NetworkProcess/cache/NetworkCacheFileSystem.cpp
131     NetworkProcess/cache/NetworkCacheKey.cpp
132     NetworkProcess/cache/NetworkCacheSpeculativeLoad.cpp
133     NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.cpp
134     NetworkProcess/cache/NetworkCacheSubresourcesEntry.cpp
135     NetworkProcess/cache/NetworkCacheStatistics.cpp
136     NetworkProcess/cache/NetworkCacheStorage.cpp
137
138     NetworkProcess/capture/NetworkCaptureEvent.cpp
139     NetworkProcess/capture/NetworkCaptureManager.cpp
140     NetworkProcess/capture/NetworkCaptureRecorder.cpp
141     NetworkProcess/capture/NetworkCaptureReplayer.cpp
142     NetworkProcess/capture/NetworkCaptureResource.cpp
143     NetworkProcess/capture/NetworkDataTaskReplay.cpp
144
145     Platform/Logging.cpp
146     Platform/Module.cpp
147
148     Platform/IPC/ArgumentCoders.cpp
149     Platform/IPC/Attachment.cpp
150     Platform/IPC/Connection.cpp
151     Platform/IPC/DataReference.cpp
152     Platform/IPC/Decoder.cpp
153     Platform/IPC/Encoder.cpp
154     Platform/IPC/MessageReceiverMap.cpp
155     Platform/IPC/MessageSender.cpp
156     Platform/IPC/StringReference.cpp
157
158     PluginProcess/PluginControllerProxy.cpp
159     PluginProcess/PluginCreationParameters.cpp
160     PluginProcess/PluginProcess.cpp
161     PluginProcess/WebProcessConnection.cpp
162
163     Shared/ActivityAssertion.cpp
164     Shared/AsyncRequest.cpp
165     Shared/BlobDataFileReferenceWithSandboxExtension.cpp
166     Shared/CacheModel.cpp
167     Shared/ChildProcess.cpp
168     Shared/ContextMenuContextData.cpp
169     Shared/EditorState.cpp
170     Shared/FontInfo.cpp
171     Shared/FrameInfoData.cpp
172     Shared/LayerTreeContext.cpp
173     Shared/LoadParameters.cpp
174     Shared/NavigationActionData.cpp
175     Shared/PlatformPopupMenuData.cpp
176     Shared/PrintInfo.cpp
177     Shared/SessionState.cpp
178     Shared/SessionTracker.cpp
179     Shared/ShareableBitmap.cpp
180     Shared/ShareableResource.cpp
181     Shared/StatisticsData.cpp
182     Shared/UpdateInfo.cpp
183     Shared/UserData.cpp
184     Shared/VisitedLinkTable.cpp
185     Shared/WebBackForwardListItem.cpp
186     Shared/WebCompiledContentRuleList.cpp
187     Shared/WebCompiledContentRuleListData.cpp
188     Shared/WebConnection.cpp
189     Shared/WebConnectionClient.cpp
190     Shared/WebContextMenuItem.cpp
191     Shared/WebContextMenuItemData.cpp
192     Shared/WebCoreArgumentCoders.cpp
193     Shared/WebErrors.cpp
194     Shared/WebEvent.cpp
195     Shared/WebEventConversion.cpp
196     Shared/WebGeolocationPosition.cpp
197     Shared/WebHitTestResultData.cpp
198     Shared/WebImage.cpp
199     Shared/WebKeyboardEvent.cpp
200     Shared/WebKit2Initialize.cpp
201     Shared/WebMediaSessionMetadata.cpp
202     Shared/WebMemorySampler.cpp
203     Shared/WebMouseEvent.cpp
204     Shared/WebPageCreationParameters.cpp
205     Shared/WebPageGroupData.cpp
206     Shared/WebPlatformTouchPoint.cpp
207     Shared/WebPopupItem.cpp
208     Shared/WebPreferencesKeys.cpp
209     Shared/WebPreferencesStore.cpp
210     Shared/WebProcessCreationParameters.cpp
211     Shared/WebRenderLayer.cpp
212     Shared/WebRenderObject.cpp
213     Shared/WebTouchEvent.cpp
214     Shared/WebUserContentControllerDataTypes.cpp
215     Shared/WebWheelEvent.cpp
216     Shared/WebsiteDataStoreParameters.cpp
217
218     Shared/API/APIArray.cpp
219     Shared/API/APIData.cpp
220     Shared/API/APIDictionary.cpp
221     Shared/API/APIError.cpp
222     Shared/API/APIFrameHandle.cpp
223     Shared/API/APIGeometry.cpp
224     Shared/API/APIObject.cpp
225     Shared/API/APIPageGroupHandle.cpp
226     Shared/API/APIPageHandle.cpp
227     Shared/API/APIURLRequest.cpp
228     Shared/API/APIURLResponse.cpp
229
230     Shared/API/c/WKArray.cpp
231     Shared/API/c/WKCertificateInfo.cpp
232     Shared/API/c/WKConnectionRef.cpp
233     Shared/API/c/WKContextMenuItem.cpp
234     Shared/API/c/WKData.cpp
235     Shared/API/c/WKDeprecatedFunctions.cpp
236     Shared/API/c/WKDictionary.cpp
237     Shared/API/c/WKErrorRef.cpp
238     Shared/API/c/WKGeometry.cpp
239     Shared/API/c/WKImage.cpp
240     Shared/API/c/WKMutableArray.cpp
241     Shared/API/c/WKMutableDictionary.cpp
242     Shared/API/c/WKNumber.cpp
243     Shared/API/c/WKPluginInformation.cpp
244     Shared/API/c/WKRenderLayer.cpp
245     Shared/API/c/WKRenderObject.cpp
246     Shared/API/c/WKSecurityOriginRef.cpp
247     Shared/API/c/WKSerializedScriptValue.cpp
248     Shared/API/c/WKString.cpp
249     Shared/API/c/WKType.cpp
250     Shared/API/c/WKURL.cpp
251     Shared/API/c/WKURLRequest.cpp
252     Shared/API/c/WKURLResponse.cpp
253     Shared/API/c/WKUserContentURLPattern.cpp
254
255     Shared/Authentication/AuthenticationManager.cpp
256
257     Shared/Databases/DatabaseProcessCreationParameters.cpp
258
259     Shared/Databases/IndexedDB/IDBUtilities.cpp
260     Shared/Databases/IndexedDB/WebIDBResult.cpp
261
262     Shared/Gamepad/GamepadData.cpp
263
264     Shared/Plugins/NPIdentifierData.cpp
265     Shared/Plugins/NPObjectMessageReceiver.cpp
266     Shared/Plugins/NPObjectProxy.cpp
267     Shared/Plugins/NPRemoteObjectMap.cpp
268     Shared/Plugins/NPVariantData.cpp
269     Shared/Plugins/PluginProcessCreationParameters.cpp
270
271     Shared/Plugins/Netscape/NetscapePluginModule.cpp
272     Shared/Plugins/Netscape/NetscapePluginModuleNone.cpp
273     Shared/Plugins/Netscape/PluginInformation.cpp
274
275     Shared/WebsiteData/WebsiteData.cpp
276
277     UIProcess/BackgroundProcessResponsivenessTimer.cpp
278     UIProcess/ChildProcessProxy.cpp
279     UIProcess/DrawingAreaProxy.cpp
280     UIProcess/FrameLoadState.cpp
281     UIProcess/GeolocationPermissionRequestManagerProxy.cpp
282     UIProcess/GeolocationPermissionRequestProxy.cpp
283     UIProcess/PageLoadState.cpp
284     UIProcess/ProcessAssertion.cpp
285     UIProcess/ProcessThrottler.cpp
286     UIProcess/RemoteWebInspectorProxy.cpp
287     UIProcess/ResponsivenessTimer.cpp
288     UIProcess/StatisticsRequest.cpp
289     UIProcess/TextCheckerCompletion.cpp
290     UIProcess/UserMediaPermissionCheckProxy.cpp
291     UIProcess/UserMediaPermissionRequestManagerProxy.cpp
292     UIProcess/UserMediaPermissionRequestProxy.cpp
293     UIProcess/UserMediaProcessManager.cpp
294     UIProcess/VisitedLinkStore.cpp
295     UIProcess/WebBackForwardList.cpp
296     UIProcess/WebColorPicker.cpp
297     UIProcess/WebConnectionToWebProcess.cpp
298     UIProcess/WebContextClient.cpp
299     UIProcess/WebContextConnectionClient.cpp
300     UIProcess/WebContextInjectedBundleClient.cpp
301     UIProcess/WebContextMenuProxy.cpp
302     UIProcess/WebCookieManagerProxy.cpp
303     UIProcess/WebCookieManagerProxyClient.cpp
304     UIProcess/WebEditCommandProxy.cpp
305     UIProcess/WebFormClient.cpp
306     UIProcess/WebFormSubmissionListenerProxy.cpp
307     UIProcess/WebFrameListenerProxy.cpp
308     UIProcess/WebFramePolicyListenerProxy.cpp
309     UIProcess/WebFrameProxy.cpp
310     UIProcess/WebFullScreenManagerProxy.cpp
311     UIProcess/WebGeolocationManagerProxy.cpp
312     UIProcess/WebGeolocationProvider.cpp
313     UIProcess/WebGrammarDetail.cpp
314     UIProcess/WebInspectorProxy.cpp
315     UIProcess/WebInspectorUtilities.cpp
316     UIProcess/WebNavigationState.cpp
317     UIProcess/WebOpenPanelResultListenerProxy.cpp
318     UIProcess/WebPageDiagnosticLoggingClient.cpp
319     UIProcess/WebPageGroup.cpp
320     UIProcess/WebPageInjectedBundleClient.cpp
321     UIProcess/WebPageProxy.cpp
322     UIProcess/WebPasteboardProxy.cpp
323     UIProcess/WebPreferences.cpp
324     UIProcess/WebProcessLifetimeObserver.cpp
325     UIProcess/WebProcessLifetimeTracker.cpp
326     UIProcess/WebProcessPool.cpp
327     UIProcess/WebProcessProxy.cpp
328     UIProcess/WebURLSchemeHandler.cpp
329     UIProcess/WebURLSchemeTask.cpp
330     UIProcess/WebViewportAttributes.cpp
331
332     UIProcess/API/APIContentRuleList.cpp
333     UIProcess/API/APIContentRuleListStore.cpp
334     UIProcess/API/APIExperimentalFeature.cpp
335     UIProcess/API/APIFrameInfo.cpp
336     UIProcess/API/APIHTTPCookieStore.cpp
337     UIProcess/API/APIHitTestResult.cpp
338     UIProcess/API/APINavigation.cpp
339     UIProcess/API/APINavigationData.cpp
340     UIProcess/API/APIPageConfiguration.cpp
341     UIProcess/API/APIProcessPoolConfiguration.cpp
342     UIProcess/API/APIOpenPanelParameters.cpp
343     UIProcess/API/APISessionState.cpp
344     UIProcess/API/APIURLSchemeTask.cpp
345     UIProcess/API/APIUserContentWorld.cpp
346     UIProcess/API/APIUserScript.cpp
347     UIProcess/API/APIUserStyleSheet.cpp
348     UIProcess/API/APIWebsiteDataStore.cpp
349     UIProcess/API/APIWebsitePolicies.cpp
350     UIProcess/API/APIWindowFeatures.cpp
351
352     UIProcess/API/C/WKApplicationCacheManager.cpp
353     UIProcess/API/C/WKAuthenticationChallenge.cpp
354     UIProcess/API/C/WKAuthenticationDecisionListener.cpp
355     UIProcess/API/C/WKBackForwardListItemRef.cpp
356     UIProcess/API/C/WKBackForwardListRef.cpp
357     UIProcess/API/C/WKContext.cpp
358     UIProcess/API/C/WKContextConfigurationRef.cpp
359     UIProcess/API/C/WKCookieManager.cpp
360     UIProcess/API/C/WKCredential.cpp
361     UIProcess/API/C/WKDownload.cpp
362     UIProcess/API/C/WKFormSubmissionListener.cpp
363     UIProcess/API/C/WKFrame.cpp
364     UIProcess/API/C/WKFrameHandleRef.cpp
365     UIProcess/API/C/WKFrameInfoRef.cpp
366     UIProcess/API/C/WKFramePolicyListener.cpp
367     UIProcess/API/C/WKGeolocationManager.cpp
368     UIProcess/API/C/WKGeolocationPermissionRequest.cpp
369     UIProcess/API/C/WKGeolocationPosition.cpp
370     UIProcess/API/C/WKHitTestResult.cpp
371     UIProcess/API/C/WKIconDatabase.cpp
372     UIProcess/API/C/WKInspector.cpp
373     UIProcess/API/C/WKKeyValueStorageManager.cpp
374     UIProcess/API/C/WKMediaSessionMetadata.cpp
375     UIProcess/API/C/WKNavigationActionRef.cpp
376     UIProcess/API/C/WKNavigationDataRef.cpp
377     UIProcess/API/C/WKNavigationRef.cpp
378     UIProcess/API/C/WKNavigationResponseRef.cpp
379     UIProcess/API/C/WKNotification.cpp
380     UIProcess/API/C/WKNotificationManager.cpp
381     UIProcess/API/C/WKNotificationPermissionRequest.cpp
382     UIProcess/API/C/WKOpenPanelParametersRef.cpp
383     UIProcess/API/C/WKOpenPanelResultListener.cpp
384     UIProcess/API/C/WKPage.cpp
385     UIProcess/API/C/WKPageConfigurationRef.cpp
386     UIProcess/API/C/WKPageGroup.cpp
387     UIProcess/API/C/WKPreferences.cpp
388     UIProcess/API/C/WKProtectionSpace.cpp
389     UIProcess/API/C/WKResourceCacheManager.cpp
390     UIProcess/API/C/WKSessionStateRef.cpp
391     UIProcess/API/C/WKTextChecker.cpp
392     UIProcess/API/C/WKUserContentControllerRef.cpp
393     UIProcess/API/C/WKUserMediaPermissionCheck.cpp
394     UIProcess/API/C/WKUserMediaPermissionRequest.cpp
395     UIProcess/API/C/WKViewportAttributes.cpp
396     UIProcess/API/C/WKWebsiteDataStoreRef.cpp
397     UIProcess/API/C/WKWebsitePolicies.cpp
398     UIProcess/API/C/WKWindowFeaturesRef.cpp
399
400     UIProcess/Authentication/AuthenticationChallengeProxy.cpp
401     UIProcess/Authentication/AuthenticationDecisionListener.cpp
402     UIProcess/Authentication/WebCredential.cpp
403     UIProcess/Authentication/WebProtectionSpace.cpp
404
405     UIProcess/Automation/WebAutomationSession.cpp
406
407     UIProcess/Databases/DatabaseProcessProxy.cpp
408
409     UIProcess/Downloads/DownloadProxy.cpp
410     UIProcess/Downloads/DownloadProxyMap.cpp
411
412     UIProcess/Gamepad/UIGamepad.cpp
413     UIProcess/Gamepad/UIGamepadProvider.cpp
414
415     UIProcess/Launcher/ProcessLauncher.cpp
416
417     UIProcess/Network/CustomProtocols/LegacyCustomProtocolManagerProxy.cpp
418
419     UIProcess/Network/NetworkProcessProxy.cpp
420
421     UIProcess/Notifications/NotificationPermissionRequest.cpp
422     UIProcess/Notifications/NotificationPermissionRequestManagerProxy.cpp
423     UIProcess/Notifications/WebNotification.cpp
424     UIProcess/Notifications/WebNotificationManagerProxy.cpp
425     UIProcess/Notifications/WebNotificationProvider.cpp
426
427     UIProcess/Plugins/PlugInAutoStartProvider.cpp
428     UIProcess/Plugins/PluginInfoStore.cpp
429     UIProcess/Plugins/PluginProcessManager.cpp
430     UIProcess/Plugins/PluginProcessProxy.cpp
431
432     UIProcess/Storage/LocalStorageDatabase.cpp
433     UIProcess/Storage/LocalStorageDatabaseTracker.cpp
434     UIProcess/Storage/ResourceLoadStatisticsPersistentStorage.cpp
435
436     UIProcess/UserContent/WebScriptMessageHandler.cpp
437     UIProcess/UserContent/WebUserContentControllerProxy.cpp
438
439     UIProcess/WebsiteData/WebsiteDataRecord.cpp
440     UIProcess/WebsiteData/WebsiteDataStore.cpp
441
442     WebProcess/WebConnectionToUIProcess.cpp
443     WebProcess/WebProcess.cpp
444
445     WebProcess/Automation/WebAutomationSessionProxy.cpp
446
447     WebProcess/Cookies/WebCookieManager.cpp
448
449     WebProcess/Databases/WebDatabaseProvider.cpp
450     WebProcess/Databases/WebToDatabaseProcessConnection.cpp
451
452     WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.cpp
453
454     WebProcess/FileAPI/BlobRegistryProxy.cpp
455
456     WebProcess/FullScreen/WebFullScreenManager.cpp
457
458     WebProcess/Gamepad/WebGamepad.cpp
459     WebProcess/Gamepad/WebGamepadProvider.cpp
460
461     WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp
462     WebProcess/Geolocation/WebGeolocationManager.cpp
463
464     WebProcess/InjectedBundle/InjectedBundle.cpp
465     WebProcess/InjectedBundle/InjectedBundleBackForwardList.cpp
466     WebProcess/InjectedBundle/InjectedBundleBackForwardListItem.cpp
467     WebProcess/InjectedBundle/InjectedBundleClient.cpp
468     WebProcess/InjectedBundle/InjectedBundleDOMWindowExtension.cpp
469     WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp
470     WebProcess/InjectedBundle/InjectedBundleNavigationAction.cpp
471     WebProcess/InjectedBundle/InjectedBundlePageContextMenuClient.cpp
472     WebProcess/InjectedBundle/InjectedBundlePageEditorClient.cpp
473     WebProcess/InjectedBundle/InjectedBundlePageFormClient.cpp
474     WebProcess/InjectedBundle/InjectedBundlePageFullScreenClient.cpp
475     WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp
476     WebProcess/InjectedBundle/InjectedBundlePagePolicyClient.cpp
477     WebProcess/InjectedBundle/InjectedBundlePageResourceLoadClient.cpp
478     WebProcess/InjectedBundle/InjectedBundlePageUIClient.cpp
479     WebProcess/InjectedBundle/InjectedBundleScriptWorld.cpp
480
481     WebProcess/InjectedBundle/API/c/WKBundle.cpp
482     WebProcess/InjectedBundle/API/c/WKBundleBackForwardList.cpp
483     WebProcess/InjectedBundle/API/c/WKBundleBackForwardListItem.cpp
484     WebProcess/InjectedBundle/API/c/WKBundleDOMWindowExtension.cpp
485     WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp
486     WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.cpp
487     WebProcess/InjectedBundle/API/c/WKBundleInspector.cpp
488     WebProcess/InjectedBundle/API/c/WKBundleNavigationAction.cpp
489     WebProcess/InjectedBundle/API/c/WKBundleNodeHandle.cpp
490     WebProcess/InjectedBundle/API/c/WKBundlePage.cpp
491     WebProcess/InjectedBundle/API/c/WKBundlePageGroup.cpp
492     WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.cpp
493     WebProcess/InjectedBundle/API/c/WKBundleRangeHandle.cpp
494     WebProcess/InjectedBundle/API/c/WKBundleScriptWorld.cpp
495
496     WebProcess/InjectedBundle/DOM/InjectedBundleCSSStyleDeclarationHandle.cpp
497     WebProcess/InjectedBundle/DOM/InjectedBundleFileHandle.cpp
498     WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp
499     WebProcess/InjectedBundle/DOM/InjectedBundleRangeHandle.cpp
500
501     WebProcess/MediaStream/MediaDeviceSandboxExtensions.cpp
502     WebProcess/MediaStream/UserMediaPermissionRequestManager.cpp
503
504     WebProcess/Network/NetworkProcessConnection.cpp
505     WebProcess/Network/WebLoaderStrategy.cpp
506     WebProcess/Network/WebResourceLoader.cpp
507     WebProcess/Network/WebSocketProvider.cpp
508     WebProcess/Network/WebSocketStream.cpp
509
510     WebProcess/Notifications/NotificationPermissionRequestManager.cpp
511     WebProcess/Notifications/WebNotificationManager.cpp
512
513     WebProcess/Plugins/Plugin.cpp
514     WebProcess/Plugins/PluginProcessConnection.cpp
515     WebProcess/Plugins/PluginProcessConnectionManager.cpp
516     WebProcess/Plugins/PluginProxy.cpp
517     WebProcess/Plugins/PluginView.cpp
518     WebProcess/Plugins/WebPluginInfoProvider.cpp
519
520     WebProcess/Plugins/Netscape/JSNPMethod.cpp
521     WebProcess/Plugins/Netscape/JSNPObject.cpp
522     WebProcess/Plugins/Netscape/NPJSObject.cpp
523     WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp
524     WebProcess/Plugins/Netscape/NPRuntimeUtilities.cpp
525     WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp
526     WebProcess/Plugins/Netscape/NetscapePlugin.cpp
527     WebProcess/Plugins/Netscape/NetscapePluginNone.cpp
528     WebProcess/Plugins/Netscape/NetscapePluginStream.cpp
529
530     WebProcess/Storage/StorageAreaImpl.cpp
531     WebProcess/Storage/StorageAreaMap.cpp
532     WebProcess/Storage/StorageNamespaceImpl.cpp
533     WebProcess/Storage/WebStorageNamespaceProvider.cpp
534
535     WebProcess/UserContent/WebUserContentController.cpp
536
537     WebProcess/WebCoreSupport/SessionStateConversion.cpp
538     WebProcess/WebCoreSupport/WebChromeClient.cpp
539     WebProcess/WebCoreSupport/WebColorChooser.cpp
540     WebProcess/WebCoreSupport/WebContextMenuClient.cpp
541     WebProcess/WebCoreSupport/WebDeviceProximityClient.cpp
542     WebProcess/WebCoreSupport/WebDiagnosticLoggingClient.cpp
543     WebProcess/WebCoreSupport/WebDragClient.cpp
544     WebProcess/WebCoreSupport/WebEditorClient.cpp
545     WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp
546     WebProcess/WebCoreSupport/WebGeolocationClient.cpp
547     WebProcess/WebCoreSupport/WebInspectorClient.cpp
548     WebProcess/WebCoreSupport/WebNotificationClient.cpp
549     WebProcess/WebCoreSupport/WebPerformanceLoggingClient.cpp
550     WebProcess/WebCoreSupport/WebPlatformStrategies.cpp
551     WebProcess/WebCoreSupport/WebPlugInClient.cpp
552     WebProcess/WebCoreSupport/WebPopupMenu.cpp
553     WebProcess/WebCoreSupport/WebProgressTrackerClient.cpp
554     WebProcess/WebCoreSupport/WebSearchPopupMenu.cpp
555     WebProcess/WebCoreSupport/WebUserMediaClient.cpp
556
557     WebProcess/WebPage/DrawingArea.cpp
558     WebProcess/WebPage/EventDispatcher.cpp
559     WebProcess/WebPage/FindController.cpp
560     WebProcess/WebPage/LayerTreeHost.cpp
561     WebProcess/WebPage/PageBanner.cpp
562     WebProcess/WebPage/RemoteWebInspectorUI.cpp
563     WebProcess/WebPage/VisitedLinkTableController.cpp
564     WebProcess/WebPage/WebBackForwardListProxy.cpp
565     WebProcess/WebPage/WebContextMenu.cpp
566     WebProcess/WebPage/WebDocumentLoader.cpp
567     WebProcess/WebPage/WebFrame.cpp
568     WebProcess/WebPage/WebInspector.cpp
569     WebProcess/WebPage/WebInspectorInterruptDispatcher.cpp
570     WebProcess/WebPage/WebInspectorFrontendAPIDispatcher.cpp
571     WebProcess/WebPage/WebInspectorUI.cpp
572     WebProcess/WebPage/WebOpenPanelResultListener.cpp
573     WebProcess/WebPage/WebPage.cpp
574     WebProcess/WebPage/WebPageGroupProxy.cpp
575     WebProcess/WebPage/WebPageOverlay.cpp
576     WebProcess/WebPage/WebURLSchemeHandlerProxy.cpp
577     WebProcess/WebPage/WebURLSchemeTaskProxy.cpp
578     WebProcess/WebPage/WebUndoStep.cpp
579 )
580
581 set(WebKit2_MESSAGES_IN_FILES
582     DatabaseProcess/DatabaseProcess.messages.in
583     DatabaseProcess/DatabaseToWebProcessConnection.messages.in
584
585     DatabaseProcess/IndexedDB/WebIDBConnectionToClient.messages.in
586
587     NetworkProcess/CustomProtocols/LegacyCustomProtocolManager.messages.in
588
589     NetworkProcess/NetworkConnectionToWebProcess.messages.in
590     NetworkProcess/NetworkProcess.messages.in
591     NetworkProcess/NetworkResourceLoader.messages.in
592     NetworkProcess/NetworkSocketStream.messages.in
593
594     NetworkProcess/webrtc/NetworkRTCMonitor.messages.in
595     NetworkProcess/webrtc/NetworkRTCProvider.messages.in
596     NetworkProcess/webrtc/NetworkRTCSocket.messages.in
597
598     PluginProcess/PluginControllerProxy.messages.in
599     PluginProcess/PluginProcess.messages.in
600     PluginProcess/WebProcessConnection.messages.in
601
602     Shared/ChildProcess.messages.in
603     Shared/WebConnection.messages.in
604
605     Shared/Authentication/AuthenticationManager.messages.in
606
607     Shared/Plugins/NPObjectMessageReceiver.messages.in
608
609     UIProcess/DrawingAreaProxy.messages.in
610     UIProcess/RemoteWebInspectorProxy.messages.in
611     UIProcess/VisitedLinkStore.messages.in
612     UIProcess/WebCookieManagerProxy.messages.in
613     UIProcess/WebFullScreenManagerProxy.messages.in
614     UIProcess/WebGeolocationManagerProxy.messages.in
615     UIProcess/WebInspectorProxy.messages.in
616     UIProcess/WebPageProxy.messages.in
617     UIProcess/WebPasteboardProxy.messages.in
618     UIProcess/WebProcessPool.messages.in
619     UIProcess/WebProcessProxy.messages.in
620     UIProcess/WebResourceLoadStatisticsStore.messages.in
621
622     UIProcess/Automation/WebAutomationSession.messages.in
623
624     UIProcess/Databases/DatabaseProcessProxy.messages.in
625
626     UIProcess/Downloads/DownloadProxy.messages.in
627
628     UIProcess/Network/NetworkProcessProxy.messages.in
629
630     UIProcess/Network/CustomProtocols/LegacyCustomProtocolManagerProxy.messages.in
631
632     UIProcess/Plugins/PluginProcessProxy.messages.in
633
634     UIProcess/Storage/StorageManager.messages.in
635
636     UIProcess/UserContent/WebUserContentControllerProxy.messages.in
637
638     WebProcess/WebProcess.messages.in
639
640     WebProcess/Automation/WebAutomationSessionProxy.messages.in
641
642     WebProcess/Cookies/WebCookieManager.messages.in
643
644     WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.messages.in
645
646     WebProcess/FullScreen/WebFullScreenManager.messages.in
647
648     WebProcess/Geolocation/WebGeolocationManager.messages.in
649
650     WebProcess/Network/webrtc/WebRTCMonitor.messages.in
651     WebProcess/Network/webrtc/WebRTCResolver.messages.in
652     WebProcess/Network/webrtc/WebRTCSocket.messages.in
653
654     WebProcess/Network/NetworkProcessConnection.messages.in
655     WebProcess/Network/WebResourceLoader.messages.in
656     WebProcess/Network/WebSocketStream.messages.in
657
658     WebProcess/Notifications/WebNotificationManager.messages.in
659
660     WebProcess/Plugins/PluginProcessConnection.messages.in
661     WebProcess/Plugins/PluginProcessConnectionManager.messages.in
662     WebProcess/Plugins/PluginProxy.messages.in
663
664     WebProcess/Storage/StorageAreaMap.messages.in
665
666     WebProcess/UserContent/WebUserContentController.messages.in
667
668     WebProcess/WebPage/DrawingArea.messages.in
669     WebProcess/WebPage/EventDispatcher.messages.in
670     WebProcess/WebPage/RemoteWebInspectorUI.messages.in
671     WebProcess/WebPage/VisitedLinkTableController.messages.in
672     WebProcess/WebPage/WebInspector.messages.in
673     WebProcess/WebPage/WebInspectorInterruptDispatcher.messages.in
674     WebProcess/WebPage/WebInspectorUI.messages.in
675     WebProcess/WebPage/WebPage.messages.in
676 )
677
678 set(WebProcess_LIBRARIES
679     WebKit2
680 )
681
682 set(NetworkProcess_LIBRARIES
683     WebKit2
684 )
685
686 set(DatabaseProcess_LIBRARIES
687     WebKit2
688 )
689
690 if (APPLE)
691     set(WebKit2_LIBRARIES
692         PRIVATE WebCore
693         PUBLIC JavaScriptCore
694     )
695 else ()
696     set(WebKit2_LIBRARIES
697         WebCore
698         JavaScriptCore
699     )
700 endif ()
701
702 set(PluginProcess_LIBRARIES
703     WebKit2
704 )
705
706 if (WIN32 AND INTERNAL_BUILD)
707     set(JavaScriptCore_SCRIPTS_DIR "${CMAKE_BINARY_DIR}/../include/private/JavaScriptCore/Scripts")
708 else ()
709     set(JavaScriptCore_SCRIPTS_DIR "${FORWARDING_HEADERS_DIR}/JavaScriptCore/Scripts")
710 endif ()
711
712 if (COMPILER_IS_GCC_OR_CLANG)
713     set(ATOMIC_TEST_SOURCE
714     "
715         #include <atomic>
716         int main() { std::atomic<int64_t> i(0); i++; return 0; }
717     "
718     )
719     check_cxx_source_compiles("${ATOMIC_TEST_SOURCE}" ATOMIC_INT64_IS_BUILTIN)
720     if (NOT ATOMIC_INT64_IS_BUILTIN)
721         set(CMAKE_REQUIRED_LIBRARIES atomic)
722         check_cxx_source_compiles("${ATOMIC_TEST_SOURCE}" ATOMIC_INT64_REQUIRES_LIBATOMIC)
723         if (ATOMIC_INT64_REQUIRES_LIBATOMIC)
724             list(APPEND WebKit2_LIBRARIES atomic)
725         endif ()
726         unset(CMAKE_REQUIRED_LIBRARIES)
727     endif ()
728 endif ()
729
730 if (UNIX)
731     check_function_exists(shm_open SHM_OPEN_EXISTS)
732     if (NOT SHM_OPEN_EXISTS)
733         set(CMAKE_REQUIRED_LIBRARIES rt)
734         check_function_exists(shm_open SHM_OPEN_REQUIRES_LIBRT)
735         if (SHM_OPEN_REQUIRES_LIBRT)
736             list(APPEND WebKit2_LIBRARIES rt)
737         endif ()
738     endif ()
739 endif ()
740
741 macro(ADD_WEBKIT2_PREFIX_HEADER _target)
742     if (WebKit2_USE_PREFIX_HEADER)
743         get_target_property(OLD_COMPILE_FLAGS ${_target} COMPILE_FLAGS)
744         if (${OLD_COMPILE_FLAGS} STREQUAL "OLD_COMPILE_FLAGS-NOTFOUND")
745             set(OLD_COMPILE_FLAGS "")
746         endif ()
747         set_target_properties(${_target} PROPERTIES COMPILE_FLAGS "${OLD_COMPILE_FLAGS} -include ${WEBKIT2_DIR}/WebKit2Prefix.h")
748     endif ()
749 endmacro()
750
751 set(WebKit2_AUTOMATION_PROTOCOL_GENERATOR_EXTRA_FLAGS
752 )
753
754 WEBKIT_FRAMEWORK_DECLARE(WebKit2)
755 WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
756
757 # Helper macro which wraps generate-message-receiver.py and generate-message-header.py scripts
758 #   _output_source is a list name which will contain generated sources.(eg. WebKit2_SOURCES)
759 #   _input_files are messages.in files to generate.
760 macro(GENERATE_MESSAGE_SOURCES _output_source _input_files)
761     foreach (_file ${_input_files})
762         get_filename_component(_name ${_file} NAME_WE)
763         add_custom_command(
764             OUTPUT ${DERIVED_SOURCES_WEBKIT2_DIR}/${_name}MessageReceiver.cpp ${DERIVED_SOURCES_WEBKIT2_DIR}/${_name}Messages.h
765             MAIN_DEPENDENCY ${_file}
766             DEPENDS ${WEBKIT2_DIR}/Scripts/webkit/__init__.py
767                     ${WEBKIT2_DIR}/Scripts/webkit/messages.py
768                     ${WEBKIT2_DIR}/Scripts/webkit/model.py
769                     ${WEBKIT2_DIR}/Scripts/webkit/parser.py
770             COMMAND ${PYTHON_EXECUTABLE} ${WEBKIT2_DIR}/Scripts/generate-message-receiver.py ${_file} > ${DERIVED_SOURCES_WEBKIT2_DIR}/${_name}MessageReceiver.cpp
771             COMMAND ${PYTHON_EXECUTABLE} ${WEBKIT2_DIR}/Scripts/generate-messages-header.py ${_file} > ${DERIVED_SOURCES_WEBKIT2_DIR}/${_name}Messages.h
772             WORKING_DIRECTORY ${WEBKIT2_DIR}
773             VERBATIM)
774
775         list(APPEND ${_output_source} ${DERIVED_SOURCES_WEBKIT2_DIR}/${_name}MessageReceiver.cpp)
776     endforeach ()
777 endmacro()
778 GENERATE_MESSAGE_SOURCES(WebKit2_DERIVED_SOURCES "${WebKit2_MESSAGES_IN_FILES}")
779
780 set(WebKit2_AUTOMATION_PROTOCOL_GENERATOR_SCRIPTS
781     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/generate-inspector-protocol-bindings.py
782     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/cpp_generator.py
783     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/cpp_generator_templates.py
784     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/generate_cpp_backend_dispatcher_header.py
785     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/generate_cpp_backend_dispatcher_implementation.py
786     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/generate_cpp_frontend_dispatcher_header.py
787     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/generate_cpp_frontend_dispatcher_implementation.py
788     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/generate_cpp_protocol_types_header.py
789     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/generate_cpp_protocol_types_implementation.py
790     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/generator.py
791     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/generator_templates.py
792     ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/codegen/models.py
793 )
794
795 set(WebKit2_AUTOMATION_PROTOCOL_GENERATOR_INPUTS
796     ${WEBKIT2_DIR}/UIProcess/Automation/Automation.json
797 )
798
799 add_custom_command(
800     OUTPUT ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationBackendDispatchers.h ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationBackendDispatchers.cpp ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationProtocolObjects.h ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationProtocolObjects.cpp ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationFrontendDispatchers.h ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationFrontendDispatchers.cpp
801     MAIN_DEPENDENCY ${WebKit2_AUTOMATION_PROTOCOL_GENERATOR_INPUTS}
802     DEPENDS ${WebKit2_AUTOMATION_PROTOCOL_GENERATOR_SCRIPTS}
803     COMMAND ${PYTHON_EXECUTABLE} ${PROTOCOL_GENERATOR_SCRIPTS_DIR}/generate-inspector-protocol-bindings.py --outputDir "${DERIVED_SOURCES_WEBKIT2_DIR}" --framework WebKit ${WebKit2_AUTOMATION_PROTOCOL_GENERATOR_EXTRA_FLAGS} --backend ${WebKit2_AUTOMATION_PROTOCOL_GENERATOR_INPUTS}
804     VERBATIM)
805
806 list(APPEND WebKit2_HEADERS
807     ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationBackendDispatchers.h
808     ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationFrontendDispatchers.h
809     ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationProtocolObjects.h
810 )
811
812 list(APPEND WebKit2_SOURCES
813     ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationBackendDispatchers.cpp
814     ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationFrontendDispatchers.cpp
815     ${DERIVED_SOURCES_WEBKIT2_DIR}/AutomationProtocolObjects.cpp
816 )
817
818 add_custom_command(
819     OUTPUT ${DERIVED_SOURCES_WEBKIT2_DIR}/WebAutomationSessionProxyScriptSource.h ${DERIVED_SOURCES_WEBKIT2_DIR}/WebAutomationSessionProxy.min.js
820     MAIN_DEPENDENCY ${WEBKIT2_DIR}/WebProcess/Automation/WebAutomationSessionProxy.js
821     DEPENDS ${JavaScriptCore_SCRIPTS_DIR}/xxd.pl ${JavaScriptCore_SCRIPTS_DIR}/jsmin.py
822     COMMAND ${CMAKE_COMMAND} -E echo "//# sourceURL=__InjectedScript_WebAutomationSessionProxy.js" > ${DERIVED_SOURCES_WEBKIT2_DIR}/WebAutomationSessionProxy.min.js
823     COMMAND ${PYTHON_EXECUTABLE} ${JavaScriptCore_SCRIPTS_DIR}/jsmin.py < ${WEBKIT2_DIR}/WebProcess/Automation/WebAutomationSessionProxy.js >> ${DERIVED_SOURCES_WEBKIT2_DIR}/WebAutomationSessionProxy.min.js
824     COMMAND ${PERL_EXECUTABLE} ${JavaScriptCore_SCRIPTS_DIR}/xxd.pl WebAutomationSessionProxyScriptSource ${DERIVED_SOURCES_WEBKIT2_DIR}/WebAutomationSessionProxy.min.js ${DERIVED_SOURCES_WEBKIT2_DIR}/WebAutomationSessionProxyScriptSource.h
825     VERBATIM)
826
827 list(APPEND WebKit2_HEADERS
828     ${DERIVED_SOURCES_WEBKIT2_DIR}/WebAutomationSessionProxyScriptSource.h
829 )
830
831 list(APPEND WebKit2_SOURCES ${WebKit2_DERIVED_SOURCES})
832
833 WEBKIT_FRAMEWORK(WebKit2)
834 add_dependencies(WebKit2 WebCore ${WEBKIT2_EXTRA_DEPENDENCIES})
835 add_webkit2_prefix_header(WebKit2)
836
837 if (COMPILER_IS_GCC_OR_CLANG AND NOT APPLE)
838     target_link_libraries(WebKit2 -Wl,--start-group WebCore WebCoreDerivedSources -Wl,--end-group)
839 endif ()
840
841 # Suppress unused parameter warnings for sources in WebKit2.
842 if (COMPILER_IS_GCC_OR_CLANG)
843     WEBKIT_ADD_TARGET_PROPERTIES(WebKit2 COMPILE_FLAGS "-Wno-unused-parameter")
844 endif ()
845
846 if (WebKit2_VERSION_SCRIPT)
847     WEBKIT_ADD_TARGET_PROPERTIES(WebKit2 LINK_FLAGS "${WebKit2_VERSION_SCRIPT}")
848 endif ()
849
850 add_executable(WebProcess ${WebProcess_SOURCES})
851 add_webkit2_prefix_header(WebProcess)
852 target_link_libraries(WebProcess ${WebProcess_LIBRARIES})
853
854 if (WebKit2_WebProcess_OUTPUT_NAME)
855     set_target_properties(WebProcess PROPERTIES OUTPUT_NAME ${WebKit2_WebProcess_OUTPUT_NAME})
856 endif ()
857
858 add_executable(NetworkProcess ${NetworkProcess_SOURCES})
859 add_webkit2_prefix_header(NetworkProcess)
860 target_link_libraries(NetworkProcess ${NetworkProcess_LIBRARIES})
861
862 if (WebKit2_NetworkProcess_OUTPUT_NAME)
863     set_target_properties(NetworkProcess PROPERTIES OUTPUT_NAME ${WebKit2_NetworkProcess_OUTPUT_NAME})
864 endif ()
865
866 if (ENABLE_PLUGIN_PROCESS AND NOT "${PORT}" STREQUAL "Mac")
867     add_definitions(-DENABLE_PLUGIN_PROCESS=1)
868     add_executable(PluginProcess ${PluginProcess_SOURCES})
869     add_webkit2_prefix_header(PluginProcess)
870     target_link_libraries(PluginProcess ${PluginProcess_LIBRARIES})
871     install(TARGETS PluginProcess DESTINATION "${LIBEXEC_INSTALL_DIR}")
872
873     if (WebKit2_PluginProcess_OUTPUT_NAME)
874       set_target_properties(PluginProcess PROPERTIES OUTPUT_NAME ${WebKit2_PluginProcess_OUTPUT_NAME})
875     endif ()
876 endif ()
877
878 if ("${PORT}" STREQUAL "Mac")
879     set(_web_xpc_dir ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/WebKit.framework/XPCServices/com.apple.WebKit.WebContent.Development.xpc/Contents)
880     make_directory(${_web_xpc_dir}/MacOS)
881     make_directory(${_web_xpc_dir}/Resources)
882     make_directory(${_web_xpc_dir}/_CodeSignature)
883
884     add_custom_target(WebContentProcessNib COMMAND
885         ibtool --compile ${_web_xpc_dir}/Resources/WebContentProcess.nib ${WEBKIT2_DIR}/Resources/WebContentProcess.xib
886         VERBATIM)
887     add_dependencies(WebKit2 WebContentProcessNib)
888
889     # FIXME: This shouldn't be two operations.
890     file(COPY ${WEBKIT2_DIR}/WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-OSX.plist DESTINATION ${_web_xpc_dir})
891     file(RENAME ${_web_xpc_dir}/Info-OSX.plist ${_web_xpc_dir}/Info.plist)
892
893     set_target_properties(WebProcess PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${_web_xpc_dir}/MacOS")
894
895
896     set(_net_xpc_dir ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/WebKit.framework/XPCServices/com.apple.WebKit.Networking.Development.xpc/Contents)
897     make_directory(${_net_xpc_dir}/MacOS)
898     make_directory(${_net_xpc_dir}/_CodeSignature)
899
900     # FIXME: This shouldn't be two operations.
901     file(COPY ${WEBKIT2_DIR}/NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info-OSX.plist DESTINATION ${_net_xpc_dir})
902     file(RENAME ${_net_xpc_dir}/Info-OSX.plist ${_net_xpc_dir}/Info.plist)
903
904     set_target_properties(NetworkProcess PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${_net_xpc_dir}/MacOS")
905 else ()
906     WEBKIT_POPULATE_LIBRARY_VERSION(WEBKIT2)
907     set_target_properties(WebKit2 PROPERTIES VERSION ${WEBKIT2_VERSION} SOVERSION ${WEBKIT2_VERSION_MAJOR})
908
909     install(TARGETS WebKit2 WebProcess NetworkProcess
910         LIBRARY DESTINATION "${LIB_INSTALL_DIR}"
911         RUNTIME DESTINATION "${LIBEXEC_INSTALL_DIR}"
912     )
913 endif ()