From bfbc8e8c6f321f926b56c03e71bed3e85f8a4364 Mon Sep 17 00:00:00 2001 From: dsomero Date: Fri, 21 May 2010 23:12:16 -0400 Subject: system/twin: Miscellaneous cleanups. --- system/twin/twin.SlackBuild | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) (limited to 'system/twin/twin.SlackBuild') diff --git a/system/twin/twin.SlackBuild b/system/twin/twin.SlackBuild index aaf71d94bcc91..ab8c0045ff071 100644 --- a/system/twin/twin.SlackBuild +++ b/system/twin/twin.SlackBuild @@ -26,10 +26,19 @@ PRGNAM=twin VERSION=${VERSION:-0.6.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) export ARCH=i486 ;; + arm*) export ARCH=arm ;; + # Unless $ARCH is already set, use uname -m for all other archs: + *) export ARCH=$( uname -m ) ;; + esac +fi + CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM @@ -70,13 +79,8 @@ CXXFLAGS="$SLKCFLAGS" \ make make install DESTDIR=$PKG -( cd $PKG - strip -g usr/lib/*.a - find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | \ - xargs strip --strip-unneeded 2> /dev/null || true - find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | \ - xargs strip --strip-unneeded 2> /dev/null -) +find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ + | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true mv $PKG/usr/share/man $PKG/usr/ ( cd $PKG/usr/man || exit 1 -- cgit v1.2.3