From 99ad32213bca66d3350de6bbb0ef69102eb2fd7b Mon Sep 17 00:00:00 2001 From: Trent Lloyd Date: Wed, 29 Jun 2005 03:34:45 +0000 Subject: * Patch by Steev Klimaszewski for gentoo compilation * Small dbus-protocol.c change git-svn-id: file:///home/lennart/svn/public/avahi/trunk@153 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- avahi-daemon/dbus-protocol.c | 5 +++-- configure.ac | 4 ++++ initscript/Gentoo/Makefile.am | 4 ++++ initscript/Gentoo/avahi.in | 20 ++++++++++++++++++++ 4 files changed, 31 insertions(+), 2 deletions(-) create mode 100644 initscript/Gentoo/Makefile.am create mode 100644 initscript/Gentoo/avahi.in diff --git a/avahi-daemon/dbus-protocol.c b/avahi-daemon/dbus-protocol.c index 242ad59..2d1db32 100644 --- a/avahi-daemon/dbus-protocol.c +++ b/avahi-daemon/dbus-protocol.c @@ -53,7 +53,7 @@ do_register (DBusConnection *conn, DBusMessage *message) return DBUS_HANDLER_RESULT_NOT_YET_HANDLED; } - g_message ("Register received from: %s", s); + g_message ("Register received from: %s (dbus:% s)", s, dbus_message_get_sender (message)); return DBUS_HANDLER_RESULT_HANDLED; } @@ -92,10 +92,11 @@ signal_filter (DBusConnection *conn, DBusMessage *message, void *user_data) } else if (dbus_message_is_signal (message, #ifdef DBUS_USE_NEW_API DBUS_INTERFACE_DBUS, + "NameAcquired")) #else DBUS_INTERFACE_ORG_FREEDESKTOP_DBUS, -#endif "ServiceAcquired")) +#endif { char *name; diff --git a/configure.ac b/configure.ac index 2bbea03..a141ad6 100644 --- a/configure.ac +++ b/configure.ac @@ -186,6 +186,8 @@ else case $with_distro in debian) ;; + gentoo) + ;; *) echo "Your distribution (${with_distro}) is not yet supported! (patches welcome)" exit 1 @@ -234,6 +236,8 @@ avahi-client/Makefile initscript/Makefile initscript/Debian/Makefile initscript/Debian/75avahi +initscript/Gentoo/Makefile +initscript/Gentoo/avahi avahi-dnsconfd/Makefile ]) AC_OUTPUT diff --git a/initscript/Gentoo/Makefile.am b/initscript/Gentoo/Makefile.am new file mode 100644 index 0000000..9d95673 --- /dev/null +++ b/initscript/Gentoo/Makefile.am @@ -0,0 +1,4 @@ +dbusinitddir = $(sysconfdir)/dbus-1/system.d +dbusinitd_SCRIPTS = avahi + +EXTRA_DIST = $(dbusinitd_SCRIPTS) diff --git a/initscript/Gentoo/avahi.in b/initscript/Gentoo/avahi.in new file mode 100644 index 0000000..af26512 --- /dev/null +++ b/initscript/Gentoo/avahi.in @@ -0,0 +1,20 @@ +DAEMON=/usr/bin/avahi + +start() { + ebegin "Starting avahi" + start-stop-daemon --start --quiet --exec $DAEMON + eend $? +} + +stop() { + ebegin "Stopping avahi" + start-stop-daemon --stop --quiet --exec $DAEMON + eend $? +} + +reload() { + ebegin "Reloading avahi configuration" + start-stop-daemon --stop --signal 1 --quiet --exec $DAEMON + eend $? +} + -- cgit