Update to avahi 0.6.20

This commit is contained in:
Lennart Poettering 2007-06-25 13:21:10 +00:00
parent 3799991c11
commit 468e64819f
2 changed files with 173 additions and 76 deletions

View File

@ -5,18 +5,17 @@
%define WITH_MONO 0 %define WITH_MONO 0
%endif %endif
Name: avahi Name: avahi
Version: 0.6.17 Version: 0.6.20
Release: 1%{?dist} Release: 1%{?dist}
Summary: Local network service discovery Summary: Local network service discovery
Group: System Environment/Base Group: System Environment/Base
License: LGPL License: LGPL
URL: http://avahi.org URL: http://avahi.org
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Requires: dbus, libdaemon, expat, python, dbus-python, libcap Requires: dbus, expat, python, dbus-python
Requires: libdaemon >= 0.11
Requires(post): initscripts, chkconfig, ldconfig Requires(post): initscripts, chkconfig, ldconfig
# BuildRequires: autoconf Requires(pre): shadow-utils
# BuildRequires: automake
# BuildRequires: libtool
BuildRequires: dbus-devel >= 0.90 BuildRequires: dbus-devel >= 0.90
BuildRequires: dbus-glib-devel >= 0.70 BuildRequires: dbus-glib-devel >= 0.70
BuildRequires: dbus-python BuildRequires: dbus-python
@ -24,7 +23,7 @@ BuildRequires: libxml2-python
BuildRequires: gtk2-devel BuildRequires: gtk2-devel
BuildRequires: qt-devel BuildRequires: qt-devel
BuildRequires: libglade2-devel BuildRequires: libglade2-devel
BuildRequires: libdaemon-devel BuildRequires: libdaemon-devel >= 0.11
BuildRequires: glib2-devel BuildRequires: glib2-devel
BuildRequires: libcap-devel BuildRequires: libcap-devel
BuildRequires: expat-devel BuildRequires: expat-devel
@ -34,15 +33,10 @@ BuildRequires: pygtk2
%if %{WITH_MONO} %if %{WITH_MONO}
BuildRequires: mono-devel >= 1.1.13 BuildRequires: mono-devel >= 1.1.13
%endif %endif
Obsoletes: howl Obsoletes: howl
Source0: %{name}-%{version}.tar.gz Source0: %{name}-%{version}.tar.gz
# enable mono's mcs to work in beehive buildroot: # enable mono's mcs to work in beehive buildroot:
Patch6: avahi-0.6.3-MONO_SHARED_DIR.patch Patch6: avahi-0.6.3-MONO_SHARED_DIR.patch
Patch14: avahi-0.6.9-bz189427.patch
Patch17: avahi-0.6.11-use-ipv6-yes.patch
Patch20: avahi-0.6.15-initscript.patch
Patch21: avahi-0.6.17-exitcode.patch
%description %description
Avahi is a system which facilitates service discovery on Avahi is a system which facilitates service discovery on
@ -56,7 +50,7 @@ convenient.
%package tools %package tools
Summary: Tools for mDNS browsing and publishing Summary: Tools for mDNS browsing and publishing
Group: System Environment/Base Group: System Environment/Base
Requires: %{name} = %{version}, gtk2, pygtk2, libglade2, pygtk2-libglade, gdbm Requires: %{name} = %{version}, gtk2, pygtk2, pygtk2-libglade, gdbm
%description tools %description tools
Tools that use avahi to browse and publish mDNS services and hosts. Tools that use avahi to browse and publish mDNS services and hosts.
@ -81,6 +75,24 @@ Requires: glib2-devel
The avahi-devel package contains the header files and libraries The avahi-devel package contains the header files and libraries
necessary for developing programs using avahi with glib. necessary for developing programs using avahi with glib.
%package ui
Summary: Gtk user interface library for Avahi
Group: System Environment/Base
Requires: gtk2
%description ui
This library contains a Gtk widget for browsing services.
%package ui-devel
Summary: Libraries and header files for Avahi UI development
Group: Development/Libraries
Requires: %{name}-devel = %{version}
Requires: %{name}-ui = %{version}
%description ui-devel
The avahi-ui-devel package contains the header files and libraries
necessary for developing programs using avahi-ui.
%package qt3 %package qt3
Summary: Qt3 libraries for avahi Summary: Qt3 libraries for avahi
Group: System Environment/Base Group: System Environment/Base
@ -104,13 +116,23 @@ necessary for developing programs using avahi with Qt3.
%if %{WITH_MONO} %if %{WITH_MONO}
%package sharp %package sharp
Summary: Mono language bindings for avahi mono development Summary: Mono language bindings for avahi mono development
Group: Development/Libraries Group: Development/Libraries
Requires: mono-core >= 1.1.13 Requires: mono-core >= 1.1.13
%description sharp %description sharp
The avahi-sharp package contains the files needed to develop The avahi-sharp package contains the files needed to develop
mono programs that use avahi. mono programs that use avahi.
%endif
%package ui-sharp
Summary: Mono language bindings for avahi-ui mono development
Group: Development/Libraries
Requires: mono-core >= 1.1.13
Requires: gtk-sharp2
%description ui-sharp
The avahi-sharp package contains the files needed to develop
mono programs that use avahi-ui.
%%endif
%package devel %package devel
Summary: Libraries and header files for avahi development Summary: Libraries and header files for avahi development
@ -122,25 +144,27 @@ The avahi-devel package contains the header files and libraries
necessary for developing programs using avahi. necessary for developing programs using avahi.
%package compat-howl %package compat-howl
Summary: Libraries for howl compatibility. Summary: Libraries for howl compatibility
Group: Development/Libraries Group: Development/Libraries
Requires: %{name} = %{version} Requires: %{name} = %{version}
Obsoletes: howl-libs Obsoletes: howl-libs
Provides: howl-libs
%description compat-howl %description compat-howl
Libraries that are compatible with those provided by the howl package. Libraries that are compatible with those provided by the howl package.
%package compat-howl-devel %package compat-howl-devel
Summary: Header files for development with the howl compatibility libraries. Summary: Header files for development with the howl compatibility libraries
Group: Development/Libraries Group: Development/Libraries
Requires: avahi-compat-howl = %{version} Requires: avahi-compat-howl = %{version}
Obsoletes: howl-devel Obsoletes: howl-devel
Provides: howl-devel
%description compat-howl-devel %description compat-howl-devel
Header files for development with the howl compatibility libraries. Header files for development with the howl compatibility libraries.
%package compat-libdns_sd %package compat-libdns_sd
Summary: Libraries for Apple Bonjour mDNSResponder compatibility. Summary: Libraries for Apple Bonjour mDNSResponder compatibility
Group: Development/Libraries Group: Development/Libraries
Requires: %{name} = %{version} Requires: %{name} = %{version}
@ -148,38 +172,50 @@ Requires: %{name} = %{version}
Libraries for Apple Bonjour mDNSResponder compatibility. Libraries for Apple Bonjour mDNSResponder compatibility.
%package compat-libdns_sd-devel %package compat-libdns_sd-devel
Summary: Header files for development with the Apple Bonjour mDNSResponder compatibility libraries. Summary: Header files for the Apple Bonjour mDNSResponder compatibility libraries
Group: Development/Libraries Group: Development/Libraries
Requires: avahi-compat-libdns_sd = %{version} Requires: avahi-compat-libdns_sd = %{version}
%description compat-libdns_sd-devel %description compat-libdns_sd-devel
Header files for development with the Apple Bonjour mDNSResponder compatibility libraries. Header files for development with the Apple Bonjour mDNSResponder compatibility
libraries.
%define avahi_user_uid 70 %package autoipd
Summary: Link-local IPv4 address automatic configuration daemon (IPv4LL)
Group: System Environment/Base
%description autoipd
avahi-autoipd implements IPv4LL, "Dynamic Configuration of IPv4
Link-Local Addresses" (IETF RFC3927), a protocol for automatic IP address
configuration from the link-local 169.254.0.0/16 range without the need for a
central server. It is primarily intended to be used in ad-hoc networks which
lack a DHCP server.
%package dnsconfd
Summary: Configure local unicast DNS settings based on information published in mDNS
Group: System Environment/Base
Requires: %{name} = %{version}
%description dnsconfd
avahi-dnsconfd connects to a running avahi-daemon and runs the script
/etc/avahi/dnsconfd.action for each unicast DNS server that is announced on the
local LAN. This is useful for configuring unicast DNS servers in a DHCP-like
fashion with mDNS.
%prep %prep
%setup -q %setup -q
%if %{WITH_MONO} %if %{WITH_MONO}
%patch6 -p1 -b .MONO_SHARED_DIR %patch6 -p1 -b .MONO_SHARED_DIR
%endif %endif
%patch14 -p1 -b .bz189427
%patch17 -p1 -b .use-ipv6-yes
%patch20 -p1 -b .initscript
%patch21 -p1 -b .exitcode
%build %build
# auto* update needed for avahi-0.5.2-fedora.patch
# aclocal -I common
# libtoolize --force
# automake-1.10 --add-missing
# autoconf
%configure --with-distro=fedora --disable-qt4 --disable-monodoc --without-python-twisted --with-avahi-user=avahi --with-avahi-group=avahi --enable-compat-howl --with-avahi-priv-access-group=avahi\ %configure --with-distro=fedora --disable-qt4 --disable-monodoc --without-python-twisted --with-avahi-user=avahi --with-avahi-group=avahi --enable-compat-howl --with-avahi-priv-access-group=avahi --with-autoipd-user=avahi-autoipd --with-autoipd-group=avahi-autoipd \
%if %{WITH_COMPAT_DNSSD} %if %{WITH_COMPAT_DNSSD}
--enable-compat-libdns_sd \ --enable-compat-libdns_sd \
%endif %endif
%if ! %{WITH_MONO} %if ! %{WITH_MONO}
--disable-mono \ --disable-mono \
%endif %endif
; ;
make %{?_smp_mflags} make %{?_smp_mflags}
@ -199,6 +235,7 @@ rm -f $RPM_BUILD_ROOT%{_datadir}/applications/avahi-discover.desktop
# create /var/run/avahi-daemon to ensure correct selinux policy for it: # create /var/run/avahi-daemon to ensure correct selinux policy for it:
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/run/avahi-daemon mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/run/avahi-daemon
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/avahi-autoipd
# remove the documentation directory - let \%doc handle it: # remove the documentation directory - let \%doc handle it:
rm -rf $RPM_BUILD_ROOT%{_datadir}/%{name}-%{version} rm -rf $RPM_BUILD_ROOT%{_datadir}/%{name}-%{version}
@ -232,81 +269,113 @@ ln -s avahi-compat-libdns_sd/dns_sd.h $RPM_BUILD_ROOT/%{_includedir}/
rm -rf $RPM_BUILD_ROOT rm -rf $RPM_BUILD_ROOT
%pre %pre
# Add the "avahi" user /usr/sbin/groupadd -f -r avahi
/usr/sbin/useradd -c 'Avahi daemon' -u %{avahi_user_uid} \ /usr/bin/id avahi >/dev/null 2>&1 || \
-s /sbin/nologin -r -d '/' avahi 2> /dev/null || : /usr/sbin/useradd -r -g avahi -c 'avahi-daemon' -s /sbin/nologin -d %{_localstatedir}/run/avahi-daemon avahi
%post %post
/sbin/ldconfig /sbin/ldconfig
dbus-send --system --type=method_call --dest=org.freedesktop.DBus / org.freedesktop.DBus.ReloadConfig >/dev/null 2>&1 || :
# Run avahi-daemon by default: # Run avahi-daemon by default:
/sbin/chkconfig --add avahi-daemon >/dev/null 2>&1 || :; /sbin/chkconfig --add avahi-daemon >/dev/null 2>&1 || :
# avahi-dnsconfd NOT run by default in any runlevel; add it
# so system-config-services can see it
/sbin/chkconfig --add avahi-dnsconfd >/dev/null 2>&1 || :;
if [ "$1" -eq 1 ]; then if [ "$1" -eq 1 ]; then
# We should realy make dbus reload the system.d config here. Dunno how though.
# kill -HUP `cat /var/run/messagebus.pid` ?
if [ -s /etc/localtime ]; then if [ -s /etc/localtime ]; then
cp -cfp /etc/localtime /etc/avahi/etc/localtime || :; cp -cfp /etc/localtime /etc/avahi/etc/localtime || :
fi; fi
fi;
%postun
/sbin/ldconfig
if [ "$1" -ge "1" ]; then
/sbin/service avahi-daemon condrestart >/dev/null 2>&1
/sbin/service avahi-dnsconfd condrestart >/dev/null 2>&1
fi fi
%preun %preun
if [ "$1" -eq 0 ]; then if [ "$1" -eq 0 ]; then
service avahi-daemon stop > /dev/null 2>&1 /sbin/service avahi-daemon stop > /dev/null 2>&1 || :
/sbin/chkconfig --del avahi-daemon /sbin/chkconfig --del avahi-daemon
service avahi-dnsconfd stop >/dev/null 2>&1 fi
%postun
/sbin/ldconfig
if [ "$1" -ge "1" ]; then
/sbin/service avahi-daemon condrestart >/dev/null 2>&1 || :
fi
%pre autoipd
/usr/sbin/groupadd -f -r avahi-autoipd
/usr/bin/id avahi-autoipd >/dev/null 2>&1 || \
/usr/sbin/useradd -r -g avahi-autoipd -c 'avahi-autoipd' -s /sbin/nologin -d %{_localstatedir}/lib/avahi-autoipd avahi-autoipd
%post dnsconfd
# avahi-dnsconfd NOT run by default in any runlevel; add it
# so system-config-services can see it
/sbin/chkconfig --add avahi-dnsconfd >/dev/null 2>&1 || :
%preun dnsconfd
if [ "$1" -eq 0 ]; then
/sbin/service avahi-dnsconfd stop >/dev/null 2>&1 || :
/sbin/chkconfig --del avahi-dnsconfd /sbin/chkconfig --del avahi-dnsconfd
fi fi
%post glib -p /sbin/ldconfig %postun dnsconfd
if [ "$1" -ge "1" ]; then
/sbin/service avahi-dnsconfd condrestart >/dev/null 2>&1 || :
fi
%post glib -p /sbin/ldconfig
%postun glib -p /sbin/ldconfig %postun glib -p /sbin/ldconfig
%post qt3 -p /sbin/ldconfig %post compat-howl -p /sbin/ldconfig
%postun compat-howl -p /sbin/ldconfig
%post compat-libdns_sd -p /sbin/ldconfig
%postun compat-libdns_sd -p /sbin/ldconfig
%post qt3 -p /sbin/ldconfig
%postun qt3 -p /sbin/ldconfig %postun qt3 -p /sbin/ldconfig
%post ui -p /sbin/ldconfig
%postun ui -p /sbin/ldconfig
%files %files
%defattr(0644,root,root,0755) %defattr(0644,root,root,0755)
%doc docs/* avahi-daemon/example.service avahi-daemon/ssh.service %doc docs/* avahi-daemon/example.service avahi-daemon/ssh.service
%attr(755,root,root) %{_sysconfdir}/rc.d/init.d/* %attr(0755,root,root) %{_sysconfdir}/rc.d/init.d/avahi-daemon
%dir %{_sysconfdir}/avahi %dir %{_sysconfdir}/avahi
%dir %{_sysconfdir}/avahi/etc %dir %{_sysconfdir}/avahi/etc
%ghost %{_sysconfdir}/avahi/etc/localtime %ghost %{_sysconfdir}/avahi/etc/localtime
%{_sysconfdir}/avahi/hosts %config(noreplace) %{_sysconfdir}/avahi/hosts
%dir %{_sysconfdir}/avahi/services %dir %{_sysconfdir}/avahi/services
%attr(0755,avahi,avahi) %dir %{_localstatedir}/run/avahi-daemon %attr(0755,avahi,avahi) %dir %{_localstatedir}/run/avahi-daemon
%config %{_sysconfdir}/avahi/avahi-daemon.conf %config(noreplace) %{_sysconfdir}/avahi/avahi-daemon.conf
%config %{_sysconfdir}/avahi/avahi-dnsconfd.action %config(noreplace) %{_sysconfdir}/avahi/services/sftp-ssh.service
%config %{_sysconfdir}/avahi/avahi-autoipd.action %config(noreplace) %{_sysconfdir}/dbus-1/system.d/avahi-dbus.conf
%config %{_sysconfdir}/avahi/services/sftp-ssh.service %attr(0755,root,root) %{_sbindir}/avahi-daemon
%config %{_sysconfdir}/dbus-1/system.d/avahi-dbus.conf %attr(0755,root,root) %{_libdir}/libavahi-common.so.*
%attr(755,root,root) %{_sbindir}/* %attr(0755,root,root) %{_libdir}/libavahi-core.so.*
%attr(755,root,root) %{_libdir}/libavahi-common.so.* %attr(0755,root,root) %{_libdir}/libavahi-client.so.*
%attr(755,root,root) %{_libdir}/libavahi-core.so.* %{_datadir}/avahi
%attr(755,root,root) %{_libdir}/libavahi-client.so.*
%attr(755,root,root) %{_datadir}/avahi
%exclude %{_datadir}/avahi/interfaces %exclude %{_datadir}/avahi/interfaces
%exclude %{_datadir}/avahi/service-types*
%{_mandir}/man5/* %{_mandir}/man5/*
%{_mandir}/man8/* %{_mandir}/man8/avahi-daemon.*
%files autoipd
%defattr(0644,root,root,0755)
%attr(0755,root,root) %{_sbindir}/avahi-autoipd
%attr(0755,root,root) %config(noreplace) %{_sysconfdir}/avahi/avahi-autoipd.action
%{_mandir}/man8/avahi-autoipd.*
%files dnsconfd
%defattr(0644,root,root,0755)
%attr(0755,root,root) %{_sysconfdir}/rc.d/init.d/avahi-dnsconfd
%attr(0755,root,root) %config(noreplace) %{_sysconfdir}/avahi/avahi-dnsconfd.action
%attr(0755,root,root) %{_sbindir}/avahi-dnsconfd
%{_mandir}/man8/avahi-dnsconfd.*
%files tools %files tools
%defattr(0755, root, root, 0755) %defattr(0644, root, root, 0755)
%{_bindir}/* %attr(0755,root,root) %{_bindir}/*
# These are .py files only, so they don't go in lib64 # These are .py files only, so they don't go in lib64
%{_prefix}/lib/python?.?/site-packages/* %{_prefix}/lib/python?.?/site-packages/*
%attr(0644,root,root) %{_mandir}/man1/* %{_mandir}/man1/*
%{_datadir}/applications/b*.desktop
%{_datadir}/avahi/interfaces/ %{_datadir}/avahi/interfaces/
%{_datadir}/avahi/service-types* %exclude %{_bindir}/avahi-discover-standalone
%files devel %files devel
%defattr(0644, root, root, 0755) %defattr(0644, root, root, 0755)
@ -329,15 +398,25 @@ fi
%{_includedir}/avahi-glib %{_includedir}/avahi-glib
%{_libdir}/pkgconfig/avahi-glib.pc %{_libdir}/pkgconfig/avahi-glib.pc
%files ui
%defattr(0755, root, root, 0755)
%{_libdir}/libavahi-ui.so.*
%files ui-devel
%defattr(0644, root, root, 0755)
%attr(755,root,root) %{_libdir}/libavahi-ui.so
%{_includedir}/avahi-ui
%{_libdir}/pkgconfig/avahi-ui.pc
%files qt3 %files qt3
%defattr(0644, root, root, 0755) %defattr(0644, root, root, 0755)
%attr(755,root,root) %{_libdir}/libavahi-qt3.so.* %attr(755,root,root) %{_libdir}/libavahi-qt3.so.*
%{_libdir}/pkgconfig/avahi-qt3.pc
%files qt3-devel %files qt3-devel
%defattr(0644, root, root, 0755) %defattr(0644, root, root, 0755)
%attr(755,root,root) %{_libdir}/libavahi-qt3.so %attr(755,root,root) %{_libdir}/libavahi-qt3.so
%{_includedir}/avahi-qt3 %{_includedir}/avahi-qt3
%{_libdir}/pkgconfig/avahi-qt3.pc
%if %{WITH_MONO} %if %{WITH_MONO}
%files sharp %files sharp
@ -345,6 +424,12 @@ fi
%{_libdir}/mono/avahi-sharp %{_libdir}/mono/avahi-sharp
%{_libdir}/mono/gac/avahi-sharp %{_libdir}/mono/gac/avahi-sharp
%{_libdir}/pkgconfig/avahi-sharp.pc %{_libdir}/pkgconfig/avahi-sharp.pc
%files ui-sharp
%defattr(0644, root, root, 0755)
%{_libdir}/mono/avahi-ui-sharp
%{_libdir}/mono/gac/avahi-ui-sharp
%{_libdir}/pkgconfig/avahi-ui-sharp.pc
%endif %endif
%if %{WITH_COMPAT_HOWL} %if %{WITH_COMPAT_HOWL}
@ -375,6 +460,18 @@ fi
%endif %endif
%changelog %changelog
* Fri Jun 22 2007 Lennart Poettering <lpoetter@redhat.com> - 0.6.20-1
- upgrade to new upstream 0.6.20
- fix a few rpmlint warnings
- create avahi-autoipd user
- no longer create avahi user with a static uid, move to dynamic uids
- drop a couple of patches merged upstream
- Provide "howl" and "howl-devel"
- Split off avahi-autoipd and avahi-dnsconfd
- Introduce avahi-ui packages for the first time
- Reload D-Bus config after installation using dbus-send
- add a couple of missing ldconfig invocations
* Mon Mar 12 2007 Martin Bacovsky <mbacovsk@redhat.com> - 0.6.17-1 * Mon Mar 12 2007 Martin Bacovsky <mbacovsk@redhat.com> - 0.6.17-1
- upgrade to new upstream 0.6.17 - upgrade to new upstream 0.6.17
- redundant patches removal - redundant patches removal

View File

@ -1 +1 @@
29ebb2181958d5721ee5fc45f035a77c avahi-0.6.17.tar.gz 6acdff79afa2631f765f3bbbc3e25a74 avahi-0.6.20.tar.gz