]> git.pld-linux.org Git - packages/avahi.git/blob - avahi.spec
- added destdir fix, fixed R: in compat-*-static (thx pluto), rel.3
[packages/avahi.git] / avahi.spec
1 #
2 # Conditional build:
3 %bcond_without  dotnet          # build with dotnet bindings
4 %bcond_without  qt              # build with qt bindings
5 #
6 %include /usr/lib/rpm/macros.mono
7 #
8 Summary:        Free mDNS/DNS-SD implementation
9 Summary(pl):    Wolna implementacja mDNS/DNS-SD
10 Name:           avahi
11 Version:        0.6.9
12 Release:        3
13 License:        GPL v.2/LGPL
14 Group:          Applications
15 Source0:        http://avahi.org/download/%{name}-%{version}.tar.gz
16 # Source0-md5:  2652910f0e52c373d7a15b6851750517
17 Source1:        %{name}-daemon
18 Source2:        %{name}-dnsconfd
19 Source3:        %{name}.png
20 Patch0:         %{name}-desktop.patch
21 Patch1:         %{name}-glade.patch
22 Patch2:         %{name}-destdir.patch
23 URL:            http://avahi.org/
24 BuildRequires:  autoconf
25 BuildRequires:  automake
26 BuildRequires:  dbus-devel >= 0.34
27 BuildRequires:  doxygen
28 BuildRequires:  expat-devel
29 BuildRequires:  gdbm-devel
30 BuildRequires:  glib2-devel >= 1:2.4.0
31 BuildRequires:  graphviz
32 BuildRequires:  gtk+2-devel >= 2:2.4.0
33 BuildRequires:  libdaemon-devel >= 0.5
34 BuildRequires:  libglade2-devel >= 2.4.0
35 BuildRequires:  libtool
36 %if %{with dotnet}
37 BuildRequires:  mono
38 BuildRequires:  monodoc
39 %endif
40 BuildRequires:  python-dbus
41 BuildRequires:  python-pygtk-devel
42 %if %{with qt}
43 BuildRequires:  qt-devel >= 3.0
44 %endif
45 BuildRequires:  rpmbuild(macros) >= 1.228
46 Requires(post,preun):   /sbin/chkconfig
47 Requires:       dbus >= 0.60-2
48 Requires:       %{name}-libs = %{version}-%{release}
49 Provides:       group(avahi)
50 Provides:       user(avahi)
51 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
52
53 %description
54 Avahi is an implementation the DNS Service Discovery and Multicast DNS
55 specifications for Zeroconf Computing. It uses D-BUS for communication
56 between user applications and a system daemon.
57
58 %description -l pl
59 Avahi jest implementacj± specyfikacji DNS Service Discovery i
60 Multicast DNS dla Zeroconf Computing. U¿ywa D-BUSa dla komunikacji
61 pomiêdzy programami u¿ytkownika a demonem systemowym.
62
63 %package libs
64 Summary:        Avahi client, common and core libraries
65 Summary(pl):    Biblioteki Avahi: klienta, wspólna i g³ówna
66 Group:          Libraries
67
68 %description libs
69 Avahi client, common and core libraries.
70
71 %description libs -l pl
72 Biblioteki Avahi: klienta, wspólna i g³ówna.
73
74 %package devel
75 Summary:        Header files for Avahi library
76 Summary(pl):    Pliki nag³ówkowe biblioteki Avahi
77 Group:          Development/Libraries
78 Requires:       %{name}-libs = %{version}-%{release}
79 Requires:       expat-devel
80 Requires:       libdaemon-devel >= 0.5
81
82 %description devel
83 This is the package containing the header files for Avahi library.
84
85 %description devel -l pl
86 Ten pakiet zawiera pliki nag³ówkowe biblioteki Avahi.
87
88 %package static
89 Summary:        Static Avahi library
90 Summary(pl):    Statyczna biblioteka Avahi
91 Group:          Development/Libraries
92 Requires:       %{name}-devel = %{version}-%{release}
93
94 %description static
95 Static Avahi library.
96
97 %description static -l pl
98 Statyczna biblioteka Avahi.
99
100 %package compat-libdns_sd
101 Summary:        Avahi Bonjour compat library
102 Summary(pl):    Biblioteka Avahi zgodna z Bonjour
103 Group:          Libraries
104 Provides:       mdns-bonjour
105 Obsoletes:      mDNSResponder-libs
106
107 %description compat-libdns_sd
108 Avahi Bonjour compat library.
109
110 %description compat-libdns_sd -l pl
111 Biblioteka Avahi zgodna z Bonjour.
112
113 %package compat-libdns_sd-devel
114 Summary:        Header files for Avahi Bonjour compat library
115 Summary(pl):    Pliki nag³ówkowe wi±zañ Avahi dla biblioteki zgodnej z Bonjour
116 Group:          Development/Libraries
117 Requires:       %{name}-compat-libdns_sd = %{version}-%{release}
118 Provides:       mdns-bonjour-devel
119 Obsoletes:      mDNSResponder-devel
120
121 %description compat-libdns_sd-devel
122 Header files for Avahi Bonjour compat library.
123
124 %description compat-libdns_sd-devel -l pl
125 Pliki nag³ówkowe wi±zañ Avahi dla biblioteki zgodnej z Bonjour.
126
127 %package compat-libdns_sd-static
128 Summary:        Static Avahi Bonjour compat library
129 Summary(pl):    Statyczna biblioteka Avahi zgodna z Bonjour
130 Group:          Development/Libraries
131 Requires:       %{name}-compat-libdns_sd-devel = %{version}-%{release}
132 Provides:       mdns-bonjour-static
133
134 %description compat-libdns_sd-static
135 Static Avahi Bonjour compat library.
136
137 %description compat-libdns_sd-static -l pl
138 Statyczna biblioteka Avahi zgodna z Bonjour.
139
140 %package compat-howl
141 Summary:        Avahi Howl compat library
142 Summary(pl):    Biblioteka Avahi zgodna z Howl
143 Group:          Libraries
144 Provides:       mdns-howl-libs
145 Obsoletes:      howl-libs
146
147 %description compat-howl
148 Avahi Howl compat library.
149
150 %description compat-howl -l pl
151 Biblioteka Avahi zgodna z Howl.
152
153 %package compat-howl-devel
154 Summary:        Header files for Avahi Howl compat library
155 Summary(pl):    Pliki nag³ówkowe wi±zañ Avahi dla biblioteki zgodnej z Howl
156 Group:          Development/Libraries
157 Requires:       %{name}-compat-howl = %{version}-%{release}
158 Provides:       mdns-howl-devel
159 Obsoletes:      howl-devel
160
161 %description compat-howl-devel
162 Header files for Avahi Howl compat library.
163
164 %description compat-howl-devel -l pl
165 Pliki nag³ówkowe wi±zañ Avahi dla biblioteki zgodnej z Howl.
166
167 %package compat-howl-static
168 Summary:        Static Avahi Howl compat library
169 Summary(pl):    Statyczna biblioteka Avahi zgodna z Howl
170 Group:          Development/Libraries
171 Requires:       %{name}-compat-howl-devel = %{version}-%{release}
172 Provides:       mdns-howl-static
173 Obsoletes:      howl-static
174
175 %description compat-howl-static
176 Static Avahi Howl compat library.
177
178 %description compat-howl-static -l pl
179 Statyczna biblioteka Avahi zgodna z Howl.
180
181 %package glib
182 Summary:        Avahi GLib library bindings
183 Summary(pl):    Wi±zania Avahi dla bibioteki GLib
184 Group:          Libraries
185
186 %description glib
187 Avahi GLib library bindings.
188
189 %description glib -l pl
190 Wi±zania Avahi dla bibioteki GLib.
191
192 %package glib-devel
193 Summary:        Header files for Avahi GLib library bindings
194 Summary(pl):    Pliki nag³ówkowe wi±zañ Avahi dla biblioteki GLib
195 Group:          Development/Libraries
196 Requires:       %{name}-devel = %{version}-%{release}
197 Requires:       %{name}-glib = %{version}-%{release}
198 Requires:       glib2-devel >= 1:2.4.0
199
200 %description glib-devel
201 This is the package containing the header files for Avahi-glib
202 library.
203
204 %description glib-devel -l pl
205 Ten pakiet zawiera pliki nag³ówkowe biblioteki Avahi-glib.
206
207 %package glib-static
208 Summary:        Static Avahi GLib library
209 Summary(pl):    Statyczna biblioteka Avahi GLib
210 Group:          Development/Libraries
211 Requires:       %{name}-glib-devel = %{version}-%{release}
212
213 %description glib-static
214 Static Avahi GLib library.
215
216 %description glib-static -l pl
217 Statyczna biblioteka Avahi GLib.
218
219 %package qt3
220 Summary:        Avahi Qt 3 library bindings
221 Summary(pl):    Wi±zania Avahi dla biblioteki Qt 3
222 Group:          Libraries
223 Requires:       %{name}-libs = %{version}-%{release}
224
225 %description qt3
226 Avahi Qt 3 library bindings.
227
228 %description qt3 -l pl
229 Wi±zania Avahi dla biblioteki Qt 3.
230
231 %package qt3-devel
232 Summary:        Header files for Avahi Qt 3 library bindings
233 Summary(pl):    Pliki nag³ówkowe wi±zañ Avahi dla biblioteki Qt 3
234 Group:          Development/Libraries
235 Requires:       %{name}-devel = %{version}-%{release}
236 Requires:       %{name}-qt3 = %{version}-%{release}
237 Requires:       qt-devel >= 3.0
238
239 %description qt3-devel
240 Header files for Avahi Qt 3 library bindings.
241
242 %description qt3-devel -l pl
243 Pliki nag³ówkowe wi±zañ Avahi dla biblioteki Qt 3.
244
245 %package qt3-static
246 Summary:        Static Avahi Qt 3 library
247 Summary(pl):    Statyczna biblioteka Avahi Qt 3
248 Group:          Development/Libraries
249 Requires:       %{name}-qt3-devel = %{version}-%{release}
250
251 %description qt3-static
252 Static Avahi Qt 3 library.
253
254 %description qt3-static -l pl
255 Statyczna biblioteka Avahi Qt 3.
256
257 %package -n dotnet-avahi
258 Summary:        Avahi MONO bindings
259 Summary(pl):    Wi±zania Avahi dla MONO
260 Group:          Libraries
261
262 %description -n dotnet-avahi
263 Avahi MONO bindings.
264
265 %description -n dotnet-avahi -l pl
266 Wi±zania Avahi dla MONO.
267
268 %package -n dotnet-avahi-devel
269 Summary:        Development files for MONO Avahi bindings
270 Summary(pl):    Pliki rozwojowe wi±zañ Avahi dla MONO
271 Group:          Development/Libraries
272 Requires:       dotnet-avahi = %{version}-%{release}
273 Requires:       monodoc
274
275 %description -n dotnet-avahi-devel
276 Development files for MONO Avahi bindings.
277
278 %description -n dotnet-avahi-devel -l pl
279 Pliki rozwojowe wi±zañ Avahi dla MONO.
280
281 %package bookmarks
282 Summary:        Miniature web server
283 Summary(pl):    Miniaturowy serwer web
284 Group:          Applications
285
286 %description bookmarks
287 A Python based miniature web server that browses for mDNS/DNS-SD
288 services of type '_http._tcp' (i.e. web sites) and makes them
289 available as HTML links on http://localhost:8080/.
290
291 %description bookmarks -l pl
292 Napisany w Pythonie miniaturowy serwer WWW, pozwalaj±cy na
293 przegl±danie us³ug typu '_http._tcp' (np. stron WWW) i udostêpniaj±cy
294 je jako odno¶niki HTML na http://localhost:8080/.
295
296 %package discover
297 Summary:        Avahi Zeroconf browser
298 Summary(pl):    Przegl±darka Zeroconf Avahi
299 Group:          Applications
300
301 %description discover
302 A tool for enumerating all available services on the local LAN
303 (python-pygtk implementation).
304
305 %description discover -l pl
306 Narzêdzie wymieniaj±ce wszystkie dostêpne us³ugi w sieci lokalnej LAN
307 (implementacja w python-pygtk).
308
309 %package discover-standalone
310 Summary:        Avahi Zeroconf browser
311 Summary(pl):    Przegl±darka Zeroconf Avahi
312 Group:          Applications
313
314 %description discover-standalone
315 GTK+ tool for enumerating all available services on the local LAN.
316
317 %description discover-standalone -l pl
318 Narzêdzie GTK+ wymieniaj±ce wszystkie dostêpne us³ugi w sieci lokalnej
319 LAN.
320
321 %package utils
322 Summary:        Avahi CLI utilities
323 Summary(pl):    Narzêdzia CLI Avahi
324 Group:          Applications
325
326 %description utils
327 Command line utilities using avahi-client.
328
329 %description utils -l pl
330 Narzêdzia linii poleceñ korzystaj±ce z avahi-client.
331
332 %prep
333 %setup -q
334 %patch0 -p1
335 %patch1 -p1
336 %patch2 -p1
337
338 %build
339 %{__libtoolize}
340 %{__aclocal} -I common
341 %{__autoconf}
342 %{__autoheader}
343 %{__automake}
344 %configure \
345         --enable-compat-libdns_sd \
346         --enable-compat-howl \
347         --with-distro=none \
348         --disable-qt4 \
349         %{!?with_qt:--disable-qt3} \
350         %{!?with_dotnet:--disable-mono} \
351         %{!?with_dotnet:--disable-monodoc}
352 %{__make}
353
354 %install
355 rm -rf $RPM_BUILD_ROOT
356 install -d $RPM_BUILD_ROOT{%{_pixmapsdir},/etc/rc.d/init.d}
357
358 %{__make} install \
359         DESTDIR=$RPM_BUILD_ROOT \
360         pythondir=%{py_sitedir}
361
362 install %{SOURCE1} %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d
363 install %{SOURCE3} $RPM_BUILD_ROOT%{_pixmapsdir}
364
365 ln -sf %{_includedir}/avahi-compat-libdns_sd/dns_sd.h \
366         $RPM_BUILD_ROOT%{_includedir}/dns_sd.h
367
368 ln -sf %{_pkgconfigdir}/avahi-compat-howl.pc \
369         $RPM_BUILD_ROOT%{_pkgconfigdir}/howl.pc
370
371 rm -f $RPM_BUILD_ROOT%{py_sitedir}/avahi/{__init__,SimpleGladeApp}.py
372
373 %clean
374 rm -rf $RPM_BUILD_ROOT
375
376 %pre
377 %groupadd -g 165 -r -f avahi
378 %useradd -u 165 -r -d /usr/share/empty -s /bin/false -c "Avahi daemon" -g avahi avahi
379
380 %post
381 /sbin/chkconfig --add %{name}-daemon
382 %service %{name}-daemon restart
383 /sbin/chkconfig --add %{name}-dnsconfd
384 %service %{name}-dnsconfd restart
385
386 %preun
387 if [ "$1" = "0" ]; then
388         %service -q %{name}-dnsconfd stop
389         /sbin/chkconfig --del %{name}-dnsconfd
390         %service -q %{name}-daemon stop
391         /sbin/chkconfig --del %{name}-daemon
392 fi
393
394 %postun
395 if [ "$1" = "0" ]; then
396         %userremove avahi
397         %groupremove avahi
398 fi
399
400 %post   libs -p /sbin/ldconfig
401 %postun libs -p /sbin/ldconfig
402
403 %post   compat-libdns_sd -p /sbin/ldconfig
404 %postun compat-libdns_sd -p /sbin/ldconfig
405
406 %post   compat-howl -p /sbin/ldconfig
407 %postun compat-howl -p /sbin/ldconfig
408
409 %post   glib -p /sbin/ldconfig
410 %postun glib -p /sbin/ldconfig
411
412 %post   qt3 -p /sbin/ldconfig
413 %postun qt3 -p /sbin/ldconfig
414
415 %files
416 %defattr(644,root,root,755)
417 %doc docs/AUTHORS docs/COMPAT-LAYERS docs/NEWS docs/README docs/TODO
418
419 %dir %{_sysconfdir}/avahi
420 %dir %{_sysconfdir}/avahi/services
421 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/avahi/avahi-daemon.conf
422 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/avahi/avahi-dnsconfd.action
423 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/avahi/hosts
424 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/avahi/services/ssh.service
425 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/dbus-1/system.d/*
426
427 %attr(755,root,root) %{_bindir}/avahi-browse
428 %attr(755,root,root) %{_bindir}/avahi-publish
429 %attr(755,root,root) %{_bindir}/avahi-resolve
430
431 %attr(755,root,root) %{_sbindir}/avahi-daemon
432 %attr(755,root,root) %{_sbindir}/avahi-dnsconfd
433
434 %dir %{_datadir}/%{name}
435 %dir %{_datadir}/%{name}/introspection
436 %{_datadir}/%{name}/introspection/*.introspect
437 %{_datadir}/%{name}/avahi-service.dtd
438 %{_datadir}/%{name}/service-types
439 %{_datadir}/%{name}/service-types.db
440
441 %{_mandir}/man*/*
442
443 %attr(754,root,root) /etc/rc.d/init.d/%{name}-daemon
444 %attr(754,root,root) /etc/rc.d/init.d/%{name}-dnsconfd
445
446 %files libs
447 %defattr(644,root,root,755)
448 %attr(755,root,root) %{_libdir}/libavahi-client.so.*.*.*
449 %attr(755,root,root) %{_libdir}/libavahi-common.so.*.*.*
450 %attr(755,root,root) %{_libdir}/libavahi-core.so.*.*.*
451
452 %files devel
453 %defattr(644,root,root,755)
454 %doc docs/API-CHANGES-0.6 docs/DBUS-API docs/HACKING docs/MALLOC
455 %attr(755,root,root) %{_libdir}/libavahi-client.so
456 %attr(755,root,root) %{_libdir}/libavahi-common.so
457 %attr(755,root,root) %{_libdir}/libavahi-core.so
458 %{_libdir}/libavahi-client.la
459 %{_libdir}/libavahi-common.la
460 %{_libdir}/libavahi-core.la
461 %{_includedir}/avahi-client
462 %{_includedir}/avahi-common
463 %{_includedir}/avahi-core
464 %{_pkgconfigdir}/avahi-client.pc
465 %{_pkgconfigdir}/avahi-core.pc
466
467 %files static
468 %defattr(644,root,root,755)
469 %{_libdir}/libavahi-client.a
470 %{_libdir}/libavahi-common.a
471 %{_libdir}/libavahi-core.a
472
473 %files compat-libdns_sd
474 %defattr(644,root,root,755)
475 %attr(755,root,root) %{_libdir}/libdns_sd.so.*.*.*
476
477 %files compat-libdns_sd-devel
478 %defattr(644,root,root,755)
479 %attr(755,root,root) %{_libdir}/libdns_sd.so
480 %{_libdir}/libdns_sd.la
481 %{_includedir}/avahi-compat-libdns_sd
482 %{_includedir}/dns_sd.h
483 %{_pkgconfigdir}/avahi-compat-libdns_sd.pc
484
485 %files compat-libdns_sd-static
486 %defattr(644,root,root,755)
487 %{_libdir}/libdns_sd.a
488
489 %files compat-howl
490 %defattr(644,root,root,755)
491 %attr(755,root,root) %{_libdir}/libhowl.so.*.*.*
492
493 %files compat-howl-devel
494 %defattr(644,root,root,755)
495 %attr(755,root,root) %{_libdir}/libhowl.so
496 %{_libdir}/libhowl.la
497 %{_includedir}/avahi-compat-howl
498 %{_pkgconfigdir}/avahi-compat-howl.pc
499 %{_pkgconfigdir}/howl.pc
500
501 %files compat-howl-static
502 %defattr(644,root,root,755)
503 %{_libdir}/libhowl.a
504
505 %if %{with dotnet}
506 %files -n dotnet-avahi
507 %defattr(644,root,root,755)
508 %{_prefix}/lib/mono/gac/avahi-sharp
509
510 %files -n dotnet-avahi-devel
511 %defattr(644,root,root,755)
512 %{_prefix}/lib/monodoc/sources/avahi-*
513 %{_pkgconfigdir}/*.pc
514 %endif
515
516 %files glib
517 %defattr(644,root,root,755)
518 %attr(755,root,root) %{_libdir}/libavahi-glib.so.*.*.*
519
520 %files glib-devel
521 %defattr(644,root,root,755)
522 %attr(755,root,root) %{_libdir}/libavahi-glib.so
523 %{_libdir}/libavahi-glib.la
524 %{_includedir}/avahi-glib
525 %{_pkgconfigdir}/avahi-glib.pc
526
527 %files glib-static
528 %defattr(644,root,root,755)
529 %{_libdir}/libavahi-glib.a
530
531 %if %{with qt}
532 %files qt3
533 %defattr(644,root,root,755)
534 %attr(755,root,root) %{_libdir}/libavahi-qt3.so.*.*.*
535
536 %files qt3-devel
537 %defattr(644,root,root,755)
538 %attr(755,root,root) %{_libdir}/libavahi-qt3.so
539 %{_libdir}/libavahi-qt3.la
540 %{_includedir}/avahi-qt3
541 %{_pkgconfigdir}/avahi-qt3.pc
542
543 %files qt3-static
544 %defattr(644,root,root,755)
545 %{_libdir}/libavahi-qt3.a
546 %endif
547
548 %files bookmarks
549 %defattr(644,root,root,755)
550 %attr(755,root,root) %{_bindir}/avahi-bookmarks
551
552 %files discover
553 %defattr(644,root,root,755)
554 %attr(755,root,root) %{_bindir}/avahi-discover
555 # XXX: possibly missing %{_datadir}/%{name} dir, shared subdir
556 %dir %{_datadir}/%{name}/interfaces
557 %{_datadir}/%{name}/interfaces/avahi-discover.glade
558 %{py_sitedir}/avahi
559 %{_desktopdir}/*.desktop
560 %{_pixmapsdir}/avahi.png
561
562 %files discover-standalone
563 %defattr(644,root,root,755)
564 %attr(755,root,root) %{_bindir}/avahi-discover-standalone
565 # XXX: possibly missing %{_datadir}/%{name} dir, shared subdir
566 %dir %{_datadir}/%{name}/interfaces
567 %{_datadir}/%{name}/interfaces/avahi-discover-standalone.glade
568
569 %files utils
570 %defattr(644,root,root,755)
571 %attr(755,root,root) %{_bindir}/avahi-browse
572 %attr(755,root,root) %{_bindir}/avahi-publish
573 %attr(755,root,root) %{_bindir}/avahi-resolve
This page took 0.072671 seconds and 4 git commands to generate.