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