summaryrefslogtreecommitdiff
path: root/network/avahi/avahi.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'network/avahi/avahi.SlackBuild')
-rw-r--r--network/avahi/avahi.SlackBuild49
1 files changed, 23 insertions, 26 deletions
diff --git a/network/avahi/avahi.SlackBuild b/network/avahi/avahi.SlackBuild
index 5887d37cdb..7f5fef5f9e 100644
--- a/network/avahi/avahi.SlackBuild
+++ b/network/avahi/avahi.SlackBuild
@@ -33,13 +33,6 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-# Support for QT4
-if [ "${QT4:-no}" = "no" ]; then
- QT4="--disable-qt4"
-else
- QT4="--enable-qt4"
-fi
-
# Support for mono
if [ "${MONO:-no}" = "no" ]; then
MONO="--disable-mono"
@@ -47,14 +40,6 @@ else
MONO="--enable-mono"
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() {
echo " You must have an avahi user and group to run this script. "
echo " Something like this should suffice for most systems: "
@@ -71,6 +56,17 @@ if ! grep -q "^avahi:" /etc/group ; then
warn_accounts
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
rm -rf $PKG
@@ -86,6 +82,7 @@ CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \
--prefix=/usr \
+ --libdir=/usr/lib${LIBDIRSUFFIX} \
--sysconfdir=/etc \
--localstatedir=/var \
--mandir=/usr/man \
@@ -99,7 +96,8 @@ CXXFLAGS="$SLKCFLAGS" \
--enable-dbus \
--enable-python \
--enable-gtk \
- --enable-qt3 \
+ --enable-qt4 \
+ --disable-qt3 \
--enable-core-docs \
--enable-compat-howl \
--enable-compat-libdns_sd \
@@ -110,9 +108,8 @@ CXXFLAGS="$SLKCFLAGS" \
--with-distro=slackware \
--program-prefix= \
--program-suffix= \
- $MONO \
- $QT4 \
- --build=$ARCH-slackware-linux
+ --build=$ARCH-slackware-linux \
+ $MONO
make
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
)
+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
cp -a LICENSE docs/* $PKG/usr/doc/$PRGNAM-$VERSION
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/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
-/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}