1 SET(PROJECT_VERSION_MAJOR 0)
2 SET(PROJECT_VERSION_MINOR 6)
3 SET(PROJECT_VERSION_PATCH 9)
4 SET(PROJECT_VERSION ${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH})
6 # -----------------------------------------------------------------------------
7 # We mention Safari version because many sites check for it.
8 # Sync with Source/WebCore/Configurations/Version.xcconfig whenever Safari is
10 # -----------------------------------------------------------------------------
11 SET(WEBKIT_USER_AGENT_MAJOR_VERSION 534)
12 SET(WEBKIT_USER_AGENT_MINOR_VERSION 16)
14 ADD_DEFINITIONS(-DBUILDING_EFL__=1)
15 ADD_DEFINITIONS(-DWTF_PLATFORM_EFL=1)
16 SET(WTF_PLATFORM_EFL 1)
18 # -----------------------------------------------------------------------------
19 # Determine which network backend will be used
20 # -----------------------------------------------------------------------------
21 SET(ALL_NETWORK_BACKENDS soup curl)
22 SET(NETWORK_BACKEND "soup" CACHE STRING "choose which network backend to use (one of ${ALL_NETWORK_BACKENDS})")
24 # -----------------------------------------------------------------------------
25 # Determine which font backend will be used
26 # -----------------------------------------------------------------------------
27 SET(ALL_FONT_BACKENDS freetype pango)
28 SET(FONT_BACKEND "freetype" CACHE STRING "choose which font backend to use (one of ${ALL_FONT_BACKENDS})")
30 FIND_PACKAGE(Cairo 1.10 REQUIRED)
31 FIND_PACKAGE(EFL REQUIRED)
32 FIND_PACKAGE(Fontconfig 2.8.0 REQUIRED)
33 FIND_PACKAGE(Sqlite REQUIRED)
34 FIND_PACKAGE(LibXml2 2.6 REQUIRED)
35 FIND_PACKAGE(LibXslt 1.1.7 REQUIRED)
36 FIND_PACKAGE(ICU REQUIRED)
37 FIND_PACKAGE(Threads REQUIRED)
38 FIND_PACKAGE(JPEG REQUIRED)
39 FIND_PACKAGE(PNG REQUIRED)
41 ADD_DEFINITIONS(-DENABLE_CONTEXT_MENUS=1)
43 SET(WTF_USE_PTHREADS 1)
44 ADD_DEFINITIONS(-DWTF_USE_PTHREADS=1)
46 SET(WTF_USE_ICU_UNICODE 1)
47 ADD_DEFINITIONS(-DWTF_USE_ICU_UNICODE=1)
50 ADD_DEFINITIONS(-DWTF_USE_CAIRO=1)
52 SET(JSC_EXECUTABLE_NAME jsc_efl)
53 SET(WTF_LIBRARY_NAME wtf_efl)
54 SET(JavaScriptCore_LIBRARY_NAME javascriptcore_efl)
55 SET(WebCore_LIBRARY_NAME webcore_efl)
56 SET(WebKit_LIBRARY_NAME ewebkit)
57 SET(WebKit2_LIBRARY_NAME ewebkit2)
59 SET(DATA_INSTALL_DIR "share/${WebKit_LIBRARY_NAME}-${PROJECT_VERSION_MAJOR}" CACHE PATH "Installation path for theme data")
60 SET(THEME_BINARY_DIR ${CMAKE_BINARY_DIR}/WebKit/efl/DefaultTheme)
62 SET(VERSION_SCRIPT "-Wl,--version-script,${CMAKE_MODULE_PATH}/eflsymbols.filter")
65 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_3D_RENDERING ON)
66 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_BATTERY_STATUS OFF)
67 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_BLOB ON)
68 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_CSS_FILTERS ON)
69 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_DATALIST ON)
70 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_DEVICE_ORIENTATION ON)
71 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_FILE_SYSTEM ON)
72 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_FILTERS ON)
73 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_FULLSCREEN_API ON)
74 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_GEOLOCATION ON)
75 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_GLIB_SUPPORT ON)
76 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_INDEXED_DATABASE ON)
77 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_INPUT_TYPE_DATE ON)
78 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_INPUT_TYPE_DATETIME ON)
79 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_INPUT_TYPE_DATETIMELOCAL ON)
80 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_INPUT_TYPE_MONTH ON)
81 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_INPUT_TYPE_TIME ON)
82 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_INPUT_TYPE_WEEK ON)
83 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_INPUT_TYPE_COLOR ON)
84 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_LEGACY_WEBKIT_BLOB_BUILDER ON)
85 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_MEDIA_CAPTURE ON)
86 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_MICRODATA ON)
87 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_PAGE_VISIBILITY_API ON)
88 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_REGISTER_PROTOCOL_HANDLER ON)
89 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_REQUEST_ANIMATION_FRAME OFF)
90 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_SHARED_WORKERS ON)
91 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_TOUCH_EVENTS ON)
92 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_TOUCH_ICON_LOADING ON)
93 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_VIBRATION ON)
94 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_VIDEO ON)
95 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_VIDEO_TRACK ON)
96 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_WEB_AUDIO ON)
97 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_WORKERS ON)
98 WEBKIT_OPTION_DEFAULT_PORT_VALUE(USE_SYSTEM_MALLOC ON)
100 WEBKIT_OPTION_DEFINE(ENABLE_AS_IMAGE "Enable SVG as image" ON)
101 WEBKIT_OPTION_DEFINE(ENABLE_CDOM_BINDINGS "C DOM Bindings" OFF)
102 WEBKIT_OPTION_DEFINE(ENABLE_DFG_JIT "Enable DFG JIT" OFF)
103 WEBKIT_OPTION_DEFINE(ENABLE_FAST_MALLOC "Enable fastMalloc" OFF)
104 WEBKIT_OPTION_DEFINE(ENABLE_MEMORY_SAMPLER "Enable Memory Sampler for WebKit2" ON)
105 WEBKIT_OPTION_DEFINE(ENABLE_OFFLINE_WEB_APPLICATIONS "Enable offline web applications" ON)
106 WEBKIT_OPTION_DEFINE(ENABLE_OVERFLOW_SCROLLING "Enable css overflow scrolling property" ON)
107 WEBKIT_OPTION_DEFINE(ENABLE_PLUGIN_PROCESS "Enable PluginProcess for WebKit2" ON)
109 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_ORIENTATION_EVENTS ON)
111 #--------------------------------------------------------------------------------------
112 # Enabled WebKit Features for Tizen or Tizen Specific Features.
113 #--------------------------------------------------------------------------------------
114 WEBKIT_OPTION_DEFINE(ENABLE_TIZEN_DBSPACE_PATH "Enable Tizen application's directory path" ON)
115 WEBKIT_OPTION_DEFINE(ENABLE_TIZEN_INTERNATIONAL_TEXT_SUPPORT "Enable International text support for tizen webkit" ON)
116 WEBKIT_OPTION_DEFINE(ENABLE_TIZEN_REGISTER_CONTENT_HANDLER "Enable the register content handler for Tizen" ON)
117 WEBKIT_OPTION_DEFINE(ENABLE_TIZEN_SEARCH_PROVIDER "Enable Tizen search provider for Tizen" OFF)
118 WEBKIT_OPTION_DEFINE(ENABLE_TIZEN_SUPPORT "Enable Tizen Support" ON)
119 WEBKIT_OPTION_DEFINE(ENABLE_TIZEN_SUPPORT_WEBAPP_META_TAG "Enable apple meta tag" ON)
120 WEBKIT_OPTION_DEFINE(ENABLE_TIZEN_WEBKIT_EFL_DRT "Enable DumpRenderTree for Tizen WebKit" ON)
122 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_SCREEN_ORIENTATION_SUPPORT ON)
123 ADD_DEFINITIONS(-DENABLE_TIZEN_SCREEN_ORIENTATION_SUPPORT=1)
126 WEBKIT_OPTION_DEFINE(ENABLE_NOTIFICATIONS "notification" ON)
127 WEBKIT_OPTION_DEFINE(ENABLE_LEGACY_NOTIFICATIONS "legacy notification" ON)
128 WEBKIT_OPTION_DEFINE(ENABLE_TIZEN_MM_PLAYER "Use Tizen Multimedia Framework for Tizen" OFF)
129 WEBKIT_OPTION_DEFINE(ENABLE_MEDIA_STREAM "Enable Media Stream" ON)
130 WEBKIT_OPTION_DEFINE(ENABLE_TIZEN_WEBKIT2_SPELLCHECKING "Enable spellchecking in WebKit 2" OFF)
135 OPTION(ENABLE_ECORE_X "Enable Ecore_X specific usage (cursor, bell)" ON)
138 MESSAGE(STATUS "Using Ecore-X to provide extended support.")
139 ADD_DEFINITIONS(-DHAVE_ECORE_X)
141 MESSAGE(ERROR "Requested Ecore-X but it was not found!")
145 IF (NETWORK_BACKEND STREQUAL "soup")
146 IF (NOT ENABLE_GLIB_SUPPORT)
147 SET(ENABLE_GLIB_SUPPORT 1)
148 MESSAGE("Forcing Glib support")
150 FIND_PACKAGE(LibSoup2 2.33.4 REQUIRED)
152 ADD_DEFINITIONS(-DWTF_USE_SOUP=1)
154 FIND_PACKAGE(CURL REQUIRED)
155 FIND_PACKAGE(ZLIB REQUIRED)
157 ADD_DEFINITIONS(-DWTF_USE_CURL=1)
160 IF (FONT_BACKEND STREQUAL "freetype")
162 FIND_PACKAGE(Freetype REQUIRED)
163 FIND_PACKAGE(ZLIB REQUIRED)
164 SET(WTF_USE_FREETYPE 1)
165 ADD_DEFINITIONS(-DWTF_USE_FREETYPE=1)
167 FIND_PACKAGE(Pango REQUIRED)
169 ADD_DEFINITIONS(-DWTF_USE_PANGO=1)
171 IF (NOT ENABLE_GLIB_SUPPORT)
172 SET(ENABLE_GLIB_SUPPORT 1)
173 MESSAGE("Forcing Glib support")
178 SET(ENABLE_GLIB_SUPPORT 1)
179 MESSAGE("Forcing Glib support")
182 IF (ENABLE_GLIB_SUPPORT)
183 FIND_PACKAGE(Glib REQUIRED)
184 FIND_PACKAGE(Gthread REQUIRED)
187 SET(CPACK_SOURCE_GENERATOR TBZ2)
189 # -----------------------------------------------------------------------------
190 # Determine which Samsung model will be defined
191 # -----------------------------------------------------------------------------
192 IF (ENABLE_TIZEN_SUPPORT)
193 ADD_DEFINITIONS(-DWTF_OS_TIZEN=1)
196 ADD_DEFINITIONS(-DENABLE_TIZEN_WEBKIT2=1)
199 SET(ENABLE_TOUCH_ICON_LOADING 1)
201 IF (ENABLE_BATTERY_STATUS)
202 ADD_DEFINITIONS(-DENABLE_TIZEN_BATTERY_STATUS=1)
203 SET(ENABLE_TIZEN_BATTERY_STATUS 1)
204 FIND_PACKAGE(Pmapi REQUIRED)
208 # SET(ENABLE_NOTIFICATIONS 1)
209 # LIST(APPEND FEATURE_DEFINES ENABLE_NOTIFICATIONS)
210 # SET(ENABLE_LEGACY_NOTIFICATIONS 1)
211 # LIST(APPEND FEATURE_DEFINES ENABLE_LEGACY_NOTIFICATIONS)
213 SET(ENABLE_PAGE_VISIBILITY_API 1)
214 SET(ENABLE_TIZEN_KEYGEN 1)
215 LIST(APPEND FEATURE_DEFINES ENABLE_TIZEN_KEYGEN)
216 #FIXME SET(ENABLE_WEBGL 1)
218 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_TIZEN_MM_PLAYER "Use Tizen Multimedia Framework for Tizen" DEFAULT ON)
219 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_MEDIA_STREAM "Enable Media Stream" DEFAULT OFF)
222 IF (ENABLE_REGISTER_PROTOCOL_HANDLER)
223 SET(ENABLE_TIZEN_REGISTER_PROTOCOL_HANDLER 1)
226 # -----------------------------------------------------------------------------
227 # Checking Tizen dependencies.
228 # -----------------------------------------------------------------------------
229 MESSAGE("Checking Tizen dependencies...")
231 FIND_PACKAGE(ELEMENTARY REQUIRED)
232 FIND_PACKAGE(UIGadget REQUIRED)
236 ADD_DEFINITIONS(-DENABLE_TIZEN_DLOG_SUPPORT=1)
239 FIND_PACKAGE(Media-Utils 0.1.35 REQUIRED)
240 FIND_PACKAGE(VConf REQUIRED)
242 IF (ENABLE_DEVICE_ORIENTATION)
243 FIND_PACKAGE(Tizen-Sensor REQUIRED)
244 SET(ENABLE_TIZEN_DEVICE_ORIENTATION 1)
247 IF(ENABLE_GEOLOCATION)
248 FIND_PACKAGE(Tizen-Location-Manager REQUIRED)
249 ADD_DEFINITIONS(-DENABLE_TIZEN_GEOLOCATION=1)
250 SET(ENABLE_TIZEN_GEOLOCATION 1)
253 IF (ENABLE_TIZEN_KEYGEN)
254 FIND_PACKAGE(SSL REQUIRED)
258 FIND_PACKAGE(Skia REQUIRED)
259 FIND_PACKAGE(Harfbuzz REQUIRED)
261 ADD_DEFINITIONS(-UWTF_USE_CAIRO)
262 ADD_DEFINITIONS(-DWTF_USE_SKIA=1)
263 ADD_DEFINITIONS(-DENABLE_TIZEN_SKIA_FOR_PROFILE=1)
266 IF (ENABLE_TIZEN_RENDERING_PROFILE)
267 ADD_DEFINITIONS(-DENABLE_TIZEN_RENDERING_PROFILE_TEST=1)
270 FIND_PACKAGE(GLES REQUIRED)
271 IF (ENABLE_WEBKIT2 OR NOT WTF_USE_CAIRO)
272 IF ("${EFL_TARGET}" STREQUAL "i386")
273 SET(WTF_USE_ACCELERATED_COMPOSITING 1)
274 SET(WTF_USE_TEXTURE_MAPPER 1)
276 ADD_DEFINITIONS(-DENABLE_TIZEN_WEBKIT2_DIRECT_RENDERING=0)
277 SET(ENABLE_TIZEN_WEBKIT2_DIRECT_RENDERING 0)
279 SET(WTF_USE_ACCELERATED_COMPOSITING 1)
280 SET(WTF_USE_TEXTURE_MAPPER 1)
282 ADD_DEFINITIONS(-DENABLE_TIZEN_WEBKIT2_DIRECT_RENDERING=1)
283 SET(ENABLE_TIZEN_WEBKIT2_DIRECT_RENDERING 1)
286 SET(WTF_USE_ACCELERATED_COMPOSITING 1)
287 SET(WTF_USE_TEXTURE_MAPPER 0)
290 MESSAGE("EGL Image Extensions ON")
291 ADD_DEFINITIONS(-DWTF_USE_EGL_IMAGE_EXT=1)
292 SET(WTF_USE_EGL_IMAGE_EXT 1)
294 MESSAGE("EGL Image Extensions OFF")
295 ADD_DEFINITIONS(-DWTF_USE_EGL_IMAGE_EXT=0)
296 SET(WTF_USE_EGL_IMAGE_EXT 0)
299 IF (WTF_USE_TEXTURE_MAPPER)
306 ADD_DEFINITIONS(-DWTF_USE_ACCELERATED_COMPOSITING=${WTF_USE_ACCELERATED_COMPOSITING})
307 REMOVE_DEFINITIONS(-DWTF_USE_TEXTURE_MAPPER=1) # FIXME: Is it necessary?
308 ADD_DEFINITIONS(-DWTF_USE_TEXTURE_MAPPER=${WTF_USE_TEXTURE_MAPPER})
310 IF (ENABLE_FILE_SYSTEM)
311 SET(ENABLE_TIZEN_FILE_SYSTEM 1)
314 IF (ENABLE_INDEXED_DATABASE)
315 FIND_PACKAGE(LevelDB REQUIRED)
316 FIND_PACKAGE(LevelDB-MemEnv REQUIRED)
317 SET(WTF_USE_LEVELDB 1)
318 ADD_DEFINITIONS(-DWTF_USE_LEVELDB=1)
319 SET(ENABLE_TIZEN_INDEXED_DATABASE 1)
322 IF (ENABLE_NOTIFICATIONS)
323 SET(ENABLE_TIZEN_NOTIFICATION 1)
326 IF (ENABLE_WEB_AUDIO)
327 MESSAGE("WEB AUDIO is enabled...")
328 SET(ENABLE_TIZEN_WEB_AUDIO 1)
329 LIST(APPEND FEATURE_DEFINES ENABLE_TIZEN_WEB_AUDIO)
331 SET(GSTREAMER_COMPONENTS app interfaces pbutils)
332 SET(WTF_USE_GSTREAMER 1)
333 ADD_DEFINITIONS(-DWTF_USE_GSTREAMER=1)
335 LIST(APPEND GSTREAMER_COMPONENTS audio fft)
336 SET(WTF_USE_WEBAUDIO_GSTREAMER 1)
337 ADD_DEFINITIONS(-DWTF_USE_WEBAUDIO_GSTREAMER=1)
339 FIND_PACKAGE(GStreamer REQUIRED COMPONENTS ${GSTREAMER_COMPONENTS})
342 share/${WebKit_LIBRARY_NAME}-${PROJECT_VERSION_MAJOR}/webaudio)
343 ADD_DEFINITIONS(-DWEB_AUDIO_DIR="/usr/${WEB_AUDIO_DIR}")
345 IF (NOT ENABLE_WEBKIT2)
346 # FIXME: It should be moved to proper position.
347 FILE(GLOB WEB_AUDIO_DATA "${WEBCORE_DIR}/platform/audio/resources/*.wav")
348 INSTALL(FILES ${WEB_AUDIO_DATA} DESTINATION ${WEB_AUDIO_DIR})
353 IF (ENABLE_TIZEN_DBSPACE_PATH)
354 FIND_PACKAGE(CAPI REQUIRED)
357 IF (ENABLE_MEDIA_STREAM)
358 SET(ENABLE_TIZEN_MEDIA_STREAM 1)
359 LIST(APPEND FEATURE_DEFINES ENABLE_TIZEN_MEDIA_STREAM)
362 IF (ENABLE_TIZEN_MM_PLAYER)
363 FIND_PACKAGE(ELEMENTARY REQUIRED)
364 FIND_PACKAGE(EFREET REQUIRED)
365 FIND_PACKAGE(ETHUMB REQUIRED)
366 FIND_PACKAGE(EDBUS REQUIRED)
367 FIND_PACKAGE(DBUS-1 REQUIRED)
368 FIND_PACKAGE(MM-Player REQUIRED)
371 SET(GSTREAMER_COMPONENTS app interfaces pbutils video)
372 FIND_PACKAGE(GStreamer REQUIRED COMPONENTS ${GSTREAMER_COMPONENTS})
374 SET(WTF_USE_GSTREAMER 1)
375 ADD_DEFINITIONS(-DWTF_USE_GSTREAMER=1)
379 IF (ENABLE_TIZEN_WEBKIT2_SPELLCHECKING)
380 FIND_PACKAGE(Enchant REQUIRED)
381 ADD_DEFINITIONS(-DENABLE_TIZEN_WEBKIT2_SPELLCHECKING=1)
384 MESSAGE("Finish to check Tizen dependencies")