slackbuilds/y/scribble/scribble.SlackBuild

70 lines
2.3 KiB
Text
Raw Normal View History

2011-02-18 09:00:28 +01:00
#!/bin/sh -x
CWD=$(pwd)
TAG=cyco
OUTPUT=/tmp
TMP=/tmp/$TAG
PRGNAM=$(basename $CWD)
VERSION=1.11-1
ARCH=${ARCH:-$(uname -m)}
2011-03-06 09:24:25 +01:00
BUILD=3
2011-02-18 09:00:28 +01:00
PKG=$TMP/pkg-$PRGNAM
rm -rf $PKG $TMP/${PRGNAM}-${VERSION}
cd $TMP
[ ! -e $CWD/${PRGNAM}_${VERSION}.tar.gz ] && wget -c http://ftp.de.debian.org/debian/pool/main/s/scribble/${PRGNAM}_${VERSION}.tar.gz -O $CWD/${PRGNAM}_${VERSION}.tar.gz
tar xf $CWD/${PRGNAM}_${VERSION}.tar.gz
mv ${PRGNAM} ${PRGNAM}-${VERSION}
cd ${PRGNAM}-${VERSION}
chown -R root.root *
find . -perm 777 -exec chmod 755 {} \;
make prefix=$PKG/usr mandir=$PKG/usr/man
2011-03-06 07:22:25 +01:00
# Racket also has a 'scribble' binary in /usr/bin
# Scribble's scribble is in /usr/games but Racket's steal its place in $PATH
2011-03-06 09:24:13 +01:00
( cd $PKG/usr/games/
2011-03-06 07:22:25 +01:00
ln -s scribble scribble-scrabble
)
2011-03-06 09:24:13 +01:00
( cd $PKG/usr/man/man6/
ln -s scribble.6.gz scribble-scrabble.6.gz
)
2011-03-06 07:22:25 +01:00
2011-02-18 09:00:28 +01:00
# Compress the man page(s)
[ -d $PKG/usr/man ] && find $PKG/usr/man -type f -name "*.?" -exec gzip -9f {} \;
chmod -R o-w $PKG
chown -R root:root $PKG/*
mkdir -p $PKG/install
cat <<EOF > $PKG/install/slack-desc
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|'
# on the right side marks the last column you can put a character in. You must
# make exactly 11 lines for the formatting to be correct. It's also
# customary to leave one space after the ':'.
|-----handy-ruler------------------------------------------------------|
${PRGNAM}: ${PRGNAM} (CLI Popular crossword game, similar to Scrabble<6C>)
${PRGNAM}:
${PRGNAM}: Scribble is a hybrid of crossword mentality, positional strategy, and
${PRGNAM}: a true test of your language mastery, similar to the game Scrabble<6C>
${PRGNAM}: by Hasbro. You start with a board that serves for the placement for
${PRGNAM}: letter tiles. On the board there are specific squares that when used can
${PRGNAM}: add to your score dramatically. These premium squares can double or triple
${PRGNAM}: letter values. Some of these squares can even double or triple your word
${PRGNAM}: scores! You must position yourself to grab the squares and block your
${PRGNAM}: opponent from spelling out a "killer" word.
${PRGNAM}: http://packages.debian.org/unstable/games/scribble
EOF
cd $PKG
makepkg --linkadd y --chown n $OUTPUT/${PRGNAM}-$(echo ${VERSION} | tr - _)-${ARCH}-${BUILD}$TAG.txz