upload webkit/tizen 2.0_beta source.
[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 load(features)
15
16 WEBCORE_GENERATED_SOURCES_DIR = ../WebCore/$${GENERATED_SOURCES_DESTDIR}
17
18 SOURCE_DIR = $${ROOT_WEBKIT_DIR}/Source
19
20 WEBCORE_GENERATED_HEADERS_FOR_WEBKIT2 += \
21     $$WEBCORE_GENERATED_SOURCES_DIR/HTMLNames.h \
22     $$WEBCORE_GENERATED_SOURCES_DIR/JSCSSStyleDeclaration.h \
23     $$WEBCORE_GENERATED_SOURCES_DIR/JSDOMWindow.h \
24     $$WEBCORE_GENERATED_SOURCES_DIR/JSElement.h \
25     $$WEBCORE_GENERATED_SOURCES_DIR/JSHTMLElement.h \
26     $$WEBCORE_GENERATED_SOURCES_DIR/JSNode.h \
27     $$WEBCORE_GENERATED_SOURCES_DIR/JSRange.h \
28
29 defineReplace(message_header_generator_output) {
30   FILENAME=$$basename(1)
31   return($${GENERATED_SOURCES_DESTDIR}/$$replace(FILENAME, ".messages.in", "Messages.h"))
32 }
33
34 defineReplace(message_receiver_generator_output) {
35   FILENAME=$$basename(1)
36   return($${GENERATED_SOURCES_DESTDIR}/$$replace(FILENAME, ".messages.in", "MessageReceiver.cpp"))
37 }
38
39 VPATH = \
40     PluginProcess \
41     WebProcess/ApplicationCache \
42     WebProcess/Authentication \
43     WebProcess/Cookies \
44     WebProcess/FullScreen \
45     WebProcess/Geolocation \
46     WebProcess/IconDatabase \
47     WebProcess/KeyValueStorage \
48     WebProcess/MediaCache \
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     LayerTreeHostProxy.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     WebContext.messages.in \
75     WebCookieManager.messages.in \
76     WebCookieManagerProxy.messages.in \
77     WebDatabaseManager.messages.in \
78     WebDatabaseManagerProxy.messages.in \
79     WebGeolocationManager.messages.in \
80     WebGeolocationManagerProxy.messages.in \
81     WebIconDatabase.messages.in \
82     WebIconDatabaseProxy.messages.in \
83     WebInspectorProxy.messages.in \
84     WebKeyValueStorageManager.messages.in \
85     WebKeyValueStorageManagerProxy.messages.in \
86     WebMediaCacheManager.messages.in \
87     WebMediaCacheManagerProxy.messages.in \
88     WebNotificationManagerProxy.messages.in \
89     WebNotificationManager.messages.in \
90     WebFullScreenManager.messages.in \
91     WebFullScreenManagerProxy.messages.in \
92     WebPage/DrawingArea.messages.in \
93     WebPage/LayerTreeHost.messages.in \
94     WebPage/WebInspector.messages.in \
95     WebPage/WebPage.messages.in \
96     WebPageProxy.messages.in \
97     WebProcess.messages.in \
98     WebProcessConnection.messages.in \
99     WebProcessProxy.messages.in \
100     WebResourceCacheManager.messages.in \
101     WebResourceCacheManagerProxy.messages.in \
102     NPObjectMessageReceiver.messages.in
103
104 SCRIPTS = \
105     $$PWD/Scripts/generate-message-receiver.py \
106     $$PWD/Scripts/generate-messages-header.py \
107     $$PWD/Scripts/webkit2/__init__.py \
108     $$PWD/Scripts/webkit2/messages.py \
109     $$PWD/Scripts/webkit2/model.py \
110     $$PWD/Scripts/webkit2/parser.py
111
112 message_header_generator.commands = $${PYTHON} $${SOURCE_DIR}/WebKit2/Scripts/generate-messages-header.py ${QMAKE_FILE_IN} > ${QMAKE_FILE_OUT}
113 message_header_generator.input = MESSAGE_RECEIVERS
114 message_header_generator.depends = $$SCRIPTS
115 message_header_generator.output_function = message_header_generator_output
116 message_header_generator.add_output_to_sources = false
117 GENERATORS += message_header_generator
118
119 message_receiver_generator.commands = $${PYTHON} $${SOURCE_DIR}/WebKit2/Scripts/generate-message-receiver.py  ${QMAKE_FILE_IN} > ${QMAKE_FILE_OUT}
120 message_receiver_generator.input = MESSAGE_RECEIVERS
121 message_receiver_generator.depends = $$SCRIPTS
122 message_receiver_generator.output_function = message_receiver_generator_output
123 GENERATORS += message_receiver_generator
124
125 fwheader_generator.commands = perl $${SOURCE_DIR}/WebKit2/Scripts/generate-forwarding-headers.pl $${SOURCE_DIR}/WebKit2 $${ROOT_BUILD_DIR}/Source/include qt
126 fwheader_generator.depends = $${SOURCE_DIR}/WebKit2/Scripts/generate-forwarding-headers.pl
127 generated_files.depends += fwheader_generator
128 GENERATORS += fwheader_generator
129
130 for(header, WEBCORE_GENERATED_HEADERS_FOR_WEBKIT2) {
131     header_name = $$basename(header)
132     header_path = $$header
133     header_target = $$replace(header_path, [^a-zA-Z0-9_], -)
134     header_target = "qtheader-$${header_target}"
135     dest_dir = $${ROOT_BUILD_DIR}/Source/include/WebCore
136
137     eval($${header_target}.target = $$dest_dir/$$header_name)
138     eval($${header_target}.depends = $$header_path)
139     eval($${header_target}.commands = $${QMAKE_MKDIR} $$dest_dir && echo $${DOUBLE_ESCAPED_QUOTE}\$${LITERAL_HASH}include \\\"$$header_path\\\"$${DOUBLE_ESCAPED_QUOTE} > $$eval($${header_target}.target))
140
141     GENERATORS += $$header_target
142 }
143