From ffa5085cc2ab25a9ee1f4bfe947c9f06c1e7df41 Mon Sep 17 00:00:00 2001 From: Erik Hanson Date: Wed, 12 May 2010 17:37:13 +0200 Subject: audio/mpdscribble: Updated for version 0.17 --- audio/mpdscribble/doinst.sh | 15 ++++++++++++ audio/mpdscribble/mpdscribble.SlackBuild | 39 ++++++++++++++++++++++---------- audio/mpdscribble/mpdscribble.info | 10 ++++---- audio/mpdscribble/slack-desc | 10 +++++++- 4 files changed, 56 insertions(+), 18 deletions(-) create mode 100644 audio/mpdscribble/doinst.sh (limited to 'audio/mpdscribble') diff --git a/audio/mpdscribble/doinst.sh b/audio/mpdscribble/doinst.sh new file mode 100644 index 0000000000..a07f26ade6 --- /dev/null +++ b/audio/mpdscribble/doinst.sh @@ -0,0 +1,15 @@ +config() { + NEW="$1" + OLD="$(dirname $NEW)/$(basename $NEW .new)" + # If there's no config file by that name, mv it over: + if [ ! -r $OLD ]; then + mv $NEW $OLD + elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then + # toss the redundant copy + rm $NEW + fi + # Otherwise, we leave the .new copy for the admin to consider... +} + +config etc/mpdscribble.conf.new + diff --git a/audio/mpdscribble/mpdscribble.SlackBuild b/audio/mpdscribble/mpdscribble.SlackBuild index bad04247d3..ba5f8431ad 100644 --- a/audio/mpdscribble/mpdscribble.SlackBuild +++ b/audio/mpdscribble/mpdscribble.SlackBuild @@ -1,16 +1,14 @@ #!/bin/sh - # Slackware build script for mpdscribble # Written by Erik Hanson erik@slackbuilds.org -set -eu - PRGNAM=mpdscribble -VERSION=0.2.12 +VERSION=0.17 ARCH=${ARCH:-i486} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} -CWD=`pwd` + +CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} @@ -19,16 +17,24 @@ 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 +set -eu + rm -rf $PKG -mkdir -p $TMP $PKG +mkdir -p $TMP $PKG $OUTPUT cd $TMP rm -rf $PRGNAM-$VERSION tar xvf $CWD/$PRGNAM-$VERSION.tar.gz cd $PRGNAM-$VERSION chown -R root:root . -chmod -R u+w,go+r-w,a-s . +find . \ + \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ + -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ + -exec chmod 644 {} \; CFLAGS="$SLKCFLAGS" \ ./configure \ @@ -36,18 +42,27 @@ CFLAGS="$SLKCFLAGS" \ --sysconfdir=/etc \ --localstatedir=/var/lib \ --mandir=/usr/man \ - --disable-static + --docdir=/usr/doc/$PRGNAM-$VERSION \ + --build=$ARCH-slackware-linux make make install-strip DESTDIR=$PKG -gzip -9 $PKG/usr/man/man?/*.? +( cd $PKG/usr/man + find . -type f -exec gzip -9 {} \; + for i in $(find . -type l) ; do ln -s $(readlink $i).gz $i.gz ; rm $i ; done +) -mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION $PKG/install -cp -a AUTHORS COPYING ChangeLog INSTALL NEWS README TODO \ - $PKG/usr/doc/$PRGNAM-$VERSION +# Don't clobber the config file +mv $PKG/etc/mpdscribble.conf $PKG/etc/mpdscribble.conf.new + +# Add some missed docs +cp -a COPYING INSTALL $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild + +mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc +cat $CWD/doinst.sh > $PKG/install/doinst.sh cd $PKG /sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz diff --git a/audio/mpdscribble/mpdscribble.info b/audio/mpdscribble/mpdscribble.info index 0ae99de96e..c9b2f8db4a 100644 --- a/audio/mpdscribble/mpdscribble.info +++ b/audio/mpdscribble/mpdscribble.info @@ -1,8 +1,8 @@ PRGNAM="mpdscribble" -VERSION="0.2.12" -HOMEPAGE="http://www.frob.nl/scribble.html" -DOWNLOAD="http://www.frob.nl/projects/scribble/mpdscribble-0.2.12.tar.gz" -MD5SUM="7f0e976e7a066df0ddf21f3f4041ef6a" +VERSION="0.17" +HOMEPAGE="http://mpd.wikia.com/wiki/Client:Mpdscribble" +DOWNLOAD="http://downloads.sourceforge.net/musicpd/mpdscribble-0.17.tar.gz" +MD5SUM="ea6a0197f638443366c412cafd0a99ba" MAINTAINER="Erik Hanson" EMAIL="erik@slackbuilds.org" -APPROVED="David Somero" +APPROVED="dsomero" diff --git a/audio/mpdscribble/slack-desc b/audio/mpdscribble/slack-desc index 33189e8cae..fba110ff19 100644 --- a/audio/mpdscribble/slack-desc +++ b/audio/mpdscribble/slack-desc @@ -1,11 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. Line +# up the first '|' above the ':' following the base package name, and the '|' +# on the right side marks the last column you can put a character in. You must +# make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':'. + + |-----handy-ruler-------------------------------------------------| mpdscribble: mpdscribble (audioscrobbler daemon for mpd) mpdscribble: mpdscribble: mpdscribble is a music player daemon client which submits mpdscribble: information about tracks being played to audioscrobbler. mpdscribble: +mpdscribble: http://www.frob.nl/scribble.html mpdscribble: mpdscribble: mpdscribble: mpdscribble: -mpdscribble: http://www.frob.nl/scribble.html mpdscribble: -- cgit v1.2.3