]>
Commit | Line | Data |
---|---|---|
71d7c8d4 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without apidocs # API documentation | |
33f131d4 | 4 | %bcond_without icu # libicu instead of libunistring [the latter broken since 3.1.1] |
d797e1f6 | 5 | %bcond_with libsoup3 # libsoup3 support |
71d7c8d4 JB |
6 | %bcond_with static_libs # static libraries |
7 | %bcond_without vala # Vala API | |
8 | ||
9 | %define abiver 3.0 | |
10 | Summary: Tracker 3 - an indexing subsystem | |
11 | Summary(pl.UTF-8): Tracker 3 - podsystem indeksujący | |
12 | Name: tracker3 | |
b653228d | 13 | Version: 3.2.1 |
7c777c55 | 14 | Release: 3 |
71d7c8d4 JB |
15 | License: GPL v2+ |
16 | Group: Applications | |
d797e1f6 | 17 | Source0: https://download.gnome.org/sources/tracker/3.2/tracker-%{version}.tar.xz |
b653228d | 18 | # Source0-md5: 89bb081f0ffcdd1d92296b73de0a371c |
71d7c8d4 JB |
19 | URL: https://wiki.gnome.org/Projects/Tracker |
20 | BuildRequires: asciidoc | |
21 | BuildRequires: dbus-devel >= 1.3.1 | |
71d7c8d4 JB |
22 | BuildRequires: gettext-tools |
23 | BuildRequires: glib2-devel >= 1:2.52.0 | |
24 | BuildRequires: gobject-introspection-devel >= 0.10.0 | |
25 | BuildRequires: graphviz | |
d797e1f6 JB |
26 | # dist tarballs contain pregenerated docs |
27 | #BuildRequires: hotdoc | |
28 | BuildRequires: json-glib-devel >= 1.4 | |
71d7c8d4 | 29 | %{?with_icu:BuildRequires: libicu-devel >= 4.8.1.1} |
d797e1f6 JB |
30 | %{!?with_libsoup3:BuildRequires: libsoup-devel >= 2.40} |
31 | %{?with_libsoup3:BuildRequires: libsoup3-devel >= 2.99.2} | |
71d7c8d4 JB |
32 | BuildRequires: libstemmer-devel |
33 | %{!?with_icu:BuildRequires: libunistring-devel} | |
34 | BuildRequires: libuuid-devel | |
35 | BuildRequires: libxml2-devel >= 1:2.6.31 | |
36 | BuildRequires: libxslt-progs | |
d797e1f6 | 37 | BuildRequires: meson >= 0.51 |
71d7c8d4 JB |
38 | BuildRequires: ninja >= 1.5 |
39 | BuildRequires: pkgconfig | |
40 | BuildRequires: python3 >= 1:3.2 | |
5a9ed503 | 41 | BuildRequires: rpm-build >= 4.6 |
96fe3c5c | 42 | BuildRequires: rpmbuild(macros) >= 2.011 |
5a9ed503 | 43 | BuildRequires: sqlite3-devel >= 3.35.2 |
71d7c8d4 JB |
44 | BuildRequires: tar >= 1:1.22 |
45 | %{?with_vala:BuildRequires: vala >= 2:0.18.0} | |
d797e1f6 | 46 | %{?with_libsoup3:BuildRequires: vala-libsoup3 >= 2.99.2} |
71d7c8d4 JB |
47 | BuildRequires: xz |
48 | BuildRequires: zlib-devel | |
49 | Requires(post,postun): glib2 >= 1:2.52.0 | |
96fe3c5c | 50 | Requires(post,preun): systemd-units >= 1:250.1 |
71d7c8d4 JB |
51 | Requires: %{name}-libs = %{version}-%{release} |
52 | Requires: dbus >= 1.3.1 | |
96fe3c5c | 53 | Requires: systemd-units >= 1:250.1 |
71d7c8d4 JB |
54 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
55 | ||
56 | %description | |
57 | Tracker is an indexing sub-system and search aggregator. | |
58 | ||
59 | %description -l pl.UTF-8 | |
60 | Tracker jest podsystemem indeksującym i wyszukującym. | |
61 | ||
62 | %package libs | |
63 | Summary: Tracker 3 library | |
64 | Summary(pl.UTF-8): Biblioteka Trackera 3 | |
65 | License: LGPL v2.1+ | |
66 | Group: Libraries | |
67 | Requires: glib2 >= 1:2.52.0 | |
d797e1f6 JB |
68 | Requires: json-glib >= 1.4 |
69 | %{!?with_soup3:Requires: libsoup >= 2.40} | |
70 | %{?with_soup3:Requires: libsoup3 >= 2.99.2} | |
71d7c8d4 | 71 | Requires: libxml2 >= 1:2.6.31 |
5a9ed503 | 72 | Requires: sqlite3 >= 3.35.2 |
71d7c8d4 JB |
73 | |
74 | %description libs | |
75 | Tracker 3 library. | |
76 | ||
77 | %description libs -l pl.UTF-8 | |
78 | Biblioteka Trackera 3. | |
79 | ||
80 | %package devel | |
81 | Summary: Header files for Tracker 3 library | |
82 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki Trackera 3 | |
83 | License: LGPL v2.1+ | |
84 | Group: Development/Libraries | |
85 | Requires: %{name}-libs = %{version}-%{release} | |
86 | Requires: glib2-devel >= 1:2.52.0 | |
d797e1f6 | 87 | Requires: json-glib-devel >= 1.4 |
71d7c8d4 JB |
88 | Requires: libstemmer-devel |
89 | Requires: libxml2-devel >= 1:2.6.31 | |
90 | ||
91 | %description devel | |
92 | Header files for Tracker 3 library. | |
93 | ||
94 | %description devel -l pl.UTF-8 | |
95 | Pliki nagłówkowe bibliotek Trackera 3. | |
96 | ||
97 | %package static | |
98 | Summary: Static Tracker 3 library | |
99 | Summary(pl.UTF-8): Statyczna biblioteka Trackera 3 | |
100 | License: LGPL v2.1+ | |
101 | Group: Development/Libraries | |
102 | Requires: %{name}-devel = %{version}-%{release} | |
103 | ||
104 | %description static | |
105 | Static Tracker 3 library. | |
106 | ||
107 | %description static -l pl.UTF-8 | |
108 | Statyczna biblioteka Trackera 3. | |
109 | ||
110 | %package testutils | |
111 | Summary: Tracker 3 test utilities | |
112 | Summary(pl.UTF-8): Narzędzia testowe Trackera 3 | |
113 | Group: Development/Tools | |
114 | Requires: %{name}-libs = %{version}-%{release} | |
115 | Requires: python3 >= 1:3.2 | |
116 | Requires: python3-pygobject3 >= 3 | |
117 | ||
118 | %description testutils | |
119 | Tracker 3 test utilities. | |
120 | ||
121 | %description testutils -l pl.UTF-8 | |
122 | Narzędzia testowe Trackera 3. | |
123 | ||
124 | %package apidocs | |
125 | Summary: Tracker 3 library API documentation | |
126 | Summary(pl.UTF-8): Dokumentacja API biblioteki Trackera 3 | |
127 | Group: Documentation | |
128 | Requires: gtk-doc-common | |
2c6584a3 | 129 | BuildArch: noarch |
71d7c8d4 JB |
130 | |
131 | %description apidocs | |
132 | Tracker 3 library API documentation. | |
133 | ||
134 | %description apidocs -l pl.UTF-8 | |
135 | Dokumentacja API biblioteki Trackera 3. | |
136 | ||
137 | %package -n bash-completion-tracker3 | |
138 | Summary: Bash completion for tracker3 command | |
139 | Summary(pl.UTF-8): Bashowe uzupełnianie parametrów dla polecenia tracker3 | |
140 | Group: Applications/Shells | |
141 | Requires: %{name} = %{version}-%{release} | |
142 | Requires: bash-completion >= 2.0 | |
5a9ed503 | 143 | BuildArch: noarch |
71d7c8d4 JB |
144 | |
145 | %description -n bash-completion-tracker3 | |
146 | Bash completion for tracker3 command. | |
147 | ||
148 | %description -n bash-completion-tracker3 -l pl.UTF-8 | |
149 | Bashowe uzupełnianie parametrów dla polecenia tracker3. | |
150 | ||
151 | %package -n vala-tracker3 | |
152 | Summary: Tracker 3 API for Vala language | |
153 | Summary(pl.UTF-8): API Trackera 3 dla języka Vala | |
154 | Group: Development/Libraries | |
155 | Requires: %{name}-devel = %{version}-%{release} | |
156 | Requires: vala >= 2:0.18.0 | |
2c6584a3 | 157 | BuildArch: noarch |
71d7c8d4 JB |
158 | |
159 | %description -n vala-tracker3 | |
160 | Tracker 3 API for Vala language. | |
161 | ||
162 | %description -n vala-tracker3 -l pl.UTF-8 | |
163 | API Trackera 3 dla języka Vala. | |
164 | ||
165 | %prep | |
166 | %setup -q -n tracker-%{version} | |
167 | ||
d797e1f6 JB |
168 | %if %{with libsoup3} |
169 | %{__sed} -i -e 's/libsoup2\.found()/false/' meson.build src/libtracker-sparql/meson.build | |
170 | %else | |
171 | %{__sed} -i -e 's/libsoup3\.found()/false/' meson.build src/libtracker-sparql/meson.build | |
172 | %endif | |
173 | ||
71d7c8d4 JB |
174 | %build |
175 | CPPFLAGS="%{rpmcppflags} -I/usr/include/libstemmer" | |
176 | %meson build \ | |
177 | %{!?with_static_libs:--default-library=shared} \ | |
178 | -Dbash_completion_dir=%{bash_compdir} \ | |
179 | %{!?with_apidocs:-Ddocs=false} \ | |
71d7c8d4 JB |
180 | -Dsystemd_user_services_dir=%{systemduserunitdir} \ |
181 | -Dunicode_support=%{?with_icu:icu}%{!?with_icu:unistring} | |
182 | ||
183 | %ninja_build -C build -j1 | |
184 | ||
185 | %install | |
186 | rm -rf $RPM_BUILD_ROOT | |
187 | ||
188 | %ninja_install -C build | |
189 | ||
190 | %if %{with static_libs} | |
191 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/tracker-%{abiver}/libtracker-*.a | |
192 | %endif | |
193 | ||
194 | %find_lang tracker3 | |
195 | ||
196 | %clean | |
197 | rm -rf $RPM_BUILD_ROOT | |
198 | ||
96fe3c5c JR |
199 | %post |
200 | %systemd_user_post tracker-xdg-portal-3.service | |
201 | ||
202 | %preun | |
203 | %systemd_user_preun tracker-xdg-portal-3.service | |
204 | ||
71d7c8d4 JB |
205 | %post libs -p /sbin/ldconfig |
206 | %postun libs -p /sbin/ldconfig | |
207 | ||
208 | %files -f tracker3.lang | |
209 | %defattr(644,root,root,755) | |
210 | %attr(755,root,root) %{_bindir}/tracker3 | |
211 | %attr(755,root,root) %{_libexecdir}/tracker-xdg-portal-3 | |
212 | %dir %{_libexecdir}/tracker3 | |
213 | %attr(755,root,root) %{_libexecdir}/tracker3/endpoint | |
214 | %attr(755,root,root) %{_libexecdir}/tracker3/export | |
215 | %attr(755,root,root) %{_libexecdir}/tracker3/help | |
216 | %attr(755,root,root) %{_libexecdir}/tracker3/import | |
217 | %attr(755,root,root) %{_libexecdir}/tracker3/sparql | |
218 | %attr(755,root,root) %{_libexecdir}/tracker3/sql | |
219 | %{_datadir}/dbus-1/services/org.freedesktop.portal.Tracker.service | |
220 | %{_datadir}/tracker3 | |
221 | %{systemduserunitdir}/tracker-xdg-portal-3.service | |
222 | %{_mandir}/man1/tracker-xdg-portal-3.1* | |
223 | %{_mandir}/man1/tracker3-endpoint.1* | |
224 | %{_mandir}/man1/tracker3-export.1* | |
225 | %{_mandir}/man1/tracker3-import.1* | |
226 | %{_mandir}/man1/tracker3-sparql.1* | |
227 | %{_mandir}/man1/tracker3-sql.1* | |
228 | ||
229 | %files libs | |
230 | %defattr(644,root,root,755) | |
231 | %doc AUTHORS COPYING MAINTAINERS NEWS README.md | |
232 | %attr(755,root,root) %{_libdir}/libtracker-sparql-%{abiver}.so.*.*.* | |
233 | %attr(755,root,root) %ghost %{_libdir}/libtracker-sparql-%{abiver}.so.0 | |
234 | %{_libdir}/girepository-1.0/Tracker-%{abiver}.typelib | |
d797e1f6 JB |
235 | %dir %{_libdir}/tracker-%{abiver} |
236 | %if %{with libsoup3} | |
237 | %attr(755,root,root) %{_libdir}/tracker-%{abiver}/libtracker-remote-soup3.so | |
238 | %else | |
239 | %attr(755,root,root) %{_libdir}/tracker-%{abiver}/libtracker-remote-soup2.so | |
240 | %endif | |
71d7c8d4 JB |
241 | |
242 | %files devel | |
243 | %defattr(644,root,root,755) | |
244 | %attr(755,root,root) %{_libdir}/libtracker-sparql-%{abiver}.so | |
245 | %{_includedir}/tracker-%{abiver} | |
246 | %{_pkgconfigdir}/tracker-sparql-%{abiver}.pc | |
247 | %{_datadir}/gir-1.0/Tracker-%{abiver}.gir | |
248 | ||
249 | %if %{with static_libs} | |
250 | %files static | |
251 | %defattr(644,root,root,755) | |
252 | %{_libdir}/libtracker-sparql-%{abiver}.a | |
253 | %endif | |
254 | ||
255 | %files testutils | |
256 | %defattr(644,root,root,755) | |
71d7c8d4 JB |
257 | %dir %{_libdir}/tracker-%{abiver}/trackertestutils |
258 | %attr(755,root,root) %{_libdir}/tracker-%{abiver}/trackertestutils/tracker-sandbox | |
259 | %{_libdir}/tracker-%{abiver}/trackertestutils/*.py | |
260 | %{_pkgconfigdir}/tracker-testutils-%{abiver}.pc | |
261 | ||
262 | %if %{with apidocs} | |
263 | %files apidocs | |
264 | %defattr(644,root,root,755) | |
d797e1f6 | 265 | %{_datadir}/devhelp/books/Tracker |
71d7c8d4 JB |
266 | %endif |
267 | ||
268 | %files -n bash-completion-tracker3 | |
269 | %defattr(644,root,root,755) | |
270 | %{bash_compdir}/tracker3 | |
271 | ||
272 | %if %{with vala} | |
273 | %files -n vala-tracker3 | |
274 | %defattr(644,root,root,755) | |
275 | %{_datadir}/vala/vapi/tracker-sparql-%{abiver}.deps | |
276 | %{_datadir}/vala/vapi/tracker-sparql-%{abiver}.vapi | |
277 | %endif |