Merge "Add to ewk api for setting/getting the User Agent by using system info library...
[framework/web/webkit-efl.git] / Source / WebKit2 / DerivedSources.pri
1 # -------------------------------------------------------------------
2 # Derived sources for WebKit2
3 #
4 # See 'Tools/qmake/README' for an overview of the build system
5 # -------------------------------------------------------------------
6
7 # This file is both a top level target, and included from Target.pri,
8 # so that the resulting generated sources can be added to SOURCES.
9 # We only set the template if we're a top level target, so that we
10 # don't override what Target.pri has already set.
11 sanitizedFile = $$toSanitizedPath($$_FILE_)
12 equals(sanitizedFile, $$toSanitizedPath($$_PRO_FILE_)):TEMPLATE = derived
13
14 WEBCORE_GENERATED_SOURCES_DIR = ../WebCore/$${GENERATED_SOURCES_DESTDIR}
15
16 SOURCE_DIR = $${ROOT_WEBKIT_DIR}/Source
17
18 WEBCORE_GENERATED_HEADERS_FOR_WEBKIT2 += \
19     $$WEBCORE_GENERATED_SOURCES_DIR/HTMLNames.h \
20     $$WEBCORE_GENERATED_SOURCES_DIR/JSCSSStyleDeclaration.h \
21     $$WEBCORE_GENERATED_SOURCES_DIR/JSDOMWindow.h \
22     $$WEBCORE_GENERATED_SOURCES_DIR/JSElement.h \
23     $$WEBCORE_GENERATED_SOURCES_DIR/JSHTMLElement.h \
24     $$WEBCORE_GENERATED_SOURCES_DIR/JSNode.h \
25     $$WEBCORE_GENERATED_SOURCES_DIR/JSRange.h \
26
27 defineReplace(message_header_generator_output) {
28   FILENAME=$$basename(1)
29   return($${GENERATED_SOURCES_DESTDIR}/$$replace(FILENAME, ".messages.in", "Messages.h"))
30 }
31
32 defineReplace(message_receiver_generator_output) {
33   FILENAME=$$basename(1)
34   return($${GENERATED_SOURCES_DESTDIR}/$$replace(FILENAME, ".messages.in", "MessageReceiver.cpp"))
35 }
36
37 VPATH = \
38     PluginProcess \
39     WebProcess/ApplicationCache \
40     WebProcess/Authentication \
41     WebProcess/Battery \
42     WebProcess/Cookies \
43     WebProcess/FullScreen \
44     WebProcess/Geolocation \
45     WebProcess/IconDatabase \
46     WebProcess/KeyValueStorage \
47     WebProcess/MediaCache \
48     WebProcess/NetworkInfo \
49     WebProcess/Notifications \
50     WebProcess/Plugins \
51     WebProcess/ResourceCache \
52     WebProcess/WebCoreSupport \
53     WebProcess/WebPage \
54     WebProcess \
55     UIProcess \
56     UIProcess/Downloads \
57     UIProcess/Notifications \
58     UIProcess/Plugins \
59     Shared/Plugins
60
61 MESSAGE_RECEIVERS = \
62     AuthenticationManager.messages.in \
63     DownloadProxy.messages.in \
64     DrawingAreaProxy.messages.in \
65     EventDispatcher.messages.in \
66     LayerTreeCoordinatorProxy.messages.in \
67     PluginControllerProxy.messages.in \
68     PluginProcess.messages.in \
69     PluginProcessConnection.messages.in \
70     PluginProcessProxy.messages.in \
71     PluginProxy.messages.in \
72     WebApplicationCacheManager.messages.in \
73     WebApplicationCacheManagerProxy.messages.in \
74     WebBatteryManager.messages.in \
75     WebBatteryManagerProxy.messages.in \
76     WebContext.messages.in \
77     WebCookieManager.messages.in \
78     WebCookieManagerProxy.messages.in \
79     WebDatabaseManager.messages.in \
80     WebDatabaseManagerProxy.messages.in \
81     WebGeolocationManager.messages.in \
82     WebGeolocationManagerProxy.messages.in \
83     WebIconDatabase.messages.in \
84     WebIconDatabaseProxy.messages.in \
85     WebInspectorProxy.messages.in \
86     WebKeyValueStorageManager.messages.in \
87     WebKeyValueStorageManagerProxy.messages.in \
88     WebMediaCacheManager.messages.in \
89     WebMediaCacheManagerProxy.messages.in \
90     WebNetworkInfoManager.messages.in \
91     WebNetworkInfoManagerProxy.messages.in \
92     WebNotificationManagerProxy.messages.in \
93     WebNotificationManager.messages.in \
94     WebFullScreenManager.messages.in \
95     WebFullScreenManagerProxy.messages.in \
96     WebPage/DrawingArea.messages.in \
97     WebPage/LayerTreeCoordinator/LayerTreeCoordinator.messages.in \
98     WebPage/WebInspector.messages.in \
99     WebPage/WebPage.messages.in \
100     WebPageProxy.messages.in \
101     WebProcess.messages.in \
102     WebProcessConnection.messages.in \
103     WebProcessProxy.messages.in \
104     WebResourceCacheManager.messages.in \
105     WebResourceCacheManagerProxy.messages.in \
106     WebVibrationProxy.messages.in \
107     NPObjectMessageReceiver.messages.in
108
109 SCRIPTS = \
110     $$PWD/Scripts/generate-message-receiver.py \
111     $$PWD/Scripts/generate-messages-header.py \
112     $$PWD/Scripts/webkit2/__init__.py \
113     $$PWD/Scripts/webkit2/messages.py \
114     $$PWD/Scripts/webkit2/model.py \
115     $$PWD/Scripts/webkit2/parser.py
116
117 message_header_generator.commands = $${PYTHON} $${SOURCE_DIR}/WebKit2/Scripts/generate-messages-header.py ${QMAKE_FILE_IN} > ${QMAKE_FILE_OUT}
118 message_header_generator.input = MESSAGE_RECEIVERS
119 message_header_generator.depends = $$SCRIPTS
120 message_header_generator.output_function = message_header_generator_output
121 message_header_generator.add_output_to_sources = false
122 GENERATORS += message_header_generator
123
124 message_receiver_generator.commands = $${PYTHON} $${SOURCE_DIR}/WebKit2/Scripts/generate-message-receiver.py  ${QMAKE_FILE_IN} > ${QMAKE_FILE_OUT}
125 message_receiver_generator.input = MESSAGE_RECEIVERS
126 message_receiver_generator.depends = $$SCRIPTS
127 message_receiver_generator.output_function = message_receiver_generator_output
128 GENERATORS += message_receiver_generator
129
130 fwheader_generator.commands = perl $${SOURCE_DIR}/WebKit2/Scripts/generate-forwarding-headers.pl $${SOURCE_DIR}/WebKit2 $${ROOT_BUILD_DIR}/Source/include qt
131 fwheader_generator.depends = $${SOURCE_DIR}/WebKit2/Scripts/generate-forwarding-headers.pl
132 generated_files.depends += fwheader_generator
133 GENERATORS += fwheader_generator
134
135 for(header, WEBCORE_GENERATED_HEADERS_FOR_WEBKIT2) {
136     header_name = $$basename(header)
137     header_path = $$header
138     header_target = $$replace(header_path, [^a-zA-Z0-9_], -)
139     header_target = "qtheader-$${header_target}"
140     dest_dir = $${ROOT_BUILD_DIR}/Source/include/WebCore
141
142     eval($${header_target}.target = $$dest_dir/$$header_name)
143     eval($${header_target}.depends = $$header_path)
144     eval($${header_target}.commands = $${QMAKE_MKDIR} $$dest_dir && echo $${DOUBLE_ESCAPED_QUOTE}\$${LITERAL_HASH}include \\\"$$header_path\\\"$${DOUBLE_ESCAPED_QUOTE} > $$eval($${header_target}.target))
145
146     GENERATORS += $$header_target
147 }
148