Remove sysv init script
This commit is contained in:
parent
d2eddfce89
commit
d6e5bc7183
51
avahi.spec
51
avahi.spec
@ -6,7 +6,7 @@
|
||||
%endif
|
||||
Name: avahi
|
||||
Version: 0.6.30
|
||||
Release: 3%{?dist}
|
||||
Release: 4%{?dist}
|
||||
Summary: Local network service discovery
|
||||
Group: System Environment/Base
|
||||
License: LGPLv2
|
||||
@ -15,7 +15,9 @@ Requires: dbus
|
||||
Requires: expat
|
||||
Requires: libdaemon >= 0.11
|
||||
Requires: systemd-units
|
||||
Requires(post): initscripts, chkconfig, ldconfig
|
||||
Requires(post): initscripts
|
||||
Requires(post): ldconfig
|
||||
Requires(post): systemd-sysv
|
||||
Requires(pre): shadow-utils
|
||||
Requires: %{name}-libs = %{version}-%{release}
|
||||
BuildRequires: automake libtool
|
||||
@ -345,7 +347,9 @@ ln -s avahi-compat-howl.pc $RPM_BUILD_ROOT/%{_libdir}/pkgconfig/howl.pc
|
||||
ln -s avahi-compat-libdns_sd.pc $RPM_BUILD_ROOT/%{_libdir}/pkgconfig/libdns_sd.pc
|
||||
ln -s avahi-compat-libdns_sd/dns_sd.h $RPM_BUILD_ROOT/%{_includedir}/
|
||||
%endif
|
||||
#
|
||||
|
||||
rm -f $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/avahi-daemon
|
||||
rm -f $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/avahi-dnsconfd
|
||||
:;
|
||||
|
||||
%find_lang %{name}
|
||||
@ -369,31 +373,32 @@ getent passwd avahi >/dev/null 2>&1 || useradd \
|
||||
:;
|
||||
|
||||
%post
|
||||
/sbin/ldconfig || :
|
||||
/sbin/ldconfig >/dev/null 2>&1 || :
|
||||
dbus-send --system --type=method_call --dest=org.freedesktop.DBus / org.freedesktop.DBus.ReloadConfig >/dev/null 2>&1 || :
|
||||
/sbin/chkconfig --add avahi-daemon >/dev/null 2>&1 || :
|
||||
if [ "$1" -eq 1 ]; then
|
||||
/bin/systemctl enable avahi-daemon.service >/dev/null 2>&1 || :
|
||||
if [ -s /etc/localtime ]; then
|
||||
cp -cfp /etc/localtime /etc/avahi/etc/localtime || :
|
||||
cp -cfp /etc/localtime /etc/avahi/etc/localtime >/dev/null 2>&1 || :
|
||||
fi
|
||||
fi
|
||||
|
||||
%triggerun -- avahi < 0.6.28-1
|
||||
if /sbin/chkconfig --level 5 avahi-daemon ; then
|
||||
/bin/systemctl --no-reload enable avahi-daemon.service >/dev/null 2>&1 || :
|
||||
fi
|
||||
|
||||
%preun
|
||||
if [ "$1" -eq 0 ]; then
|
||||
/bin/systemctl --no-reload disable avahi-daemon.service >/dev/null 2>&1 || :
|
||||
/bin/systemctl stop avahi-daemon.service >/dev/null 2>&1 || :
|
||||
/sbin/chkconfig --del avahi-daemon >/dev/null 2>&1 || :
|
||||
fi
|
||||
|
||||
%postun
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
/sbin/ldconfig || :
|
||||
if [ $1 -ge 1 ] ; then
|
||||
/bin/systemctl try-restart avahi-daemon.service >/dev/null 2>&1 || :
|
||||
fi
|
||||
/sbin/ldconfig >/dev/null 2>&1 || :
|
||||
|
||||
%triggerun -- avahi < 0.6.28-1
|
||||
%{_bindir}/systemd-sysv-convert --save avahi-daemon
|
||||
/bin/systemctl --no-reload enable avahi-daemon.service >/dev/null 2>&1 || :
|
||||
/bin/systemctl try-restart avahi-daemon.service >/dev/null 2>&1 || :
|
||||
|
||||
%pre autoipd
|
||||
getent group avahi-autoipd >/dev/null 2>&1 || groupadd \
|
||||
@ -411,25 +416,26 @@ getent passwd avahi-autoipd >/dev/null 2>&1 || useradd \
|
||||
:;
|
||||
|
||||
%post dnsconfd
|
||||
/sbin/chkconfig --add avahi-dnsconfd >/dev/null 2>&1 || :
|
||||
if [ "$1" -eq 1 ]; then
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
|
||||
%triggerun dnsconfd -- avahi-dnsconfd < 0.6.28-1
|
||||
if /sbin/chkconfig --level 5 avahi-dnsconfd ; then
|
||||
/bin/systemctl --no-reload enable avahi-dnsconfd.service >/dev/null 2>&1 || :
|
||||
fi
|
||||
|
||||
%preun dnsconfd
|
||||
if [ "$1" -eq 0 ]; then
|
||||
/bin/systemctl --no-reload disable avahi-dnsconfd.service >/dev/null 2>&1 || :
|
||||
/bin/systemctl stop avahi-dnsconfd.service >/dev/null 2>&1 || :
|
||||
/sbin/chkconfig --del avahi-dnsconfd >/dev/null 2>&1 || :
|
||||
fi
|
||||
|
||||
%postun dnsconfd
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
if [ $1 -ge 1 ] ; then
|
||||
/bin/systemctl try-restart avahi-dnsconfd.service >/dev/null 2>&1 || :
|
||||
fi
|
||||
|
||||
%triggerun dnsconfd -- avahi-dnsconfd < 0.6.28-1
|
||||
%{_bindir}/systemd-sysv-convert --save avahi-dnsconfd
|
||||
/bin/systemctl --no-reload enable avahi-dnsconfd.service >/dev/null 2>&1 || :
|
||||
/bin/systemctl try-restart avahi-dnsconfd.service >/dev/null 2>&1 || :
|
||||
|
||||
%post glib -p /sbin/ldconfig
|
||||
%postun glib -p /sbin/ldconfig
|
||||
@ -461,7 +467,6 @@ fi
|
||||
%files -f %{name}.lang
|
||||
%defattr(0644,root,root,0755)
|
||||
%doc docs/* avahi-daemon/example.service avahi-daemon/sftp-ssh.service
|
||||
%attr(0755,root,root) %{_sysconfdir}/rc.d/init.d/avahi-daemon
|
||||
%dir %{_sysconfdir}/avahi
|
||||
%dir %{_sysconfdir}/avahi/etc
|
||||
%ghost %{_sysconfdir}/avahi/etc/localtime
|
||||
@ -492,7 +497,6 @@ fi
|
||||
|
||||
%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.*
|
||||
@ -645,6 +649,9 @@ fi
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Mon Aug 22 2011 Lennart Poettering <lpoetter@redhat.com> - 0.6.30-4
|
||||
- Remove sysv init script (#714649)
|
||||
|
||||
* Thu May 5 2011 Bill Nottingham <notting@redhat.com> - 0.6.30-3
|
||||
- fix versioning on triggers
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user