diff options
author | Michiel van Wessem <michiel@slackbuilds.org> | 2010-05-11 19:46:05 +0200 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2010-05-11 19:46:05 +0200 |
commit | 521e6c6ce4dfd2eea8da0394053c42688d668d5c (patch) | |
tree | 53150ec430e9855802725925ffadc39f557746fa /network/vnstat/vnstat.SlackBuild | |
parent | e846e1bf5fcca3f169b0e5605dfce98823d3a7b0 (diff) |
network/vnstat: Updated for version 1.6
Diffstat (limited to 'network/vnstat/vnstat.SlackBuild')
-rw-r--r-- | network/vnstat/vnstat.SlackBuild | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/network/vnstat/vnstat.SlackBuild b/network/vnstat/vnstat.SlackBuild index 3525ebd1465f6..b31203c273295 100644 --- a/network/vnstat/vnstat.SlackBuild +++ b/network/vnstat/vnstat.SlackBuild @@ -22,15 +22,12 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# Modified by the SlackBuilds.org project - -set -e - PRGNAM=vnstat -VERSION=1.4 +VERSION=1.6 ARCH=${ARCH:-i486} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} + CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM @@ -38,6 +35,8 @@ OUTPUT=${OUTPUT:-/tmp} DOCFILES="CHANGES COPYING FAQ INSTALL README UNINSTALL UPGRADE" +set -e + rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP @@ -45,13 +44,19 @@ rm -rf $PRGNAM-$VERSION tar -xzvf $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 {} \; # vnstat doesn't have a proper configure. So we set the locations in the # Makefiles properly by the way of sed-fu sed -i 's#MAN = $(DESTDIR)/usr/share/man#MAN = $(DESTDIR)/usr/man#' \ $TMP/$PRGNAM-$VERSION/Makefile -sed -i 's#CRON = $(DESTDIR)/etc/cron.d#CRON = $(DESTDIR)/usr/doc/vnstat-1.4/scripts#' \ +sed -i "s#CRON = \$(DESTDIR)/etc/cron.d#CRON = \$(DESTDIR)/usr/doc/$PRGNAM-$VERSION/scripts#" \ + $TMP/$PRGNAM-$VERSION/Makefile +sed -i 's#install -m 644 cfg/vnstat.conf $(DESTDIR)/etc;#install -D -m 644 cfg/vnstat.conf $(DESTDIR)/etc/vnstat.conf.new;#' \ $TMP/$PRGNAM-$VERSION/Makefile # Set the compile flags in the src/Makefile properly @@ -70,6 +75,7 @@ make install DESTDIR=$PKG find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null ) + ( 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 @@ -83,6 +89,7 @@ cp -a pppd/* $PKG/usr/doc/$PRGNAM-$VERSION/scripts cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild mkdir -p $PKG/install +cat $CWD/doinst.sh > $PKG/install/doinst.sh cat $CWD/slack-desc > $PKG/install/slack-desc cd $PKG |