summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Somero <xgizzmo@slackbuilds.org>2010-06-04 01:10:42 -0400
committerDavid Somero <xgizzmo@slackbuilds.org>2010-06-04 01:10:42 -0400
commit00995aa05c57bd2ae0bb6c96a3aacb9c6da1c1b9 (patch)
tree6b8cb3ba73d7cbd86c2508d204b31de98d801443
parent138e0178c80771187c740290b8dac4e81da8266a (diff)
downloadslackbuilds-00995aa05c57bd2ae0bb6c96a3aacb9c6da1c1b9.tar.gz
libraries/xmonad-contrib: Misc automated cleanups.
Signed-off-by: David Somero <xgizzmo@slackbuilds.org>
-rw-r--r--libraries/xmonad-contrib/xmonad-contrib.SlackBuild14
1 files changed, 13 insertions, 1 deletions
diff --git a/libraries/xmonad-contrib/xmonad-contrib.SlackBuild b/libraries/xmonad-contrib/xmonad-contrib.SlackBuild
index 93a20cdefa..08f2270e64 100644
--- a/libraries/xmonad-contrib/xmonad-contrib.SlackBuild
+++ b/libraries/xmonad-contrib/xmonad-contrib.SlackBuild
@@ -7,10 +7,19 @@
PRGNAM=xmonad-contrib
VERSION=${VERSION:-0.9.1}
-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
@@ -25,6 +34,9 @@ elif [ "$ARCH" = "i686" ]; then
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
fi
set -e