summaryrefslogtreecommitdiff
path: root/accessibility/xdotool/xdotool.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'accessibility/xdotool/xdotool.SlackBuild')
-rw-r--r--accessibility/xdotool/xdotool.SlackBuild16
1 files changed, 10 insertions, 6 deletions
diff --git a/accessibility/xdotool/xdotool.SlackBuild b/accessibility/xdotool/xdotool.SlackBuild
index 8161b042e0..1300e01bc1 100644
--- a/accessibility/xdotool/xdotool.SlackBuild
+++ b/accessibility/xdotool/xdotool.SlackBuild
@@ -17,10 +17,13 @@ OUTPUT=${OUTPUT:-/tmp}
if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
fi
set -e
@@ -34,21 +37,22 @@ cd $PRGNAM-$VERSION
chown -R root:root .
chmod -R a-s,u+w,go+r-w .
-sed -i -e "/^CFLAGS/s/-/$SLKCFLAGS -/" Makefile
-make PREFIX=/usr
+make WARNFLAGS="$SLKCFLAGS" PREFIX=/usr
mkdir -p $PKG/usr/bin $PKG/usr/man/man1
-strip $PRGNAM
make install PREFIX=$PKG/usr
+
+strip --strip-unneeded $PKG/usr/bin/$PRGNAM 2>/dev/null || true
gzip -9 $PKG/usr/man/man1/$PRGNAM.1
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -r README COPYRIGHT COPYRIGHT examples xdotool.pod \
- $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a \
+ README COPYRIGHT examples xdotool.pod \
+ $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
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}