aboutsummaryrefslogtreecommitdiff
path: root/libraries/libdmtx/libdmtx.SlackBuild
diff options
context:
space:
mode:
authorDavid Somero <xgizzmo@slackbuilds.org>2010-06-04 01:07:36 -0400
committerDavid Somero <xgizzmo@slackbuilds.org>2010-06-04 01:07:36 -0400
commite1e4c6e795c92f281e61aeb3f8f773c03c59c6d1 (patch)
tree92eedf5ae3c97365a404cab370e3e573d7ca16d7 /libraries/libdmtx/libdmtx.SlackBuild
parenta48bb2d96513dcea85d077afab1fc0aff9ce30b3 (diff)
libraries/libdmtx: Misc automated cleanups.
Signed-off-by: David Somero <xgizzmo@slackbuilds.org>
Diffstat (limited to 'libraries/libdmtx/libdmtx.SlackBuild')
-rw-r--r--libraries/libdmtx/libdmtx.SlackBuild14
1 files changed, 13 insertions, 1 deletions
diff --git a/libraries/libdmtx/libdmtx.SlackBuild b/libraries/libdmtx/libdmtx.SlackBuild
index b94676290c648..dc4a848ea6feb 100644
--- a/libraries/libdmtx/libdmtx.SlackBuild
+++ b/libraries/libdmtx/libdmtx.SlackBuild
@@ -7,10 +7,19 @@
PRGNAM=libdmtx
VERSION=${VERSION:-0.7.2}
-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