network/avahi: Updated for version 0.6.25

This commit is contained in:
David Somero 2010-05-13 00:35:42 +02:00 committed by Robby Workman
parent 3f8f2deb7c
commit c7ad19ba14
4 changed files with 53 additions and 37 deletions

View file

@ -1,16 +1,15 @@
Avahi is an implementation of the DNS Service Discovery and Multicast Avahi is an implementation of the DNS Service Discovery and Multicast DNS
DNS specifications for Zeroconf Computing. It uses D-BUS for specifications for Zeroconf Computing. It uses D-BUS for communication
communication between user applications and a system daemon. The between user applications and a system daemon. The daemon is used to
daemon is used to coordinate application efforts in caching replies, coordinate application efforts in caching replies, necessary to minimize the
necessary to minimize the traffic imposed on networks. This kind of traffic imposed on networks. This kind of technology is already found in
technology is already found in Apple MacOS X (branded Rendezvous Apple MacOS X (branded Rendezvous Bonjour and sometimes Zeroconf) and is very
Bonjour and sometimes Zeroconf) and is very convenient. convenient.
Required dependency libdaemon, which is available at SlackBuilds.org.
Optional dependencies: mono and/or qt4 (also available at
SlackBuilds.org); enable with MONO=yes QT4=yes ./avahi.SlackBuild
You will need to have an "avahi" user and group on the target system You will need to have an "avahi" user and group on the target system
prior to installing the avahi package. See README.SBo in this prior to installing the avahi package. See README.SBo in this
directory (it is also installed to the package docmentation directory) directory (it is also installed to the package docmentation directory)
for more information and for setup notes. for more information and for setup notes.
This requires libdaemon, and mono is optional - enable it with the following:
MONO=yes ./avahi.SlackBuild

View file

@ -3,17 +3,23 @@ README.SBo (avahi)
First, be sure you have an "avahi" user and group. Do this *before* First, be sure you have an "avahi" user and group. Do this *before*
you install the avahi package. We recommend uid/gid of 214, but you install the avahi package. We recommend uid/gid of 214, but
adjust as needed for your system. Something like this should suffice: adjust as needed for your system. Something like this should suffice:
# groupadd -g 214 avahi # groupadd -g 214 avahi
# useradd -u 214 -g 214 -c "Avahi User" -d /dev/null -s /bin/false avahi # useradd -u 214 -g 214 -c "Avahi User" -d /dev/null -s /bin/false avahi
Now start the Avahi daemon: Now start the Avahi daemon:
# /etc/rc.d/rc.avahidaemon start # /etc/rc.d/rc.avahidaemon start
Optionally start the unicast DNS configuration daemon: Optionally start the unicast DNS configuration daemon:
# /etc/rc.d/rc.avahidnsconfd start # /etc/rc.d/rc.avahidnsconfd start
You will need to start avahi at boot by adding the following You will need to start avahi at boot by adding the following
to your /etc/rc.d/rc.local and make them executable: to your /etc/rc.d/rc.local and make them executable:
# Start avahidaemon # Start avahidaemon
if [ -x /etc/rc.d/rc.avahidaemon ]; then if [ -x /etc/rc.d/rc.avahidaemon ]; then
/etc/rc.d/rc.avahidaemon start /etc/rc.d/rc.avahidaemon start
@ -23,3 +29,15 @@ to your /etc/rc.d/rc.local and make them executable:
/etc/rc.d/rc.avahidnsconfd start /etc/rc.d/rc.avahidnsconfd start
fi fi
You will also want to put the following into /etc/rc.d/rc.local_shutdown
(if that file does not exist, create it and make it executable):
# Stop avahidnsconfd
if [ -x /etc/rc.d/rc.avahidnsconfd ]; then
/etc/rc.d/rc.avahidnsconfd stop
fi
# Stop avahidaemon
if [ -x /etc/rc.d/rc.avahidaemon ]; then
/etc/rc.d/rc.avahidaemon stop
fi

View file

