Merge branch 'tizen_4.0' into tizen_5.0
[platform/core/api/webapi-plugins.git] / packaging / webapi-plugins.spec
1 %bcond_with wayland
2
3 %define _manifestdir %{TZ_SYS_RW_PACKAGES}
4 %define _desktop_icondir %{TZ_SYS_SHARE}/icons/default/small
5
6 %define crosswalk_extensions tizen-extensions-crosswalk
7
8 %define crosswalk_extensions_path %{_libdir}/%{crosswalk_extensions}
9
10 Name:       webapi-plugins
11 Version:    2.44
12 Release:    0
13 License:    Apache-2.0 and BSD-3-Clause and MIT
14 Group:      Development/Libraries
15 Summary:    Tizen Web APIs implemented
16 Source0:    %{name}-%{version}.tar.gz
17
18 ####################################################################
19 #       Common Profile : artik                                     #
20 ####################################################################
21
22 %define tizen_common_privilege_engine                        CYNARA
23
24 %define tizen_common_feature_account_support                 0
25 %define tizen_common_feature_alarm_support                   1
26 %define tizen_common_feature_app_control_settings_support    1
27 %define tizen_common_feature_application_support             1
28 %define tizen_common_feature_archive_support                 0
29 %define tizen_common_feature_badge_support                   0
30 %define tizen_common_feature_bluetooth_support               1
31 %define tizen_common_feature_bookmark_support                0
32 %define tizen_common_feature_calendar_support                0
33 %define tizen_common_feature_callhistory_support             0
34 %define tizen_common_feature_contact_support                 0
35 %define tizen_common_feature_content_support                 1
36 %define tizen_common_feature_datacontrol_support             0
37 %define tizen_common_feature_datasync_support                0
38 %define tizen_common_feature_download_support                1
39 %define tizen_common_feature_exif_support                    1
40 %define tizen_common_feature_feedback_support                0
41 %define tizen_common_feature_filesystem_support              1
42 %define tizen_common_feature_fm_radio_support                0
43 %define tizen_common_feature_ham_support                     0
44 %define tizen_common_feature_inputdevice_support             0
45 %define tizen_common_feature_iotcon_support                  0
46 %define tizen_common_feature_key_manager_support             0
47 %define tizen_common_feature_location_batch                  0
48 %define tizen_common_feature_media_controller_support        0
49 %define tizen_common_feature_media_key_support               0
50 %define tizen_common_feature_message_port_support            1
51 %define tizen_common_feature_messaging_support               0
52 %define tizen_common_feature_nbs_support                     0
53 %define tizen_common_feature_nfc_support                     0
54 %define tizen_common_feature_nfc_emulation_support           0
55 %define tizen_common_feature_notification_support            0
56 %define tizen_common_feature_package_support                 1
57 %define tizen_common_feature_player_util_support             0
58 %define tizen_common_feature_power_support                   0
59 %define tizen_common_feature_ppm_support                     0
60 %define tizen_common_feature_preference_support              0
61 %define tizen_common_feature_push_support                    0
62 %define tizen_common_feature_se_support                      0
63 %define tizen_common_feature_sensor_support                  0
64 %define tizen_common_feature_sound_support                   1
65 %define tizen_common_feature_system_info_support             1
66 %define tizen_common_feature_system_setting_support          0
67 %define tizen_common_feature_telephony_support               0
68 %define tizen_common_feature_time_support                    1
69 %define tizen_common_feature_tvinputdevice_support           0
70 %define tizen_common_feature_voicecontrol_support            0
71 %define tizen_common_feature_web_setting_support             0
72 %define tizen_common_feature_wi_fi_support                   1
73 %define tizen_common_feature_widget_service_support          0
74
75 ####################################################################
76 #       Mobile Profile :  TM1(32bit), Redwood(SM-Z910F), KIRAN(Z130H)          #
77 #                         TM2(64bit)
78 ####################################################################
79
80 %define tizen_mobile_privilege_engine                        CYNARA
81
82 %define tizen_mobile_feature_account_support                 1
83 %define tizen_mobile_feature_alarm_support                   1
84 %define tizen_mobile_feature_app_control_settings_support    1
85 %define tizen_mobile_feature_application_support             1
86 %define tizen_mobile_feature_archive_support                 1
87 %define tizen_mobile_feature_badge_support                   1
88 %define tizen_mobile_feature_bluetooth_support               1
89 %define tizen_mobile_feature_bookmark_support                1
90 %define tizen_mobile_feature_calendar_support                1
91 %define tizen_mobile_feature_contact_support                 1
92 %define tizen_mobile_feature_content_support                 1
93 %define tizen_mobile_feature_datacontrol_support             1
94 %define tizen_mobile_feature_datasync_support                0
95 %define tizen_mobile_feature_download_support                1
96 %define tizen_mobile_feature_exif_support                    1
97 %define tizen_mobile_feature_feedback_support                1
98 %define tizen_mobile_feature_filesystem_support              1
99
100 %ifarch aarch64
101 %define tizen_mobile_feature_fm_radio_support                0
102 %else
103 %define tizen_mobile_feature_fm_radio_support                1
104 %endif
105
106 %define tizen_mobile_feature_ham_support                     0
107 %define tizen_mobile_feature_inputdevice_support             1
108 %define tizen_mobile_feature_iotcon_support                  1
109 %define tizen_mobile_feature_key_manager_support             1
110 %define tizen_mobile_feature_location_batch                  0
111 %define tizen_mobile_feature_media_controller_support        1
112 %define tizen_mobile_feature_media_key_support               1
113 %define tizen_mobile_feature_message_port_support            1
114 %define tizen_mobile_feature_messaging_support               1
115 %define tizen_mobile_feature_nfc_support                     0
116 %define tizen_mobile_feature_nfc_emulation_support           0
117 %define tizen_mobile_feature_notification_support            1
118 %define tizen_mobile_feature_package_support                 1
119 %define tizen_mobile_feature_player_util_support             1
120 %define tizen_mobile_feature_power_support                   1
121 %define tizen_mobile_feature_ppm_support                     1
122 %define tizen_mobile_feature_preference_support              1
123 %define tizen_mobile_feature_push_support                    1
124
125 # secure element feature
126 %ifarch aarch64
127 %define tizen_mobile_feature_se_support                      0
128 %else
129 %define tizen_mobile_feature_se_support                      1
130 %endif
131
132 %define tizen_mobile_feature_sensor_support                  1
133 %define tizen_mobile_feature_sound_support                   1
134 %define tizen_mobile_feature_system_info_support             1
135 %define tizen_mobile_feature_system_setting_support          1
136
137 # telephony feature
138 %ifarch aarch64
139 %define tizen_mobile_feature_telephony_support               0
140 %define tizen_mobile_feature_callhistory_support             0
141 %define tizen_mobile_feature_nbs_support                     0
142 %else
143 %define tizen_mobile_feature_telephony_support               1
144 %define tizen_mobile_feature_callhistory_support             1
145 %define tizen_mobile_feature_nbs_support                     1
146 %endif
147
148 %define tizen_mobile_feature_time_support                    1
149 %define tizen_mobile_feature_tvinputdevice_support           0
150 %define tizen_mobile_feature_voicecontrol_support            1
151 %define tizen_mobile_feature_web_setting_support             1
152 %define tizen_mobile_feature_wi_fi_support                   1
153 %define tizen_mobile_feature_widget_service_support          1
154
155 ## Mobile emulator
156
157 %define tizen_mobile_emulator_feature_bluetooth_support      0
158
159 # FM radio feature
160 %define tizen_mobile_emulator_feature_fm_radio_support       1
161
162 %define tizen_mobile_emulator_feature_ham_support            1
163 %define tizen_mobile_emulator_feature_media_key_support      0
164 %define tizen_mobile_emulator_feature_nfc_support            1
165 %define tizen_mobile_emulator_feature_nfc_emulation_support  0
166
167 # secure element feature
168 %define tizen_mobile_emulator_feature_se_support             0
169
170 # telephony feature
171 %define tizen_mobile_emulator_feature_telephony_support      1
172 %define tizen_mobile_emulator_feature_callhistory_support    1
173 %define tizen_mobile_emulator_feature_nbs_support            1
174
175 %define tizen_mobile_emulator_feature_wi_fi_support          0
176
177 ####################################################################
178 #       Wearable Profile :  B2 / TW2                      #
179 ####################################################################
180
181 %define tizen_wearable_privilege_engine                        CYNARA
182
183 # Account API is optional in Tizen Wearable Profile.
184 %define tizen_wearable_feature_account_support                 1
185
186 %define tizen_wearable_feature_alarm_support                   1
187 %define tizen_wearable_feature_app_control_settings_support    1
188 %define tizen_wearable_feature_application_support             1
189
190 # Archive API is optional in Tizen Wearable Profile.
191 %define tizen_wearable_feature_archive_support                 1
192
193 # Badge API is mandatory in Tizen Wearable Profile.
194 %define tizen_wearable_feature_badge_support                   1
195
196 %define tizen_wearable_feature_bluetooth_support               1
197
198 # Bookmark API is optional in Tizen Wearable Profile.
199 %define tizen_wearable_feature_bookmark_support                0
200
201 # Calendar API is mandatory in Tizen Wearable Profile.
202 %define tizen_wearable_feature_calendar_support                1
203 %define tizen_wearable_feature_contact_support                 1
204 %define tizen_wearable_feature_content_support                 1
205 %define tizen_wearable_feature_datacontrol_support             1
206 %define tizen_wearable_feature_datasync_support                0
207 %define tizen_wearable_feature_download_support                1
208 %define tizen_wearable_feature_exif_support                    1
209 %define tizen_wearable_feature_feedback_support                1
210 %define tizen_wearable_feature_filesystem_support              1
211 %define tizen_wearable_feature_fm_radio_support                0
212 %define tizen_wearable_feature_ham_support                     1
213 %define tizen_wearable_feature_inputdevice_support             1
214 %define tizen_wearable_feature_iotcon_support                  1
215 %define tizen_wearable_feature_key_manager_support             1
216 %define tizen_wearable_feature_location_batch                  0
217 %define tizen_wearable_feature_media_controller_support        1
218
219 # MediayKey API is optional in Tizen Wearable Profile.
220 # tizen.org/feature/network.bluetooth.audio.media is required for MediayKey API
221 %define tizen_wearable_feature_media_key_support               1
222 %define tizen_wearable_feature_message_port_support            1
223 %define tizen_wearable_feature_messaging_support               0
224 %define tizen_wearable_feature_nfc_support                     1
225 %define tizen_wearable_feature_nfc_emulation_support           0
226 %define tizen_wearable_feature_notification_support            1
227 %define tizen_wearable_feature_package_support                 1
228 %define tizen_wearable_feature_player_util_support             1
229 %define tizen_wearable_feature_power_support                   1
230 %define tizen_wearable_feature_ppm_support                     1
231 %define tizen_wearable_feature_preference_support              1
232 %define tizen_wearable_feature_push_support                    1
233 %define tizen_wearable_feature_se_support                      1
234 %define tizen_wearable_feature_sensor_support                  1
235 %define tizen_wearable_feature_sound_support                   1
236 %define tizen_wearable_feature_system_info_support             1
237 %define tizen_wearable_feature_system_setting_support          1
238
239 #- telephony related APIs
240 # CallHistory API is optional in Tizen Wearable Profile.
241 # NetworkBearerSelection API is optional in Tizen Wearable Profile.
242 %define tizen_wearable_feature_telephony_support               0
243 %define tizen_wearable_feature_callhistory_support             0
244 %define tizen_wearable_feature_nbs_support                     0
245
246 %define tizen_wearable_feature_time_support                    1
247 %define tizen_wearable_feature_tvinputdevice_support           0
248 %define tizen_wearable_feature_voicecontrol_support            1
249 %define tizen_wearable_feature_web_setting_support             0
250 %define tizen_wearable_feature_wi_fi_support                   1
251 %define tizen_wearable_feature_widget_service_support          1
252
253 ## Wearable emulator
254
255 %define tizen_wearable_emulator_feature_bluetooth_support      0
256
257 # MediayKey API is optional in Tizen Wearable Profile.
258 # tizen.org/feature/network.bluetooth.audio.media is required for MediayKey API
259 %define tizen_wearable_emulator_feature_media_key_support      0
260
261 #- telephony related APIs
262 # CallHistory API is optional in Tizen Wearable Profile.
263 # NetworkBearerSelection API is optional in Tizen Wearable Profile.
264 %define tizen_wearable_emulator_feature_telephony_support      1
265 %define tizen_wearable_emulator_feature_callhistory_support    1
266 %define tizen_wearable_emulator_feature_nbs_support            1
267
268 %define tizen_wearable_emulator_feature_se_support             0
269 %define tizen_wearable_emulator_feature_sensor_support         1
270
271 ####################################################################
272 #       TV Profile                                                 #
273 ####################################################################
274
275 %define tizen_tv_privilege_engine                        CYNARA
276
277 %define tizen_tv_feature_account_support                 1
278 %define tizen_tv_feature_alarm_support                   1
279 %define tizen_tv_feature_app_control_settings_support    0
280 %define tizen_tv_feature_application_support             1
281 %define tizen_tv_feature_archive_support                 1
282 %define tizen_tv_feature_badge_support                   0
283 %define tizen_tv_feature_bluetooth_support               0
284 %define tizen_tv_feature_bookmark_support                0
285 %define tizen_tv_feature_calendar_support                0
286 %define tizen_tv_feature_callhistory_support             0
287 %define tizen_tv_feature_contact_support                 0
288 %define tizen_tv_feature_content_support                 1
289 %define tizen_tv_feature_datacontrol_support             1
290 %define tizen_tv_feature_datasync_support                0
291 %define tizen_tv_feature_download_support                1
292 %define tizen_tv_feature_exif_support                    1
293 %define tizen_tv_feature_feedback_support                0
294 %define tizen_tv_feature_filesystem_support              1
295 %define tizen_tv_feature_fm_radio_support                0
296 %define tizen_tv_feature_ham_support                     0
297 %define tizen_tv_feature_inputdevice_support             0
298 %define tizen_tv_feature_iotcon_support                  1
299 %define tizen_tv_feature_key_manager_support             1
300 %define tizen_tv_feature_media_controller_support        1
301 %define tizen_tv_feature_media_key_support               0
302 %define tizen_tv_feature_message_port_support            1
303 %define tizen_tv_feature_messaging_support               0
304 %define tizen_tv_feature_nbs_support                     0
305 %define tizen_tv_feature_nfc_support                     0
306 %define tizen_tv_feature_nfc_emulation_support           0
307 %define tizen_tv_feature_notification_support            0
308 %define tizen_tv_feature_package_support                 1
309 %define tizen_tv_feature_player_util_support             0
310 %define tizen_tv_feature_power_support                   0
311 %define tizen_tv_feature_ppm_support                     0
312 %define tizen_tv_feature_preference_support              0
313 %define tizen_tv_feature_push_support                    1
314 %define tizen_tv_feature_se_support                      0
315 %define tizen_tv_feature_sensor_support                  0
316 %define tizen_tv_feature_sound_support                   0
317 %define tizen_tv_feature_system_info_support             1
318 %define tizen_tv_feature_system_setting_support          0
319 %define tizen_tv_feature_telephony_support               0
320 %define tizen_tv_feature_time_support                    1
321 %define tizen_tv_feature_tvinputdevice_support           1
322 %define tizen_tv_feature_voicecontrol_support            1
323 %define tizen_tv_feature_web_setting_support             1
324 %define tizen_tv_feature_wi_fi_support                   1
325 %define tizen_tv_feature_widget_service_support          0
326
327 # common, or "unified (undefined)"
328 %define unified_build   1
329 # GBM Product Build Optimization. Not for 4.0 Public Unified Build.
330 %if "%{?profile}" == "tv" || "%{?profile}" == "mobile" || "%{?profile}" == "wearable" || "%{?profile}" == "ivi"
331 %define unified_build   0
332 %endif
333
334 # GBM Product Build Optimization. Not for 4.0 Public Unified Build.
335 %if "%{?profile}" == "tv" || "%{?profile}" == "mobile" || "%{?profile}" == "wearable" || "%{?profile}" == "common"
336 %define tizen_privilege_engine                        %{expand:%tizen_%{?profile}_privilege_engine}
337
338 %define tizen_feature_account_support                 %{expand:%tizen_%{?profile}_feature_account_support}
339 %define tizen_feature_alarm_support                   %{expand:%tizen_%{?profile}_feature_alarm_support}
340 %define tizen_feature_app_control_settings_support    %{expand:%tizen_%{?profile}_feature_app_control_settings_support}
341 %define tizen_feature_application_support             %{expand:%tizen_%{?profile}_feature_application_support}
342 %define tizen_feature_archive_support                 %{expand:%tizen_%{?profile}_feature_archive_support}
343 %define tizen_feature_badge_support                   %{expand:%tizen_%{?profile}_feature_badge_support}
344 %define tizen_feature_bluetooth_support               %{expand:%tizen_%{?profile}_feature_bluetooth_support}
345 %define tizen_feature_bookmark_support                %{expand:%tizen_%{?profile}_feature_bookmark_support}
346 %define tizen_feature_calendar_support                %{expand:%tizen_%{?profile}_feature_calendar_support}
347 %define tizen_feature_contact_support                 %{expand:%tizen_%{?profile}_feature_contact_support}
348 %define tizen_feature_content_support                 %{expand:%tizen_%{?profile}_feature_content_support}
349 %define tizen_feature_datacontrol_support             %{expand:%tizen_%{?profile}_feature_datacontrol_support}
350 %define tizen_feature_datasync_support                %{expand:%tizen_%{?profile}_feature_datasync_support}
351 %define tizen_feature_download_support                %{expand:%tizen_%{?profile}_feature_download_support}
352 %define tizen_feature_exif_support                    %{expand:%tizen_%{?profile}_feature_exif_support}
353 %define tizen_feature_feedback_support                %{expand:%tizen_%{?profile}_feature_feedback_support}
354 %define tizen_feature_filesystem_support              %{expand:%tizen_%{?profile}_feature_filesystem_support}
355 %define tizen_feature_fm_radio_support                %{expand:%tizen_%{?profile}_feature_fm_radio_support}
356 %define tizen_feature_ham_support                     %{expand:%tizen_%{?profile}_feature_ham_support}
357 %define tizen_feature_iotcon_support                  %{expand:%tizen_%{?profile}_feature_iotcon_support}
358 %define tizen_feature_location_batch                  %{expand:%tizen_%{?profile}_feature_location_batch}
359 %define tizen_feature_key_manager_support             %{expand:%tizen_%{?profile}_feature_key_manager_support}
360 %define tizen_feature_media_controller_support        %{expand:%tizen_%{?profile}_feature_media_controller_support}
361 %define tizen_feature_media_key_support               %{expand:%tizen_%{?profile}_feature_media_key_support}
362 %define tizen_feature_message_port_support            %{expand:%tizen_%{?profile}_feature_message_port_support}
363 %define tizen_feature_messaging_support               %{expand:%tizen_%{?profile}_feature_messaging_support}
364 %define tizen_feature_nfc_emulation_support           %{expand:%tizen_%{?profile}_feature_nfc_emulation_support}
365 %define tizen_feature_nfc_support                     %{expand:%tizen_%{?profile}_feature_nfc_support}
366 %define tizen_feature_notification_support            %{expand:%tizen_%{?profile}_feature_notification_support}
367 %define tizen_feature_package_support                 %{expand:%tizen_%{?profile}_feature_package_support}
368 %define tizen_feature_player_util_support             %{expand:%tizen_%{?profile}_feature_player_util_support}
369 %define tizen_feature_power_support                   %{expand:%tizen_%{?profile}_feature_power_support}
370 %define tizen_feature_preference_support              %{expand:%tizen_%{?profile}_feature_preference_support}
371 %define tizen_feature_push_support                    %{expand:%tizen_%{?profile}_feature_push_support}
372 %define tizen_feature_se_support                      %{expand:%tizen_%{?profile}_feature_se_support}
373 %define tizen_feature_sensor_support                  %{expand:%tizen_%{?profile}_feature_sensor_support}
374 %define tizen_feature_sound_support                   %{expand:%tizen_%{?profile}_feature_sound_support}
375 %define tizen_feature_system_info_support             %{expand:%tizen_%{?profile}_feature_system_info_support}
376 %define tizen_feature_system_setting_support          %{expand:%tizen_%{?profile}_feature_system_setting_support}
377 %define tizen_feature_telephony_support               %{expand:%tizen_%{?profile}_feature_telephony_support}
378 %define tizen_feature_time_support                    %{expand:%tizen_%{?profile}_feature_time_support}
379 %define tizen_feature_web_setting_support             %{expand:%tizen_%{?profile}_feature_web_setting_support}
380 %define tizen_feature_widget_service_support          %{expand:%tizen_%{?profile}_feature_widget_service_support}
381 %define tizen_feature_wi_fi_support                   %{expand:%tizen_%{?profile}_feature_wi_fi_support}
382 %define tizen_feature_inputdevice_support             %{expand:%tizen_%{?profile}_feature_inputdevice_support}
383 %define tizen_feature_callhistory_support             %{expand:%tizen_%{?profile}_feature_callhistory_support}
384 %define tizen_feature_nbs_support                     %{expand:%tizen_%{?profile}_feature_nbs_support}
385 %define tizen_feature_tvinputdevice_support           %{expand:%tizen_%{?profile}_feature_tvinputdevice_support}
386 %define tizen_feature_voicecontrol_support            %{expand:%tizen_%{?profile}_feature_voicecontrol_support}
387 %define tizen_feature_ppm_support                     %{expand:%tizen_%{?profile}_feature_ppm_support}
388 %endif
389
390 BuildRequires: pkgconfig(security-privilege-manager)
391 BuildRequires: ninja
392 BuildRequires: pkgconfig(appcore-common)
393 BuildRequires: pkgconfig(dlog)
394 BuildRequires: pkgconfig(evas)
395 BuildRequires: pkgconfig(gio-unix-2.0)
396 BuildRequires: pkgconfig(gio-2.0)
397 BuildRequires: pkgconfig(glib-2.0)
398 BuildRequires: pkgconfig(libudev)
399 BuildRequires: pkgconfig(minizip)
400 BuildRequires: pkgconfig(zlib)
401 BuildRequires: pkgconfig(pkgmgr)
402 BuildRequires: pkgconfig(pkgmgr-info)
403 BuildRequires: pkgconfig(pkgmgr-installer)
404 BuildRequires: pkgconfig(vconf)
405 BuildRequires: pkgconfig(ecore)
406 BuildRequires: pkgconfig(icu-i18n)
407 BuildRequires: pkgconfig(aul)
408 BuildRequires: pkgconfig(storage)
409 BuildRequires: python
410 BuildRequires: pkgconfig(capi-base-common)
411 BuildRequires: pkgconfig(capi-system-info)
412 BuildRequires: pkgconfig(capi-system-runtime-info)
413 BuildRequires: pkgconfig(capi-network-connection)
414 BuildRequires: pkgconfig(capi-system-device)
415 BuildRequires: pkgconfig(capi-system-system-settings)
416 BuildRequires: pkgconfig(capi-network-bluetooth)
417 BuildRequires: pkgconfig(capi-network-wifi-manager)
418 BuildRequires: pkgconfig(tapi)
419 BuildRequires: pkgconfig(libpcrecpp)
420 BuildRequires: pkgconfig(capi-appfw-app-common)
421 BuildRequires: pkgconfig(capi-appfw-app-manager)
422 BuildRequires: pkgconfig(capi-appfw-package-manager)
423 BuildRequires: pkgconfig(capi-content-media-content)
424 BuildRequires: pkgconfig(capi-media-metadata-extractor)
425 BuildRequires: pkgconfig(libtzplatform-config)
426 BuildRequires: pkgconfig(appsvc)
427
428 %if %{with wayland}
429 %define display_type wayland
430 BuildRequires: pkgconfig(wayland-client)
431 %else
432 %define display_type x11
433 #BuildRequires: pkgconfig(x11)
434 #BuildRequires: pkgconfig(xrandr)
435 %endif
436
437 %if "%{?tizen_privilege_engine}" == "ACE"
438 BuildRequires: pkgconfig(security-privilege-checker)
439 %endif
440
441 %if "%{?tizen_privilege_engine}" == "CYNARA" || "%{?unified_build}" == "1"
442 BuildRequires: pkgconfig(cynara-client)
443 BuildRequires: pkgconfig(libsmack)
444 %endif
445
446 %if "%{?tizen_feature_account_support}" == "1" || "%{?unified_build}" == "1"
447 BuildRequires: pkgconfig(accounts-svc)
448 %endif
449
450 %if "%{?tizen_feature_alarm_support}" == "1" || "%{?unified_build}" == "1"
451 BuildRequires: pkgconfig(capi-appfw-app-control)
452 BuildRequires: pkgconfig(capi-appfw-application)
453 BuildRequires: pkgconfig(capi-appfw-alarm)
454 BuildRequires: pkgconfig(alarm-service)
455 %endif
456
457 %if "%{?tizen_feature_application_support}" == "1" || "%{?unified_build}" == "1"
458 BuildRequires: pkgconfig(capi-appfw-app-control)
459 BuildRequires: pkgconfig(capi-appfw-event)
460
461 %if "%{?unified_build}" == "1" || "%{?profile}" == "mobile" || "%{?profile}" == "wearable"
462 BuildRequires: pkgconfig(capi-context)
463 %endif
464
465 %endif
466
467 %if "%{?tizen_feature_bluetooth_support}" == "1" || "%{?unified_build}" == "1"
468 BuildRequires: pkgconfig(capi-appfw-app-control)
469 %endif
470
471 %if "%{?tizen_feature_bookmark_support}" == "1" || "%{?unified_build}" == "1"
472 BuildRequires: pkgconfig(capi-web-bookmark)
473 BuildRequires: pkgconfig(bookmark-adaptor)
474 %endif
475
476 %if "%{?tizen_feature_datacontrol_support}" == "1" || "%{?unified_build}" == "1"
477 BuildRequires: pkgconfig(capi-data-control)
478 %endif
479
480 %if "%{?tizen_feature_download_support}" == "1" || "%{?unified_build}" == "1"
481 BuildRequires: pkgconfig(capi-web-url-download)
482 %endif
483
484 %if "%{?tizen_feature_ham_support}" == "1" || "%{?unified_build}" == "1" || "%{?tizen_mobile_emulator_feature_ham_support}" == "1"
485 BuildRequires: pkgconfig(motion)
486 BuildRequires: pkgconfig(capi-system-sensor)
487 BuildRequires: pkgconfig(capi-location-manager)
488 BuildRequires: pkgconfig(sensor)
489 %endif
490
491 %if "%{?tizen_feature_iotcon_support}" == "1" || "%{?unified_build}" == "1"
492 BuildRequires: pkgconfig(iotcon)
493 %endif
494
495 %if "%{?tizen_feature_player_util_support}" == "1" || "%{?unified_build}" == "1"
496 BuildRequires: pkgconfig(chromium-efl)
497 %endif
498
499 %if "%{?tizen_feature_power_support}" == "1" || "%{?unified_build}" == "1"
500 BuildRequires: pkgconfig(capi-appfw-application)
501 %endif
502
503 %if "%{?tizen_feature_push_support}" == "1" || "%{?unified_build}" == "1"
504 BuildRequires: pkgconfig(push)
505 BuildRequires: pkgconfig(capi-appfw-app-control)
506 %endif
507
508 %if "%{?tizen_feature_key_manager_support}" == "1" || "%{?unified_build}" == "1"
509 BuildRequires: pkgconfig(key-manager)
510 %endif
511
512 %if "%{?tizen_feature_media_controller_support}" == "1" || "%{?unified_build}" == "1"
513 BuildRequires: pkgconfig(capi-media-controller)
514 %endif
515
516 %if "%{?tizen_feature_messaging_support}" == "1" || "%{?unified_build}" == "1"
517 BuildRequires:  pkgconfig(ecore-file)
518 BuildRequires:  pkgconfig(email-service)
519 BuildRequires:  pkgconfig(msg-service)
520 BuildRequires:  pkgconfig(db-util)
521 %endif
522
523 %if "%{?tizen_feature_badge_support}" == "1" || "%{?unified_build}" == "1"
524 BuildRequires:  pkgconfig(badge)
525 %endif
526
527 %if "%{?tizen_feature_calendar_support}" == "1" || "%{?unified_build}" == "1"
528 BuildRequires:  pkgconfig(calendar-service2)
529 %endif
530
531 %if "%{?tizen_feature_contact_support}" == "1" || "%{?unified_build}" == "1"
532 BuildRequires:  pkgconfig(contacts-service2)
533 %endif
534
535 %if "%{?tizen_feature_callhistory_support}" == "1" || "%{?unified_build}" == "1" || "%{?tizen_mobile_emulator_feature_callhistory_support}" == "1" || "%{?tizen_wearable_emulator_feature_callhistory_support}" == "1"
536 BuildRequires:  pkgconfig(contacts-service2)
537 %endif
538
539 %if "%{?tizen_feature_exif_support}" == "1" || "%{?unified_build}" == "1"
540 BuildRequires:  pkgconfig(libexif)
541 %endif
542
543 %if "%{?tizen_feature_nfc_support}" == "1" || "%{?unified_build}" == "1" || "%{?tizen_mobile_emulator_feature_nfc_support}" == "1"
544 BuildRequires:  pkgconfig(capi-network-nfc)
545 BuildRequires:  pkgconfig(capi-appfw-app-control)
546 %endif
547
548 %if "%{?tizen_feature_fm_radio_support}" == "1" || "%{?unified_build}" == "1" || "%{?tizen_mobile_emulator_feature_fm_radio_support}" == "1"
549 BuildRequires: pkgconfig(capi-media-radio)
550 %endif
551
552 %if "%{?tizen_feature_feedback_support}" == "1" || "%{?unified_build}" == "1"
553 BuildRequires: pkgconfig(feedback)
554 %endif
555
556 %if "%{?tizen_feature_se_support}" == "1" || "%{?unified_build}" == "1"
557 BuildRequires:  pkgconfig(capi-network-smartcard)
558 %endif
559
560 %if "%{?tizen_feature_message_port_support}" == "1" || "%{?unified_build}" == "1"
561 BuildRequires: pkgconfig(capi-message-port)
562 %endif
563
564 %if "%{?tizen_feature_notification_support}" == "1" || "%{?unified_build}" == "1"
565 BuildRequires: pkgconfig(notification)
566 BuildRequires: pkgconfig(capi-appfw-app-control)
567 %endif
568
569 %if "%{?tizen_feature_preference_support}" == "1" || "%{?unified_build}" == "1"
570 BuildRequires: pkgconfig(capi-appfw-preference)
571 %endif
572
573 %if "%{?tizen_feature_sound_support}" == "1" || "%{?unified_build}" == "1"
574 BuildRequires:  pkgconfig(capi-media-sound-manager)
575 %endif
576
577 %if "%{?tizen_feature_sensor_support}" == "1" || "%{?unified_build}" == "1" || "%{?tizen_wearable_emulator_feature_sensor_support}" == "1"
578 BuildRequires: pkgconfig(capi-system-sensor)
579 %endif
580
581 %if "%{?tizen_feature_media_key_support}" == "1" || "%{?unified_build}" == "1"
582 BuildRequires:  pkgconfig(capi-system-media-key)
583 %endif
584
585 %if "%{?tizen_feature_widget_service_support}" == "1" || "%{?unified_build}" == "1"
586 BuildRequires: pkgconfig(widget_service)
587 %endif
588
589 %if "%{?tizen_feature_voicecontrol_support}" == "1" || "%{?unified_build}" == "1"
590 BuildRequires: pkgconfig(voice-control)
591 %endif
592
593 %if "%{?tizen_feature_ppm_support}" == "1" || "%{?unified_build}" == "1"
594 BuildRequires: pkgconfig(capi-privacy-privilege-manager)
595 %endif
596
597 Requires:      %{name}-compat = %{version}-%{release}
598 %if "%{?unified_build}" == "1"
599 Recommends:    %{name}-profile_common = %{version}-%{release}
600 %endif
601
602 %description
603 Tizen Web APIs implemented.
604
605 %package profile_common
606 Summary:       webapi-plugin binaries for common profile
607 Provides:      %{name}-compat = %{version}-%{release}
608 Conflicts:     %{name}-profile_mobile
609 Conflicts:     %{name}-profile_wearable
610 Conflicts:     %{name}-profile_tv
611 Conflicts:     %{name}-profile_ivi
612 %description profile_common
613 Tizen Web API implementation binaries for Tizen common profile.
614
615 %package profile_mobile
616 Summary:       webapi-plugin binaries for mobile profile
617 Provides:      %{name}-compat = %{version}-%{release}
618 Conflicts:     %{name}-profile_common
619 Conflicts:     %{name}-profile_wearable
620 Conflicts:     %{name}-profile_tv
621 Conflicts:     %{name}-profile_ivi
622 %description profile_mobile
623 Tizen Web API implementation binaries for Tizen mobile profile.
624
625 %ifarch %{ix86} x86_64
626 %package mobile-extension-emulator
627 Summary:       webapi-plugin binaries for mobile emulator
628 Requires:      %{name}-profile_mobile = %{version}-%{release}
629 %description mobile-extension-emulator
630 Tizen Web API implementation binaries for Tizen mobile emulator.
631 %endif
632
633 %package profile_wearable
634 Summary:       webapi-plugin binaries for wearable profile
635 Provides:      %{name}-compat = %{version}-%{release}
636 Conflicts:     %{name}-profile_mobile
637 Conflicts:     %{name}-profile_common
638 Conflicts:     %{name}-profile_tv
639 Conflicts:     %{name}-profile_ivi
640 %description profile_wearable
641 Tizen Web API implementation binaries for Tizen wearable profile.
642
643 %ifarch %{ix86} x86_64
644 %package wearable-extension-emulator
645 Summary:       webapi-plugin binaries for wearable emulator
646 Requires:      %{name}-profile_wearable = %{version}-%{release}
647 %description wearable-extension-emulator
648 Tizen Web API implementation binaries for Tizen wearable emulator.
649 %endif
650
651 %package profile_tv
652 Summary:       webapi-plugin binaries for tv profile
653 Provides:      %{name}-compat = %{version}-%{release}
654 Conflicts:     %{name}-profile_mobile
655 Conflicts:     %{name}-profile_wearable
656 Conflicts:     %{name}-profile_common
657 Conflicts:     %{name}-profile_ivi
658 %description profile_tv
659 Tizen Web API implementation binaries for Tizen tv profile.
660
661 %package profile_ivi
662 Summary:       webapi-plugin binaries for ivi profile
663 Provides:      %{name}-compat = %{version}-%{release}
664 Conflicts:     %{name}-profile_mobile
665 Conflicts:     %{name}-profile_wearable
666 Conflicts:     %{name}-profile_tv
667 Conflicts:     %{name}-profile_common
668 %description profile_ivi
669 Tizen Web API implementation binaries for Tizen ivi profile.
670
671 %package devel
672 Summary:    webapi-plugins development headers
673 Group:      Development/Libraries
674 Requires:   %{name} = %{version}
675
676 %description devel
677 webapi-plugins development headers
678
679 %prep
680 %setup -q
681
682 %build
683
684 export GYP_GENERATORS='ninja'
685
686 %if "%{?unified_build}" == "1" || "%{?profile}" == "mobile"
687 # MOBILE
688 GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_os=mobile -Dprivilege_engine=%{tizen_mobile_privilege_engine}"
689 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
690 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
691
692 # feature flags
693 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_mobile_feature_account_support}"
694 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_mobile_feature_alarm_support}"
695 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_app_control_settings_support=%{?tizen_mobile_feature_app_control_settings_support}"
696 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_application_support=%{?tizen_mobile_feature_application_support}"
697 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_archive_support=%{?tizen_mobile_feature_archive_support}"
698 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_badge_support=%{?tizen_mobile_feature_badge_support}"
699 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bluetooth_support=%{?tizen_mobile_feature_bluetooth_support}"
700 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bookmark_support=%{?tizen_mobile_feature_bookmark_support}"
701 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_calendar_support=%{?tizen_mobile_feature_calendar_support}"
702 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_callhistory_support=%{?tizen_mobile_feature_callhistory_support}"
703 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_contact_support=%{?tizen_mobile_feature_contact_support}"
704 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_content_support=%{?tizen_mobile_feature_content_support}"
705 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datacontrol_support=%{?tizen_mobile_feature_datacontrol_support}"
706 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datasync_support=%{?tizen_mobile_feature_datasync_support}"
707 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_download_support=%{?tizen_mobile_feature_download_support}"
708 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_exif_support=%{?tizen_mobile_feature_exif_support}"
709 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_feedback_support=%{?tizen_mobile_feature_feedback_support}"
710 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_filesystem_support=%{?tizen_mobile_feature_filesystem_support}"
711 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_fm_radio_support=%{?tizen_mobile_feature_fm_radio_support}"
712 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ham_support=%{?tizen_mobile_feature_ham_support}"
713 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_iotcon_support=%{?tizen_mobile_feature_iotcon_support}"
714 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_location_batch=%{?tizen_mobile_feature_location_batch}"
715 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_key_manager_support=%{?tizen_mobile_feature_key_manager_support}"
716 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_controller_support=%{?tizen_mobile_feature_media_controller_support}"
717 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_key_support=%{?tizen_mobile_feature_media_key_support}"
718 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_message_port_support=%{?tizen_mobile_feature_message_port_support}"
719 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_messaging_support=%{?tizen_mobile_feature_messaging_support}"
720 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nbs_support=%{?tizen_mobile_feature_nbs_support}"
721 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_emulation_support=%{?tizen_mobile_feature_nfc_emulation_support}"
722 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_support=%{?tizen_mobile_feature_nfc_support}"
723 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_notification_support=%{?tizen_mobile_feature_notification_support}"
724 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_package_support=%{?tizen_mobile_feature_package_support}"
725 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_player_util_support=%{?tizen_mobile_feature_player_util_support}"
726 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_power_support=%{?tizen_mobile_feature_power_support}"
727 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_preference_support=%{?tizen_mobile_feature_preference_support}"
728 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_push_support=%{?tizen_mobile_feature_push_support}"
729 #GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sap_support=%{?tizen_mobile_feature_sap_support}"
730 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sensor_support=%{?tizen_mobile_feature_sensor_support}"
731 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_se_support=%{?tizen_mobile_feature_se_support}"
732 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sound_support=%{?tizen_mobile_feature_sound_support}"
733 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_info_support=%{?tizen_mobile_feature_system_info_support}"
734 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_setting_support=%{?tizen_mobile_feature_system_setting_support}"
735 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_telephony_support=%{?tizen_mobile_feature_telephony_support}"
736 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_time_support=%{?tizen_mobile_feature_time_support}"
737 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_inputdevice_support=%{?tizen_mobile_feature_inputdevice_support}"
738 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_web_setting_support=%{?tizen_mobile_feature_web_setting_support}"
739 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_widget_service_support=%{?tizen_mobile_feature_widget_service_support}"
740 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_wi_fi_support=%{?tizen_mobile_feature_wi_fi_support}"
741 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_tvinputdevice_support=%{?tizen_mobile_feature_tvinputdevice_support}"
742 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_voicecontrol_support=%{?tizen_mobile_feature_voicecontrol_support}"
743 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ppm_support=%{?tizen_mobile_feature_ppm_support}"
744
745 ./tools/gyp/gyp $GYP_OPTIONS src/tizen-wrt.gyp
746
747 ninja -C out/Default %{?_smp_mflags}
748 pushd out
749 mv Default bin_mobile
750 popd
751
752 # mobile-extension-emulator
753 %ifarch %{ix86} x86_64
754
755 %define tizen_mobile_feature_bluetooth_support               %{?tizen_mobile_emulator_feature_bluetooth_support}
756
757 # FM radio feature
758 %define tizen_mobile_feature_fm_radio_support                %{?tizen_mobile_emulator_feature_fm_radio_support}
759
760 %define tizen_mobile_feature_ham_support                     %{?tizen_mobile_emulator_feature_ham_support}
761 %define tizen_mobile_feature_media_key_support               %{?tizen_mobile_emulator_feature_media_key_support}
762 %define tizen_mobile_feature_nfc_emulation_support           %{?tizen_mobile_emulator_feature_nfc_emulation_support}
763 %define tizen_mobile_feature_nfc_support                     %{?tizen_mobile_emulator_feature_nfc_support}
764
765 # secure element feature
766 %define tizen_mobile_feature_se_support                      %{?tizen_mobile_emulator_feature_se_support}
767
768 # telephony feature
769 %define tizen_mobile_feature_telephony_support               %{?tizen_mobile_emulator_feature_telephony_support}
770 %define tizen_mobile_feature_callhistory_support             %{?tizen_mobile_emulator_feature_callhistory_support}
771 %define tizen_mobile_feature_nbs_support                     %{?tizen_mobile_emulator_feature_nbs_support}
772
773 %define tizen_mobile_feature_wi_fi_support                   %{?tizen_mobile_emulator_feature_wi_fi_support}
774
775 GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_os=mobile -Dprivilege_engine=%{tizen_mobile_privilege_engine}"
776 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
777 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
778
779 # feature flags
780 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_mobile_feature_account_support}"
781 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_mobile_feature_alarm_support}"
782 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_app_control_settings_support=%{?tizen_mobile_feature_app_control_settings_support}"
783 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_application_support=%{?tizen_mobile_feature_application_support}"
784 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_archive_support=%{?tizen_mobile_feature_archive_support}"
785 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_badge_support=%{?tizen_mobile_feature_badge_support}"
786 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bluetooth_support=%{?tizen_mobile_feature_bluetooth_support}"
787 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bookmark_support=%{?tizen_mobile_feature_bookmark_support}"
788 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_calendar_support=%{?tizen_mobile_feature_calendar_support}"
789 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_callhistory_support=%{?tizen_mobile_feature_callhistory_support}"
790 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_contact_support=%{?tizen_mobile_feature_contact_support}"
791 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_content_support=%{?tizen_mobile_feature_content_support}"
792 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datacontrol_support=%{?tizen_mobile_feature_datacontrol_support}"
793 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datasync_support=%{?tizen_mobile_feature_datasync_support}"
794 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_download_support=%{?tizen_mobile_feature_download_support}"
795 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_exif_support=%{?tizen_mobile_feature_exif_support}"
796 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_feedback_support=%{?tizen_mobile_feature_feedback_support}"
797 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_filesystem_support=%{?tizen_mobile_feature_filesystem_support}"
798 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_fm_radio_support=%{?tizen_mobile_feature_fm_radio_support}"
799 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ham_support=%{?tizen_mobile_feature_ham_support}"
800 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_iotcon_support=%{?tizen_mobile_feature_iotcon_support}"
801 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_location_batch=%{?tizen_mobile_feature_location_batch}"
802 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_key_manager_support=%{?tizen_mobile_feature_key_manager_support}"
803 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_controller_support=%{?tizen_mobile_feature_media_controller_support}"
804 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_key_support=%{?tizen_mobile_feature_media_key_support}"
805 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_message_port_support=%{?tizen_mobile_feature_message_port_support}"
806 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_messaging_support=%{?tizen_mobile_feature_messaging_support}"
807 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nbs_support=%{?tizen_mobile_feature_nbs_support}"
808 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_emulation_support=%{?tizen_mobile_feature_nfc_emulation_support}"
809 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_support=%{?tizen_mobile_feature_nfc_support}"
810 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_notification_support=%{?tizen_mobile_feature_notification_support}"
811 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_package_support=%{?tizen_mobile_feature_package_support}"
812 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_player_util_support=%{?tizen_mobile_feature_player_util_support}"
813 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_power_support=%{?tizen_mobile_feature_power_support}"
814 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_preference_support=%{?tizen_mobile_feature_preference_support}"
815 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_push_support=%{?tizen_mobile_feature_push_support}"
816 #GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sap_support=%{?tizen_mobile_feature_sap_support}"
817 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sensor_support=%{?tizen_mobile_feature_sensor_support}"
818 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_se_support=%{?tizen_mobile_feature_se_support}"
819 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sound_support=%{?tizen_mobile_feature_sound_support}"
820 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_info_support=%{?tizen_mobile_feature_system_info_support}"
821 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_setting_support=%{?tizen_mobile_feature_system_setting_support}"
822 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_telephony_support=%{?tizen_mobile_feature_telephony_support}"
823 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_time_support=%{?tizen_mobile_feature_time_support}"
824 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_inputdevice_support=%{?tizen_mobile_feature_inputdevice_support}"
825 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_web_setting_support=%{?tizen_mobile_feature_web_setting_support}"
826 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_widget_service_support=%{?tizen_mobile_feature_widget_service_support}"
827 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_wi_fi_support=%{?tizen_mobile_feature_wi_fi_support}"
828 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_tvinputdevice_support=%{?tizen_mobile_feature_tvinputdevice_support}"
829 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_voicecontrol_support=%{?tizen_mobile_feature_voicecontrol_support}"
830 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ppm_support=%{?tizen_mobile_feature_ppm_support}"
831
832 ./tools/gyp/gyp $GYP_OPTIONS src/tizen-wrt.gyp
833
834 ninja -C out/Default %{?_smp_mflags}
835 pushd out
836 mv Default bin_mobile_emulator
837 popd
838 %endif # mobile-extension-emulator
839
840 pushd out
841 %if "%{?profile}" == "mobile"
842 ln -sf bin_mobile Default
843 %endif
844 popd
845
846 %endif # MOBILE
847
848 %if "%{?unified_build}" == "1" || "%{?profile}" == "wearable"
849 # WEARABLE
850 GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_os=wearable -Dprivilege_engine=%{tizen_wearable_privilege_engine}"
851 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
852 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
853
854 # feature flags
855 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_wearable_feature_account_support}"
856 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_wearable_feature_alarm_support}"
857 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_app_control_settings_support=%{?tizen_wearable_feature_app_control_settings_support}"
858 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_application_support=%{?tizen_wearable_feature_application_support}"
859 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_archive_support=%{?tizen_wearable_feature_archive_support}"
860 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_badge_support=%{?tizen_wearable_feature_badge_support}"
861 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bluetooth_support=%{?tizen_wearable_feature_bluetooth_support}"
862 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bookmark_support=%{?tizen_wearable_feature_bookmark_support}"
863 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_calendar_support=%{?tizen_wearable_feature_calendar_support}"
864 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_callhistory_support=%{?tizen_wearable_feature_callhistory_support}"
865 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_contact_support=%{?tizen_wearable_feature_contact_support}"
866 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_content_support=%{?tizen_wearable_feature_content_support}"
867 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datacontrol_support=%{?tizen_wearable_feature_datacontrol_support}"
868 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datasync_support=%{?tizen_wearable_feature_datasync_support}"
869 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_download_support=%{?tizen_wearable_feature_download_support}"
870 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_exif_support=%{?tizen_wearable_feature_exif_support}"
871 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_feedback_support=%{?tizen_wearable_feature_feedback_support}"
872 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_filesystem_support=%{?tizen_wearable_feature_filesystem_support}"
873 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_fm_radio_support=%{?tizen_wearable_feature_fm_radio_support}"
874 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ham_support=%{?tizen_wearable_feature_ham_support}"
875 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_iotcon_support=%{?tizen_wearable_feature_iotcon_support}"
876 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_location_batch=%{?tizen_wearable_feature_location_batch}"
877 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_key_manager_support=%{?tizen_wearable_feature_key_manager_support}"
878 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_controller_support=%{?tizen_wearable_feature_media_controller_support}"
879 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_key_support=%{?tizen_wearable_feature_media_key_support}"
880 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_message_port_support=%{?tizen_wearable_feature_message_port_support}"
881 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_messaging_support=%{?tizen_wearable_feature_messaging_support}"
882 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nbs_support=%{?tizen_wearable_feature_nbs_support}"
883 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_emulation_support=%{?tizen_wearable_feature_nfc_emulation_support}"
884 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_support=%{?tizen_wearable_feature_nfc_support}"
885 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_notification_support=%{?tizen_wearable_feature_notification_support}"
886 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_package_support=%{?tizen_wearable_feature_package_support}"
887 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_player_util_support=%{?tizen_wearable_feature_player_util_support}"
888 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_power_support=%{?tizen_wearable_feature_power_support}"
889 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_preference_support=%{?tizen_wearable_feature_preference_support}"
890 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_push_support=%{?tizen_wearable_feature_push_support}"
891 #GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sap_support=%{?tizen_wearable_feature_sap_support}"
892 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sensor_support=%{?tizen_wearable_feature_sensor_support}"
893 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_se_support=%{?tizen_wearable_feature_se_support}"
894 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sound_support=%{?tizen_wearable_feature_sound_support}"
895 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_info_support=%{?tizen_wearable_feature_system_info_support}"
896 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_setting_support=%{?tizen_wearable_feature_system_setting_support}"
897 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_telephony_support=%{?tizen_wearable_feature_telephony_support}"
898 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_time_support=%{?tizen_wearable_feature_time_support}"
899 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_inputdevice_support=%{?tizen_wearable_feature_inputdevice_support}"
900 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_web_setting_support=%{?tizen_wearable_feature_web_setting_support}"
901 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_widget_service_support=%{?tizen_wearable_feature_widget_service_support}"
902 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_wi_fi_support=%{?tizen_wearable_feature_wi_fi_support}"
903 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_tvinputdevice_support=%{?tizen_wearable_feature_tvinputdevice_support}"
904 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_voicecontrol_support=%{?tizen_wearable_feature_voicecontrol_support}"
905 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ppm_support=%{?tizen_wearable_feature_ppm_support}"
906
907 ./tools/gyp/gyp $GYP_OPTIONS src/tizen-wrt.gyp
908
909 ninja -C out/Default %{?_smp_mflags}
910 pushd out
911 mv Default bin_wearable
912 popd
913
914 # wearable-extension-emulator
915 %ifarch %{ix86} x86_64
916
917 %define tizen_wearable_feature_bluetooth_support             %{?tizen_wearable_emulator_feature_bluetooth_support}
918
919 # MediayKey API is optional in Tizen Wearable Profile.
920 # tizen.org/feature/network.bluetooth.audio.media is required for MediayKey API
921 %define tizen_wearable_feature_media_key_support             %{?tizen_wearable_emulator_feature_media_key_support}
922
923 #- telephony related APIs
924 # CallHistory API is optional in Tizen Wearable Profile.
925 # NetworkBearerSelection API is optional in Tizen Wearable Profile.
926 %define tizen_wearable_feature_se_support                    %{?tizen_wearable_emulator_feature_se_support}
927 %define tizen_wearable_feature_telephony_support             %{?tizen_wearable_emulator_feature_telephony_support}
928 %define tizen_wearable_feature_callhistory_support           %{?tizen_wearable_emulator_feature_callhistory_support}
929 %define tizen_wearable_feature_nbs_support                   %{?tizen_wearable_emulator_feature_nbs_support}
930 %define tizen_wearable_feature_sensor_support                %{?tizen_wearable_emulator_feature_sensor_support}
931
932 GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_os=wearable -Dprivilege_engine=%{tizen_wearable_privilege_engine}"
933 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
934 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
935
936 # feature flags
937 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_wearable_feature_account_support}"
938 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_wearable_feature_alarm_support}"
939 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_app_control_settings_support=%{?tizen_wearable_feature_app_control_settings_support}"
940 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_application_support=%{?tizen_wearable_feature_application_support}"
941 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_archive_support=%{?tizen_wearable_feature_archive_support}"
942 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_badge_support=%{?tizen_wearable_feature_badge_support}"
943 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bluetooth_support=%{?tizen_wearable_feature_bluetooth_support}"
944 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bookmark_support=%{?tizen_wearable_feature_bookmark_support}"
945 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_calendar_support=%{?tizen_wearable_feature_calendar_support}"
946 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_callhistory_support=%{?tizen_wearable_feature_callhistory_support}"
947 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_contact_support=%{?tizen_wearable_feature_contact_support}"
948 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_content_support=%{?tizen_wearable_feature_content_support}"
949 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datacontrol_support=%{?tizen_wearable_feature_datacontrol_support}"
950 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datasync_support=%{?tizen_wearable_feature_datasync_support}"
951 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_download_support=%{?tizen_wearable_feature_download_support}"
952 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_exif_support=%{?tizen_wearable_feature_exif_support}"
953 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_feedback_support=%{?tizen_wearable_feature_feedback_support}"
954 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_filesystem_support=%{?tizen_wearable_feature_filesystem_support}"
955 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_fm_radio_support=%{?tizen_wearable_feature_fm_radio_support}"
956 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ham_support=%{?tizen_wearable_feature_ham_support}"
957 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_iotcon_support=%{?tizen_wearable_feature_iotcon_support}"
958 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_location_batch=%{?tizen_wearable_feature_location_batch}"
959 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_key_manager_support=%{?tizen_wearable_feature_key_manager_support}"
960 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_controller_support=%{?tizen_wearable_feature_media_controller_support}"
961 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_key_support=%{?tizen_wearable_feature_media_key_support}"
962 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_message_port_support=%{?tizen_wearable_feature_message_port_support}"
963 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_messaging_support=%{?tizen_wearable_feature_messaging_support}"
964 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nbs_support=%{?tizen_wearable_feature_nbs_support}"
965 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_emulation_support=%{?tizen_wearable_feature_nfc_emulation_support}"
966 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_support=%{?tizen_wearable_feature_nfc_support}"
967 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_notification_support=%{?tizen_wearable_feature_notification_support}"
968 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_package_support=%{?tizen_wearable_feature_package_support}"
969 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_player_util_support=%{?tizen_wearable_feature_player_util_support}"
970 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_power_support=%{?tizen_wearable_feature_power_support}"
971 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_preference_support=%{?tizen_wearable_feature_preference_support}"
972 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_push_support=%{?tizen_wearable_feature_push_support}"
973 #GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sap_support=%{?tizen_wearable_feature_sap_support}"
974 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sensor_support=%{?tizen_wearable_feature_sensor_support}"
975 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_se_support=%{?tizen_wearable_feature_se_support}"
976 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sound_support=%{?tizen_wearable_feature_sound_support}"
977 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_info_support=%{?tizen_wearable_feature_system_info_support}"
978 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_setting_support=%{?tizen_wearable_feature_system_setting_support}"
979 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_telephony_support=%{?tizen_wearable_feature_telephony_support}"
980 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_time_support=%{?tizen_wearable_feature_time_support}"
981 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_inputdevice_support=%{?tizen_wearable_feature_inputdevice_support}"
982 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_web_setting_support=%{?tizen_wearable_feature_web_setting_support}"
983 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_widget_service_support=%{?tizen_wearable_feature_widget_service_support}"
984 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_wi_fi_support=%{?tizen_wearable_feature_wi_fi_support}"
985 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_tvinputdevice_support=%{?tizen_wearable_feature_tvinputdevice_support}"
986 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_voicecontrol_support=%{?tizen_wearable_feature_voicecontrol_support}"
987 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ppm_support=%{?tizen_wearable_feature_ppm_support}"
988
989 ./tools/gyp/gyp $GYP_OPTIONS src/tizen-wrt.gyp
990
991 ninja -C out/Default %{?_smp_mflags}
992 pushd out
993 mv Default bin_wearable_emulator
994 popd
995 %endif # wearable-extension-emulator
996
997 pushd out
998 %if "%{?profile}" == "wearable"
999 ln -sf bin_wearable Default
1000 %endif
1001 popd
1002
1003 %endif # WEARABLE
1004
1005 %if "%{?unified_build}" == "1" || "%{?profile}" == "tv"
1006 # TV
1007 GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_os=tv -Dprivilege_engine=%{tizen_tv_privilege_engine}"
1008 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
1009 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
1010
1011 # feature flags
1012 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_tv_feature_account_support}"
1013 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_tv_feature_alarm_support}"
1014 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_app_control_settings_support=%{?tizen_tv_feature_app_control_settings_support}"
1015 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_application_support=%{?tizen_tv_feature_application_support}"
1016 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_archive_support=%{?tizen_tv_feature_archive_support}"
1017 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_badge_support=%{?tizen_tv_feature_badge_support}"
1018 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bluetooth_support=%{?tizen_tv_feature_bluetooth_support}"
1019 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bookmark_support=%{?tizen_tv_feature_bookmark_support}"
1020 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_calendar_support=%{?tizen_tv_feature_calendar_support}"
1021 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_callhistory_support=%{?tizen_tv_feature_callhistory_support}"
1022 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_contact_support=%{?tizen_tv_feature_contact_support}"
1023 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_content_support=%{?tizen_tv_feature_content_support}"
1024 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datacontrol_support=%{?tizen_tv_feature_datacontrol_support}"
1025 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datasync_support=%{?tizen_tv_feature_datasync_support}"
1026 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_download_support=%{?tizen_tv_feature_download_support}"
1027 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_exif_support=%{?tizen_tv_feature_exif_support}"
1028 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_feedback_support=%{?tizen_tv_feature_feedback_support}"
1029 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_filesystem_support=%{?tizen_tv_feature_filesystem_support}"
1030 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_fm_radio_support=%{?tizen_tv_feature_fm_radio_support}"
1031 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ham_support=%{?tizen_tv_feature_ham_support}"
1032 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_iotcon_support=%{?tizen_tv_feature_iotcon_support}"
1033 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_location_batch=%{?tizen_tv_feature_location_batch}"
1034 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_key_manager_support=%{?tizen_tv_feature_key_manager_support}"
1035 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_controller_support=%{?tizen_tv_feature_media_controller_support}"
1036 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_key_support=%{?tizen_tv_feature_media_key_support}"
1037 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_message_port_support=%{?tizen_tv_feature_message_port_support}"
1038 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_messaging_support=%{?tizen_tv_feature_messaging_support}"
1039 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nbs_support=%{?tizen_tv_feature_nbs_support}"
1040 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_emulation_support=%{?tizen_tv_feature_nfc_emulation_support}"
1041 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_support=%{?tizen_tv_feature_nfc_support}"
1042 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_notification_support=%{?tizen_tv_feature_notification_support}"
1043 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_package_support=%{?tizen_tv_feature_package_support}"
1044 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_player_util_support=%{?tizen_tv_feature_player_util_support}"
1045 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_power_support=%{?tizen_tv_feature_power_support}"
1046 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_preference_support=%{?tizen_tv_feature_preference_support}"
1047 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_push_support=%{?tizen_tv_feature_push_support}"
1048 #GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sap_support=%{?tizen_tv_feature_sap_support}"
1049 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sensor_support=%{?tizen_tv_feature_sensor_support}"
1050 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_se_support=%{?tizen_tv_feature_se_support}"
1051 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sound_support=%{?tizen_tv_feature_sound_support}"
1052 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_info_support=%{?tizen_tv_feature_system_info_support}"
1053 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_setting_support=%{?tizen_tv_feature_system_setting_support}"
1054 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_telephony_support=%{?tizen_tv_feature_telephony_support}"
1055 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_time_support=%{?tizen_tv_feature_time_support}"
1056 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_inputdevice_support=%{?tizen_tv_feature_inputdevice_support}"
1057 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_web_setting_support=%{?tizen_tv_feature_web_setting_support}"
1058 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_widget_service_support=%{?tizen_tv_feature_widget_service_support}"
1059 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_wi_fi_support=%{?tizen_tv_feature_wi_fi_support}"
1060 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_tvinputdevice_support=%{?tizen_tv_feature_tvinputdevice_support}"
1061 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_voicecontrol_support=%{?tizen_tv_feature_voicecontrol_support}"
1062 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ppm_support=%{?tizen_tv_feature_ppm_support}"
1063
1064 ./tools/gyp/gyp $GYP_OPTIONS src/tizen-wrt.gyp
1065
1066 ninja -C out/Default %{?_smp_mflags}
1067 pushd out
1068 mv Default bin_tv
1069 %if "%{?profile}" == "tv"
1070 ln -sf bin_tv Default
1071 %endif
1072 popd
1073
1074 %endif # TV
1075
1076 %if "%{?unified_build}" == "1" || "%{?profile}" == "common" || "%{?profile}" == "ivi"
1077
1078 # UNIFIED / COMMON or IVI
1079 GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_os=common -Dprivilege_engine=%{tizen_common_privilege_engine}"
1080
1081 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
1082 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
1083
1084 # feature flags
1085 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_common_feature_account_support}"
1086 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_common_feature_alarm_support}"
1087 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_app_control_settings_support=%{?tizen_common_feature_app_control_settings_support}"
1088 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_application_support=%{?tizen_common_feature_application_support}"
1089 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_archive_support=%{?tizen_common_feature_archive_support}"
1090 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_badge_support=%{?tizen_common_feature_badge_support}"
1091 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bluetooth_support=%{?tizen_common_feature_bluetooth_support}"
1092 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_bookmark_support=%{?tizen_common_feature_bookmark_support}"
1093 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_calendar_support=%{?tizen_common_feature_calendar_support}"
1094 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_callhistory_support=%{?tizen_common_feature_callhistory_support}"
1095 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_contact_support=%{?tizen_common_feature_contact_support}"
1096 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_content_support=%{?tizen_common_feature_content_support}"
1097 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datacontrol_support=%{?tizen_common_feature_datacontrol_support}"
1098 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_datasync_support=%{?tizen_common_feature_datasync_support}"
1099 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_download_support=%{?tizen_common_feature_download_support}"
1100 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_exif_support=%{?tizen_common_feature_exif_support}"
1101 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_feedback_support=%{?tizen_common_feature_feedback_support}"
1102 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_filesystem_support=%{?tizen_common_feature_filesystem_support}"
1103 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_fm_radio_support=%{?tizen_common_feature_fm_radio_support}"
1104 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ham_support=%{?tizen_common_feature_ham_support}"
1105 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_iotcon_support=%{?tizen_common_feature_iotcon_support}"
1106 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_location_batch=%{?tizen_common_feature_location_batch}"
1107 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_key_manager_support=%{?tizen_common_feature_key_manager_support}"
1108 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_controller_support=%{?tizen_common_feature_media_controller_support}"
1109 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_media_key_support=%{?tizen_common_feature_media_key_support}"
1110 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_message_port_support=%{?tizen_common_feature_message_port_support}"
1111 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_messaging_support=%{?tizen_common_feature_messaging_support}"
1112 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nbs_support=%{?tizen_common_feature_nbs_support}"
1113 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_emulation_support=%{?tizen_common_feature_nfc_emulation_support}"
1114 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_nfc_support=%{?tizen_common_feature_nfc_support}"
1115 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_notification_support=%{?tizen_common_feature_notification_support}"
1116 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_package_support=%{?tizen_common_feature_package_support}"
1117 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_player_util_support=%{?tizen_common_feature_player_util_support}"
1118 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_power_support=%{?tizen_common_feature_power_support}"
1119 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_preference_support=%{?tizen_common_feature_preference_support}"
1120 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_push_support=%{?tizen_common_feature_push_support}"
1121 #GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sap_support=%{?tizen_common_feature_sap_support}"
1122 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sensor_support=%{?tizen_common_feature_sensor_support}"
1123 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_se_support=%{?tizen_common_feature_se_support}"
1124 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_sound_support=%{?tizen_common_feature_sound_support}"
1125 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_info_support=%{?tizen_common_feature_system_info_support}"
1126 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_system_setting_support=%{?tizen_common_feature_system_setting_support}"
1127 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_telephony_support=%{?tizen_common_feature_telephony_support}"
1128 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_time_support=%{?tizen_common_feature_time_support}"
1129 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_inputdevice_support=%{?tizen_common_feature_inputdevice_support}"
1130 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_web_setting_support=%{?tizen_common_feature_web_setting_support}"
1131 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_widget_service_support=%{?tizen_common_feature_widget_service_support}"
1132 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_wi_fi_support=%{?tizen_common_feature_wi_fi_support}"
1133 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_tvinputdevice_support=%{?tizen_common_feature_tvinputdevice_support}"
1134 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_voicecontrol_support=%{?tizen_common_feature_voicecontrol_support}"
1135 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_ppm_support=%{?tizen_common_feature_ppm_support}"
1136
1137 ./tools/gyp/gyp $GYP_OPTIONS src/tizen-wrt.gyp
1138
1139 %if "%{?unified_build}" == "1"
1140 # UNIFIED
1141 ninja -C out/Default %{?_smp_mflags}
1142 pushd out
1143 mv Default bin_common
1144 ln -sf bin_common Default
1145
1146 # IVI does not have independent configurations, yet.
1147 # Copying the whole result in order to support ivi subpacakge
1148 cp -R bin_common bin_ivi
1149
1150 popd
1151 %else # UNIFIED
1152 # COMMON or IVI
1153 ninja -C out/Default %{?_smp_mflags}
1154 pushd out
1155 mv Default bin_%{?profile}
1156 ln -sf bin_%{?profile} Default
1157 popd
1158 %endif # COMMON or IVI
1159 %endif # UNIFIED / COMMON or IVI
1160
1161 %install
1162
1163 # Extensions.
1164 mkdir -p %{buildroot}%{crosswalk_extensions_path}
1165
1166 %if "%{?unified_build}" == "1" || "%{?profile}" == "common"
1167 mkdir -p %{buildroot}%{crosswalk_extensions_path}/common
1168 install -p -m 644 out/bin_common/libtizen*.so %{buildroot}%{crosswalk_extensions_path}/common
1169 # execute desc_gentool
1170 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{crosswalk_extensions_path}/common out/Default/desc_gentool \
1171         %{crosswalk_extensions_path}/common \
1172         %{buildroot}%{crosswalk_extensions_path}/common > plugins.json
1173
1174 # temporary plugins description for lazy loading
1175 install -p -m 644 plugins.json %{buildroot}%{crosswalk_extensions_path}/common/plugins.json
1176 %endif
1177
1178 %if "%{?unified_build}" == "1" || "%{?profile}" == "mobile"
1179 mkdir -p %{buildroot}%{crosswalk_extensions_path}/mobile
1180 install -p -m 644 out/bin_mobile/libtizen*.so %{buildroot}%{crosswalk_extensions_path}/mobile
1181 # execute desc_gentool
1182 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{crosswalk_extensions_path}/mobile out/Default/desc_gentool \
1183         %{crosswalk_extensions_path}/mobile \
1184         %{buildroot}%{crosswalk_extensions_path}/mobile > plugins.json
1185
1186 # temporary plugins description for lazy loading
1187 install -p -m 644 plugins.json %{buildroot}%{crosswalk_extensions_path}/mobile/plugins.json
1188
1189 # mobile-extension-emulator
1190 %ifarch %{ix86} x86_64
1191 mkdir -p %{buildroot}%{crosswalk_extensions_path}/mobile_emulator
1192 install -p -m 644 out/bin_mobile_emulator/libtizen*.so %{buildroot}%{crosswalk_extensions_path}/mobile_emulator
1193 # execute desc_gentool
1194 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{crosswalk_extensions_path}/mobile_emulator out/Default/desc_gentool \
1195         %{crosswalk_extensions_path}/mobile_emulator \
1196         %{buildroot}%{crosswalk_extensions_path}/mobile_emulator > plugins.json
1197
1198 # temporary plugins description for lazy loading
1199 install -p -m 644 plugins.json %{buildroot}%{crosswalk_extensions_path}/mobile_emulator/plugins.json
1200 %endif // mobile-extension-emulator
1201
1202 %endif // mobile
1203
1204 %if "%{?unified_build}" == "1" || "%{?profile}" == "wearable"
1205 mkdir -p %{buildroot}%{crosswalk_extensions_path}/wearable
1206 install -p -m 644 out/bin_wearable/libtizen*.so %{buildroot}%{crosswalk_extensions_path}/wearable
1207 # execute desc_gentool
1208 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{crosswalk_extensions_path}/wearable out/Default/desc_gentool \
1209         %{crosswalk_extensions_path}/wearable \
1210         %{buildroot}%{crosswalk_extensions_path}/wearable > plugins.json
1211
1212 # temporary plugins description for lazy loading
1213 install -p -m 644 plugins.json %{buildroot}%{crosswalk_extensions_path}/wearable/plugins.json
1214
1215 # wearable-extension-emulator
1216 %ifarch %{ix86} x86_64
1217 mkdir -p %{buildroot}%{crosswalk_extensions_path}/wearable_emulator
1218 install -p -m 644 out/bin_wearable_emulator/libtizen*.so %{buildroot}%{crosswalk_extensions_path}/wearable_emulator
1219 # execute desc_gentool
1220 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{crosswalk_extensions_path}/wearable_emulator out/Default/desc_gentool \
1221         %{crosswalk_extensions_path}/wearable_emulator \
1222         %{buildroot}%{crosswalk_extensions_path}/wearable_emulator > plugins.json
1223
1224 # temporary plugins description for lazy loading
1225 install -p -m 644 plugins.json %{buildroot}%{crosswalk_extensions_path}/wearable_emulator/plugins.json
1226 %endif // wearable-extension-emulator
1227
1228 %endif // wearable
1229
1230 %if "%{?unified_build}" == "1" || "%{?profile}" == "tv"
1231 mkdir -p %{buildroot}%{crosswalk_extensions_path}/tv
1232 install -p -m 644 out/bin_tv/libtizen*.so %{buildroot}%{crosswalk_extensions_path}/tv
1233 # execute desc_gentool
1234 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{crosswalk_extensions_path}/tv out/Default/desc_gentool \
1235         %{crosswalk_extensions_path}/tv \
1236         %{buildroot}%{crosswalk_extensions_path}/tv > plugins.json
1237
1238 # temporary plugins description for lazy loading
1239 install -p -m 644 plugins.json %{buildroot}%{crosswalk_extensions_path}/tv/plugins.json
1240 %endif
1241
1242 %if "%{?unified_build}" == "1" || "%{?profile}" == "ivi"
1243 mkdir -p %{buildroot}%{crosswalk_extensions_path}/ivi
1244 install -p -m 644 out/bin_ivi/libtizen*.so %{buildroot}%{crosswalk_extensions_path}/ivi
1245 # execute desc_gentool
1246 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{crosswalk_extensions_path}/ivi out/Default/desc_gentool \
1247         %{crosswalk_extensions_path}/ivi \
1248         %{buildroot}%{crosswalk_extensions_path}/ivi > plugins.json
1249
1250 # temporary plugins description for lazy loading
1251 install -p -m 644 plugins.json %{buildroot}%{crosswalk_extensions_path}/ivi/plugins.json
1252 %endif
1253
1254 # devel files
1255 mkdir -p %{buildroot}%{_libdir}/pkgconfig
1256 sed -i s,__LIB_DIR__,%{crosswalk_extensions_path},g packaging/%{name}.pc.in
1257 sed -i s,__INCLUDE_DIR__,%{_includedir}/%{name}/src,g packaging/%{name}.pc.in
1258 cp packaging/%{name}.pc.in %{buildroot}%{_libdir}/pkgconfig/%{name}.pc
1259 mkdir -p %{buildroot}%{_includedir}/%{name}/src/common
1260 mkdir -p %{buildroot}%{_includedir}/%{name}/src/common/filesystem
1261 install -p -m 644 src/common/*.h %{buildroot}%{_includedir}/%{name}/src/common
1262 install -p -m 644 src/common/filesystem/*.h %{buildroot}%{_includedir}/%{name}/src/common/filesystem
1263 install -p -m 644 src/common/*.gypi %{buildroot}%{_includedir}/%{name}/src/common
1264 install -p -m 644 src/common/XW_Extension.cc %{buildroot}%{_includedir}/%{name}/src/common
1265 mkdir -p %{buildroot}%{_includedir}/%{name}/tools
1266 install -p -m 644 tools/generate_api.py %{buildroot}%{_includedir}/%{name}/tools
1267 install -p -m 644 tools/mergejs.py %{buildroot}%{_includedir}/%{name}/tools
1268 install -p -m 644 tools/js_minimize.py %{buildroot}%{_includedir}/%{name}/tools
1269 cp -a tools/gyp %{buildroot}%{_includedir}/%{name}/tools/gyp
1270 cp -a tools/slimit %{buildroot}%{_includedir}/%{name}/tools/slimit
1271 cp -a out/Default/desc_gentool %{buildroot}%{_includedir}/%{name}/tools/desc_gentool
1272
1273 %files
1274 %manifest webapi-plugins.manifest
1275 %license LICENSE
1276
1277 %if "%{?unified_build}" == "1" || "%{?profile}" == "common"
1278 %post profile_common
1279 ln -sf %{crosswalk_extensions_path}/common/* %{crosswalk_extensions_path}
1280 %preun profile_common
1281 # This is an un-installation.
1282 if [ "$1" == "0" ]; then
1283   rm %{crosswalk_extensions_path}/libtizen*.so
1284   rm %{crosswalk_extensions_path}/plugins.json
1285 fi
1286 %files profile_common
1287 %dir %{crosswalk_extensions_path}/common/
1288 %{crosswalk_extensions_path}/common/libtizen*.so
1289 %{crosswalk_extensions_path}/common/plugins.json
1290 %manifest webapi-plugins.manifest
1291 %endif
1292
1293 %if "%{?unified_build}" == "1" || "%{?profile}" == "mobile"
1294 %post profile_mobile
1295 ln -sf %{crosswalk_extensions_path}/mobile/* %{crosswalk_extensions_path}
1296 %preun profile_mobile
1297 # This is an un-installation.
1298 if [ "$1" == "0" ]; then
1299   if [ -n "$(ls %{crosswalk_extensions_path}/ | grep libtizen*.so)" ]; then
1300     rm %{crosswalk_extensions_path}/libtizen*.so
1301   fi
1302   if [ -f %{crosswalk_extensions_path}/plugins.json ]; then
1303     rm %{crosswalk_extensions_path}/plugins.json
1304   fi
1305 fi
1306 %files profile_mobile
1307 %dir %{crosswalk_extensions_path}/mobile/
1308 %{crosswalk_extensions_path}/mobile/libtizen*.so
1309 %{crosswalk_extensions_path}/mobile/plugins.json
1310 %manifest webapi-plugins.manifest
1311
1312 # mobile-extension-emulator
1313 %ifarch %{ix86} x86_64
1314 %post mobile-extension-emulator
1315 ln -sf %{crosswalk_extensions_path}/mobile_emulator/* %{crosswalk_extensions_path}
1316 %preun mobile-extension-emulator
1317 # This is an un-installation.
1318 if [ "$1" == "0" ]; then
1319   if [ -n "$(ls %{crosswalk_extensions_path}/ | grep libtizen*.so)" ]; then
1320     rm %{crosswalk_extensions_path}/libtizen*.so
1321   fi
1322   if [ -f %{crosswalk_extensions_path}/plugins.json ]; then
1323     rm %{crosswalk_extensions_path}/plugins.json
1324   fi
1325 fi
1326 %files mobile-extension-emulator
1327 %dir %{crosswalk_extensions_path}/mobile_emulator/
1328 %{crosswalk_extensions_path}/mobile_emulator/libtizen*.so
1329 %{crosswalk_extensions_path}/mobile_emulator/plugins.json
1330 %manifest webapi-plugins.manifest
1331 %endif // mobile-extension-emulator
1332 %endif // mobile
1333
1334 %if "%{?unified_build}" == "1" || "%{?profile}" == "wearable"
1335 %post profile_wearable
1336 ln -sf %{crosswalk_extensions_path}/wearable/* %{crosswalk_extensions_path}
1337 %preun profile_wearable
1338 # This is an un-installation.
1339 if [ "$1" == "0" ]; then
1340   if [ -n "$(ls %{crosswalk_extensions_path}/ | grep libtizen*.so)" ]; then
1341     rm %{crosswalk_extensions_path}/libtizen*.so
1342   fi
1343   if [ -f %{crosswalk_extensions_path}/plugins.json ]; then
1344     rm %{crosswalk_extensions_path}/plugins.json
1345   fi
1346 fi
1347 %files profile_wearable
1348 %dir %{crosswalk_extensions_path}/wearable/
1349 %{crosswalk_extensions_path}/wearable/libtizen*.so
1350 %{crosswalk_extensions_path}/wearable/plugins.json
1351 %manifest webapi-plugins.manifest
1352
1353 # wearable-extension-emulator
1354 %ifarch %{ix86} x86_64
1355 %post wearable-extension-emulator
1356 ln -sf %{crosswalk_extensions_path}/wearable_emulator/* %{crosswalk_extensions_path}
1357 %preun wearable-extension-emulator
1358 # This is an un-installation.
1359 if [ "$1" == "0" ]; then
1360   if [ -n "$(ls %{crosswalk_extensions_path}/ | grep libtizen*.so)" ]; then
1361     rm %{crosswalk_extensions_path}/libtizen*.so
1362   fi
1363   if [ -f %{crosswalk_extensions_path}/plugins.json ]; then
1364     rm %{crosswalk_extensions_path}/plugins.json
1365   fi
1366 fi
1367 %files wearable-extension-emulator
1368 %dir %{crosswalk_extensions_path}/wearable_emulator/
1369 %{crosswalk_extensions_path}/wearable_emulator/libtizen*.so
1370 %{crosswalk_extensions_path}/wearable_emulator/plugins.json
1371 %manifest webapi-plugins.manifest
1372 %endif // wearable-extension-emulator
1373 %endif // wearable
1374
1375 %if "%{?unified_build}" == "1" || "%{?profile}" == "tv"
1376 %post profile_tv
1377 ln -sf %{crosswalk_extensions_path}/tv/* %{crosswalk_extensions_path}
1378 %preun profile_tv
1379 # This is an un-installation.
1380 if [ "$1" == "0" ]; then
1381   rm %{crosswalk_extensions_path}/libtizen*.so
1382   rm %{crosswalk_extensions_path}/plugins.json
1383 fi
1384 %files profile_tv
1385 %dir %{crosswalk_extensions_path}/tv/
1386 %{crosswalk_extensions_path}/tv/libtizen*.so
1387 %{crosswalk_extensions_path}/tv/plugins.json
1388 %manifest webapi-plugins.manifest
1389 %endif
1390
1391 %if "%{?unified_build}" == "1" || "%{?profile}" == "ivi"
1392 %post profile_ivi
1393 ln -sf %{crosswalk_extensions_path}/ivi/* %{crosswalk_extensions_path}
1394 %preun profile_ivi
1395 # This is an un-installation.
1396 if [ "$1" == "0" ]; then
1397   rm %{crosswalk_extensions_path}/libtizen*.so
1398   rm %{crosswalk_extensions_path}/plugins.json
1399 fi
1400 %files profile_ivi
1401 %dir %{crosswalk_extensions_path}/ivi/
1402 %{crosswalk_extensions_path}/ivi/libtizen*.so
1403 %{crosswalk_extensions_path}/ivi/plugins.json
1404 %manifest webapi-plugins.manifest
1405 %endif
1406
1407 %files devel
1408 %{_includedir}/*
1409 %{_libdir}/pkgconfig/*