]> git.pld-linux.org Git - packages/beagle.git/blob - beagle.spec
a3de3830d472c2036bb8ff429f478bb40dc15810
[packages/beagle.git] / beagle.spec
1 #
2 # TODO:
3 #       - kill bashisms in crawl stuff
4 #       - mozilla extension?
5 #
6 %include        /usr/lib/rpm/macros.mono
7 #
8 # Conditional build:
9 %bcond_without  apidocs         # don't build API documentation
10 %bcond_without  evolution       # don't include evolution support
11 %bcond_without  galago          # build without galago support
12 %bcond_without  gsf             # build without libgsf support
13 %bcond_without  gui             # don't build GNOME based GUI
14 %bcond_without  python          # don't build python libraries
15 %bcond_without  epiphany        # don't build epiphany extension
16 %bcond_with     sqlite3         # use sqlite3 instead of sqlite2
17 %bcond_with     thunderbird     # use Thunderbird backend
18 #
19 %if !%{with gui}
20 %undefine       with_evolution
21 %endif
22 #
23 Summary:        Beagle - An indexing subsystem
24 Summary(pl):    Beagle - podsystem indeksuj±cy
25 Name:           beagle
26 Version:        0.2.16
27 Release:        1
28 License:        Various
29 Group:          Libraries
30 Source0:        http://ftp.gnome.org/pub/gnome/sources/beagle/0.2/%{name}-%{version}.tar.bz2
31 # Source0-md5:  4818ca64dc2311208a27f03893836e49
32 Patch0:         %{name}-desktop.patch
33 Patch1:         %{name}-crawl.patch
34 Patch2:         %{name}-kill_exec_a.patch
35 Patch3:         %{name}-configure.patch
36 Patch4:         %{name}-unary-plus-string.patch
37 URL:            http://beagle-project.org/Main_Page
38 BuildRequires:  autoconf >= 2.52
39 BuildRequires:  automake
40 BuildRequires:  chmlib-devel
41 %{?with_evolution:BuildRequires:        dotnet-evolution-sharp-devel >= 0.11.1}
42 %{?with_galago:BuildRequires:   dotnet-galago-sharp-devel >= 0.5.0}
43 BuildRequires:  dotnet-gmime-sharp-devel >= 2.2.3
44 %{?with_gsf:BuildRequires:      dotnet-gsf-sharp-devel >= 0.8.1}
45 #BuildRequires: dotnet-gst-sharp-devel
46 BuildRequires:  dotnet-gtk-sharp2-devel >= 2.10.0
47 %if %{with epiphany} 
48 BuildRequires:  epiphany-devel >= 2.16.1
49 %endif
50 BuildRequires:  gtk+2-devel >= 2:2.10.6
51 %{?with_apidocs:BuildRequires:  gtk-doc >= 1.7}
52 BuildRequires:  libexif-devel >= 0.6.13
53 BuildRequires:  librsvg-devel >= 1:2.16.0
54 BuildRequires:  libpng-devel
55 BuildRequires:  libtool
56 BuildRequires:  libxml2-devel >= 1:2.6.26
57 BuildRequires:  mono-csharp >= 1.1.13.5
58 # not used atm
59 #BuildRequires: mozilla-devel
60 %{?with_python:BuildRequires:   python-pygtk-devel >= 2.10.3}
61 BuildRequires:  pkgconfig
62 BuildRequires:  perl-XML-Parser
63 BuildRequires:  python-devel
64 %if %{with sqlite3}
65 BuildRequires:  sqlite3-devel >= 3.3.4
66 %else
67 BuildRequires:  sqlite-devel
68 %endif
69 BuildRequires:  wv-devel >= 1.2.4
70 BuildRequires:  xorg-lib-libXScrnSaver-devel
71 BuildRequires:  zip
72 # GUI BRs
73 %if %{with gui}
74 BuildRequires:  dotnet-gnome-sharp-devel >= 2.16.0
75 BuildRequires:  gnome-vfs2-devel >= 2.16.1
76 %endif
77 Requires:       %{name}-libs = %{version}-%{release}
78 Requires:       dotnet-gmime-sharp >= 2.2.3
79 %if %{with sqlite3}
80 Requires:       sqlite3
81 %else
82 Requires:       sqlite
83 %endif
84 ExclusiveArch:  %{ix86} %{x8664} arm hppa ia64 ppc s390 s390x sparc sparcv9 sparc64
85 ExcludeArch:    i386
86 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
87
88 %description
89 Beagle is an indexing sub-system and search aggregator built on top of
90 Lucene.Net.
91
92 %description -l pl
93 Beagle jest podsystemem indeksuj±cym i wyszukuj±cym zbudowanym na
94 bazie Lucene.Net.
95
96 %package libs
97 Summary:        Beagle libraries
98 Summary(pl):    Bibiloteki Beagle
99 Group:          Libraries
100
101 %description libs
102 Beagle libraries.
103
104 %description libs -l pl
105 Bibiloteki Beagle.
106
107 %package devel
108 Summary:        Beagle development files
109 Summary(pl):    Pliki programistyczne Beagle
110 Group:          Development/Libraries
111 Requires:       %{name}-libs = %{version}-%{release}
112
113 %description devel
114 Beagle development files.
115
116 %description devel -l pl
117 Pliki programistyczne Beagle.
118
119 %package static
120 Summary:        Beagle static libraries
121 Summary(pl):    Statyczne biblioteki Beagle
122 Group:          Development/Libraries
123 Requires:       %{name}-devel = %{version}-%{release}
124
125 %description static
126 Beagle static libraries.
127
128 %description static -l pl
129 Statyczne biblioteki Beagle.
130
131 %package apidocs
132 Summary:        libbeagle API documentation
133 Summary(pl):    Dokumentacja API libbeagle
134 Group:          Documentation
135 Requires:       gtk-doc-common
136
137 %description apidocs
138 libbeagle API documentation.
139
140 %description apidocs -l pl
141 Dokumentacja API libbeagle.
142
143 %package crawl-system
144 Summary:        Beagle crawl system
145 Summary(pl):    System przeszukuj±cy beagle-crawl
146 Group:          Applications/System
147 Requires:       crondaemon
148 Provides:       group(beagleindex)
149 Provides:       user(beagleindex)
150
151 %description crawl-system
152 Beagle crawl system.
153
154 %description crawl-system -l pl
155 System przeszukuj±cy beagle-crawl.
156
157 %package evolution
158 Summary:        Beagle Evolution backend
159 Summary(pl):    Backend Beagle dla Evolution
160 Group:          X11/Applications/Networking
161 Requires:       %{name} = %{version}-%{release}
162 Requires:       dotnet-evolution-sharp >= 0.11.1
163 Requires:       evolution >= 2.8.0
164
165 %description evolution
166 Beagle Evolution backend.
167
168 %description evolution -l pl
169 Backend Beagle dla Evolution.
170
171 %package thunderbird
172 Summary:        Beagle Mozilla Thunderbird backend
173 Summary(pl):    Backend Beagle dla Mozilli Thunderbird
174 Group:          X11/Applications/Networking
175 Requires:       %{name} = %{version}-%{release}
176
177 %description thunderbird
178 Beagle Mozilla Thunderbird backend.
179
180 %description thunderbird -l pl
181 Backend Beagle dla Mozilli Thunderbird.
182
183 %package -n mozilla-firefox-extension-beagle
184 Summary:        Mozilla Firefox extension - beagle
185 Summary(pl):    Rozszerzenie dla Mozilla Firefox - beagle
186 Group:          X11/Applications/Networking
187 Requires:       %{name} = %{version}-%{release}
188 Requires:       mozilla-firefox >= 2.0.0.1-2
189
190 %description -n mozilla-firefox-extension-beagle
191 Mozilla Firefox extension that allows Beagle to index every page the
192 user views.
193
194 %description -n mozilla-firefox-extension-beagle -l pl
195 Rozszerzenie dla Mozilla Firefox sprawiaj±ce, ¿e Beagle indeksuje
196 ka¿d± odwiedzan± stronê.
197
198 %package -n epiphany-extension-beagle
199 Summary:        Epiphany extension - beagle
200 Summary(pl):    Rozszerzenie dla Epiphany - beagle
201 Group:          X11/Applications/Networking
202 Requires:       %{name} = %{version}-%{release}
203 Requires:       epiphany-extensions >= 2.16.1
204
205 %description -n epiphany-extension-beagle
206 Epiphany extension that allows Beagle to index every page the user
207 views.
208
209 %description -n epiphany-extension-beagle -l pl
210 Rozszerzenie dla Epiphany sprawiaj±ce, ¿e Beagle indeksuje ka¿d±
211 odwiedzan± stronê.
212
213 %package -n python-%{name}
214 Summary:        Beagle Python bindings
215 Summary(pl):    Wi±zania jêzyka Python dla Beagle
216 Group:          Libraries/Python
217 Requires:       %{name} = %{version}-%{release}
218 %pyrequires_eq  python-libs
219
220 %description -n python-%{name}
221 Beagle Python bindings.
222
223 %description -n python-%{name} -l pl
224 Wi±zania jêzyka Python dla Beagle.
225
226 %package search-gui
227 Summary:        GNOME based Beagle GUI
228 Summary(pl):    Oparty na GNOME graficzny interfejs dla Beagle
229 Group:          Libraries/Python
230 Requires:       %{name} = %{version}-%{release}
231 Requires:       gtk+2 >= 2:2.10.6
232
233 %description search-gui
234 GNOME based Beagle GUI.
235
236 %description search-gui -l pl
237 Oparty na GNOME graficzny interfejs dla Beagle.
238
239 %package startup
240 Summary:        Automatic startup integration for Beagle
241 Summary(pl):    Integracja funkcji automatycznego startu Beagle
242 Group:          X11/Applications
243 Requires:       %{name} = %{version}-%{release}
244 Obsoletes:      beagle-gnome
245
246 %description startup
247 Automatic session startup integration for Beagle.
248
249 %description startup -l pl
250 Integracja funkcji automatycznego startu Beagle.
251
252 %prep
253 %setup -q
254 %patch0 -p1
255 %patch1 -p1
256 %patch2 -p1
257 %patch3 -p1
258 %patch4 -p1
259
260 %build
261 %{__libtoolize}
262 %{__aclocal}
263 %{__autoconf}
264 %{__automake}
265 %configure \
266         --enable-static \
267         %{?with_apidocs:--enable-gtk-doc} \
268         --with-html-dir=%{_gtkdocdir} \
269         --%{!?with_epiphany:dis}%{?with_epiphany:en}able-epiphany-extension \
270         --%{!?with_evolution:dis}%{?with_evolution:en}able-evolution-sharp \
271         --%{!?with_gui:dis}%{?with_gui:en}able-gui \
272         --%{!?with_thunderbird:dis}%{?with_thunderbird:en}able-thunderbird
273
274 %{__make} \
275         MOZILLA_HOME=%{_libdir}/mozilla \
276         pythondir=%{py_sitedir}
277
278 %install
279 rm -rf $RPM_BUILD_ROOT
280 install -d $RPM_BUILD_ROOT%{_var}/cache/beagle/indexes
281
282 %{__make} install \
283         DESTDIR=$RPM_BUILD_ROOT \
284         pythondir=%{py_sitedir}
285
286 dest=$RPM_BUILD_ROOT%{_datadir}/mozilla-firefox/extensions/\{fda00e13-8c62-4f63-9d19-d168115b11ca\}
287 install -d $dest $dest/chrome
288 install mozilla-extension/{chrome.manifest,install.rdf} $dest
289 install mozilla-extension/chrome/beagle.jar $dest/chrome
290
291 # Kill useless files
292 rm -f $RPM_BUILD_ROOT%{_libdir}/epiphany/2.16/extensions/*.{la,a} \
293         $RPM_BUILD_ROOT%{_libdir}/%{name}/*.la
294
295 rm -f $RPM_BUILD_ROOT%{py_sitedir}/*.{a,la}
296 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/*.{a,la}
297
298 rm -rf $RPM_BUILD_ROOT%{_datadir}/locale/no
299
300 %find_lang %{name}
301
302 %clean
303 rm -rf $RPM_BUILD_ROOT
304
305 %pre crawl-system
306 %groupadd -g 166 -r -f beagleindex
307 %useradd -u 166 -r -d /var/cache/beagle -s /bin/false -c "Beagle indexing" -g beagleindex beagleindex
308
309 %postun crawl-system
310 if [ "$1" = "0" ]; then
311         %userremove beagleindex
312         %groupremove beagleindex
313 fi
314
315 %post   libs -p /sbin/ldconfig
316 %postun libs -p /sbin/ldconfig
317
318 %files -f %{name}.lang
319 %defattr(644,root,root,755)
320 %doc AUTHORS COPYING ChangeLog NEWS README
321 %attr(755,root,root) %{_bindir}/beagle-config
322 %attr(755,root,root) %{_bindir}/beagled
323 %attr(755,root,root) %{_bindir}/beagle-doc-extractor
324 %attr(755,root,root) %{_bindir}/beagle-exercise-file-system
325 %attr(755,root,root) %{_bindir}/beagle-extract-content
326 %attr(755,root,root) %{_bindir}/beagle-index-info
327 %attr(755,root,root) %{_bindir}/beagle-index-url
328 %attr(755,root,root) %{_bindir}/beagle-info
329 %attr(755,root,root) %{_bindir}/beagle-ping
330 %attr(755,root,root) %{_bindir}/beagle-query
331 %attr(755,root,root) %{_bindir}/beagle-shutdown
332 %attr(755,root,root) %{_bindir}/beagle-status
333 %attr(755,root,root) %{_libdir}/%{name}/libbeagleglue.so*
334 %attr(755,root,root) %{_libdir}/%{name}/*.exe
335 %dir %{_libdir}/%{name}
336 %dir %{_libdir}/%{name}/Backends
337 %dir %{_libdir}/%{name}/Filters
338 %{_libdir}/%{name}/*.dll
339 %{_libdir}/%{name}/*.dll.config
340 %{_libdir}/%{name}/Filters/*.dll
341 %attr(755,root,root) %{_libdir}/%{name}/beagled-index-helper
342 %{_mandir}/man*/*
343
344 %files libs
345 %defattr(644,root,root,755)
346 %attr(755,root,root) %{_libdir}/lib*.so.*.*.*
347
348 %files devel
349 %defattr(644,root,root,755)
350 %attr(755,root,root) %{_libdir}/*.so
351 %{_includedir}/libbeagle
352 %{_libdir}/*.la
353 %{_pkgconfigdir}/*
354
355 %files static
356 %defattr(644,root,root,755)
357 %{_libdir}/*.a
358
359 %if %{with apidocs}
360 %files apidocs
361 %defattr(644,root,root,755)
362 %{_gtkdocdir}/beagle
363 %endif
364
365 %files crawl-system
366 %defattr(644,root,root,755)
367 %attr(750,root,crontab) %config(noreplace) %verify(not md5 mtime size) /etc/cron.daily/*
368 %dir %{_sysconfdir}/beagle
369 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/beagle/*
370 %dir %attr(755,beagleindex,beagleindex) %{_var}/cache/beagle
371 %dir %attr(755,beagleindex,beagleindex) %{_var}/cache/beagle/indexes
372 %attr(755,root,root) %{_sbindir}/*
373
374 %if %{with evolution}
375 %files evolution
376 %defattr(644,root,root,755)
377 %{_libdir}/%{name}/Backends/Evolution*.dll
378 %endif
379
380 %if %{with thunderbird}
381 %files thunderbird
382 %defattr(644,root,root,755)
383 %attr(755,root,root) %{_bindir}/beagle-contactviewer
384 %{_libdir}/%{name}/Backends/Thunderbird*.dll
385 %endif
386
387 %files -n mozilla-firefox-extension-beagle
388 %defattr(644,root,root,755)
389 %{_datadir}/mozilla-firefox/extensions/{fda00e13-8c62-4f63-9d19-d168115b11ca}
390
391 %if %{with epiphany}
392 %files -n epiphany-extension-beagle
393 %defattr(644,root,root,755)
394 %doc epiphany-extension/README
395 %attr(755,root,root) %{_libdir}/epiphany/2.16/extensions/libbeagleextension.so*
396 %{_libdir}/epiphany/2.16/extensions/*.xml
397 %endif
398
399 %if %{with python}
400 %files -n python-%{name}
401 %defattr(644,root,root,755)
402 %attr(755,root,root) %{py_sitedir}/*.so
403 %endif
404
405 %if %{with gui}
406 %files search-gui
407 %defattr(644,root,root,755)
408 %attr(755,root,root) %{_bindir}/beagle-imlogviewer
409 %attr(755,root,root) %{_bindir}/beagle-search
410 %attr(755,root,root) %{_bindir}/beagle-settings
411 %attr(755,root,root) %{_libdir}/%{name}/libbeagleuiglue.so*
412 %{_pixmapsdir}/*.png
413 %{_desktopdir}/*.desktop
414 %endif
415
416 %files startup
417 %defattr(644,root,root,755)
418 %{_sysconfdir}/xdg/autostart/beagled-autostart.desktop
419 %{_sysconfdir}/xdg/autostart/beagle-search-autostart.desktop
This page took 0.047311 seconds and 2 git commands to generate.