diff options
Diffstat (limited to 'source/ap/a2ps')
-rwxr-xr-x | source/ap/a2ps/a2ps.SlackBuild | 25 |
1 files changed, 21 insertions, 4 deletions
diff --git a/source/ap/a2ps/a2ps.SlackBuild b/source/ap/a2ps/a2ps.SlackBuild index b8e5ed18..6df5f4d0 100755 --- a/source/ap/a2ps/a2ps.SlackBuild +++ b/source/ap/a2ps/a2ps.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 @@ -26,8 +26,17 @@ PKGNAM2=psutils VERSION=${VERSION:-4.14} A2PS=${A2PS:-4.14} PSUTILS=${PSUTILS:-1.17} -ARCH=${ARCH:-x86_64} -BUILD=${BUILD:-4} +BUILD=${BUILD:-5} + +# 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} @@ -123,10 +132,18 @@ find $PKG | xargs file | grep -e "executable" -e "shared object" \ # Add a documentation directory: mkdir -p $PKG/usr/doc/a2ps-$VERSION -cp -a ABOUT-NLS ANNOUNCE AUTHORS COPYING ChangeLog \ +cp -a ABOUT-NLS ANNOUNCE AUTHORS COPYING \ FAQ INSTALL NEWS README THANKS TODO \ $PKG/usr/doc/a2ps-$VERSION +# 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 ChangeLog ]; then + DOCSDIR=$(echo $PKG/usr/doc/${PKGNAM}-$VERSION) + cat ChangeLog | head -n 1000 > $DOCSDIR/ChangeLog + touch -r ChangeLog $DOCSDIR/ChangeLog +fi + # Compress info files, if any: if [ -d $PKG/usr/info ]; then ( cd $PKG/usr/info |