52020862fe66941fe82ffe5d381046a824ba51d8
[WebKit-https.git] / Source / WebKit2 / GNUmakefile.am
1 include $(srcdir)/Source/WebKit2/GNUmakefile.list.am
2
3 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_HEADERS = \
4         $(webkit2_h_api)
5
6 libwebkit2gtkincludedir = $(libwebkitgtkincludedir)/webkit2
7 nodist_libwebkit2gtkinclude_HEADERS = \
8         DerivedSources/WebKit2/webkit2gtk/webkit2/WebKitEnumTypes.h \
9         DerivedSources/WebKit2/webkit2gtk/webkit2/WebKitVersion.h
10
11 libwebkit2gtkinclude_HEADERS = \
12         $(webkit2gtk_h_api)
13
14 nodist_libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_SOURCES = \
15         $(webkit2_built_sources) \
16         $(webkit2gtk_built_sources)
17
18 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_SOURCES = \
19         $(webkit2_sources)
20
21 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_CPPFLAGS = \
22         -fno-strict-aliasing \
23         $(global_cppflags) \
24         -include $(srcdir)/Source/WebKit2/WebKit2Prefix.h \
25         -I$(srcdir)/Source/WebKit/gtk \
26         -I$(srcdir)/Source/WebKit2 \
27         -I$(srcdir)/Source/WebKit2/gtk \
28         -I$(srcdir)/Source/WebKit2/Platform \
29         -I$(srcdir)/Source/WebKit2/Platform/CoreIPC \
30         -I$(srcdir)/Source/WebKit2/Platform/CoreIPC/gtk \
31         -I$(srcdir)/Source/WebKit2/Platform/gtk \
32         -I$(srcdir)/Source/WebKit2/PluginProcess \
33         -I$(srcdir)/Source/WebKit2/Shared \
34         -I$(srcdir)/Source/WebKit2/Shared/API \
35         -I$(srcdir)/Source/WebKit2/Shared/API/c \
36         -I$(srcdir)/Source/WebKit2/Shared/API/c/gtk \
37         -I$(srcdir)/Source/WebKit2/Shared/API/c/soup \
38         -I$(srcdir)/Source/WebKit2/Shared/CoreIPCSupport \
39         -I$(srcdir)/Source/WebKit2/Shared/gtk \
40         -I$(srcdir)/Source/WebKit2/Shared/Plugins \
41         -I$(srcdir)/Source/WebKit2/Shared/Plugins/Netscape \
42         -I$(srcdir)/Source/WebKit2/Shared/Plugins/Netscape/x11 \
43         -I$(srcdir)/Source/WebKit2/Shared/soup \
44         -I$(srcdir)/Source/WebKit2/UIProcess \
45         -I$(srcdir)/Source/WebKit2/UIProcess/API \
46         -I$(srcdir)/Source/WebKit2/UIProcess/API/C \
47         -I$(srcdir)/Source/WebKit2/UIProcess/API/C/gtk \
48         -I$(srcdir)/Source/WebKit2/UIProcess/API/C/soup \
49         -I$(srcdir)/Source/WebKit2/UIProcess/API/cpp \
50         -I$(srcdir)/Source/WebKit2/UIProcess/API/gtk \
51         -I$(srcdir)/Source/WebKit2/UIProcess/Authentication \
52         -I$(srcdir)/Source/WebKit2/UIProcess/Downloads \
53         -I$(srcdir)/Source/WebKit2/UIProcess/gtk \
54         -I$(srcdir)/Source/WebKit2/UIProcess/Launcher \
55         -I$(srcdir)/Source/WebKit2/UIProcess/Launcher/gtk \
56         -I$(srcdir)/Source/WebKit2/UIProcess/Notifications \
57         -I$(srcdir)/Source/WebKit2/UIProcess/Plugins \
58         -I$(srcdir)/Source/WebKit2/UIProcess/Plugins/gtk \
59         -I$(srcdir)/Source/WebKit2/UIProcess/soup \
60         -I$(srcdir)/Source/WebKit2/WebProcess \
61         -I$(srcdir)/Source/WebKit2/WebProcess/ApplicationCache \
62         -I$(srcdir)/Source/WebKit2/WebProcess/Authentication \
63         -I$(srcdir)/Source/WebKit2/WebProcess/Battery \
64         -I$(srcdir)/Source/WebKit2/WebProcess/Cookies \
65         -I$(srcdir)/Source/WebKit2/WebProcess/Downloads \
66         -I$(srcdir)/Source/WebKit2/WebProcess/Downloads/soup \
67         -I$(srcdir)/Source/WebKit2/WebProcess/FullScreen \
68         -I$(srcdir)/Source/WebKit2/WebProcess/Geolocation \
69         -I$(srcdir)/Source/WebKit2/WebProcess/gtk \
70         -I$(srcdir)/Source/WebKit2/WebProcess/IconDatabase \
71         -I$(srcdir)/Source/WebKit2/WebProcess/InjectedBundle \
72         -I$(srcdir)/Source/WebKit2/WebProcess/InjectedBundle/API \
73         -I$(srcdir)/Source/WebKit2/WebProcess/InjectedBundle/API/c \
74         -I$(srcdir)/Source/WebKit2/WebProcess/InjectedBundle/DOM \
75         -I$(srcdir)/Source/WebKit2/WebProcess/InjectedBundle/gtk \
76         -I$(srcdir)/Source/WebKit2/WebProcess/KeyValueStorage \
77         -I$(srcdir)/Source/WebKit2/WebProcess/Launching \
78         -I$(srcdir)/Source/WebKit2/WebProcess/MediaCache \
79         -I$(srcdir)/Source/WebKit2/WebProcess/NetworkInfo \
80         -I$(srcdir)/Source/WebKit2/WebProcess/Notifications \
81         -I$(srcdir)/Source/WebKit2/WebProcess/ResourceCache \
82         -I$(srcdir)/Source/WebKit2/WebProcess/soup \
83         -I$(srcdir)/Source/WebKit2/WebProcess/Plugins \
84         -I$(srcdir)/Source/WebKit2/WebProcess/Plugins/Netscape \
85         -I$(srcdir)/Source/WebKit2/WebProcess/Plugins/Netscape/gtk \
86         -I$(srcdir)/Source/WebKit2/WebProcess/WebCoreSupport \
87         -I$(srcdir)/Source/WebKit2/WebProcess/WebCoreSupport/gtk \
88         -I$(srcdir)/Source/WebKit2/WebProcess/WebCoreSupport/soup \
89         -I$(srcdir)/Source/WebKit2/WebProcess/WebPage \
90         -I$(srcdir)/Source/WebKit2/WebProcess/WebPage/gtk \
91         -I$(top_builddir)/DerivedSources/WebKit2 \
92         -I$(top_builddir)/DerivedSources/WebKit2/include \
93         -I$(top_builddir)/DerivedSources/WebKit2/webkit2gtk \
94         -I$(top_builddir)/DerivedSources/WebKit2/webkit2gtk/include \
95         -I$(top_builddir)/DerivedSources/WebKit2/webkit2gtk/webkit2 \
96         -I$(top_builddir)/DerivedSources/WebKit2/include/JavaScriptCore \
97         -I$(top_builddir)/DerivedSources/WebKit2/include/WebCore \
98         -I$(top_builddir)/DerivedSources/WebKit2/include/WebKit2 \
99         -DLIBEXECDIR=\""$(libexecdir)"\" \
100         -DWEBKIT2_COMPILATION \
101         $(webcore_cppflags) \
102         $(webcoregtk_cppflags) \
103         $(javascriptcore_cppflags) \
104         $(CLUTTER_CFLAGS) \
105         $(COVERAGE_CFLAGS) \
106         $(GEOCLUE_CFLAGS) \
107         $(GLIB_CFLAGS) \
108         $(GTK_CFLAGS) \
109         $(GTK_UNIX_PRINTING_CFLAGS) \
110         $(LIBSOUP_CFLAGS) \
111         $(UNICODE_CFLAGS) \
112         $(XCOMPOSITE_CFLAGS) \
113         $(XT_CFLAGS)
114
115 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_CXXFLAGS = \
116         $(global_cxxflags)
117
118 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_CFLAGS = \
119         $(global_cflags)
120
121 if ENABLE_WEBKIT2
122 # Shared libraries
123 lib_LTLIBRARIES += \
124         libwebkit2gtk-@WEBKITGTK_API_MAJOR_VERSION@.@WEBKITGTK_API_MINOR_VERSION@.la
125 endif
126
127 # Artificial dependency to make sure libwebkit2gtk and libwebkitgtk are not linked at the same time
128 # The variable creation is to avoid having automake override the entire rule instead of adding the
129 # dependency.
130 webkit2gtk_lib_for_dep = libwebkit2gtk-@WEBKITGTK_API_MAJOR_VERSION@.@WEBKITGTK_API_MINOR_VERSION@.la
131 $(webkit2gtk_lib_for_dep): libwebkitgtk-@WEBKITGTK_API_MAJOR_VERSION@.@WEBKITGTK_API_MINOR_VERSION@.la
132
133 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_ladir = \
134         $(libwebkit2gtkincludedir)/WebKit2
135
136 # For the Gtk port we want to use XP_UNIX both in X11 and Mac
137 if !TARGET_WIN32
138 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_CPPFLAGS += \
139         -DXP_UNIX
140 endif
141
142 # Add MOZ_X11 for X11 targets only
143 if TARGET_X11
144 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_CPPFLAGS += \
145         -DMOZ_X11
146 endif
147
148 # Plugin process
149 if ENABLE_PLUGIN_PROCESS
150 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_CPPFLAGS += \
151         -DENABLE_PLUGIN_PROCESS=1
152 endif
153
154 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_LDFLAGS = \
155         -version-info @LIBWEBKIT2GTK_VERSION@ \
156         $(version_script) \
157         $(no_undefined)
158
159 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_LIBADD = \
160         -lpthread \
161         libWebCore.la \
162         libWebCoreModules.la \
163         libjavascriptcoregtk-@WEBKITGTK_API_MAJOR_VERSION@.@WEBKITGTK_API_MINOR_VERSION@.la \
164         libWebCoreGtk.la \
165         $(CAIRO_LIBS) \
166         $(CLUTTER_LIBS) \
167         $(COVERAGE_LDFLAGS) \
168         $(FARSTREAM_LIBS) \
169         $(GAIL_LIBS) \
170         $(GAMEPAD_LIBS) \
171         $(GEOCLUE_LIBS) \
172         $(GLIB_LIBS) \
173         $(GSTREAMER_LIBS) \
174         $(GTK_LIBS) \
175         $(GTK_UNIX_PRINTING_LIBS) \
176         $(JPEG_LIBS) \
177         $(LIBSOUP_LIBS) \
178         $(LIBXML_LIBS) \
179         $(LIBXSLT_LIBS) \
180         $(OPENGL_LIBS) \
181         $(PANGO_LIBS) \
182         $(PNG_LIBS) \
183         $(SQLITE3_LIBS) \
184         $(UNICODE_LIBS) \
185         $(XRENDER_LIBS) \
186         $(XCOMPOSITE_LIBS) \
187         $(XT_LIBS) \
188         $(ZLIB_LIBS)
189
190 if ENABLE_SPELLCHECK
191 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_CPPFLAGS += \
192         -DENABLE_SPELLCHECK=1 \
193         $(ENCHANT_CFLAGS)
194
195 libwebkit2gtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_LIBADD += \
196         $(ENCHANT_LIBS)
197 endif
198
199
200 if ENABLE_WEBKIT2
201 pkgconfig_DATA += Source/WebKit2/webkit2gtk-@WEBKITGTK_API_VERSION@.pc
202 endif
203
204 # WebKit2 specific variables
205 forwarding_headers := $(GENSOURCES_WEBKIT2)/include
206 generate-webkit2-forwarding-headers: $(WebKit2)/Scripts/generate-forwarding-headers.pl $(libWebKit2_la_SOURCES)
207         $(AM_V_GEN)$(PERL) $< $(WebKit2) $(forwarding_headers) gtk
208         $(AM_V_GEN)$(PERL) $< $(WebKit2) $(forwarding_headers) soup
209
210 BUILT_SOURCES += generate-webkit2-forwarding-headers
211
212 $(GENSOURCES_WEBKIT2)/webkit2gtk/include/webkit2: $(libwebkit2gtkinclude_HEADERS)
213         $(AM_V_GEN)mkdir -p $(GENSOURCES_WEBKIT2)/webkit2gtk/include \
214         && ln -n -s -f ${shell pwd}/$(WebKit2)/UIProcess/API/gtk $@
215
216 BUILT_SOURCES += $(GENSOURCES_WEBKIT2)/webkit2gtk/include/webkit2
217
218 vpath %.messages.in = \
219         $(WebKit2)/PluginProcess \
220         $(WebKit2)/Shared/Plugins \
221         $(WebKit2)/UIProcess \
222         $(WebKit2)/UIProcess/ApplicationCache \
223         $(WebKit2)/UIProcess/Downloads \
224         $(WebKit2)/UIProcess/Geolocation \
225         $(WebKit2)/UIProcess/Notifications \
226         $(WebKit2)/UIProcess/Plugins \
227         $(WebKit2)/UIProcess/ResourceCache \
228         $(WebKit2)/UIProcess/soup \
229         $(WebKit2)/WebProcess \
230         $(WebKit2)/WebProcess/ApplicationCache \
231         $(WebKit2)/WebProcess/Authentication \
232         $(WebKit2)/WebProcess/Battery \
233         $(WebKit2)/WebProcess/Cookies \
234         $(WebKit2)/WebProcess/FullScreen \
235         $(WebKit2)/WebProcess/Geolocation \
236         $(WebKit2)/WebProcess/IconDatabase \
237         $(WebKit2)/WebProcess/KeyValueStorage \
238         $(WebKit2)/WebProcess/MediaCache \
239         $(WebKit2)/WebProcess/NetworkInfo \
240         $(WebKit2)/WebProcess/Notifications \
241         $(WebKit2)/WebProcess/Plugins \
242         $(WebKit2)/WebProcess/ResourceCache \
243         $(WebKit2)/WebProcess/WebCoreSupport \
244         $(WebKit2)/WebProcess/WebPage \
245         $(WebKit2)/WebProcess/soup
246
247 message_gen_scripts = \
248         $(WebKit2)/Scripts/generate-message-receiver.py \
249         $(WebKit2)/Scripts/generate-messages-header.py \
250         $(WebKit2)/Scripts/webkit2/__init__.py \
251         $(WebKit2)/Scripts/webkit2/messages.py \
252         $(WebKit2)/Scripts/webkit2/model.py \
253         $(WebKit2)/Scripts/webkit2/parser.py
254
255 # Message header generation
256 DerivedSources/WebKit2/%MessageReceiver.cpp: %.messages.in $(message_gen_scripts)
257         $(AM_V_GEN)$(PYTHON) $(WebKit2)/Scripts/generate-message-receiver.py $< > $@
258
259 DerivedSources/WebKit2/%Messages.h: %.messages.in $(message_gen_scripts)
260         $(AM_V_GEN)$(PYTHON) $(WebKit2)/Scripts/generate-messages-header.py $< > $@
261
262 webkit2gtk_built_headers_dir := $(GENSOURCES_WEBKIT2)/webkit2gtk/webkit2
263 $(GENSOURCES_WEBKIT2)/webkit2gtk/webkit2/WebKitEnumTypes.h: stamp-webkit2enumtypes
264         @true
265
266 stamp-webkit2enumtypes: $(libwebkit2gtkinclude_HEADERS) $(WebKit2)/GNUmakefile.am
267         $(AM_V_GEN)mkdir -p $(GENSOURCES_WEBKIT2)/webkit2gtk/webkit2 \
268         && glib-mkenums \
269                         --fhead "#if !defined(__WEBKIT2_H_INSIDE__) && !defined(WEBKIT2_COMPILATION)\n" \
270                         --fhead "#error \"Only <webkit2/webkit2.h> can be included directly.\"\n" \
271                         --fhead "#endif\n\n" \
272                         --fhead "#ifndef WEBKIT_ENUM_TYPES_H\n" \
273                         --fhead "#define WEBKIT_ENUM_TYPES_H\n\n" \
274                         --fhead "#include <glib-object.h>\n\n" \
275                         --fhead "#include <webkit2/WebKitDefines.h>\n\n" \
276                         --fhead "G_BEGIN_DECLS\n\n" \
277                         --ftail "G_END_DECLS\n\n" \
278                         --ftail "#endif\n" \
279                         --fprod "#include <webkit2/@basename@>\n\n" \
280                         --eprod "#define WEBKIT_TYPE_@ENUMSHORT@ @enum_name@_get_type()\n\n" \
281                         --eprod "WEBKIT_API GType\n@enum_name@_get_type(void);\n\n" \
282                 $(libwebkit2gtkinclude_HEADERS) | \
283                 sed 's,web_kit,webkit,' | \
284                 sed 's,WEBKIT_TYPE_KIT,WEBKIT_TYPE,' \
285                 > wk2-xgen-gth \
286         && (cmp -s wk2-xgen-gth $(webkit2gtk_built_headers_dir)/WebKitEnumTypes.h || cp wk2-xgen-gth $(webkit2gtk_built_headers_dir)/WebKitEnumTypes.h) \
287         && rm -f wk2-xgen-gth \
288         && echo timestamp > $(@F)
289
290 $(GENSOURCES_WEBKIT2)/webkit2gtk/webkit2/WebKitEnumTypes.cpp: $(libwebkit2gtkinclude_HEADERS) $(WebKit2)/GNUmakefile.am
291         $(AM_V_GEN)mkdir -p $(GENSOURCES_WEBKIT2)/webkit2gtk/webkit2 \
292         && glib-mkenums \
293                         --fhead "#include <config.h>\n" \
294                         --fhead "#include <glib-object.h>\n" \
295                         --fhead "#include \"$(webkit2gtk_built_headers_dir)/WebKitEnumTypes.h\"\n\n" \
296                         --fhead "extern \"C\" {\n\n" \
297                         --fprod "\n/* Enumerations from \"@filename@\". */" \
298                         --vhead "static const G@Type@Value _@enum_name@_values[] = {" \
299                         --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
300                         --vtail "    { 0, NULL, NULL }\n};\n\n" \
301                         --vtail "GType @enum_name@_get_type(void)\n{\n" \
302                         --vtail "    static GType type = 0;\n\n" \
303                         --vtail "    if (!type)\n" \
304                         --vtail "        type = g_@type@_register_static(\"@EnumName@\", _@enum_name@_values);\n\n" \
305                         --vtail "    return type;\n}\n\n" \
306                         --ftail "}\n" \
307                 $(libwebkit2gtkinclude_HEADERS) | \
308                 sed 's,web_kit,webkit,' \
309                 > wk2-xgen-gtc \
310         && cp wk2-xgen-gtc $@ \
311         && rm -f wk2-xgen-gtc
312
313 WEBKIT2_MARSHAL_LIST = $(WebKit2)/UIProcess/API/gtk/webkit2marshal.list
314
315 $(GENSOURCES_WEBKIT2)/webkit2gtk/webkit2/WebKitMarshal.cpp: stamp-webkit2marshal.cpp
316         @true
317 $(GENSOURCES_WEBKIT2)/webkit2gtk/webkit2/WebKitMarshal.h: stamp-webkit2marshal.h
318         @true
319
320 stamp-webkit2marshal.cpp: $(WEBKIT2_MARSHAL_LIST)
321         $(AM_V_GEN) echo "extern \"C\" {" > $(webkit2gtk_built_headers_dir)/WebKitMarshal.cpp && \
322         $(GLIB_GENMARSHAL) --prefix=webkit_marshal $(WEBKIT2_MARSHAL_LIST) --body >> $(webkit2gtk_built_headers_dir)/WebKitMarshal.cpp && \
323         echo '}' >> $(webkit2gtk_built_headers_dir)/WebKitMarshal.cpp && \
324         echo timestamp > $(@F)
325
326 stamp-webkit2marshal.h: $(WEBKIT2_MARSHAL_LIST)
327         $(AM_V_GEN)$(GLIB_GENMARSHAL) --prefix=webkit_marshal $(WEBKIT2_MARSHAL_LIST) --header > $(webkit2gtk_built_headers_dir)/WebKitMarshal.h && \
328         echo timestamp > $(@F)
329
330 CLEANFILES += \
331         $(BUILT_SOURCES) \
332         $(top_builddir)/stamp-webkit2enumtypes \
333         $(top_builddir)/stamp-webkit2marshal.cpp \
334         $(top_builddir)/stamp-webkit2marshal.h \
335         $(top_builddir)/Programs/WebKitWebProcess
336
337 DISTCLEANFILES += \
338         $(top_builddir)/WebKit2/webkit2gtk-@WEBKITGTK_API_VERSION@.pc
339
340 if ENABLE_WEBKIT2
341 libexec_PROGRAMS += \
342         Programs/WebKitWebProcess
343 endif
344
345 Programs_WebKitWebProcess_CPPFLAGS = \
346         -I$(srcdir)/Source/WebKit2 \
347         -I$(srcdir)/Source/WebKit2/UIProcess/API/C \
348         -I$(srcdir)/Source/WebKit2/WebProcess/gtk \
349         -I$(top_builddir)/DerivedSources/WebKit2 \
350         -I$(top_builddir)/DerivedSources/WebKit2/include \
351         -I$(top_builddir)/DerivedSources/WebKit2/include/WebCore \
352         $(global_cppflags) \
353         $(javascriptcore_cppflags)
354
355 Programs_WebKitWebProcess_CFLAGS = \
356         $(global_cflags) \
357         $(CAIRO_CFLAGS) \
358         $(GLIB_CFLAGS) \
359         $(GTK_CFLAGS) \
360         $(GTK_UNIX_PRINTING_CFLAGS) \
361         $(LIBSOUP_CFLAGS) \
362         $(ZLIB_CFLAGS)
363
364 Programs_WebKitWebProcess_SOURCES = \
365         Source/WebKit2/gtk/MainGtk.cpp
366
367 Programs_WebKitWebProcess_LDADD = \
368         libjavascriptcoregtk-@WEBKITGTK_API_MAJOR_VERSION@.@WEBKITGTK_API_MINOR_VERSION@.la \
369         libwebkit2gtk-@WEBKITGTK_API_MAJOR_VERSION@.@WEBKITGTK_API_MINOR_VERSION@.la \
370         $(GLIB_LIBS) \
371         $(GTK_LIBS) \
372         $(GTK_UNIX_PRINTING_LIBS) \
373         $(LIBSOUP_LIBS)
374
375 # PluginProcess
376 if ENABLE_PLUGIN_PROCESS
377
378 # We need to make sure plugin process is always built with gtk2, because plugins like flash
379 # still use gtk2. Since webcore was built with gtk3, we need to build webcoregtk sources again with gtk2
380 noinst_LTLIBRARIES += \
381         libWebCoreGtk2.la
382
383 libWebCoreGtk2_la_SOURCES = \
384         $(webcoregtk_sources)
385
386 libWebCoreGtk2_la_CXXFLAGS = \
387         $(SYMBOL_VISIBILITY_INLINES) \
388         $(global_cxxflags)
389
390 libWebCoreGtk2_la_CFLAGS = \
391         $(SYMBOL_VISIBILITY) \
392         $(global_cflags)
393
394 libWebCoreGtk2_la_CPPFLAGS = \
395         -DBUILDING_WEBKIT \
396         -DGTK_API_VERSION_2=1 \
397         $(global_cppflags) \
398         $(webcore_cppflags) \
399         $(webcoregtk_cppflags) \
400         $(javascriptcore_cppflags) \
401         -fno-strict-aliasing \
402         $(COVERAGE_CFLAGS) \
403         $(ENCHANT_CFLAGS) \
404         $(GEOCLUE_CFLAGS) \
405         $(FARSTREAM_CFLAGS) \
406         $(GLIB_CFLAGS) \
407         $(GSTREAMER_CFLAGS) \
408         $(GTK2_CFLAGS) \
409         $(LIBSOUP_CFLAGS) \
410         $(LIBXML_CFLAGS) \
411         $(LIBXSLT_CFLAGS) \
412         $(SQLITE3_CFLAGS) \
413         $(UNICODE_CFLAGS) \
414         $(XRENDER_CFLAGS) \
415         $(XT_CFLAGS)
416
417 libexec_PROGRAMS += \
418         Programs/WebKitPluginProcess
419
420 # Serialize linking of the plugin process with both webkit libraries.
421 plugin_process_for_dep = Programs/WebKitPluginProcess
422 $(plugin_process_for_dep): libwebkitgtk-@WEBKITGTK_API_MAJOR_VERSION@.@WEBKITGTK_API_MINOR_VERSION@.la libwebkit2gtk-@WEBKITGTK_API_MAJOR_VERSION@.@WEBKITGTK_API_MINOR_VERSION@.la
423
424 Programs_WebKitPluginProcess_CPPFLAGS = \
425         -include $(srcdir)/Source/WebKit2/WebKit2Prefix.h \
426         -I$(srcdir)/Source/WebKit2 \
427         -I$(srcdir)/Source/WebKit2/Platform \
428         -I$(srcdir)/Source/WebKit2/Platform/CoreIPC/ \
429         -I$(srcdir)/Source/WebKit2/PluginProcess/ \
430         -I$(srcdir)/Source/WebKit2/PluginProcess/gtk \
431         -I$(srcdir)/Source/WebKit2/Shared \
432         -I$(srcdir)/Source/WebKit2/Shared/Plugins \
433         -I$(srcdir)/Source/WebKit2/Shared/Plugins/Netscape/ \
434         -I$(srcdir)/Source/WebKit2/UIProcess/Plugins/ \
435         -I$(srcdir)/Source/WebKit2/UIProcess/Launcher \
436         -I$(srcdir)/Source/WebKit2/WebProcess/Plugins/ \
437         -I$(srcdir)/Source/WebKit2/WebProcess/Plugins/Netscape/ \
438         -I$(srcdir)/Source/WebKit2/Shared/soup \
439         -I$(top_builddir)/DerivedSources/WebKit2 \
440         -I$(top_builddir)/DerivedSources/WebKit2/include \
441         -I$(top_builddir)/DerivedSources/WebKit2/include/JavaScriptCore \
442         -I$(top_builddir)/DerivedSources/WebKit2/include/WebCore \
443         -I$(top_builddir)/DerivedSources/WebKit2/include/WebKit2 \
444         -DBUILDING_WEBKIT \
445         -DGTK_API_VERSION_2=1 \
446         -DENABLE_PLUGIN_PROCESS=1 \
447         -DLIBEXECDIR=\""$(libexecdir)"\" \
448         $(global_cppflags) \
449         $(webcore_cppflags) \
450         $(webcoregtk_cppflags) \
451         $(javascriptcore_cppflags) \
452         -fno-strict-aliasing \
453         $(CAIRO_CFLAGS) \
454         $(GLIB_CFLAGS) \
455         $(GSTREAMER_CFLAGS) \
456         $(GTK2_CFLAGS) \
457         $(LIBSOUP_CFLAGS) \
458         $(UNICODE_CFLAGS)
459
460 Programs_WebKitPluginProcess_CFLAGS = \
461         $(SYMBOL_VISIBILITY) \
462         $(global_cflags) \
463         $(CAIRO_CFLAGS) \
464         $(GLIB_CFLAGS) \
465         $(GSTREAMER_CFLAGS) \
466         $(GTK2_CFLAGS) \
467         $(LIBSOUP_CFLAGS) \
468         $(UNICODE_CFLAGS)
469
470 nodist_Programs_WebKitPluginProcess_SOURCES = \
471         $(webkit2_plugin_process_built_sources)
472
473 Programs_WebKitPluginProcess_SOURCES = \
474         $(webkit2_plugin_process_sources)
475
476 Programs_WebKitPluginProcess_LDADD = \
477         -lpthread \
478         libjavascriptcoregtk-@WEBKITGTK_API_MAJOR_VERSION@.@WEBKITGTK_API_MINOR_VERSION@.la \
479         libWebCore.la \
480         libWebCoreGtk2.la \
481         $(CAIRO_LIBS) \
482         $(COVERAGE_LDFLAGS) \
483         $(GEOCLUE_LIBS) \
484         $(GLIB_LIBS) \
485         $(GSTREAMER_LIBS) \
486         $(GTK2_LIBS) \
487         $(JPEG_LIBS) \
488         $(LIBSOUP_LIBS) \
489         $(LIBXML_LIBS) \
490         $(LIBXSLT_LIBS) \
491         $(OLE32_LIBS) \
492         $(OPENGL_LIBS) \
493         $(PANGO_LIBS) \
494         $(PNG_LIBS) \
495         $(SHLWAPI_LIBS) \
496         $(SQLITE3_LIBS) \
497         $(UNICODE_LIBS) \
498         $(XRENDER_LIBS) \
499         $(XT_LIBS) \
500         $(WINMM_LIBS) \
501         $(ZLIB_LIBS)
502
503 # libWebCore and libWebCoreModules have circular dependencies that only seem to
504 # be a problem when linking the plugin process; we don't really care about
505 # modules for the plugin process, though, so to work around that we ignore
506 # internal unresolved symbols
507 Programs_WebKitPluginProcess_LDFLAGS = \
508         -Wl,--unresolved-symbols=ignore-in-object-files
509
510 Programs_WebKitPluginProcess_CXXFLAGS = \
511         $(SYMBOL_VISIBILITY_INLINES) \
512         $(global_cxxflags)
513
514 endif # ENABLE_PLUGIN_PROCESS
515
516 EXTRA_DIST += \
517         $(WebKit2)/UIProcess/API/gtk/docs/webkit2gtk-docs.sgml \
518         $(WebKit2)/UIProcess/API/gtk/docs/webkit2gtk-sections.txt \
519         $(WebKit2)/UIProcess/API/gtk/docs/webkit2gtk.types \
520         $(WebKit2)/Scripts/generate-message-receiver.py \
521         $(WebKit2)/Scripts/generate-messages-header.py \
522         $(WebKit2)/Scripts/webkit2/__init__.py \
523         $(WebKit2)/Scripts/webkit2/messages.py \
524         $(WebKit2)/Scripts/webkit2/model.py \
525         $(WebKit2)/Scripts/webkit2/parser.py \
526         $(WebKit2)/UIProcess/API/gtk/webkit2marshal.list \
527         $(WebKit2)/Scripts/generate-forwarding-headers.pl \
528         $(shell ls $(WebKit2)/PluginProcess/*.in) \
529         $(shell ls $(WebKit2)/Shared/Plugins/*.in) \
530         $(shell ls $(WebKit2)/UIProcess/*.in) \
531         $(shell ls $(WebKit2)/UIProcess/Downloads/*.in) \
532         $(shell ls $(WebKit2)/UIProcess/Notifications/*.in) \
533         $(shell ls $(WebKit2)/UIProcess/Plugins/*.in) \
534         $(shell ls $(WebKit2)/UIProcess/soup/*.in) \
535         $(shell ls $(WebKit2)/WebProcess/*.in) \
536         $(shell ls $(WebKit2)/WebProcess/ApplicationCache/*.in) \
537         $(shell ls $(WebKit2)/WebProcess/Authentication/*.in) \
538         $(shell ls $(WebKit2)/WebProcess/Battery/*.in) \
539         $(shell ls $(WebKit2)/WebProcess/Cookies/*.in) \
540         $(shell ls $(WebKit2)/WebProcess/FullScreen/*.in) \
541         $(shell ls $(WebKit2)/WebProcess/Geolocation/*.in) \
542         $(shell ls $(WebKit2)/WebProcess/IconDatabase/*.in) \
543         $(shell ls $(WebKit2)/WebProcess/KeyValueStorage/*.in) \
544         $(shell ls $(WebKit2)/WebProcess/MediaCache/*.in) \
545         $(shell ls $(WebKit2)/WebProcess/NetworkInfo/*.in) \
546         $(shell ls $(WebKit2)/WebProcess/Notifications/*.in) \
547         $(shell ls $(WebKit2)/WebProcess/Plugins/*.in) \
548         $(shell ls $(WebKit2)/WebProcess/ResourceCache/*.in) \
549         $(shell ls $(WebKit2)/WebProcess/WebCoreSupport/*.in) \
550         $(shell ls $(WebKit2)/WebProcess/WebPage/*.in) \
551         $(shell ls $(WebKit2)/WebProcess/soup/*.in)