diff options
Diffstat (limited to 'desktop/liberation-fonts-ttf/liberation-fonts-ttf.SlackBuild')
-rw-r--r-- | desktop/liberation-fonts-ttf/liberation-fonts-ttf.SlackBuild | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/desktop/liberation-fonts-ttf/liberation-fonts-ttf.SlackBuild b/desktop/liberation-fonts-ttf/liberation-fonts-ttf.SlackBuild new file mode 100644 index 0000000000..6390ada9ae --- /dev/null +++ b/desktop/liberation-fonts-ttf/liberation-fonts-ttf.SlackBuild @@ -0,0 +1,53 @@ +#!/bin/sh + +# Slackware build script for liberation-fonts-ttf + +# Written by core (eroc@linuxmail.org) +# I took some ideas from alienBOB's slackbuild: +# http://www.slackware.com/~alien/slackbuilds/liberation-fonts/build/liberation-fonts.SlackBuild + +set -e + +PRGNAM=liberation-fonts-ttf +PRGNAMALT=liberation-fonts +VERSION=3 +VERSIONALT=0.2 +ARCH=noarch +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf $PRGNAM-$VERSION +tar -xzvf $CWD/$PRGNAM-$VERSION.tar.gz +mv $PRGNAMALT-$VERSIONALT $PRGNAM-$VERSION +cd $PRGNAM-$VERSION +chown -R root:root . +chmod -R u+w,go+r-w,a-s . + +# To determinate Xorg's location +XPREF=$(pkg-config --variable=prefix x11) || true +if [ "$XPREF" == "/usr" ]; then + FONTDIR="$PKG/usr/share/fonts/TTF" +else + FONTDIR="$PKG/usr/X11R6/lib/X11/fonts/TTF" +fi + +mkdir -p $FONTDIR/ +cp -a *.ttf $FONTDIR/ + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a COPYING License.txt $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 +cat $CWD/doinst.sh > $PKG/install/doinst.sh + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz |