9da77ad18b4c54e4ac98b9e7e6b11d735a18c4e7
[apps/core/preloaded/settings.git] / packaging / org.tizen.setting.spec
1 Name:       settings
2 Summary:    Setting application
3 Version:    0.1.87
4 Release:    99
5 Group:      misc
6 License:    samsung
7 Source0:    %{name}-%{version}.tar.gz
8 BuildRequires:  pkgconfig(appcore-common)
9 BuildRequires:  pkgconfig(appcore-efl)
10 BuildRequires:  pkgconfig(elementary)
11 BuildRequires:  pkgconfig(vconf)
12 BuildRequires:  pkgconfig(tapi)
13 BuildRequires:  pkgconfig(utilX)
14 BuildRequires:  pkgconfig(devman)
15 BuildRequires:  pkgconfig(devman_haptic)
16 BuildRequires:  pkgconfig(bluetooth-api)
17 BuildRequires:  pkgconfig(mm-sound)
18 BuildRequires:  pkgconfig(openssl)
19 BuildRequires:  pkgconfig(heynoti)
20 BuildRequires:  pkgconfig(ui-gadget-1)
21 BuildRequires:  pkgconfig(json-glib-1.0)
22 BuildRequires:  pkgconfig(libxml-2.0)
23 BuildRequires:  pkgconfig(dlog)
24 BuildRequires:  pkgconfig(aul)
25 BuildRequires:  pkgconfig(pmapi)
26 BuildRequires:  pkgconfig(ecore-input)
27 BuildRequires:  pkgconfig(eina)
28 BuildRequires:  pkgconfig(icu-i18n)
29 BuildRequires:  pkgconfig(ail)
30 BuildRequires:  pkgconfig(sysman)
31 BuildRequires:  pkgconfig(glib-2.0)
32 BuildRequires:  pkgconfig(gthread-2.0)
33 BuildRequires:  pkgconfig(dbus-glib-1)
34 BuildRequires:  pkgconfig(ecore-imf)
35 BuildRequires:  pkgconfig(ecore-x)
36 BuildRequires:  pkgconfig(ecore)
37 BuildRequires:  pkgconfig(ecore-file)
38 BuildRequires:  pkgconfig(icu-io)
39 BuildRequires:  pkgconfig(icu-le)
40 BuildRequires:  pkgconfig(icu-lx)
41 BuildRequires:  pkgconfig(icu-uc)
42 BuildRequires:  pkgconfig(ewebkit2)
43 BuildRequires:  pkgconfig(evas)
44 BuildRequires:  pkgconfig(edje)
45 BuildRequires:  pkgconfig(mm-player)
46 BuildRequires:  pkgconfig(network)
47 BuildRequires:  pkgconfig(security-server)
48 BuildRequires:  pkgconfig(svi)
49 BuildRequires:  pkgconfig(appsvc)
50 BuildRequires:  pkgconfig(libxml-2.0)
51 BuildRequires:  pkgconfig(notification)
52 BuildRequires:  pkgconfig(pango)
53 BuildRequires:  pkgconfig(capi-system-runtime-info)
54 BuildRequires:  pkgconfig(capi-media-player)
55 BuildRequires:  pkgconfig(capi-media-sound-manager)
56 BuildRequires:  pkgconfig(capi-system-device)
57 BuildRequires:  pkgconfig(capi-appfw-application)
58 BuildRequires:  pkgconfig(capi-appfw-app-manager)
59 BuildRequires:  pkgconfig(capi-system-sensor)
60 BuildRequires:  pkgconfig(capi-system-haptic)
61 BuildRequires:  pkgconfig(capi-system-info)
62 BuildRequires:  pkgconfig(capi-system-system-settings)
63 BuildRequires:  pkgconfig(capi-network-bluetooth)
64 BuildRequires:  sysman-internal-devel
65 BuildRequires:  cmake
66 BuildRequires:  edje-tools
67 BuildRequires:  gettext-tools
68 %description
69 Setting application
70  BEAT UI, Setting application.
71
72
73 %prep
74 %setup -q
75
76 %build
77
78 %define PREFIX    "/opt/apps/org.tizen.setting"
79 %define RESDIR    "/opt/apps/org.tizen.setting/res"
80 %define DATADIR    "/opt/apps/org.tizen.setting/data"
81 CFLAGS+=" -fPIC";export CFLAGS
82 CXXFLAGS+=" -fPIC";export CFLAGS
83 LDFLAGS+="-Wl,--rpath=%{PREFIX}/lib -Wl,--hash-style=both -Wl,--as-needed";export LDFLAGS
84
85 %ifarch %{arm}
86         cmake . -DCMAKE_INSTALL_PREFIX=%{PREFIX} -DARCH=arm
87 %else
88         cmake . -DCMAKE_INSTALL_PREFIX=%{PREFIX} -DARCH=x86
89 %endif
90
91 make
92
93 %install
94 rm -rf %{buildroot}
95 %make_install
96
97 mkdir -p %{buildroot}/opt/data/setting
98
99 %clean
100
101 %post
102
103 # Set vconf values with -g/-u options
104 GOPTION="-g 6514"
105
106 #resetMenuscreen
107         # menuscreen app will take this vconf
108         #vconftool $GOPTION set -t string db/setting/menuscreen/package_name "com.samsung.cluster-home"
109
110
111 #resetFlightmode
112         vconftool $GOPTION set -t bool db/setting/flight_mode "0"
113
114 #resetNetwork
115         vconftool $GOPTION set -t int db/setting/select_network "0"
116         vconftool $GOPTION set -t int db/setting/select_network_act "0"
117         vconftool $GOPTION set -t int db/setting/network_mode "0"
118         vconftool $GOPTION set -t bool db/setting/3gEnabled "1"
119         vconftool $GOPTION set -t bool db/setting/data_roaming "1"
120
121 #resetUsbConnectivity
122         vconftool $GOPTION set -t int memory/setting/usb_mode "-1" -i -f
123         vconftool $GOPTION set -t int memory/setting/usb_sel_mode "0" -i -f
124         vconftool $GOPTION set -t int memory/setting/usb_in_mode_change "0" -i -f
125
126 #resetSound
127         DEFAULT_CALL_TONE="/opt/share/settings/Ringtones/ringtone_sdk.mp3"
128         DEFAULT_NOTI_TONE="/opt/share/settings/Alerts/General notification_sdk.wav"
129
130         vconftool $GOPTION set -t bool db/setting/sound/sound_on "1"
131         vconftool $GOPTION set -t bool db/setting/sound/vibration_on "1"
132
133         vconftool $GOPTION set -t int db/setting/sound/call/ringtone_sound_volume "13"
134         vconftool $GOPTION set -t int db/setting/sound/noti/sound_volume "7"
135         vconftool $GOPTION set -t int db/setting/sound/media/sound_volume "7"
136         vconftool $GOPTION set -t int db/setting/sound/touch_feedback/sound_volume "5"
137
138         vconftool $GOPTION set -t int db/setting/sound/noti/vibration_level "5"
139         vconftool $GOPTION set -t int db/setting/sound/touch_feedback/vibration_level "3"
140         vconftool $GOPTION set -t int db/setting/sound/touch_feedback/vibration_level_bak "3" ##private key
141
142         vconftool $GOPTION set -t string db/setting/sound/call/ringtone_path "${DEFAULT_CALL_TONE}"
143         vconftool $GOPTION set -t int db/setting/sound/call/vibration_type "2"
144
145         vconftool $GOPTION set -t string db/setting/sound/noti/msg_ringtone_path        "${DEFAULT_NOTI_TONE}"
146         vconftool $GOPTION set -t int db/setting/sound/noti/msg_alert_rep_type          "0"
147
148         vconftool $GOPTION set -t string db/setting/sound/noti/email_ringtone_path      "${DEFAULT_NOTI_TONE}"
149         vconftool $GOPTION set -t int db/setting/sound/noti/email_alert_rep_type                "0"
150
151         vconftool $GOPTION set -t bool db/setting/sound/sound_lock "1"
152
153 #resetWallpaper
154         vconftool $GOPTION set -t string db/menu_widget/bgset "/opt/share/settings/Wallpapers/Home_default.jpg"
155         vconftool $GOPTION set -t string db/idle_lock/bgset "/opt/share/settings/Wallpapers/Home_default.jpg"
156
157 #resetTilt
158         vconftool $GOPTION set -t bool db/setting/use_tilt "1"
159         vconftool $GOPTION set -t int db/setting/tilt_sensitivity "3"
160         vconftool $GOPTION set -t bool db/setting/use_tilt_scroll "1"
161         vconftool $GOPTION set -t int db/setting/tilt_scroll_sensitivity "3"
162
163 #resetPanning
164         vconftool $GOPTION set -t bool db/setting/use_panning "0"
165         vconftool $GOPTION set -t int db/setting/panning_sensitivity "3"
166         vconftool $GOPTION set -t bool db/setting/use_panning_browser "1"
167         vconftool $GOPTION set -t int db/setting/panning_browser_sensitivity "3"
168
169 #resetDoubleTap
170         vconftool $GOPTION set -t bool db/setting/use_double_tap "1"
171
172 #resetShake
173         vconftool $GOPTION set -t bool db/setting/use_shake "1"
174
175 #resetPickup
176         vconftool $GOPTION set -t bool db/setting/use_pick_up "1"
177         vconftool $GOPTION set -t bool db/setting/use_pick_up_call "1"
178
179 #resetTurnOver
180         vconftool $GOPTION set -t bool db/setting/use_turn_over "1"
181
182 #resetMotions
183         vconftool $GOPTION set -t bool db/setting/motion_active "1"
184         vconftool $GOPTION set -t bool db/setting/motion/palm_swipe_capture "1"
185         vconftool $GOPTION set -t bool db/setting/motion/palm_touch_mute "1"
186         vconftool $GOPTION set -t bool db/setting/motion/tap_twist "1"
187
188 #resetDisplay
189         #backlight
190 %ifarch %{arm}
191         vconftool $GOPTION set -t int db/setting/lcd_backlight_normal "30"
192 %else
193         vconftool $GOPTION set -t int db/setting/lcd_backlight_normal "0"
194 %endif
195         vconftool $GOPTION set -t int db/setting/lcd_timeout_normal_backup "30"
196
197         #brightness
198         vconftool $GOPTION set -t int db/setting/Brightness "-1"
199         vconftool $GOPTION set -t int db/setting/brightness_automatic "0"
200
201         #battery
202         vconftool $GOPTION set -t bool db/setting/battery_percentage "0"
203         #launch
204         #vconftool $GOPTION set -t string db/menu_widget/launch_effect "0"
205
206         #smart screen
207         vconftool $GOPTION set -t int db/pm/smartstay_status "0"
208         vconftool $GOPTION set -t bool db/setting/smartscreen/smart_rotation "0"
209         vconftool $GOPTION set -t bool db/setting/auto_adjust_screen_tone "1"
210         vconftool $GOPTION set -t bool db/setting/smartscreen/smart_stay_r "1"
211         vconftool $GOPTION set -t bool db/setting/smartscreen/smart_rotation_r "1"
212
213 #resetPowersaving
214         vconftool $GOPTION set -t bool db/setting/pwrsv/system_mode/status "0"
215         vconftool $GOPTION set -t bool db/setting/pwrsv/system_mode/reminder "1"
216         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/status "0"
217
218         vconftool $GOPTION set -t int db/setting/pwrsv/custom_mode/at "30"
219         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/wifi "1"
220         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/bt "1"
221         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/gps "1"
222         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/data_sync "1"
223         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/hotspot "1"
224
225         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/brt/status  "1"
226         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/brt/auto/status "0"
227         vconftool $GOPTION set -t int db/setting/pwrsv/custom_mode/brt/value "10"
228         vconftool $GOPTION set -t int db/setting/pwrsv/custom_mode/backlight/time "15"
229
230         #v0.4
231         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/cpu "0"
232         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/display "0"
233         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/bg_color "0"
234         vconftool $GOPTION set -t bool db/setting/pwrsv/custom_mode/screen_vib "0"
235
236 #resetFont
237         vconftool $GOPTION set -t int db/setting/font_size "1"
238         vconftool $GOPTION set -t int db/setting/font_type "0"
239
240 #resetRotationLock
241         vconftool $GOPTION set -t bool db/setting/rotate_lock "1"
242
243 #resetTimeAndData
244 %ifarch %{arm}
245         vconftool $GOPTION set -t bool db/setting/automatic_time_update "1"
246 %else
247         vconftool $GOPTION set -t bool db/setting/automatic_time_update "0"
248 %endif
249
250         vconftool $GOPTION set -t int db/menu_widget/regionformat_time1224 "1"
251         vconftool $GOPTION set -t int db/setting/date_format "0"
252         vconftool $GOPTION set -t int db/setting/weekofday_format  "0"
253
254         vconftool $GOPTION set -t string db/setting/timezone "+9"
255         # to be removed
256         vconftool $GOPTION set -t string db/setting/cityname_id "IDS_WCL_BODY_CITYNAME_SEOUL"
257
258         vconftool $GOPTION set -t string db/setting/timezone_id "Asia/Seoul"
259
260         #if [ -f /opt/etc/localtime ]
261         #then
262         rm -f /opt/etc/localtime
263         ln -s /usr/share/zoneinfo/Asia/Seoul /opt/etc/localtime
264         #fi
265
266
267 #resetAccessibility
268         vconftool $GOPTION set -t bool db/setting/accessibility/accessibility "0"
269         vconftool $GOPTION set -t bool db/setting/accessibility/high_contrast "0"
270         vconftool $GOPTION set -t bool db/setting/accessibility/screen_zoom "1"
271         vconftool $GOPTION set -t int db/setting/accessibility/font_size "1"
272         #vconftool $GOPTION set -t int db/setting/accessibility/font_style "0"
273         vconftool $GOPTION set -t string db/setting/accessibility/font_name "HelveticaNeue"
274         vconftool $GOPTION set -t bool db/setting/accessibility/tts "0"
275
276         vconftool $GOPTION set -t bool db/setting/accessibility/torch_light "0"
277         vconftool $GOPTION set -t bool db/setting/accessibility/mono_audio "0"
278         vconftool $GOPTION set -t int db/setting/accessibility/power_key_hold "1"
279         vconftool $GOPTION set -t bool db/setting/accessibility/led_notify "0"
280
281         vconftool $GOPTION set -t bool db/ciss/call_answering_key "0"
282         vconftool $GOPTION set -t bool db/ciss/call_power_key_ends_call "0"
283         vconftool $GOPTION set -t int db/ciss/answering_mode "0"
284         vconftool $GOPTION set -t int db/ciss/answering_mode_time "3"
285
286         vconftool $GOPTION set -t bool db/setting/accessibility/accept_call "0"
287         vconftool $GOPTION set -t bool db/setting/accessibility/enable_auto_answer "0"
288         vconftool $GOPTION set -t int db/setting/accessibility/auto_answer "1"
289         vconftool $GOPTION set -t bool db/setting/accessibility/powerkey_end_calls "0"
290
291 #Driving Mode
292         vconftool $GOPTION set -t bool db/setting/drivingmode/drivingmode "1"
293         vconftool $GOPTION set -t bool db/setting/drivingmode/incomingcall "1"
294         vconftool $GOPTION set -t bool db/setting/drivingmode/message "1"
295         vconftool $GOPTION set -t bool db/setting/drivingmode/newemails "1"
296         vconftool $GOPTION set -t bool db/setting/drivingmode/newvoicemails "1"
297         vconftool $GOPTION set -t bool db/setting/drivingmode/alarm "1"
298         vconftool $GOPTION set -t bool db/setting/drivingmode/schedule "1"
299         vconftool $GOPTION set -t bool db/setting/drivingmode/unlockscreen "1"
300
301 #resetLanguageAndRegion
302         vconftool $GOPTION set -t int db/setting/lang "2"
303         vconftool $GOPTION set -t string db/menu_widget/language "en_US.UTF-8"
304         vconftool $GOPTION set -t string db/menu_widget/regionformat "en_US.UTF-8"
305
306 #resetViewtype
307         #vconftool $GOPTION set -t int db/menuscreen/viewtype "0"
308         #vconftool $GOPTION set -t int db/taskswitcher/viewtype "0"
309
310 #resetTouch
311         #vconftool $GOPTION set -t int db/setting/vib_feedback "3"
312         #vconftool $GOPTION set -t bool db/setting/touch_panel_autolock "0"
313
314 #resetLicense
315         vconftool $GOPTION set -t bool db/setting/transaction_tracking "0"
316         vconftool $GOPTION set -t bool db/setting/expiry_reminder "0"
317         vconftool $GOPTION set -t int db/setting/roaming_network "0"
318
319 #resetNotification
320         vconftool $GOPTION set -t bool db/setting/ticker_noti/messages "1"
321         vconftool $GOPTION set -t bool db/setting/ticker_noti/email "1"
322         vconftool $GOPTION set -t bool db/setting/ticker_noti/im "1"
323         vconftool $GOPTION set -t bool db/setting/ticker_noti/twitter "1"
324         vconftool $GOPTION set -t bool db/setting/ticker_noti/facebook "1"
325
326         # display content
327         vconftool $GOPTION set -t bool db/setting/ticker_noti/display_content/messages "1"
328         vconftool $GOPTION set -t bool db/setting/ticker_noti/display_content/email "1"
329         vconftool $GOPTION set -t bool db/setting/ticker_noti/display_content/im "1"
330         vconftool $GOPTION set -t bool db/setting/ticker_noti/display_content/twitter "1"
331         vconftool $GOPTION set -t bool db/setting/ticker_noti/display_content/facebook "1"
332
333         vconftool $GOPTION set -t bool db/setting/ticker_noti/badge/messages "1"
334         vconftool $GOPTION set -t bool db/setting/ticker_noti/badge/email "1"
335         vconftool $GOPTION set -t bool db/setting/ticker_noti/badge/im "1"
336         vconftool $GOPTION set -t bool db/setting/ticker_noti/badge/twitter "1"
337         vconftool $GOPTION set -t bool db/setting/ticker_noti/badge/facebook "1"
338
339 #resetSecurity
340         rm -rf /opt/data/setting/set_info
341         #vconftool $GOPTION set -t string db/setting/privacy_passwd ""
342
343         vconftool $GOPTION set -t bool db/setting/power_on_lock "0"
344         vconftool $GOPTION set -t bool db/setting/simple_password "1"
345         vconftool $GOPTION set -t int db/setting/screen_lock_type "0"
346         vconftool $GOPTION set -t bool db/setting/fmm/sim_change_alert "0"
347         vconftool $GOPTION set -t string db/setting/fmm/recipients ""
348         vconftool $GOPTION set -t string db/setting/fmm/sender ""
349         vconftool $GOPTION set -t string db/setting/fmm/alert_message ""
350         vconftool $GOPTION set -t bool db/setting/fmm/remote_control "0"
351         vconftool $GOPTION set -t bool db/setting/fmm/location_consent "0"
352
353         # NOT USED NOW.
354         #vconftool $GOPTION set -t bool db/setting/rcs "0"
355
356         vconftool $GOPTION set -t int db/setting/phone_lock_attempts_left "5"
357         vconftool $GOPTION set -t string db/setting/phone_lock_timestamp ""
358         vconftool $GOPTION set -t int db/setting/sim_lock_attempts_left "5"
359         vconftool $GOPTION set -t string db/setting/sim_lock_timestamp ""
360         vconftool $GOPTION set -t bool db/setting/fixed_dialing_mode "0"
361 #resetMemory
362         vconftool $GOPTION set -t int db/setting/default_memory/wap "0"
363         vconftool $GOPTION set -t int db/setting/default_memory/bluetooth "0"
364         vconftool $GOPTION set -t int db/setting/default_memory/camera "0"
365         vconftool $GOPTION set -t int db/setting/default_memory/voice_recorder "0"
366         vconftool $GOPTION set -t int db/setting/default_memory/fm_radio "0"
367         vconftool $GOPTION set -t int db/setting/default_memory/all_share "0"
368         vconftool $GOPTION set -t int db/setting/default_memory/adobe_air "0"
369         vconftool $GOPTION set -t int db/setting/default_memory/dvb_h "0"
370
371         # format - system server
372         #vconftool $GOPTION -i set -t int memory/mmc/format "0"
373
374 #resetAbout
375         vconftool $GOPTION set -t string db/setting/device_name "Magnolia"
376         vconftool $GOPTION set -t string db/setting/selected_num ""
377 #resetMenuWidgets
378         vconftool $GOPTION -i set -t int memory/setting/font_changed "0"
379         #vconftool $GOPTION -i set -t int memory/mobile_hotspot/skin_changed "0"
380
381 #resetDevoptions
382         vconftool $GOPTION -i set -t int db/setting/devoption/bgprocess "0"
383
384 #resetDatausage
385         vconftool $GOPTION set -t bool db/setting/mobile_data "1"
386         vconftool $GOPTION set -t bool db/setting/disable_mobile_data_at_limit "0"
387         vconftool $GOPTION set -t bool db/setting/restrict_background_data "0"
388         vconftool $GOPTION set -t bool db/setting/show_wifi_usage "0"
389         vconftool $GOPTION set -t int db/setting/data_each_month "10"
390
391 #resetDisplay
392         vconftool $GOPTION set -t string db/setting/screenmode/selected_name "Dynamic"
393
394 #------------------------------------------
395 #create directory /opt/data/setting
396 if [ ! -d /opt/data/setting ]
397 then
398         mkdir -p /opt/data/setting
399 fi
400
401 # create setting.cfg at runtime right after installation
402 #/opt/apps/org.tizen.setting/bin/setting_conf_util
403 # After flashing, initialize timezone file
404 /opt/apps/org.tizen.setting/bin/setting_conf_util timezone_init
405 chown 5000:5000 /opt/data/setting -R
406 #------------------------------------------
407 heynotitool set setting_time_changed -a
408 sync
409
410 mkdir -p /opt/ug/bin/
411 ln -sf /usr/bin/ug-client /opt/ug/bin/setting-font-efl
412 # ln -sf /usr/bin/ug-client /opt/ug/bin/setting-accessibility-efl
413
414 %files -n settings
415 #%manifest settings.manifest
416 %defattr(-,root,root,-)
417 #%attr(-,inhouse,inhouse) %dir /opt/data/setting
418 %attr(-,app,app) %dir /opt/data/setting
419 /opt/apps/org.tizen.setting/bin/setting
420 /opt/apps/org.tizen.setting/bin/setting_conf_util
421 /opt/data/setting/setting.cfg
422
423 /opt/share/packages/org.tizen.setting.xml
424 /opt/share/packages/ug-setting-accessibility-efl.xml
425 /opt/share/packages/ug-setting-font-efl.xml
426
427 /opt/share/icons/default/small/org.tizen.setting.png
428 /opt/share/settings/*
429 /opt/apps/org.tizen.setting/res/*
430 /opt/apps/org.tizen.setting/lib/*
431 /opt/apps/org.tizen.setting/data/*
432 /opt/ug/lib/*
433 /opt/data/setting/langlist.xml
434 /opt/data/setting/plugin-cfg/*
435 /opt/data/setting/plugin-xml/*
436 /opt/apps/org.tizen.setting/bin/test_server