Version number update 0.2.30 to 0.2.31
[framework/system/sensor-framework.git] / packaging / sensor-framework.spec
1 #sbs-git:slp/pkgs/s/sensor-framework sensor-framework 0.2.5 f585f766aa864c3857e93c776846771899a4fa41
2 Name:       sensor-framework
3 Summary:    Sensor framework
4 Version: 0.2.31
5 Release:    1
6 Group:      Framework/system
7 License:    Apache License, Version 2.0
8 Source0:    %{name}-%{version}.tar.gz
9 Source1:    sensor-framework.service
10
11 %ifarch %{arm}
12   #arm build
13   %define        _archtype arch_arm
14 %else
15   #ix86 build
16   %if 0%{?simulator}
17    #emul build target
18    %define       _archtype arch_sdk
19   %else
20    #IA build target
21    %define       _archtype arch_ia
22   %endif
23 %endif
24 Requires(post): /usr/bin/vconftool
25
26 BuildRequires:  cmake
27 BuildRequires:  pkgconfig(glib-2.0)
28 BuildRequires:  pkgconfig(sf_common)
29 BuildRequires:  pkgconfig(vconf)
30 BuildRequires:  pkgconfig(heynoti)
31
32 %description
33 Sensor framework
34
35 %prep
36 %setup -q
37
38 %build
39 cmake . -DCMAKE_INSTALL_PREFIX=/usr -DPLATFORM_ARCH=%{_archtype}
40
41 make %{?jobs:-j%jobs}
42
43 %install
44 %make_install
45
46 mkdir -p %{buildroot}/usr/share/license
47 cp LICENSE %{buildroot}/usr/share/license/%{name}
48
49 mkdir -p %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants
50 install -m 0644 %SOURCE1 %{buildroot}%{_libdir}/systemd/system/
51 ln -s ../sensor-framework.service %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants/sensor-framework.service
52
53 # FIXME: remove initscripts after we start using systemd
54 mkdir -p %{buildroot}%{_sysconfdir}/rc.d/rc3.d
55 mkdir -p %{buildroot}%{_sysconfdir}/rc.d/rc4.d
56 ln -s ../init.d/sfsvc %{buildroot}%{_sysconfdir}/rc.d/rc3.d/S40sfsvc
57 ln -s ../init.d/sfsvc %{buildroot}%{_sysconfdir}/rc.d/rc4.d/S40sfsvc
58
59 %post 
60 vconftool set -t int memory/private/sensor/10001 0 -i
61 vconftool set -t int memory/private/sensor/10002 0 -i
62 vconftool set -t int memory/private/sensor/10004 0 -i
63 vconftool set -t int memory/private/sensor/10008 0 -i
64 vconftool set -t int memory/private/sensor/10010 0 -i
65 vconftool set -t int memory/private/sensor/20001 0 -i
66 vconftool set -t int memory/private/sensor/20002 0 -i
67 vconftool set -t int memory/private/sensor/20004 0 -i
68 vconftool set -t int memory/private/sensor/200001 0 -i
69 vconftool set -t int memory/private/sensor/40001 0 -i
70 vconftool set -t int memory/private/sensor/40002 0 -i
71 vconftool set -t int memory/private/sensor/800001 0 -i
72 vconftool set -t int memory/private/sensor/800002 0 -i
73 vconftool set -t int memory/private/sensor/800004 0 -i
74 vconftool set -t int memory/private/sensor/800008 0 -i
75 vconftool set -t int memory/private/sensor/800010 0 -i
76 vconftool set -t int memory/private/sensor/800020 0 -i
77 vconftool set -t int memory/private/sensor/800040 0 -i
78 vconftool set -t int memory/private/sensor/800080 0 -i
79 vconftool set -t int memory/private/sensor/800100 0 -i
80 vconftool set -t int memory/private/sensor/800200 0 -i
81 vconftool set -t int memory/private/sensor/800400 0 -i
82 vconftool set -t int memory/private/sensor/800800 0 -i
83 vconftool set -t int memory/private/sensor/80001 0 -i
84 vconftool set -t int memory/private/sensor/80002 0 -i
85 vconftool set -t int memory/private/sensor/poweroff 0 -i
86
87 %files
88 %manifest sensor-framework.manifest
89 %attr(0755,root,root) %{_sysconfdir}/rc.d/init.d/sfsvc
90 %{_sysconfdir}/rc.d/rc3.d/S40sfsvc
91 %{_sysconfdir}/rc.d/rc4.d/S40sfsvc
92 %{_bindir}/sf_server
93 %attr(0644,root,root)/usr/etc/sf_data_stream.conf
94 %attr(0644,root,root)/usr/etc/sf_filter.conf
95 %attr(0644,root,root)/usr/etc/sf_processor.conf
96 %attr(0644,root,root)/usr/etc/sf_sensor.conf
97 %{_libdir}/systemd/system/sensor-framework.service
98 %{_libdir}/systemd/system/multi-user.target.wants/sensor-framework.service
99 /usr/share/license/%{name}
100