slackbuilds/y/scribble/scribble.SlackBuild
Gwenhael Le Moine 5fce56b9e5 bump $BUILD
2011-03-06 15:24:25 +07:00

69 lines
2.3 KiB
Bash
Executable file

#!/bin/sh -x
CWD=$(pwd)
TAG=cyco
OUTPUT=/tmp
TMP=/tmp/$TAG
PRGNAM=$(basename $CWD)
VERSION=1.11-1
ARCH=${ARCH:-$(uname -m)}
BUILD=3
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
# Racket also has a 'scribble' binary in /usr/bin
# Scribble's scribble is in /usr/games but Racket's steal its place in $PATH
( cd $PKG/usr/games/
ln -s scribble scribble-scrabble
)
( cd $PKG/usr/man/man6/
ln -s scribble.6.gz scribble-scrabble.6.gz
)
# 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®)
${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®
${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