summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Somero <xgizzmo@slackbuilds.org>2010-06-04 01:08:27 -0400
committerDavid Somero <xgizzmo@slackbuilds.org>2010-06-04 01:08:27 -0400
commitde5f88de4b67d868aa5ca597d83354a8ed232932 (patch)
tree94fca5566ca333ecf84005075dad56a5d36be6ad
parenta36334203673968cf9cf531793abcbb4908efd7d (diff)
downloadslackbuilds-de5f88de4b67d868aa5ca597d83354a8ed232932.tar.gz
libraries/libnetfilter_queue: Misc automated cleanups.
Signed-off-by: David Somero <xgizzmo@slackbuilds.org>
-rw-r--r--libraries/libnetfilter_queue/libnetfilter_queue.SlackBuild14
1 files changed, 13 insertions, 1 deletions
diff --git a/libraries/libnetfilter_queue/libnetfilter_queue.SlackBuild b/libraries/libnetfilter_queue/libnetfilter_queue.SlackBuild
index d90b8af3ec..50d15f5c5b 100644
--- a/libraries/libnetfilter_queue/libnetfilter_queue.SlackBuild
+++ b/libraries/libnetfilter_queue/libnetfilter_queue.SlackBuild
@@ -26,10 +26,19 @@
PRGNAM=libnetfilter_queue
VERSION=0.0.16
-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
@@ -44,6 +53,9 @@ elif [ "$ARCH" = "i686" ]; then
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
fi
set -e