aboutsummaryrefslogtreecommitdiff
path: root/libraries/gnet
diff options
context:
space:
mode:
authorDavid Somero <xgizzmo@slackbuilds.org>2010-06-04 01:06:44 -0400
committerDavid Somero <xgizzmo@slackbuilds.org>2010-06-04 01:06:44 -0400
commit538fbdc0ff573dd1d0418026a21e462471382b2a (patch)
tree99a894b8070173ed3f3ec96cd9348955ab509b5d /libraries/gnet
parentaff57cc713a32f2b442616701abe2057dd1e2d6e (diff)
libraries/gnet: Misc automated cleanups.
Signed-off-by: David Somero <xgizzmo@slackbuilds.org>
Diffstat (limited to 'libraries/gnet')
-rw-r--r--libraries/gnet/gnet.SlackBuild14
1 files changed, 13 insertions, 1 deletions
diff --git a/libraries/gnet/gnet.SlackBuild b/libraries/gnet/gnet.SlackBuild
index 8c109a3bd994..922846bab7de 100644
--- a/libraries/gnet/gnet.SlackBuild
+++ b/libraries/gnet/gnet.SlackBuild
@@ -12,10 +12,19 @@
PRGNAM=gnet
VERSION=2.0.8
-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
@@ -30,6 +39,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 errors