diff options
Diffstat (limited to 'source/ap/xfsdump/xfsdump.SlackBuild')
-rwxr-xr-x | source/ap/xfsdump/xfsdump.SlackBuild | 27 |
1 files changed, 23 insertions, 4 deletions
diff --git a/source/ap/xfsdump/xfsdump.SlackBuild b/source/ap/xfsdump/xfsdump.SlackBuild index 378d46de..f293b6a3 100755 --- a/source/ap/xfsdump/xfsdump.SlackBuild +++ b/source/ap/xfsdump/xfsdump.SlackBuild @@ -1,6 +1,6 @@ #!/bin/sh -# Copyright 2008, 2009 Patrick J. Volkerding, Sebeka, MN, USA +# Copyright 2008, 2009, 2010 Patrick J. Volkerding, Sebeka, MN, USA # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -21,12 +21,21 @@ # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -VERSION=3.0.1 -ARCH=${ARCH:-x86_64} +VERSION=${VERSION:-$(echo xfsdump-*.tar.?z* | rev | cut -f 3- -d . | cut -f 1 -d - | rev)} BUILD=${BUILD:-1} NUMJOBS=${NUMJOBS:-" -j7 "} +# Automatically determine the architecture we're building on: +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) export ARCH=i486 ;; + arm*) export ARCH=arm ;; + # Unless $ARCH is already set, use uname -m for all other archs: + *) export ARCH=$( uname -m ) ;; + esac +fi + CWD=$(pwd) TMP=${TMP:-/tmp} PKG=$TMP/package-xfsdump @@ -54,7 +63,7 @@ autoconf ./configure \ --prefix=/usr \ - --sbindir=/sbin \ + --sbindir=/usr/sbin \ --bindir=/usr/sbin \ --enable-gettext=yes \ --mandir=/usr/man \ @@ -99,6 +108,16 @@ mkdir -p $PKG/usr/doc/xfsdump-$VERSION/html cp -a *.gif *.html $PKG/usr/doc/xfsdump-$VERSION/html ) +rm -f $PKG/usr/doc/xfsdump-$VERSION/CHANGES.gz + +# If there's a ChangeLog, installing at least part of the recent history +# is useful, but don't let it get totally out of control: +if [ -r doc/CHANGES ]; then + DOCSDIR=$(echo $PKG/usr/doc/*-$VERSION) + cat doc/CHANGES | head -n 1000 > $DOCSDIR/CHANGES + touch -r doc/CHANGES $DOCSDIR/CHANGES +fi + mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc |