* Start avahi-daemon and avahi-dnsconfd as regular SysV init scripts.
(Closes: #396811, #367748, #378114)
+ debian/avahi-daemon.init,
debian/avahi-dnsconfd.init
- Added. Based on the upstream init scripts.
- Add proper LSB headers.
- Remove reimplementation of LSB logging functions. Depend on lsb-base
being installed.
- Use log_daemon_msg instead of log_begin_msg.
- Remove SVN $Id keyword. (Closes: #354988)
+ debian/avahi-daemon.install,
debian/avahi-dnsconfd.install
- Do not install the upstream init script anymore.
+ debian/avahi-daemon.links
- Remove the symlink /etc/dbus-1/event.d/25avahi-daemon
+ debian/avahi-daemon.postinst
- Do not restart avahi-daemon manually. dh_installinit takes care of
that automatically.
+ debian/avahi-daemon.prerm,
debian/avahi-dnsconfd.{links,postinst,prerm}
- Removed. Not needed anymore.
+ debian/control
- Add Depends: lsb-base (>= 3.0-6) to avahi-daemon and avahi-dnsconfd.
+ debian/rules
- Set DEB_DH_INSTALLINIT_ARGS to start at 24 and stop at 16.
git-svn-id: svn+ssh://svn.debian.org/svn/pkg-utopia/packages/unstable/avahi@1439 ceb527fc-18e6-0310-9fe2-813c157c29e7
Michael Biebl
17 years ago
0 | #!/bin/sh | |
1 | ### BEGIN INIT INFO | |
2 | # Provides: avahi | |
3 | # Required-Start: $local_fs dbus | |
4 | # Required-Stop: $local_fs dbus | |
5 | # Should-Start: $syslog | |
6 | # Should-Stop: $syslog | |
7 | # Default-Start: 2 3 4 5 | |
8 | # Default-Stop: S 0 1 6 | |
9 | # Short-Description: Avahi mDNS/DNS-SD Daemon | |
10 | # Description: Zeroconf daemon for configuring your network | |
11 | # automatically | |
12 | ### END INIT INFO | |
13 | ||
14 | #set -e | |
15 | ||
16 | PATH=/sbin:/bin:/usr/sbin:/usr/bin | |
17 | DESC="Avahi mDNS/DNS-SD Daemon" | |
18 | NAME="avahi-daemon" | |
19 | DAEMON="/usr/sbin/$NAME" | |
20 | SCRIPTNAME=/etc/init.d/$NAME | |
21 | ||
22 | # Gracefully exit if the package has been removed. | |
23 | test -x $DAEMON || exit 0 | |
24 | ||
25 | . /lib/lsb/init-functions | |
26 | ||
27 | # don't start if /etc/default/avahi-daemon says so. | |
28 | AVAHI_DAEMON_START=1 | |
29 | test -f /etc/default/avahi-daemon && . /etc/default/avahi-daemon | |
30 | ||
31 | DISABLE_TAG="/var/run/avahi-daemon/disabled-for-unicast-local" | |
32 | ||
33 | if [ "$AVAHI_DAEMON_START" != "1" -a "$1" != "stop" ]; then | |
34 | log_warning_msg "Not starting $DESC $NAME, disabled via /etc/default/$NAME" | |
35 | exit 0 | |
36 | fi | |
37 | ||
38 | # | |
39 | # Function that starts the daemon/service. | |
40 | # | |
41 | d_start() { | |
42 | modprobe capability >/dev/null 2>&1 || true | |
43 | ||
44 | $DAEMON -c && return 0 | |
45 | ||
46 | if [ -e ${DISABLE_TAG} ]; then | |
47 | # Disabled because of the existance of an unicast .local domain | |
48 | log_warning_msg "avahi-daemon disabled because there is a unicast .local domain" | |
49 | exit 0; | |
50 | fi; | |
51 | ||
52 | if [ -s /etc/localtime ]; then | |
53 | if [ ! -d /etc/avahi/etc ]; then | |
54 | mkdir -p /etc/avahi/etc >/dev/null 2>&1 | |
55 | fi | |
56 | cp -fp /etc/localtime /etc/avahi/etc >/dev/null 2>&1 | |
57 | fi; | |
58 | ||
59 | $DAEMON -D | |
60 | } | |
61 | ||
62 | # | |
63 | # Function that stops the daemon/service. | |
64 | # | |
65 | d_stop() { | |
66 | $DAEMON -c && $DAEMON -k | |
67 | } | |
68 | ||
69 | # | |
70 | # Function that reload the config file for the daemon/service. | |
71 | # | |
72 | d_reload() { | |
73 | $DAEMON -c && $DAEMON -r | |
74 | } | |
75 | ||
76 | # | |
77 | # Function that check the status of the daemon/service. | |
78 | # | |
79 | d_status() { | |
80 | $DAEMON -c && echo "$DESC is running" || echo "$DESC is not running" | |
81 | } | |
82 | ||
83 | case "$1" in | |
84 | start) | |
85 | log_daemon_msg "Starting $DESC" "$NAME" | |
86 | d_start | |
87 | log_end_msg $? | |
88 | ;; | |
89 | stop) | |
90 | log_daemon_msg "Stopping $DESC" "$NAME" | |
91 | d_stop | |
92 | log_end_msg $? | |
93 | ;; | |
94 | reload) | |
95 | log_daemon_msg "Reloading services for $DESC" "$NAME" | |
96 | d_reload | |
97 | log_end_msg $? | |
98 | ;; | |
99 | restart|force-reload) | |
100 | log_daemon_msg "Restarting $DESC" "$NAME" | |
101 | $DAEMON -c && d_stop | |
102 | d_start | |
103 | log_end_msg $? | |
104 | ;; | |
105 | status) | |
106 | d_status | |
107 | ;; | |
108 | *) | |
109 | echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload|reload}" >&2 | |
110 | exit 1 | |
111 | ;; | |
112 | esac | |
113 | ||
114 | exit 0 |
0 | 0 | debian/tmp/etc/avahi/avahi-daemon.conf |
1 | 1 | debian/tmp/etc/avahi/hosts |
2 | debian/tmp/etc/init.d/avahi-daemon | |
3 | 2 | debian/tmp/etc/dbus-1/system.d/avahi-dbus.conf |
4 | 3 | debian/tmp/usr/sbin/avahi-daemon |
5 | 4 | debian/tmp/usr/share/avahi/avahi-service.dtd |
0 | etc/init.d/avahi-daemon etc/dbus-1/event.d/25avahi-daemon | |
1 | 0 | etc/network/if-up.d/avahi-daemon etc/network/if-post-down.d/avahi-daemon |
34 | 34 | if [ -x "/etc/init.d/dbus" ]; then |
35 | 35 | invoke-rc.d dbus force-reload || true |
36 | 36 | fi |
37 | /etc/init.d/avahi-daemon restart | |
38 | 37 | ;; |
39 | 38 | abort-upgrade|abort-remove|abort-deconfigure) |
40 | 39 | ;; |
0 | #!/bin/sh -e | |
1 | ||
2 | if [ "$1" = "remove" ]; then | |
3 | /etc/init.d/avahi-daemon stop || true | |
4 | fi | |
5 | ||
6 | #DEBHELPER# | |
7 | ||
8 | exit 0 |
0 | #!/bin/sh | |
1 | ### BEGIN INIT INFO | |
2 | # Provides: avahi-dnsconfd | |
3 | # Required-Start: $local_fs avahi | |
4 | # Required-Stop: $local_fs avahi | |
5 | # Should-Start: $syslog | |
6 | # Should-Stop: $syslog | |
7 | # Default-Start: 2 3 4 5 | |
8 | # Default-Stop: S 0 1 6 | |
9 | # Short-Description: Avahi Unicast DNS Configuration Daemon | |
10 | # Description: A DNS configuration daemon using mDNS in a | |
11 | # DHCP-like fashion | |
12 | ### END INIT INFO | |
13 | ||
14 | #set -e | |
15 | ||
16 | PATH=/sbin:/bin:/usr/sbin:/usr/bin | |
17 | DESC="Avahi Unicast DNS Configuration Daemon" | |
18 | NAME="avahi-dnsconfd" | |
19 | DAEMON="/usr/sbin/$NAME" | |
20 | SCRIPTNAME=/etc/init.d/$NAME | |
21 | ||
22 | # Gracefully exit if the package has been removed. | |
23 | test -x $DAEMON || exit 0 | |
24 | ||
25 | . /lib/lsb/init-functions | |
26 | ||
27 | # don't start if /etc/default/avahi-dnsconfd says so. | |
28 | AVAHI_DNSCONFD_START=1 | |
29 | test -f /etc/default/avahi-dnsconfd && . /etc/default/avahi-dnsconfd | |
30 | ||
31 | if [ "$AVAHI_DNSCONFD_START" != "1" -a "$1" != "stop" ]; then | |
32 | log_warning_msg "Not starting $DESC $NAME, disabled via /etc/default/$NAME" | |
33 | exit 0 | |
34 | fi | |
35 | ||
36 | # | |
37 | # Function that starts the daemon/service. | |
38 | # | |
39 | d_start() { | |
40 | $DAEMON -c | |
41 | [ $? = 0 ] && exit 0 | |
42 | ||
43 | if [ -s /etc/localtime ]; then | |
44 | if [ ! -d /etc/avahi/etc ]; then | |
45 | mkdir -p /etc/avahi/etc >/dev/null 2>&1 | |
46 | fi | |
47 | cp -fp /etc/localtime /etc/avahi/etc >/dev/null 2>&1 | |
48 | fi; | |
49 | ||
50 | $DAEMON -D | |
51 | } | |
52 | ||
53 | # | |
54 | # Function that stops the daemon/service. | |
55 | # | |
56 | d_stop() { | |
57 | $DAEMON -c | |
58 | [ $? != 0 ] && exit 0 | |
59 | ||
60 | $DAEMON -k | |
61 | } | |
62 | ||
63 | # | |
64 | # Function that reload the config file for the daemon/service. | |
65 | # | |
66 | d_refresh() { | |
67 | $DAEMON -c | |
68 | [ $? != 0 ] && exit 0 | |
69 | ||
70 | $DAEMON -r | |
71 | } | |
72 | ||
73 | # | |
74 | # Function that check the status of the daemon/service. | |
75 | # | |
76 | d_status() { | |
77 | $DAEMON -c | |
78 | [ $? = 0 ] && echo "$DESC is running" || echo "$DESC is not running" | |
79 | } | |
80 | ||
81 | case "$1" in | |
82 | start) | |
83 | log_daemon_msg "Starting $DESC" "$NAME" | |
84 | d_start | |
85 | log_end_msg $? | |
86 | ;; | |
87 | stop) | |
88 | log_daemon_msg "Stopping $DESC" "$NAME" | |
89 | d_stop | |
90 | log_end_msg $? | |
91 | ;; | |
92 | refresh) | |
93 | log_daemon_msg "Refreshing $DESC" "$NAME" | |
94 | d_refresh | |
95 | log_end_msg $? | |
96 | ;; | |
97 | reload|restart|force-reload) | |
98 | log_daemon_msg "Restarting $DESC" "$NAME" | |
99 | $DAEMON -c && d_stop | |
100 | d_start | |
101 | log_end_msg $? | |
102 | ;; | |
103 | status) | |
104 | d_status | |
105 | ;; | |
106 | *) | |
107 | echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload|reload}" >&2 | |
108 | exit 1 | |
109 | ;; | |
110 | esac | |
111 | ||
112 | exit 0 |
0 | 0 | debian/tmp/etc/avahi/avahi-dnsconfd.action |
1 | debian/tmp/etc/init.d/avahi-dnsconfd | |
2 | 1 | debian/tmp/usr/sbin/avahi-dnsconfd |
0 | etc/init.d/avahi-dnsconfd etc/dbus-1/event.d/25avahi-dnsconfd |
0 | #! /bin/sh | |
1 | # postinst script for avai | |
2 | ||
3 | set -e | |
4 | ||
5 | # summary of how this script can be called: | |
6 | # * <postinst> `configure' <most-recently-configured-version> | |
7 | # * <old-postinst> `abort-upgrade' <new version> | |
8 | # * <conflictor's-postinst> `abort-remove' `in-favour' <package> | |
9 | # <new-version> | |
10 | # * <deconfigured's-postinst> `abort-deconfigure' `in-favour' | |
11 | # <failed-install-package> <version> `removing' | |
12 | # <conflicting-package> <version> | |
13 | # for details, see http://www.debian.org/doc/debian-policy/ or | |
14 | # the debian-policy package | |
15 | ||
16 | case "$1" in | |
17 | configure) | |
18 | # Restart the daemon | |
19 | /etc/init.d/avahi-dnsconfd restart | |
20 | ;; | |
21 | abort-upgrade|abort-remove|abort-deconfigure) | |
22 | ;; | |
23 | *) | |
24 | echo "postinst called with unknown argument \`$1'" >&2 | |
25 | exit 1 | |
26 | ;; | |
27 | esac | |
28 | ||
29 | #DEBHELPER# | |
30 | ||
31 | exit 0 |
0 | #!/bin/sh -e | |
1 | ||
2 | if [ "$1" = "remove" ]; then | |
3 | /etc/init.d/avahi-dnsconfd stop || true | |
4 | fi | |
5 | ||
6 | #DEBHELPER# | |
7 | ||
8 | exit 0 |
0 | avahi (0.6.18-4) UNRELEASED; urgency=low | |
1 | ||
0 | avahi (0.6.18-4) unstable; urgency=low | |
1 | ||
2 | [ Sjoerd Simons ] | |
2 | 3 | * debian/rules: |
3 | 4 | + Ensure that ServiceTypeDatabase.py is generated instead of using the one |
4 | 5 | from the tarball (Closes: #420184) |
5 | 6 | |
6 | -- Sjoerd Simons <sjoerd@debian.org> Sun, 22 Apr 2007 20:31:27 +0200 | |
7 | [ Michael Biebl ] | |
8 | * Start avahi-daemon and avahi-dnsconfd as regular SysV init scripts. | |
9 | (Closes: #396811, #367748, #378114) | |
10 | + debian/avahi-daemon.init, | |
11 | debian/avahi-dnsconfd.init | |
12 | - Added. Based on the upstream init scripts. | |
13 | - Add proper LSB headers. | |
14 | - Remove reimplementation of LSB logging functions. Depend on lsb-base | |
15 | being installed. | |
16 | - Use log_daemon_msg instead of log_begin_msg. | |
17 | - Remove SVN $Id keyword. (Closes: #354988) | |
18 | + debian/avahi-daemon.install, | |
19 | debian/avahi-dnsconfd.install | |
20 | - Do not install the upstream init script anymore. | |
21 | + debian/avahi-daemon.links | |
22 | - Remove the symlink /etc/dbus-1/event.d/25avahi-daemon | |
23 | + debian/avahi-daemon.postinst | |
24 | - Do not restart avahi-daemon manually. dh_installinit takes care of | |
25 | that automatically. | |
26 | + debian/avahi-daemon.prerm, | |
27 | debian/avahi-dnsconfd.{links,postinst,prerm} | |
28 | - Removed. Not needed anymore. | |
29 | + debian/control | |
30 | - Add Depends: lsb-base (>= 3.0-6) to avahi-daemon and avahi-dnsconfd. | |
31 | + debian/rules | |
32 | - Set DEB_DH_INSTALLINIT_ARGS to start at 24 and stop at 16. | |
33 | ||
34 | -- Michael Biebl <biebl@debian.org> Wed, 25 Apr 2007 17:49:54 +0200 | |
7 | 35 | |
8 | 36 | avahi (0.6.18-3) unstable; urgency=low |
9 | 37 |
9 | 9 | Package: avahi-daemon |
10 | 10 | Section: net |
11 | 11 | Architecture: any |
12 | Depends: ${shlibs:Depends}, ${misc:Depends}, adduser, dbus (>= 0.60) | |
12 | Depends: ${shlibs:Depends}, ${misc:Depends}, adduser, dbus (>= 0.60), lsb-base (>= 3.0-6) | |
13 | 13 | Recommends: libnss-mdns |
14 | 14 | Suggests: avahi-autoipd |
15 | 15 | Conflicts: mdnsresponder |
27 | 27 | Package: avahi-dnsconfd |
28 | 28 | Section: net |
29 | 29 | Architecture: any |
30 | Depends: avahi-daemon, ${shlibs:Depends}, ${misc:Depends} | |
30 | Depends: avahi-daemon, ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.0-6) | |
31 | 31 | Recommends: resolvconf |
32 | 32 | Description: Avahi DNS configuration tool |
33 | 33 | Avahi is a fully LGPL framework for Multicast DNS Service Discovery. |
17 | 17 | DEB_CONFIGURE_EXTRA_FLAGS += --enable-compat-libdns_sd --enable-compat-howl \ |
18 | 18 | --disable-mono --disable-monodoc |
19 | 19 | |
20 | DEB_DH_INSTALLINIT_ARGS := -- start 24 2 3 4 5 . stop 16 0 1 6 . | |
21 | ||
20 | 22 | ifneq (linux,$(DEB_HOST_ARCH_OS)) |
21 | 23 | DEB_CONFIGURE_EXTRA_FLAGS += --disable-autoipd |
22 | 24 | endif |
35 | 37 | |
36 | 38 | binary-install/avahi-discover:: |
37 | 39 | dh_pysupport -p$(cdbs_curpkg) |
38 | dh_python -p$(cdbs_curpkg) | |
39 | 40 | rm -f debian/tmp/usr/lib/python*/site-packages/avahi/*.py[co] |
40 | 41 | |
41 | 42 | binary-install/python-avahi:: |
42 | 43 | dh_pysupport -p$(cdbs_curpkg) |
43 | dh_python -p$(cdbs_curpkg) | |
44 | 44 | rm -f debian/tmp/usr/lib/python*/site-packages/avahi/*.py[co] |
45 | ||
46 | binary-fixup/avahi-daemon binary-fixup/avahi-dnsconfd:: | |
47 | chmod +x debian/$(cdbs_curpkg)/etc/dbus-1/event.d/* | |
48 | 45 | |
49 | 46 | install/avahi-autoipd:: |
50 | 47 | install -D -o root -g root -m 755 debian/avahi-autoipd.ifup \ |