From cafc11376c87d627083bc9f8f022a80eb9d55eba Mon Sep 17 00:00:00 2001 From: David Somero Date: Fri, 4 Jun 2010 01:16:36 -0400 Subject: [PATCH] system/rdiff-backup: Misc automated cleanups. Signed-off-by: David Somero --- system/rdiff-backup/rdiff-backup.SlackBuild | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/system/rdiff-backup/rdiff-backup.SlackBuild b/system/rdiff-backup/rdiff-backup.SlackBuild index bf33653912..2151f73c17 100644 --- a/system/rdiff-backup/rdiff-backup.SlackBuild +++ b/system/rdiff-backup/rdiff-backup.SlackBuild @@ -25,12 +25,21 @@ PRGNAM=rdiff-backup VERSION=1.2.8 -ARCH=${ARCH:-i486} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} -TMP=${TMP:-/tmp/SBo} +# Automatically determine the architecture we're building on: +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i486 ;; + arm*) ARCH=arm ;; + # Unless $ARCH is already set, use uname -m for all other archs: + *) ARCH=$( uname -m ) ;; + esac +fi + CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp}