summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Somero <xgizzmo@slackbuilds.org>2010-06-04 01:14:50 -0400
committerDavid Somero <xgizzmo@slackbuilds.org>2010-06-04 01:14:50 -0400
commit74365fb8a912c9b7ff25ce734adb948b065402a7 (patch)
tree88b0e3e60637dfd696d0c4fbed1e090b3e21ca20
parent31c0647cd69238d7c8931a8f371d3a79ee36f67f (diff)
downloadslackbuilds-74365fb8a912c9b7ff25ce734adb948b065402a7.tar.gz
office/kmymoney2: Misc automated cleanups.
Signed-off-by: David Somero <xgizzmo@slackbuilds.org>
-rw-r--r--office/kmymoney2/kmymoney2.SlackBuild14
1 files changed, 13 insertions, 1 deletions
diff --git a/office/kmymoney2/kmymoney2.SlackBuild b/office/kmymoney2/kmymoney2.SlackBuild
index ffa731f64a..7e07ec4631 100644
--- a/office/kmymoney2/kmymoney2.SlackBuild
+++ b/office/kmymoney2/kmymoney2.SlackBuild
@@ -29,10 +29,19 @@
PRGNAM=kmymoney2
VERSION=${VERSION:-1.0.0}
-ARCH=${ARCH:-i486}
BUILD=${BUILD:-1}
TAG=${TAG:-_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
@@ -50,6 +59,9 @@ elif [ "$ARCH" = "i686" ]; then
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
fi
set -e # Exit on most of the errors.