version up to release all pkg of the merged
[platform/core/system/system-server.git] / packaging / system-server.spec
1 #sbs-git:slp/pkgs/s/system-server system-server 0.1.51 56e16bca39f96d6c8aed9ed3df2fea9b393801be
2 Name:       system-server
3 Summary:    System server
4 Version:    2.0.0
5 Release:    1
6 Group:      System/Service
7 License:    Apache-2.0
8 Source0:    system-server-%{version}.tar.gz
9 Source1:    system-server.manifest
10 Source2:    deviced.manifest
11 Source3:    sysman.manifest
12 Source4:    libslp-pm.manifest
13 Source5:    haptic.manifest
14 Source6:    devman.manifest
15 BuildRequires:  cmake
16 BuildRequires:  libattr-devel
17 BuildRequires:  pkgconfig(ecore)
18 BuildRequires:  pkgconfig(heynoti)
19 BuildRequires:  pkgconfig(vconf)
20 BuildRequires:  pkgconfig(tapi)
21 BuildRequires:  pkgconfig(edbus)
22 BuildRequires:  pkgconfig(dlog)
23 BuildRequires:  pkgconfig(syspopup-caller)
24 BuildRequires:  pkgconfig(x11)
25 BuildRequires:  pkgconfig(notification)
26 BuildRequires:  pkgconfig(usbutils)
27 BuildRequires:  pkgconfig(udev)
28 BuildRequires:  pkgconfig(device-node)
29 BuildRequires:  pkgconfig(libsmack)
30 BuildRequires:  gettext
31 BuildRequires:  pkgconfig(sensor)
32 BuildRequires:  pkgconfig(libsystemd-daemon)
33 BuildRequires:  pkgconfig(capi-base-common)
34 %{?systemd_requires}
35 Requires(preun): /usr/bin/systemctl
36 Requires(post): /usr/bin/systemctl
37 Requires(post): /usr/bin/vconftool
38 Requires(postun): /usr/bin/systemctl
39
40 %description
41 system server
42
43 %package system-server
44 Summary:    System-server daemon
45 Group:      System/Service
46 Requires:   %{name} = %{version}-%{release}
47
48 %description system-server
49 system server daemon.
50
51 %package -n sysman
52 Summary:    Sysman library
53 License:    Apache-2.0
54 Group:      System/Libraries
55 Requires:   %{name} = %{version}-%{release}
56
57 %description -n sysman
58 sysman library.
59
60 %package -n sysman-devel
61 Summary:    Sysman devel library
62 License:    Apache-2.0
63 Group:      System/Development
64 Requires:   %{name} = %{version}-%{release}
65
66 %description -n sysman-devel
67 sysman devel library.
68
69 %package -n sysman-internal-devel
70 Summary:    Sysman internal devel library
71 License:    Apache-2.0
72 Group:      System/Development
73 Requires:   %{name} = %{version}-%{release}
74
75 %description -n sysman-internal-devel
76 sysman internal devel library.
77
78 %package -n libslp-pm
79 Summary:    power manager client
80 Group:      System/Libraries
81 Requires:   %{name} = %{version}-%{release}
82
83 %description -n libslp-pm
84 power-manager library.
85
86 %package -n libslp-pm-devel
87 Summary:    power manager client (devel)
88 Group:      System/Development
89 Requires:   %{name} = %{version}-%{release}
90 #Requires:   libslp-pm
91
92 %description -n libslp-pm-devel
93 power-manager devel library.
94
95 %package -n libhaptic
96 Summary:    Haptic library
97 Group:      Development/Libraries
98
99 %description -n libhaptic
100 Haptic library for device control
101
102 %package -n libhaptic-devel
103 Summary:    Haptic library for (devel)
104 Group:      Development/Libraries
105 Requires:   libhaptic = %{version}-%{release}
106
107 %description -n libhaptic-devel
108 Haptic library for device control (devel)
109
110 %package -n libhaptic-plugin-devel
111 Summary:    Haptic plugin library for (devel)
112 Group:      Development/Libraries
113
114 %description -n libhaptic-plugin-devel
115 Haptic plugin library for device control (devel)
116
117 %package -n libdevman
118 Summary:    Device manager library
119 Group:      Development/Libraries
120
121 %description -n libdevman
122 Device manager library for device control
123
124 %package -n libdevman-devel
125 Summary:    Device manager library for (devel)
126 Group:      Development/Libraries
127 Requires:   libdevman = %{version}-%{release}
128
129 %description -n libdevman-devel
130 Device manager library for device control (devel)
131
132 %package -n libdevman-haptic-devel
133 Summary:    Haptic Device manager library for (devel)
134 Group:      Development/Libraries
135 Requires:   libdevman-devel = %{version}-%{release}
136
137 %description -n libdevman-haptic-devel
138 Haptic Device manager library for device control (devel)
139
140 %package -n libdeviced
141 Summary:    Deviced library
142 Group:      System/Libraries
143
144 %description -n libdeviced
145 Deviced library for device control
146
147 %package -n libdeviced-devel
148 Summary:    Deviced library for (devel)
149 Group:      System/Development
150 Requires:   libdeviced = %{version}-%{release}
151
152 %description -n libdeviced-devel
153 Deviced library for device control (devel)
154
155 %prep
156 %setup -q
157 %cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix}
158
159 %build
160 cp %{SOURCE1} .
161 cp %{SOURCE2} .
162 cp %{SOURCE3} .
163 cp %{SOURCE4} .
164 cp %{SOURCE5} .
165 cp %{SOURCE6} .
166 %cmake .
167
168 %install
169 rm -rf %{buildroot}
170 %make_install
171
172 mkdir -p %{buildroot}%{_unitdir}/multi-user.target.wants
173 mkdir -p %{buildroot}%{_unitdir}/sockets.target.wants
174 ln -s ../system-server.service %{buildroot}%{_unitdir}/multi-user.target.wants/system-server.service
175 ln -s ../system-server.service %{buildroot}%{_unitdir}/sockets.target.wants/system-server.socket
176
177 %post
178 #memory type vconf key init
179 vconftool set -t int memory/sysman/usbhost_status -1 -i
180 vconftool set -t int memory/sysman/mmc 0 -i
181 vconftool set -t int memory/sysman/earjack_key 0 -i
182 vconftool set -t int memory/sysman/added_usb_storage 0 -i
183 vconftool set -t int memory/sysman/removed_usb_storage 0 -i
184 vconftool set -t int memory/sysman/charger_status -1 -i
185 vconftool set -t int memory/sysman/charge_now -1 -i
186 vconftool set -t int memory/sysman/battery_status_low -1 -i
187 vconftool set -t int memory/sysman/battery_capacity -1 -i
188 vconftool set -t int memory/sysman/usb_status -1 -i
189 vconftool set -t int memory/sysman/earjack -1 -i
190 vconftool set -t int memory/sysman/low_memory 1 -i
191 vconftool set -t int memory/sysman/sliding_keyboard -1 -i
192 vconftool set -t int memory/sysman/mmc_mount -1 -i
193 vconftool set -t int memory/sysman/mmc_unmount -1 -i
194 vconftool set -t int memory/sysman/mmc_format -1 -i
195 vconftool set -t int memory/sysman/mmc_format_progress 0 -i
196 vconftool set -t int memory/sysman/mmc_err_status 0 -i
197 vconftool set -t int memory/sysman/power_off 0 -u 5000 -i -f
198 vconftool set -t int memory/sysman/battery_level_status -1 -i
199 vconftool set -t string memory/private/sysman/added_storage_uevent "" -i
200 vconftool set -t string memory/private/sysman/removed_storage_uevent "" -u 5000 -i
201
202 vconftool set -t int memory/sysman/hdmi 0 -i
203
204 vconftool set -t int memory/sysman/stime_changed 0 -i
205
206 #db type vconf key init
207 vconftool set -t int db/sysman/mmc_dev_changed 0 -i
208
209 vconftool set -t int memory/pm/state 0 -i -g 5000
210 vconftool set -t int memory/pm/battery_timetofull -1 -i
211 vconftool set -t int memory/pm/battery_timetoempty -1 -i
212 vconftool set -t int memory/pm/sip_status 0 -i -g 5000
213 vconftool set -t int memory/pm/custom_brightness_status 0 -i -g 5000
214 vconftool set -t bool memory/pm/brt_changed_lpm 0 -i
215 vconftool set -t int memory/pm/current_brt 60 -i -g 5000
216
217 heynotitool set system_wakeup
218 heynotitool set pm_event
219
220 heynotitool set power_off_start
221
222 heynotitool set mmcblk_add
223 heynotitool set mmcblk_remove
224 heynotitool set device_charge_chgdet
225 heynotitool set device_usb_host_add
226 heynotitool set device_usb_host_remove
227 heynotitool set device_pci_keyboard_add
228 heynotitool set device_pci_keyboard_remove
229
230 heynotitool set device_usb_chgdet
231 heynotitool set device_ta_chgdet
232 heynotitool set device_earjack_chgdet
233 heynotitool set device_earkey_chgdet
234 heynotitool set device_tvout_chgdet
235 heynotitool set device_hdmi_chgdet
236 heynotitool set device_keyboard_chgdet
237
238
239 mkdir -p /etc/udev/rules.d
240 if ! [ -L /etc/udev/rules.d/91-system-server.rules ]; then
241         ln -s %{_datadir}/system-server/udev-rules/91-system-server.rules /etc/udev/rules.d/91-system-server.rules
242 fi
243
244 systemctl daemon-reload
245 if [ $1 == 1 ]; then
246     systemctl restart system-server.service
247 fi
248 /sbin/ldconfig
249
250 %preun
251 if [ $1 == 0 ]; then
252     systemctl stop system-server.service
253 fi
254
255 %postun
256 systemctl daemon-reload
257 /sbin/ldconfig
258
259 %files -n system-server
260 %manifest %{name}.manifest
261 %license LICENSE.APLv2
262 %config %{_sysconfdir}/dbus-1/system.d/system-server.conf
263 %{_bindir}/system_server
264 /opt/etc/smack/accesses.d/system-server.rule
265 %{_libdir}/system-server/shutdown.sh
266 %if 0%{?simulator}
267 %exclude %{_bindir}/restart
268 %else
269 %{_bindir}/restart
270 %endif
271 %{_bindir}/movi_format.sh
272 %{_bindir}/sys_event
273 %{_bindir}/pm_event
274 %{_bindir}/sys_pci_noti
275 %{_bindir}/mmc-smack-label
276 %{_bindir}/device-daemon
277 %{_unitdir}/multi-user.target.wants/system-server.service
278 %{_unitdir}/sockets.target.wants/system-server.socket
279 %{_unitdir}/system-server.service
280 %{_unitdir}/system-server.socket
281 %{_datadir}/system-server/udev-rules/91-system-server.rules
282 %{_datadir}/system-server/sys_pci_noti/res/locale/*/LC_MESSAGES/*.mo
283 %config %{_sysconfdir}/dbus-1/system.d/system-server.conf
284
285 %files -n sysman
286 %manifest sysman.manifest
287 %defattr(-,root,root,-)
288 %{_libdir}/libsysman.so.*
289 %{_bindir}/regpmon
290 %{_bindir}/set_pmon
291
292 %post -n sysman
293 /sbin/ldconfig
294
295 %postun -n sysman
296 /sbin/ldconfig
297
298 %files -n sysman-devel
299 %defattr(-,root,root,-)
300 %{_includedir}/sysman/sysman.h
301 %{_includedir}/sysman/sysman_managed.h
302 %{_includedir}/sysman/sysman_PG.h
303 %{_libdir}/pkgconfig/sysman.pc
304 %{_libdir}/libsysman.so
305
306 %files -n sysman-internal-devel
307 %defattr(-,root,root,-)
308 %{_includedir}/sysman/sysman-internal.h
309
310 %files -n libslp-pm
311 %defattr(-,root,root,-)
312 %manifest libslp-pm.manifest
313 %{_libdir}/libpmapi.so.*
314
315 %post -n libslp-pm
316 /sbin/ldconfig
317
318 %postun -n libslp-pm
319 /sbin/ldconfig
320
321 %files -n libslp-pm-devel
322 %defattr(-,root,root,-)
323 %{_includedir}/pmapi/pmapi.h
324 %{_includedir}/pmapi/pmapi_managed.h
325 %{_includedir}/pmapi/pm_PG.h
326 %{_libdir}/pkgconfig/pmapi.pc
327 %{_libdir}/libpmapi.so
328
329 %post -n libslp-pm-devel
330 /sbin/ldconfig
331
332 %postun -n libslp-pm-devel
333 /sbin/ldconfig
334
335 %files -n libhaptic
336 %defattr(-,root,root,-)
337 %{_libdir}/libhaptic.so.*
338 %manifest haptic.manifest
339
340 %post -n libhaptic
341 /sbin/ldconfig
342
343 %postun -n libhaptic
344 /sbin/ldconfig
345
346
347 %files -n libhaptic-devel
348 %defattr(-,root,root,-)
349 %{_includedir}/haptic/haptic.h
350 %{_libdir}/libhaptic.so
351 %{_libdir}/pkgconfig/haptic.pc
352
353 %post -n libhaptic-devel
354 /sbin/ldconfig
355
356 %postun -n libhaptic-devel
357 /sbin/ldconfig
358
359 %files -n libhaptic-plugin-devel
360 %defattr(-,root,root,-)
361 %{_includedir}/haptic/haptic_module.h
362 %{_includedir}/haptic/haptic_plugin_intf.h
363 %{_includedir}/haptic/haptic_PG.h
364 %{_libdir}/pkgconfig/haptic-plugin.pc
365
366 %files -n libdevman
367 %{_bindir}/display_wd
368 %{_libdir}/libdevman.so.*
369 %manifest devman.manifest
370
371
372 %post -n libdevman
373 /sbin/ldconfig
374
375 %postun -n libdevman
376 /sbin/ldconfig
377
378 %files -n libdevman-devel
379 %{_includedir}/devman/devman.h
380 %{_includedir}/devman/devman_image.h
381 %{_includedir}/devman/devman_managed.h
382 %{_includedir}/devman/devman_haptic.h
383 %{_includedir}/devman/devman_PG.h
384 %{_libdir}/pkgconfig/devman.pc
385 %{_libdir}/libdevman.so
386
387 %post -n libdevman-devel
388 /sbin/ldconfig
389
390 %postun -n libdevman-devel
391 /sbin/ldconfig
392
393 %files -n libdevman-haptic-devel
394 %{_includedir}/devman/devman_haptic_ext.h
395 %{_includedir}/devman/devman_haptic_ext_core.h
396 %{_libdir}/pkgconfig/devman_haptic.pc
397
398 %files -n libdeviced
399 %defattr(-,root,root,-)
400 %{_libdir}/libdeviced.so.*
401 %manifest deviced.manifest
402
403 %post -n libdeviced
404 /sbin/ldconfig
405
406 %postun -n libdeviced
407 /sbin/ldconfig
408
409 %files -n libdeviced-devel
410 %defattr(-,root,root,-)
411 %{_includedir}/deviced/dd-battery.h
412 %{_libdir}/libdeviced.so
413 %{_libdir}/pkgconfig/deviced.pc
414
415 %post -n libdeviced-devel
416 /sbin/ldconfig
417
418 %postun -n libdeviced-devel
419 /sbin/ldconfig