diff options
Diffstat (limited to 'desktop/wmctrl/wmctrl.SlackBuild')
-rw-r--r-- | desktop/wmctrl/wmctrl.SlackBuild | 32 |
1 files changed, 21 insertions, 11 deletions
diff --git a/desktop/wmctrl/wmctrl.SlackBuild b/desktop/wmctrl/wmctrl.SlackBuild index 8d6b180c79..18c8852a22 100644 --- a/desktop/wmctrl/wmctrl.SlackBuild +++ b/desktop/wmctrl/wmctrl.SlackBuild @@ -10,6 +10,7 @@ VERSION=1.07 ARCH=${ARCH:-i486} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} + CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM @@ -19,34 +20,43 @@ DOCS="AUTHORS ChangeLog COPYING INSTALL NEWS README" 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 + rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT -cd $TMP || exit 1 +cd $TMP rm -rf $PRGNAM-$VERSION -tar -xzvf $CWD/$PRGNAM-$VERSION.tar.gz || exit 1 -cd $PRGNAM-$VERSION || exit 1 +tar xvf $CWD/$PRGNAM-$VERSION.tar.gz +cd $PRGNAM-$VERSION chown -R root:root . chmod -R u+w,go+r-w,a-s . CFLAGS="$SLKCFLAGS" \ ./configure \ --prefix=/usr \ - || exit 1 + --libdir=/usr/lib${LIBDIRSUFFIX} \ + --sysconfdir=/etc/X11/WindowMaker \ + --mandir=/usr/man \ + --build=$ARCH-slackware-linux -make || exit 1 -make install DESTDIR=$PKG || exit 1 +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 "executable" | grep ELF | cut -f 1 -d : | \ + xargs strip --strip-unneeded 2> /dev/null || true ) -( cd $PKG/usr/man - find . -type f -exec gzip -9 {} \; -) +( cd $PKG/usr/man ; find . -type f -exec gzip -9 {} \; ) mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION cp $DOCS $PKG/usr/doc/$PRGNAM-$VERSION @@ -56,4 +66,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} |