summaryrefslogtreecommitdiff
path: root/graphics/mftrace/mftrace.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'graphics/mftrace/mftrace.SlackBuild')
-rw-r--r--graphics/mftrace/mftrace.SlackBuild23
1 files changed, 14 insertions, 9 deletions
diff --git a/graphics/mftrace/mftrace.SlackBuild b/graphics/mftrace/mftrace.SlackBuild
index f4f67caf4a..54d83fd296 100644
--- a/graphics/mftrace/mftrace.SlackBuild
+++ b/graphics/mftrace/mftrace.SlackBuild
@@ -6,26 +6,32 @@
set -e
PRGNAM=mftrace
-VERSION=1.2.14
+VERSION=1.2.15
ARCH=${ARCH:-i486}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+
CWD=$(pwd)
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
if [ "$ARCH" = "i486" ]; then
- SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
- SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX=""
fi
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
-tar -xzvf $CWD/$PRGNAM-$VERSION.tar.gz
+tar -xvf $CWD/$PRGNAM-$VERSION.tar.gz
cd $PRGNAM-$VERSION
chown -R root:root .
chmod -R u+w,go+r-w,a-s .
@@ -35,6 +41,7 @@ sed -i "s/^CFLAGS =/CFLAGS +=/" GNUmakefile.in
./configure \
--prefix=/usr \
+ --libdir=/usr/lib$LIBDIRSUFFIX \
--sysconfdir=/etc \
--localstatedir=/var \
--mandir=/usr/man \
@@ -44,10 +51,8 @@ sed -i "s/^CFLAGS =/CFLAGS +=/" GNUmakefile.in
CFLAGS="$SLKCFLAGS" make
make install DESTDIR=$PKG
-( cd $PKG
- find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
- 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
( cd $PKG/usr/man
find . -type f -exec gzip -9 {} \;
@@ -62,4 +67,4 @@ mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}