aboutsummaryrefslogtreecommitdiff
path: root/games/dungeon/dungeon.SlackBuild
diff options
context:
space:
mode:
authorB. Watson <yalhcru@gmail.com>2012-12-16 17:42:33 -0500
committerdsomero <xgizzmo@slackbuilds.org>2012-12-23 09:16:18 -0500
commitc1a2e05a2f2071ee7c2b9f85755c176d32477773 (patch)
treeada42adfa2a5ce142a42fbadfc299b3758ea847e /games/dungeon/dungeon.SlackBuild
parentccd0cf8537d77b54cc757f715ef5cc3c31389eec (diff)
games/dungeon: Added (text adventure game)
Signed-off-by: dsomero <xgizzmo@slackbuilds.org>
Diffstat (limited to 'games/dungeon/dungeon.SlackBuild')
-rw-r--r--games/dungeon/dungeon.SlackBuild64
1 files changed, 64 insertions, 0 deletions
diff --git a/games/dungeon/dungeon.SlackBuild b/games/dungeon/dungeon.SlackBuild
new file mode 100644
index 0000000000000..4787af606df98
--- /dev/null
+++ b/games/dungeon/dungeon.SlackBuild
@@ -0,0 +1,64 @@
+#!/bin/bash
+
+# Slackware build script for dungeon
+
+# Written by B. Watson (yalhcru@gmail.com)
+
+# Licensed under the WTFPL. See http://sam.zoy.org/wtfpl/ for details.
+
+PRGNAM=dungeon
+VERSION=${VERSION:-19800808}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i486 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+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"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
+cd $PRGNAM-$VERSION
+chown -R root:root .
+
+[ "${DEBUG:-no}" = "yes" ] && DFLAG='DEBUG=1'
+
+make FFLAGS="$SLKCFLAGS" $DFLAG
+make install DESTDIR=$PKG
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+install -m0644 $CWD/$PRGNAM.jpg history read.me $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
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}