@ -33,13 +33,6 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp} OUTPUT=${OUTPUT:-/tmp}
# Support for QT4
if [ "${QT4:-no}" = "no" ]; then
QT4="--disable-qt4"
else
QT4="--enable-qt4"
fi
# Support for mono # Support for mono
if [ "${MONO:-no}" = "no" ]; then if [ "${MONO:-no}" = "no" ]; then
MONO="--disable-mono" MONO="--disable-mono"
@ -47,14 +40,6 @@ else
MONO="--enable-mono" MONO="--enable-mono"
fi fi
if [ "${ARCH}" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
fi
warn_accounts() { warn_accounts() {
echo " You must have an avahi user and group to run this script. " echo " You must have an avahi user and group to run this script. "
echo " Something like this should suffice for most systems: " echo " Something like this should suffice for most systems: "
@ -71,6 +56,17 @@ if ! grep -q "^avahi:" /etc/group ; then
warn_accounts warn_accounts
fi fi
if [ "${ARCH}" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
fi
set -e set -e
rm -rf $PKG rm -rf $PKG
@ -86,6 +82,7 @@ CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \
./configure \ ./configure \
--prefix=/usr \ --prefix=/usr \
--libdir=/usr/lib${LIBDIRSUFFIX} \
--sysconfdir=/etc \ --sysconfdir=/etc \
--localstatedir=/var \ --localstatedir=/var \
--mandir=/usr/man \ --mandir=/usr/man \
@ -99,7 +96,8 @@ CXXFLAGS="$SLKCFLAGS" \
--enable-dbus \ --enable-dbus \
--enable-python \ --enable-python \
--enable-gtk \ --enable-gtk \
--enable-qt3 \ --enable-qt4 \
--disable-qt3 \
--enable-core-docs \ --enable-core-docs \
--enable-compat-howl \ --enable-compat-howl \
--enable-compat-libdns_sd \ --enable-compat-libdns_sd \
@ -110,9 +108,8 @@ CXXFLAGS="$SLKCFLAGS" \
--with-distro=slackware \ --with-distro=slackware \
--program-prefix= \ --program-prefix= \
--program-suffix= \ --program-suffix= \
$MONO \ --build=$ARCH-slackware-linux \
$QT4 \ $MONO
--build=$ARCH-slackware-linux
make make
make install DESTDIR=$PKG make install DESTDIR=$PKG
@ -129,6 +126,12 @@ make install DESTDIR=$PKG
for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
) )
mv $PKG/etc/rc.d/rc.avahidaemon $PKG/etc/rc.d/rc.avahidaemon.new
mv $PKG/etc/rc.d/rc.avahidnsconfd $PKG/etc/rc.d/rc.avahidnsconfd.new
mv $PKG/etc/avahi/avahi-daemon.conf $PKG/etc/avahi/avahi-daemon.conf.new
mv $PKG/etc/dbus-1/system.d/avahi-dbus.conf \
$PKG/etc/dbus-1/system.d/avahi-dbus.conf.new
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a LICENSE docs/* $PKG/usr/doc/$PRGNAM-$VERSION cp -a LICENSE docs/* $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
@ -137,11 +140,5 @@ mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc cat $CWD/slack-desc > $PKG/install/slack-desc
cat $CWD/doinst.sh > $PKG/install/doinst.sh cat $CWD/doinst.sh > $PKG/install/doinst.sh
mv $PKG/etc/rc.d/rc.avahidaemon $PKG/etc/rc.d/rc.avahidaemon.new
mv $PKG/etc/rc.d/rc.avahidnsconfd $PKG/etc/rc.d/rc.avahidnsconfd.new
mv $PKG/etc/avahi/avahi-daemon.conf $PKG/etc/avahi/avahi-daemon.conf.new
mv $PKG/etc/dbus-1/system.d/avahi-dbus.conf \
$PKG/etc/dbus-1/system.d/avahi-dbus.conf.new
cd $PKG cd $PKG
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz /sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}

View file

@ -2,7 +2,9 @@ PRGNAM="avahi"
VERSION="0.6.25" VERSION="0.6.25"
HOMEPAGE="http://avahi.org/" HOMEPAGE="http://avahi.org/"
DOWNLOAD="http://avahi.org/download/avahi-0.6.25.tar.gz" DOWNLOAD="http://avahi.org/download/avahi-0.6.25.tar.gz"
DOWNLOAD_x86_64=""
MD5SUM="a83155a6e29e3988f07e5eea3287b21e" MD5SUM="a83155a6e29e3988f07e5eea3287b21e"
MD5SUM_x86_64=""
MAINTAINER="David Somero" MAINTAINER="David Somero"
EMAIL="dsomero@hotmail.com" EMAIL="dsomero@hotmail.com"
APPROVED="rworkman" APPROVED="rworkman"