1ae8d9b6132caa73a432112cdae9a43b6af12061
[WebKit-https.git] / Source / WebKit / PlatformGTK.cmake
1 include(InspectorGResources.cmake)
2
3 set(WebKit_OUTPUT_NAME webkit2gtk-${WEBKITGTK_API_VERSION})
4 set(WebProcess_OUTPUT_NAME WebKitWebProcess)
5 set(NetworkProcess_OUTPUT_NAME WebKitNetworkProcess)
6 set(GPUProcess_OUTPUT_NAME WebKitGPUProcess)
7 set(PluginProcess_OUTPUT_NAME WebKitPluginProcess)
8
9 file(MAKE_DIRECTORY ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR})
10 file(MAKE_DIRECTORY ${FORWARDING_HEADERS_WEBKIT2GTK_DIR})
11 file(MAKE_DIRECTORY ${FORWARDING_HEADERS_WEBKIT2GTK_EXTENSION_DIR})
12
13 configure_file(UIProcess/API/gtk/WebKitVersion.h.in ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitVersion.h)
14 configure_file(gtk/webkit2gtk.pc.in ${WebKit2_PKGCONFIG_FILE} @ONLY)
15 configure_file(gtk/webkit2gtk-web-extension.pc.in ${WebKit2WebExtension_PKGCONFIG_FILE} @ONLY)
16
17 add_definitions(-DBUILDING_WEBKIT)
18 add_definitions(-DWEBKIT2_COMPILATION)
19 add_definitions(-DWEBKIT_DOM_USE_UNSTABLE_API)
20
21 add_definitions(-DPKGLIBEXECDIR="${LIBEXEC_INSTALL_DIR}")
22 add_definitions(-DLOCALEDIR="${CMAKE_INSTALL_FULL_LOCALEDIR}")
23 add_definitions(-DDATADIR="${CMAKE_INSTALL_FULL_DATADIR}")
24 add_definitions(-DLIBDIR="${LIB_INSTALL_DIR}")
25
26 if (NOT DEVELOPER_MODE AND NOT CMAKE_SYSTEM_NAME MATCHES "Darwin")
27     WEBKIT_ADD_TARGET_PROPERTIES(WebKit LINK_FLAGS "-Wl,--version-script,${CMAKE_CURRENT_SOURCE_DIR}/webkitglib-symbols.map")
28 endif ()
29
30 set(WebKit_USE_PREFIX_HEADER ON)
31
32 list(APPEND WebKit_UNIFIED_SOURCE_LIST_FILES
33     "SourcesGTK.txt"
34 )
35
36 list(APPEND WebKit_MESSAGES_IN_FILES
37     UIProcess/ViewGestureController.messages.in
38
39     WebProcess/WebPage/ViewGestureGeometryCollector.messages.in
40 )
41
42 list(APPEND WebKit_DERIVED_SOURCES
43     ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/InspectorGResourceBundle.c
44     ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitResourcesGResourceBundle.c
45
46     ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitEnumTypes.cpp
47     ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitWebProcessEnumTypes.cpp
48 )
49
50 if (ENABLE_WAYLAND_TARGET)
51     list(APPEND WebKit_DERIVED_SOURCES
52         ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitWaylandClientProtocol.c
53         ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/pointer-constraints-unstable-v1-protocol.c
54         ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/relative-pointer-unstable-v1-protocol.c
55     )
56 endif ()
57
58 set(WebKit2GTK_INSTALLED_HEADERS
59     ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitEnumTypes.h
60     ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitVersion.h
61     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitApplicationInfo.h
62     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitAuthenticationRequest.h
63     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitAutocleanups.h
64     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitAutomationSession.h
65     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitBackForwardList.h
66     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitBackForwardListItem.h
67     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitColorChooserRequest.h
68     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitCredential.h
69     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitContextMenu.h
70     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitContextMenuActions.h
71     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitContextMenuItem.h
72     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitCookieManager.h
73     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitDefines.h
74     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitDeviceInfoPermissionRequest.h
75     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitDownload.h
76     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitEditingCommands.h
77     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitEditorState.h
78     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitError.h
79     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitFaviconDatabase.h
80     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitFileChooserRequest.h
81     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitFindController.h
82     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitFormSubmissionRequest.h
83     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitForwardDeclarations.h
84     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitGeolocationManager.h
85     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitGeolocationPermissionRequest.h
86     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitHitTestResult.h
87     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitInputMethodContext.h
88     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitInstallMissingMediaPluginsPermissionRequest.h
89     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitJavascriptResult.h
90     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitMimeInfo.h
91     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitNavigationAction.h
92     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitNavigationPolicyDecision.h
93     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitNetworkProxySettings.h
94     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitNotificationPermissionRequest.h
95     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitNotification.h
96     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitOptionMenu.h
97     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitOptionMenuItem.h
98     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitPermissionRequest.h
99     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitPlugin.h
100     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitPointerLockPermissionRequest.h
101     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitPolicyDecision.h
102     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitPrintCustomWidget.h
103     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitPrintOperation.h
104     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitResponsePolicyDecision.h
105     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitScriptDialog.h
106     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitSecurityManager.h
107     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitSecurityOrigin.h
108     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitSettings.h
109     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitURIRequest.h
110     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitURIResponse.h
111     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitURISchemeRequest.h
112     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitURIUtilities.h
113     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitUserContent.h
114     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitUserContentFilterStore.h
115     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitUserContentManager.h
116     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitUserMediaPermissionRequest.h
117     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitUserMessage.h
118     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitWebContext.h
119     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitWebInspector.h
120     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitWebResource.h
121     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitWebView.h
122     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitWebViewBase.h
123     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitWebViewSessionState.h
124     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitWebsiteData.h
125     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitWebsiteDataManager.h
126     ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitWindowProperties.h
127     ${WEBKIT_DIR}/UIProcess/API/gtk/webkit2.h
128 )
129
130 set(WebKit2WebExtension_INSTALLED_HEADERS
131     ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitWebProcessEnumTypes.h
132     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/WebKitConsoleMessage.h
133     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/WebKitFrame.h
134     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/WebKitScriptWorld.h
135     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/WebKitWebEditor.h
136     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/WebKitWebExtension.h
137     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/WebKitWebExtensionAutocleanups.h
138     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/WebKitWebHitTestResult.h
139     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/WebKitWebPage.h
140     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/webkit-web-extension.h
141 )
142
143 set(WebKitDOM_INSTALLED_HEADERS
144     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/webkitdomautocleanups.h
145     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/webkitdomdefines.h
146     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/webkitdom.h
147     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMAttr.h
148     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMBlob.h
149     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCDATASection.h
150     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCharacterData.h
151     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMClientRect.h
152     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMClientRectList.h
153     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMComment.h
154     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSRule.h
155     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSRuleList.h
156     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSStyleDeclaration.h
157     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSStyleSheet.h
158     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSValue.h
159     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCustom.h
160     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCustomUnstable.h
161     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDeprecated.h
162     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentFragment.h
163     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentFragmentUnstable.h
164     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocument.h
165     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentType.h
166     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentUnstable.h
167     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMImplementation.h
168     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMSelection.h
169     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMTokenList.h
170     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMWindow.h
171     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMWindowUnstable.h
172     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMElement.h
173     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMElementUnstable.h
174     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMEvent.h
175     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMEventTarget.h
176     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMFile.h
177     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMFileList.h
178     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAnchorElement.h
179     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAppletElement.h
180     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAreaElement.h
181     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBaseElement.h
182     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBodyElement.h
183     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBRElement.h
184     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLButtonElement.h
185     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLCanvasElement.h
186     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLCollection.h
187     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDirectoryElement.h
188     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDivElement.h
189     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDListElement.h
190     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDocument.h
191     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLElement.h
192     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLElementUnstable.h
193     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLEmbedElement.h
194     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFieldSetElement.h
195     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFontElement.h
196     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFormElement.h
197     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFrameElement.h
198     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFrameSetElement.h
199     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHeadElement.h
200     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHeadingElement.h
201     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHRElement.h
202     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHtmlElement.h
203     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLIFrameElement.h
204     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLImageElement.h
205     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLInputElement.h
206     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLabelElement.h
207     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLegendElement.h
208     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLIElement.h
209     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLinkElement.h
210     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMapElement.h
211     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMarqueeElement.h
212     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMenuElement.h
213     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMetaElement.h
214     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLModElement.h
215     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLObjectElement.h
216     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOListElement.h
217     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptGroupElement.h
218     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptionElement.h
219     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptionsCollection.h
220     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLParagraphElement.h
221     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLParamElement.h
222     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLPreElement.h
223     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLQuoteElement.h
224     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLScriptElement.h
225     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLSelectElement.h
226     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLStyleElement.h
227     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableCaptionElement.h
228     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableCellElement.h
229     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableColElement.h
230     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableElement.h
231     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableRowElement.h
232     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableSectionElement.h
233     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTextAreaElement.h
234     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTitleElement.h
235     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLUListElement.h
236     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMKeyboardEvent.h
237     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMMediaList.h
238     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMMouseEvent.h
239     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNamedNodeMap.h
240     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeFilter.h
241     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNode.h
242     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeIterator.h
243     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeList.h
244     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMObject.h
245     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMProcessingInstruction.h
246     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMRange.h
247     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMRangeUnstable.h
248     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMStyleSheet.h
249     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMStyleSheetList.h
250     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMText.h
251     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMTreeWalker.h
252     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMUIEvent.h
253     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMWheelEvent.h
254     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathExpression.h
255     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathNSResolver.h
256     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathResult.h
257 )
258
259 set(WebKitDOM_GTKDOC_HEADERS
260     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMAttr.h
261     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMBlob.h
262     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCDATASection.h
263     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCharacterData.h
264     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMClientRect.h
265     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMClientRectList.h
266     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMComment.h
267     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSRule.h
268     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSRuleList.h
269     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSStyleDeclaration.h
270     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSStyleSheet.h
271     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSValue.h
272     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCustom.h
273     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDeprecated.h
274     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentFragment.h
275     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocument.h
276     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentType.h
277     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMImplementation.h
278     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMSelection.h
279     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMTokenList.h
280     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMWindow.h
281     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMElement.h
282     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMEvent.h
283     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMEventTarget.h
284     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMFile.h
285     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMFileList.h
286     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAnchorElement.h
287     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAppletElement.h
288     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAreaElement.h
289     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBaseElement.h
290     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBodyElement.h
291     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBRElement.h
292     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLButtonElement.h
293     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLCanvasElement.h
294     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLCollection.h
295     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDirectoryElement.h
296     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDivElement.h
297     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDListElement.h
298     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDocument.h
299     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLElement.h
300     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLEmbedElement.h
301     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFieldSetElement.h
302     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFontElement.h
303     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFormElement.h
304     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFrameElement.h
305     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFrameSetElement.h
306     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHeadElement.h
307     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHeadingElement.h
308     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHRElement.h
309     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHtmlElement.h
310     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLIFrameElement.h
311     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLImageElement.h
312     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLInputElement.h
313     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLabelElement.h
314     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLegendElement.h
315     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLIElement.h
316     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLinkElement.h
317     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMapElement.h
318     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMarqueeElement.h
319     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMenuElement.h
320     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMetaElement.h
321     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLModElement.h
322     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLObjectElement.h
323     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOListElement.h
324     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptGroupElement.h
325     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptionElement.h
326     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptionsCollection.h
327     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLParagraphElement.h
328     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLParamElement.h
329     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLPreElement.h
330     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLQuoteElement.h
331     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLScriptElement.h
332     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLSelectElement.h
333     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLStyleElement.h
334     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableCaptionElement.h
335     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableCellElement.h
336     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableColElement.h
337     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableElement.h
338     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableRowElement.h
339     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableSectionElement.h
340     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTextAreaElement.h
341     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTitleElement.h
342     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLUListElement.h
343     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMKeyboardEvent.h
344     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMMediaList.h
345     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMMouseEvent.h
346     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNamedNodeMap.h
347     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeFilter.h
348     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNode.h
349     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeIterator.h
350     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeList.h
351     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMObject.h
352     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMProcessingInstruction.h
353     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMRange.h
354     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMStyleSheet.h
355     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMStyleSheetList.h
356     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMText.h
357     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMTreeWalker.h
358     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMUIEvent.h
359     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMWheelEvent.h
360     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathExpression.h
361     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathNSResolver.h
362     ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathResult.h
363 )
364
365 # This is necessary because of a conflict between the GTK+ API WebKitVersion.h and one generated by WebCore.
366 list(INSERT WebKit_INCLUDE_DIRECTORIES 0
367     "${FORWARDING_HEADERS_WEBKIT2GTK_DIR}"
368     "${FORWARDING_HEADERS_WEBKIT2GTK_EXTENSION_DIR}"
369     "${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}"
370     "${DERIVED_SOURCES_WEBKIT2GTK_DIR}"
371 )
372
373 list(APPEND WebKit_INCLUDE_DIRECTORIES
374     "${DERIVED_SOURCES_JAVASCRIPCOREGTK_DIR}"
375     "${FORWARDING_HEADERS_DIR}/JavaScriptCore/"
376     "${FORWARDING_HEADERS_DIR}/JavaScriptCore/glib"
377     "${WEBKIT_DIR}/NetworkProcess/glib"
378     "${WEBKIT_DIR}/NetworkProcess/gtk"
379     "${WEBKIT_DIR}/NetworkProcess/soup"
380     "${WEBKIT_DIR}/Platform/IPC/glib"
381     "${WEBKIT_DIR}/Platform/IPC/unix"
382     "${WEBKIT_DIR}/Platform/classifier"
383     "${WEBKIT_DIR}/Shared/API/c/gtk"
384     "${WEBKIT_DIR}/Shared/API/glib"
385     "${WEBKIT_DIR}/Shared/CoordinatedGraphics"
386     "${WEBKIT_DIR}/Shared/CoordinatedGraphics/threadedcompositor"
387     "${WEBKIT_DIR}/Shared/Plugins/unix"
388     "${WEBKIT_DIR}/Shared/glib"
389     "${WEBKIT_DIR}/Shared/gtk"
390     "${WEBKIT_DIR}/Shared/linux"
391     "${WEBKIT_DIR}/Shared/soup"
392     "${WEBKIT_DIR}/UIProcess/API/C/cairo"
393     "${WEBKIT_DIR}/UIProcess/API/C/gtk"
394     "${WEBKIT_DIR}/UIProcess/API/glib"
395     "${WEBKIT_DIR}/UIProcess/API/gtk"
396     "${WEBKIT_DIR}/UIProcess/CoordinatedGraphics"
397     "${WEBKIT_DIR}/UIProcess/Inspector/glib"
398     "${WEBKIT_DIR}/UIProcess/Inspector/gtk"
399     "${WEBKIT_DIR}/UIProcess/Plugins/gtk"
400     "${WEBKIT_DIR}/UIProcess/geoclue"
401     "${WEBKIT_DIR}/UIProcess/glib"
402     "${WEBKIT_DIR}/UIProcess/gstreamer"
403     "${WEBKIT_DIR}/UIProcess/gtk"
404     "${WEBKIT_DIR}/UIProcess/linux"
405     "${WEBKIT_DIR}/UIProcess/soup"
406     "${WEBKIT_DIR}/WebProcess/InjectedBundle/API/glib"
407     "${WEBKIT_DIR}/WebProcess/InjectedBundle/API/glib/DOM"
408     "${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk"
409     "${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM"
410     "${WEBKIT_DIR}/WebProcess/Inspector/gtk"
411     "${WEBKIT_DIR}/WebProcess/Plugins/Netscape/unix"
412     "${WEBKIT_DIR}/WebProcess/Plugins/Netscape/x11"
413     "${WEBKIT_DIR}/WebProcess/gtk"
414     "${WEBKIT_DIR}/WebProcess/soup"
415     "${WEBKIT_DIR}/WebProcess/WebCoreSupport/gtk"
416     "${WEBKIT_DIR}/WebProcess/WebCoreSupport/soup"
417     "${WEBKIT_DIR}/WebProcess/WebPage/CoordinatedGraphics"
418     "${WEBKIT_DIR}/WebProcess/WebPage/atk"
419     "${WEBKIT_DIR}/WebProcess/WebPage/gtk"
420 )
421
422 list(APPEND WebKit_SYSTEM_INCLUDE_DIRECTORIES
423     ${ENCHANT_INCLUDE_DIRS}
424     ${GIO_UNIX_INCLUDE_DIRS}
425     ${GLIB_INCLUDE_DIRS}
426     ${GSTREAMER_INCLUDE_DIRS}
427     ${GSTREAMER_PBUTILS_INCLUDE_DIRS}
428     ${GTK_INCLUDE_DIRS}
429     ${GTK_UNIX_PRINT_INCLUDE_DIRS}
430     ${LIBSOUP_INCLUDE_DIRS}
431 )
432
433 if (USE_WPE_RENDERER)
434     list(APPEND WebKit_INCLUDE_DIRECTORIES
435         "${WEBKIT_DIR}/WebProcess/WebPage/libwpe"
436     )
437     list(APPEND WebKit_SYSTEM_INCLUDE_DIRECTORIES
438         ${WPEBACKEND_FDO_INCLUDE_DIRS}
439     )
440 endif ()
441
442 if (USE_LIBNOTIFY)
443 list(APPEND WebKit_SYSTEM_INCLUDE_DIRECTORIES
444     ${LIBNOTIFY_INCLUDE_DIRS}
445 )
446 endif ()
447
448 set(WebKitCommonIncludeDirectories ${WebKit_INCLUDE_DIRECTORIES})
449 set(WebKitCommonSystemIncludeDirectories ${WebKit_SYSTEM_INCLUDE_DIRECTORIES})
450
451 list(APPEND WebProcess_SOURCES
452     WebProcess/EntryPoint/unix/WebProcessMain.cpp
453 )
454
455 list(APPEND NetworkProcess_SOURCES
456     NetworkProcess/EntryPoint/unix/NetworkProcessMain.cpp
457 )
458
459 list(APPEND GPUProcess_SOURCES
460     GPUProcess/EntryPoint/unix/GPUProcessMain.cpp
461 )
462
463 list(APPEND WebKit_LIBRARIES
464     ${GTK_UNIX_PRINT_LIBRARIES}
465 )
466
467 if (USE_WPE_RENDERER)
468     list(APPEND WebKit_LIBRARIES
469       WPE::libwpe
470       ${WPEBACKEND_FDO_LIBRARIES}
471     )
472 endif ()
473
474 if (LIBNOTIFY_FOUND)
475     list(APPEND WebKit_PRIVATE_LIBRARIES
476         ${LIBNOTIFY_LIBRARIES}
477     )
478 endif ()
479
480 if (USE_LIBWEBRTC)
481     list(APPEND WebKit_SYSTEM_INCLUDE_DIRECTORIES
482         "${THIRDPARTY_DIR}/libwebrtc/Source/"
483         "${THIRDPARTY_DIR}/libwebrtc/Source/webrtc"
484     )
485 endif ()
486
487 # To generate WebKitEnumTypes.h we want to use all installed headers, except WebKitEnumTypes.h itself.
488 set(WebKit2GTK_ENUM_GENERATION_HEADERS ${WebKit2GTK_INSTALLED_HEADERS})
489 list(REMOVE_ITEM WebKit2GTK_ENUM_GENERATION_HEADERS ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitEnumTypes.h)
490 add_custom_command(
491     OUTPUT ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitEnumTypes.h
492            ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitEnumTypes.cpp
493     DEPENDS ${WebKit2GTK_ENUM_GENERATION_HEADERS}
494
495     COMMAND glib-mkenums --template ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitEnumTypes.h.template ${WebKit2GTK_ENUM_GENERATION_HEADERS} | sed s/web_kit/webkit/ | sed s/WEBKIT_TYPE_KIT/WEBKIT_TYPE/ > ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitEnumTypes.h
496
497     COMMAND glib-mkenums --template ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitEnumTypes.cpp.template ${WebKit2GTK_ENUM_GENERATION_HEADERS} | sed s/web_kit/webkit/ > ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitEnumTypes.cpp
498     VERBATIM
499 )
500
501 set(WebKit2GTK_WEB_PROCESS_ENUM_GENERATION_HEADERS ${WebKit2WebExtension_INSTALLED_HEADERS})
502 list(REMOVE_ITEM WebKit2GTK_WEB_PROCESS_ENUM_GENERATION_HEADERS ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitWebProcessEnumTypes.h)
503 add_custom_command(
504     OUTPUT ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitWebProcessEnumTypes.h
505            ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitWebProcessEnumTypes.cpp
506     DEPENDS ${WebKit2GTK_WEB_PROCESS_ENUM_GENERATION_HEADERS}
507
508     COMMAND glib-mkenums --template ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/WebKitWebProcessEnumTypes.h.template ${WebKit2GTK_WEB_PROCESS_ENUM_GENERATION_HEADERS} | sed s/web_kit/webkit/ | sed s/WEBKIT_TYPE_KIT/WEBKIT_TYPE/ > ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitWebProcessEnumTypes.h
509
510     COMMAND glib-mkenums --template ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/WebKitWebProcessEnumTypes.cpp.template ${WebKit2GTK_WEB_PROCESS_ENUM_GENERATION_HEADERS} | sed s/web_kit/webkit/ > ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}/WebKitWebProcessEnumTypes.cpp
511     VERBATIM
512 )
513
514 WEBKIT_BUILD_INSPECTOR_GRESOURCES(${DERIVED_SOURCES_WEBKIT2GTK_DIR})
515
516 set(WebKitResources
517     "        <file alias=\"css/gtk-theme.css\">gtk-theme.css</file>\n"
518     "        <file alias=\"images/missingImage\">missingImage.png</file>\n"
519     "        <file alias=\"images/missingImage@2x\">missingImage@2x.png</file>\n"
520     "        <file alias=\"images/panIcon\">panIcon.png</file>\n"
521     "        <file alias=\"images/textAreaResizeCorner\">textAreaResizeCorner.png</file>\n"
522     "        <file alias=\"images/textAreaResizeCorner@2x\">textAreaResizeCorner@2x.png</file>\n"
523 )
524
525 if (ENABLE_WEB_AUDIO)
526     list(APPEND WebKitResources
527         "        <file alias=\"audio/Composite\">Composite.wav</file>\n"
528     )
529 endif ()
530
531 file(WRITE ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitResourcesGResourceBundle.xml
532     "<?xml version=1.0 encoding=UTF-8?>\n"
533     "<gresources>\n"
534     "    <gresource prefix=\"/org/webkitgtk/resources\">\n"
535     ${WebKitResources}
536     "    </gresource>\n"
537     "</gresources>\n"
538 )
539
540 add_custom_command(
541     OUTPUT ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitResourcesGResourceBundle.c
542     DEPENDS ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitResourcesGResourceBundle.xml
543     COMMAND glib-compile-resources --generate --sourcedir=${CMAKE_SOURCE_DIR}/Source/WebCore/Resources --sourcedir=${CMAKE_SOURCE_DIR}/Source/WebCore/platform/audio/resources --sourcedir=${CMAKE_SOURCE_DIR}/Source/WebKit/Resources/gtk --target=${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitResourcesGResourceBundle.c ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitResourcesGResourceBundle.xml
544     VERBATIM
545 )
546
547 if (ENABLE_WAYLAND_TARGET)
548     # Wayland protocol extension.
549     add_custom_command(
550         OUTPUT ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitWaylandClientProtocol.c
551         DEPENDS ${WEBKIT_DIR}/Shared/gtk/WebKitWaylandProtocol.xml
552         COMMAND ${WAYLAND_SCANNER} server-header ${WEBKIT_DIR}/Shared/gtk/WebKitWaylandProtocol.xml ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitWaylandServerProtocol.h
553         COMMAND ${WAYLAND_SCANNER} client-header ${WEBKIT_DIR}/Shared/gtk/WebKitWaylandProtocol.xml ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitWaylandClientProtocol.h
554         COMMAND ${WAYLAND_SCANNER} private-code ${WEBKIT_DIR}/Shared/gtk/WebKitWaylandProtocol.xml ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/WebKitWaylandClientProtocol.c
555         VERBATIM
556     )
557
558     add_custom_command(
559         OUTPUT ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/pointer-constraints-unstable-v1-protocol.c
560         DEPENDS ${WAYLAND_PROTOCOLS_DATADIR}/unstable/pointer-constraints/pointer-constraints-unstable-v1.xml
561         COMMAND ${WAYLAND_SCANNER} private-code ${WAYLAND_PROTOCOLS_DATADIR}/unstable/pointer-constraints/pointer-constraints-unstable-v1.xml ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/pointer-constraints-unstable-v1-protocol.c
562         COMMAND ${WAYLAND_SCANNER} client-header ${WAYLAND_PROTOCOLS_DATADIR}/unstable/pointer-constraints/pointer-constraints-unstable-v1.xml ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/pointer-constraints-unstable-v1-client-protocol.h
563         VERBATIM
564     )
565
566     add_custom_command(
567         OUTPUT ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/relative-pointer-unstable-v1-protocol.c
568         DEPENDS ${WAYLAND_PROTOCOLS_DATADIR}/unstable/relative-pointer/relative-pointer-unstable-v1.xml
569         COMMAND ${WAYLAND_SCANNER} private-code ${WAYLAND_PROTOCOLS_DATADIR}/unstable/relative-pointer/relative-pointer-unstable-v1.xml ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/relative-pointer-unstable-v1-protocol.c
570         COMMAND ${WAYLAND_SCANNER} client-header ${WAYLAND_PROTOCOLS_DATADIR}/unstable/relative-pointer/relative-pointer-unstable-v1.xml ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/relative-pointer-unstable-v1-client-protocol.h
571         VERBATIM
572     )
573 endif ()
574
575 # GTK3 PluginProcess
576 list(APPEND PluginProcess_SOURCES
577     PluginProcess/EntryPoint/unix/PluginProcessMain.cpp
578 )
579
580 # Commands for building the built-in injected bundle.
581 add_library(webkit2gtkinjectedbundle MODULE "${WEBKIT_DIR}/WebProcess/InjectedBundle/API/glib/WebKitInjectedBundleMain.cpp")
582 ADD_WEBKIT_PREFIX_HEADER(webkit2gtkinjectedbundle)
583 target_link_libraries(webkit2gtkinjectedbundle WebKit)
584
585 target_include_directories(webkit2gtkinjectedbundle PRIVATE
586     ${WebKit_INCLUDE_DIRECTORIES}
587     "${DERIVED_SOURCES_DIR}/InjectedBundle"
588     "${FORWARDING_HEADERS_DIR}"
589     "${FORWARDING_HEADERS_WEBKIT2GTK_DIR}"
590     "${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}"
591 )
592
593 target_include_directories(webkit2gtkinjectedbundle SYSTEM PRIVATE
594     ${WebKit_SYSTEM_INCLUDE_DIRECTORIES}
595 )
596
597 if (COMPILER_IS_GCC_OR_CLANG)
598     WEBKIT_ADD_TARGET_CXX_FLAGS(webkit2gtkinjectedbundle -Wno-unused-parameter)
599 endif ()
600
601 # Add ${CMAKE_LIBRARY_OUTPUT_DIRECTORY} to LD_LIBRARY_PATH or DYLD_LIBRARY_PATH
602 if (APPLE)
603     set(LOADER_LIBRARY_PATH_VAR "DYLD_LIBRARY_PATH")
604     set(PREV_LOADER_LIBRARY_PATH "$ENV{DYLD_LIBRARY_PATH}")
605 else ()
606     set(LOADER_LIBRARY_PATH_VAR "LD_LIBRARY_PATH")
607     set(PREV_LOADER_LIBRARY_PATH "$ENV{LD_LIBRARY_PATH}")
608 endif ()
609
610 if (ENABLE_INTROSPECTION)
611     string(COMPARE EQUAL "${PREV_LOADER_LIBRARY_PATH}" "" ld_library_path_does_not_exist)
612     if (ld_library_path_does_not_exist)
613         set(INTROSPECTION_ADDITIONAL_LIBRARY_PATH
614             "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}"
615         )
616     else ()
617         set(INTROSPECTION_ADDITIONAL_LIBRARY_PATH
618             "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}:${PREV_LOADER_LIBRARY_PATH}"
619         )
620     endif ()
621
622     # Add required -L flags from ${CMAKE_SHARED_LINKER_FLAGS} for g-ir-scanner
623     string(REGEX MATCHALL "-L[^ ]*"
624         INTROSPECTION_ADDITIONAL_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS}")
625
626     add_custom_command(
627         OUTPUT ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
628         DEPENDS WebKit
629         DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
630         COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations LDFLAGS=
631             ${LOADER_LIBRARY_PATH_VAR}="${INTROSPECTION_ADDITIONAL_LIBRARY_PATH}"
632             ${INTROSPECTION_SCANNER}
633             --quiet
634             --warn-all
635             --symbol-prefix=webkit
636             --identifier-prefix=WebKit
637             --namespace=WebKit2
638             --nsversion=${WEBKITGTK_API_VERSION}
639             --include=GObject-2.0
640             --include=Gtk-3.0
641             --include=Soup-2.4
642             --include-uninstalled=${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
643             --library=webkit2gtk-${WEBKITGTK_API_VERSION}
644             --library=javascriptcoregtk-${WEBKITGTK_API_VERSION}
645             -L${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
646             ${INTROSPECTION_ADDITIONAL_LINKER_FLAGS}
647             --no-libtool
648             --pkg=gobject-2.0
649             --pkg=gtk+-3.0
650             --pkg=libsoup-2.4
651             --pkg-export=webkit2gtk-${WEBKITGTK_API_VERSION}
652             --output=${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
653             --c-include="webkit2/webkit2.h"
654             -DBUILDING_WEBKIT
655             -DWEBKIT2_COMPILATION
656             -I${CMAKE_SOURCE_DIR}/Source
657             -I${WEBKIT_DIR}
658             -I${DERIVED_SOURCES_DIR}
659             -I${DERIVED_SOURCES_WEBKIT2GTK_DIR}
660             -I${DERIVED_SOURCES_JAVASCRIPCOREGTK_DIR}
661             -I${FORWARDING_HEADERS_DIR}
662             -I${FORWARDING_HEADERS_DIR}/JavaScriptCore/glib
663             -I${FORWARDING_HEADERS_WEBKIT2GTK_DIR}
664             ${WebKit2GTK_INSTALLED_HEADERS}
665             ${WEBKIT_DIR}/Shared/API/glib/*.cpp
666             ${WEBKIT_DIR}/UIProcess/API/glib/*.cpp
667             ${WEBKIT_DIR}/UIProcess/API/gtk/*.cpp
668     )
669
670     add_custom_command(
671         OUTPUT ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.gir
672         DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
673         DEPENDS ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
674         COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations
675             LDFLAGS="${INTROSPECTION_ADDITIONAL_LDFLAGS}"
676             ${LOADER_LIBRARY_PATH_VAR}="${INTROSPECTION_ADDITIONAL_LIBRARY_PATH}"
677             ${INTROSPECTION_SCANNER}
678             --quiet
679             --warn-all
680             --symbol-prefix=webkit
681             --identifier-prefix=WebKit
682             --namespace=WebKit2WebExtension
683             --nsversion=${WEBKITGTK_API_VERSION}
684             --include=GObject-2.0
685             --include=Gtk-3.0
686             --include=Soup-2.4
687             --include-uninstalled=${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
688             --library=webkit2gtk-${WEBKITGTK_API_VERSION}
689             --library=javascriptcoregtk-${WEBKITGTK_API_VERSION}
690             ${INTROSPECTION_ADDITIONAL_LIBRARIES}
691             -L${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
692             ${INTROSPECTION_ADDITIONAL_LINKER_FLAGS}
693             --no-libtool
694             --pkg=gobject-2.0
695             --pkg=gtk+-3.0
696             --pkg=libsoup-2.4
697             --pkg-export=webkit2gtk-web-extension-${WEBKITGTK_API_VERSION}
698             --output=${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.gir
699             --c-include="webkit2/webkit-web-extension.h"
700             -DBUILDING_WEBKIT
701             -DWEBKIT2_COMPILATION
702             -I${CMAKE_SOURCE_DIR}/Source
703             -I${WEBKIT_DIR}
704             -I${DERIVED_SOURCES_DIR}
705             -I${DERIVED_SOURCES_WEBKIT2GTK_DIR}
706             -I${DERIVED_SOURCES_JAVASCRIPCOREGTK_DIR}
707             -I${FORWARDING_HEADERS_DIR}
708             -I${FORWARDING_HEADERS_DIR}/JavaScriptCore/glib
709             -I${FORWARDING_HEADERS_WEBKIT2GTK_DIR}
710             -I${FORWARDING_HEADERS_WEBKIT2GTK_EXTENSION_DIR}
711             -I${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk
712             ${WebKitDOM_INSTALLED_HEADERS}
713             ${WebKit2WebExtension_INSTALLED_HEADERS}
714             ${WEBKIT_DIR}/Shared/API/glib/WebKitContextMenu.cpp
715             ${WEBKIT_DIR}/Shared/API/glib/WebKitContextMenuItem.cpp
716             ${WEBKIT_DIR}/Shared/API/glib/WebKitHitTestResult.cpp
717             ${WEBKIT_DIR}/Shared/API/glib/WebKitUserMessage.cpp
718             ${WEBKIT_DIR}/Shared/API/glib/WebKitURIRequest.cpp
719             ${WEBKIT_DIR}/Shared/API/glib/WebKitURIResponse.cpp
720             ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitContextMenu.h
721             ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitContextMenuActions.h
722             ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitContextMenuItem.h
723             ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitHitTestResult.h
724             ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitUserMessage.h
725             ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitURIRequest.h
726             ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitURIResponse.h
727             ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/glib/*.cpp
728             ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/glib/DOM/*.cpp
729     )
730
731     add_custom_command(
732         OUTPUT ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.typelib
733         DEPENDS ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
734         COMMAND ${INTROSPECTION_COMPILER} --includedir=${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir -o ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.typelib
735     )
736
737     add_custom_command(
738         OUTPUT ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.typelib
739         DEPENDS ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.gir
740         COMMAND ${INTROSPECTION_COMPILER} --includedir=${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.gir -o ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.typelib
741     )
742
743     ADD_TYPELIB(${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.typelib)
744     ADD_TYPELIB(${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.typelib)
745 endif ()
746
747 install(TARGETS webkit2gtkinjectedbundle
748         DESTINATION "${LIB_INSTALL_DIR}/webkit2gtk-${WEBKITGTK_API_VERSION}/injected-bundle"
749 )
750 install(FILES "${CMAKE_BINARY_DIR}/Source/WebKit/webkit2gtk-${WEBKITGTK_API_VERSION}.pc"
751               "${CMAKE_BINARY_DIR}/Source/WebKit/webkit2gtk-web-extension-${WEBKITGTK_API_VERSION}.pc"
752         DESTINATION "${LIB_INSTALL_DIR}/pkgconfig"
753 )
754 install(FILES ${WebKit2GTK_INSTALLED_HEADERS}
755               ${WebKit2WebExtension_INSTALLED_HEADERS}
756         DESTINATION "${WEBKITGTK_HEADER_INSTALL_DIR}/webkit2"
757 )
758 install(FILES ${WebKitDOM_INSTALLED_HEADERS}
759         DESTINATION "${WEBKITGTK_HEADER_INSTALL_DIR}/webkitdom"
760 )
761
762 if (ENABLE_INTROSPECTION)
763     install(FILES ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
764                   ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.gir
765             DESTINATION ${INTROSPECTION_INSTALL_GIRDIR}
766     )
767     install(FILES ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.typelib
768                   ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.typelib
769             DESTINATION ${INTROSPECTION_INSTALL_TYPELIBDIR}
770     )
771 endif ()
772
773 file(WRITE ${CMAKE_BINARY_DIR}/gtkdoc-webkit2gtk.cfg
774     "[webkit2gtk-${WEBKITGTK_API_VERSION}]\n"
775     "pkgconfig_file=${WebKit2_PKGCONFIG_FILE}\n"
776     "decorator=WEBKIT_API|WEBKIT_DEPRECATED|WEBKIT_DEPRECATED_FOR\\(.+\\)\n"
777     "deprecation_guard=WEBKIT_DISABLE_DEPRECATED\n"
778     "namespace=webkit\n"
779     "cflags=-I${CMAKE_SOURCE_DIR}/Source\n"
780     "       -I${WEBKIT_DIR}/Shared/API/glib\n"
781     "       -I${WEBKIT_DIR}/UIProcess/API/glib\n"
782     "       -I${WEBKIT_DIR}/UIProcess/API/gtk\n"
783     "       -I${DERIVED_SOURCES_WEBKIT2GTK_DIR}\n"
784     "       -I${FORWARDING_HEADERS_WEBKIT2GTK_DIR}\n"
785     "doc_dir=${WEBKIT_DIR}/UIProcess/API/gtk/docs\n"
786     "source_dirs=${WEBKIT_DIR}/Shared/API/glib\n"
787     "            ${WEBKIT_DIR}/UIProcess/API/glib\n"
788     "            ${WEBKIT_DIR}/UIProcess/API/gtk\n"
789     "            ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/glib\n"
790     "            ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk\n"
791     "            ${DERIVED_SOURCES_WEBKIT2GTK_API_DIR}\n"
792     "headers=${WebKit2GTK_ENUM_GENERATION_HEADERS} ${WebKit2WebExtension_INSTALLED_HEADERS}\n"
793     "main_sgml_file=webkit2gtk-docs.sgml\n"
794 )
795
796 file(WRITE ${CMAKE_BINARY_DIR}/gtkdoc-webkitdom.cfg
797     "[webkitdomgtk-${WEBKITGTK_API_VERSION}]\n"
798     "pkgconfig_file=${WebKit2_PKGCONFIG_FILE}\n"
799     "decorator=WEBKIT_API|WEBKIT_DEPRECATED|WEBKIT_DEPRECATED_FOR\\(.+\\)\n"
800     "deprecation_guard=WEBKIT_DISABLE_DEPRECATED\n"
801     "namespace=webkit_dom\n"
802     "cflags=-I${CMAKE_SOURCE_DIR}/Source\n"
803     "       -I${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM\n"
804     "       -I${DERIVED_SOURCES_WEBKIT2GTK_DIR}\n"
805     "       -I${FORWARDING_HEADERS_WEBKIT2GTK_DIR}\n"
806     "doc_dir=${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM/docs\n"
807     "source_dirs=${WEBKIT_DIR}/WebProcess/InjectedBundle/API/glib/DOM\n"
808     "            ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM\n"
809     "headers=${WebKitDOM_GTKDOC_HEADERS}\n"
810     "main_sgml_file=webkitdomgtk-docs.sgml\n"
811 )
812
813 add_custom_target(WebKit-forwarding-headers
814     COMMAND ${PERL_EXECUTABLE} ${WEBKIT_DIR}/Scripts/generate-forwarding-headers.pl --include-path ${WEBKIT_DIR} --output ${FORWARDING_HEADERS_DIR} --platform gtk --platform soup
815 )
816
817 # These symbolic link allows includes like #include <webkit2/WebkitWebView.h> which simulates installed headers.
818 add_custom_command(
819     OUTPUT ${FORWARDING_HEADERS_WEBKIT2GTK_DIR}/webkit2
820     DEPENDS ${WEBKIT_DIR}/UIProcess/API/gtk
821     COMMAND ln -n -s -f ${WEBKIT_DIR}/UIProcess/API/gtk ${FORWARDING_HEADERS_WEBKIT2GTK_DIR}/webkit2
822 )
823 add_custom_command(
824     OUTPUT ${FORWARDING_HEADERS_WEBKIT2GTK_EXTENSION_DIR}/webkit2
825     DEPENDS ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk
826     COMMAND ln -n -s -f ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk ${FORWARDING_HEADERS_WEBKIT2GTK_EXTENSION_DIR}/webkit2
827 )
828 add_custom_command(
829     OUTPUT ${FORWARDING_HEADERS_WEBKIT2GTK_EXTENSION_DIR}/webkitdom
830     DEPENDS ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM
831     COMMAND ln -n -s -f ${WEBKIT_DIR}/WebProcess/InjectedBundle/API/gtk/DOM ${FORWARDING_HEADERS_WEBKIT2GTK_EXTENSION_DIR}/webkitdom
832 )
833 add_custom_target(WebKit-fake-api-headers
834     DEPENDS ${FORWARDING_HEADERS_WEBKIT2GTK_DIR}/webkit2
835             ${FORWARDING_HEADERS_WEBKIT2GTK_EXTENSION_DIR}/webkit2
836             ${FORWARDING_HEADERS_WEBKIT2GTK_EXTENSION_DIR}/webkitdom
837 )
838
839 list(APPEND WebKit_DEPENDENCIES
840      WebKit-fake-api-headers
841      WebKit-forwarding-headers
842 )