722c450f98c370d5bdf62bb941e60edf64c4c0e0
[platform/core/appfw/launchpad.git] / packaging / launchpad.spec
1 Name:       launchpad
2 Summary:    Launchpad for launching applications
3 Version:    0.18.3
4 Release:    1
5 Group:      Application Framework/Daemons
6 License:    Apache-2.0
7 Source0:    %{name}-%{version}.tar.gz
8 Source101:  launchpad-process-pool.service
9 Source102:  launchpad-process-pool.socket
10 Source1001: %{name}.manifest
11 Source1002: lib%{name}.manifest
12 Source1003: %{name}-loader.manifest
13 Source1004: app-defined-loader.manifest
14
15 BuildRequires:  cmake
16 BuildRequires:  pkgconfig(bundle)
17 BuildRequires:  pkgconfig(gio-2.0)
18 BuildRequires:  pkgconfig(ecore)
19 BuildRequires:  pkgconfig(dlog)
20 BuildRequires:  pkgconfig(dlog-redirect-stdout)
21 BuildRequires:  pkgconfig(libsystemd)
22 BuildRequires:  pkgconfig(elementary)
23 BuildRequires:  pkgconfig(vconf)
24 BuildRequires:  pkgconfig(buxton2)
25 BuildRequires:  pkgconfig(security-manager)
26 BuildRequires:  pkgconfig(aul)
27 BuildRequires:  pkgconfig(ttrace)
28 BuildRequires:  pkgconfig(libtzplatform-config)
29 BuildRequires:  pkgconfig(libcap)
30 BuildRequires:  pkgconfig(tanchor)
31 BuildRequires:  pkgconfig(dbus-1)
32 BuildRequires:  pkgconfig(iniparser)
33 BuildRequires:  pkgconfig(libxml-2.0)
34 BuildRequires:  pkgconfig(libsmack)
35 BuildRequires:  pkgconfig(pkgmgr-installer)
36
37 Requires(post): /sbin/ldconfig
38 Requires(post): /usr/bin/systemctl
39 Requires(postun): /sbin/ldconfig
40 Requires(postun): /usr/bin/systemctl
41 Requires(preun): /usr/bin/systemctl
42
43 Provides: app-launchpad
44 Obsoletes: amd-mod-launchpad
45
46 %define tizen_feature_priority_change 0
47 %define tizen_feature_loader_priority 0
48 %ifarch armv7l i586
49 %define tizen_arch32 1
50 %else
51 %define tizen_arch32 0
52 %endif
53
54 %if "%{?_prelink_enable}" == "y"
55 %define tizen_feature_prelink 1
56 %else
57 %define tizen_feature_prelink 0
58 %endif
59
60 %description
61 Launchpad for launching applications
62
63 %package devel
64 Summary:    Launchpad for launching applications (devel)
65 Group:      Development/Libraries
66 Requires:   liblaunchpad = %{version}-%{release}
67
68 %description devel
69 Launchpad for launching applications (devel)
70
71 %package -n launchpad-loader
72 Summary:    Launchpad-Loader for launching applications
73 Group:      Application Framework/Application Launcher
74
75 %description -n launchpad-loader
76 Launchpad-Loader for launching applications
77
78 %package -n app-defined-loader
79 Summary:    App-Defined-Loader for launching applications
80 Group:      Application Framework/Application Launcher
81
82 %description -n app-defined-loader
83 App-Defined-Loader for launching applications
84
85 %package -n liblaunchpad
86 Summary:    Launchpad library
87 Group:      Development/Libraries
88
89 %description -n liblaunchpad
90 Launchpad library
91
92 %package -n liblaunchpad-devel
93 Summary:    Launchpad library (devel)
94 Group:      Development/Libraries
95 Requires:   liblaunchpad = %{version}-%{release}
96
97 %description -n liblaunchpad-devel
98 Launchpad library (devel)
99
100 %prep
101 %setup -q
102 cp %{SOURCE1001} .
103 cp %{SOURCE1002} .
104 cp %{SOURCE1003} .
105 cp %{SOURCE1004} .
106
107 %build
108 %if 0%{?sec_build_binary_debug_enable}
109 export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE"
110 export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
111 export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
112 %endif
113 %if 0%{?tizen_feature_priority_change}
114 _TIZEN_FEATURE_PRIORITY_CHANGE=ON
115 %endif
116 %if 0%{?tizen_feature_loader_priority}
117 _TIZEN_FEATURE_LOADER_PRIORITY=ON
118 %endif
119 %if 0%{?tizen_arch32}
120 _TIZEN_FEATURE_SET_PERSONALITY_32=ON
121 %else
122 _TIZEN_FEATURE_LOADER_ARCH64=ON
123 %endif
124 %if 0%{?tizen_feature_prelink}
125 _TIZEN_FEATURE_PRELINK=ON
126 %endif
127
128 MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
129 %cmake -DVERSION=%{version} \
130         -DMAJORVER=${MAJORVER} \
131         -D_TIZEN_FEATURE_PRIORITY_CHANGE:BOOL=${_TIZEN_FEATURE_PRIORITY_CHANGE} \
132         -D_TIZEN_FEATURE_LOADER_PRIORITY:BOOL=${_TIZEN_FEATURE_LOADER_PRIORITY} \
133         -D_TIZEN_FEATURE_SET_PERSONALITY_32:BOOL=${_TIZEN_FEATURE_SET_PERSONALITY_32} \
134         -D_TIZEN_FEATURE_PRELINK:BOOL=${_TIZEN_FEATURE_PRELINK} \
135         -D_TIZEN_FEATURE_LOADER_ARCH64:BOOL=${_TIZEN_FEATURE_LOADER_ARCH64} \
136         .
137 %__make %{?_smp_mflags}
138
139 %install
140 rm -rf %{buildroot}
141
142
143 %make_install
144 mkdir -p %{buildroot}%{_unitdir_user}/basic.target.wants
145 mkdir -p %{buildroot}%{_unitdir_user}/sockets.target.wants
146 install -m 0644 %SOURCE101 %{buildroot}%{_unitdir_user}/launchpad-process-pool.service
147 install -m 0644 %SOURCE102 %{buildroot}%{_unitdir_user}/launchpad-process-pool.socket
148 ln -sf ../launchpad-process-pool.socket %{buildroot}%{_unitdir_user}/sockets.target.wants/launchpad-process-pool.socket
149 ln -sf ../launchpad-process-pool.service %{buildroot}%{_unitdir_user}/basic.target.wants/launchpad-process-pool.service
150
151 %post
152
153 %files
154 %manifest launchpad.manifest
155 %license LICENSE
156 %{_prefix}/share/aul/default.debugger
157 %{_unitdir_user}/launchpad-process-pool.service
158 %{_unitdir_user}/launchpad-process-pool.socket
159 %{_unitdir_user}/sockets.target.wants/launchpad-process-pool.socket
160 %{_unitdir_user}/basic.target.wants/launchpad-process-pool.service
161 %{_bindir}/launchpad-process-pool
162 %{_prefix}/share/aul/launchpad.conf
163 %{_sysconfdir}/package-manager/parserlib/liblaunchpad-parser.so
164 %{_datadir}/parser-plugins/*
165
166 %files devel
167 %{_includedir}/launchpad/*.h
168 %{_libdir}/*.so
169 %{_libdir}/pkgconfig/launchpad.pc
170
171 %files -n launchpad-loader
172 %manifest launchpad-loader.manifest
173 %license LICENSE
174 %{_prefix}/share/aul/default.loader
175 %{_bindir}/launchpad-loader
176
177 %files -n app-defined-loader
178 %manifest app-defined-loader.manifest
179 %license LICENSE
180 %{_prefix}/share/aul/app-defined-loader.conf
181 %{_bindir}/app-defined-loader
182
183 %files -n liblaunchpad
184 %manifest liblaunchpad.manifest
185 %license LICENSE
186 %attr(0644,root,root) %{_libdir}/liblaunchpad.so.*
187 %attr(0644,root,root) %{_libdir}/liblaunchpad-hydra.so.*
188
189 %files -n liblaunchpad-devel
190 %{_includedir}/launchpad/*.h
191 %{_libdir}/*.so
192 %{_libdir}/pkgconfig/liblaunchpad.pc
193 %{_libdir}/pkgconfig/liblaunchpad-hydra.pc
194