diff options
Diffstat (limited to 'desktop/cmatrix/cmatrix.SlackBuild')
-rw-r--r-- | desktop/cmatrix/cmatrix.SlackBuild | 31 |
1 files changed, 21 insertions, 10 deletions
diff --git a/desktop/cmatrix/cmatrix.SlackBuild b/desktop/cmatrix/cmatrix.SlackBuild index 1efb113f6049c..9e5038f2c42e9 100644 --- a/desktop/cmatrix/cmatrix.SlackBuild +++ b/desktop/cmatrix/cmatrix.SlackBuild @@ -6,7 +6,7 @@ PRGNAM=cmatrix VERSION=1.2a ARCH=${ARCH:-i486} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} CWD=$(pwd) @@ -16,10 +16,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" - elif [ "$ARCH" = "x86_64" ]; then + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" fi set -e @@ -33,11 +36,21 @@ cd $PRGNAM-$VERSION chown -R root:root . chmod -R a-s,u+rw,go-w . +# Patch configure to find the fonts correctly +patch -p1 < $CWD/cmatrix-1.2a-find_fonts.diff + CFLAGS="$SLKCFLAGS" \ -CPPFLAGS="$SLKCFLAGS" \ -./configure --prefix=/usr +CXXFLAGS="$SLKCFLAGS" \ +./configure \ + --prefix=/usr \ + --libdir=/usr/lib${LIBDIRSUFFIX} \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --mandir=/usr/man \ + --disable-static \ + --build=$ARCH-slackware-linux -CFLAGS="$SLKCFLAGS" CPPFLAGS="$SLKCFLAGS" make +make # Manual install - patching the Makefile not worth it install -D -m 0755 $TMP/$PRGNAM-$VERSION/cmatrix \ @@ -51,10 +64,8 @@ install -D -m 0644 $TMP/$PRGNAM-$VERSION/matrix.psf.gz \ install -D -m 0644 $TMP/$PRGNAM-$VERSION/mtx.pcf \ $PKG/usr/share/fonts/misc/mtx.pcf -( cd $PKG - 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 # Compress the man page gzip -9 $PKG/usr/man/man1/cmatrix.1 @@ -68,4 +79,4 @@ cat $CWD/slack-desc > $PKG/install/slack-desc cat $CWD/doinst.sh > $PKG/install/doinst.sh 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} |