aboutsummaryrefslogtreecommitdiff
path: root/games/einstein/einstein.SlackBuild
diff options
context:
space:
mode:
authorErik Hanson <erik@slackbuilds.org>2010-05-12 23:29:18 +0200
committerRobby Workman <rworkman@slackbuilds.org>2010-05-12 23:29:18 +0200
commite1ea50212b57c7c82e455548ea70fa2455259658 (patch)
tree5c7d8a6d10e19828304866c824778dce478330f9 /games/einstein/einstein.SlackBuild
parentf790816ee157ce9c5c8589cc8bd24248c5f0e0fa (diff)
games/einstein: Added to 12.2 repository
Diffstat (limited to 'games/einstein/einstein.SlackBuild')
-rw-r--r--games/einstein/einstein.SlackBuild62
1 files changed, 62 insertions, 0 deletions
diff --git a/games/einstein/einstein.SlackBuild b/games/einstein/einstein.SlackBuild
new file mode 100644
index 0000000000000..b3a53e319d311
--- /dev/null
+++ b/games/einstein/einstein.SlackBuild
@@ -0,0 +1,62 @@
+#!/bin/sh
+
+# Slackware build script for einstein
+# Written by Erik Hanson erik@slackbuilds.org
+
+PRGNAM=einstein
+VERSION=2.0
+ARCH=${ARCH:-i486}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+fi
+
+set -eu
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION-src.tar.gz
+cd $PRGNAM-$VERSION
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \;
+
+# Some patches from debian.
+for PATCH in $CWD/patches/*.diff ; do
+ patch -p0 < $PATCH
+done
+
+# Build
+make PREFIX="/usr" OPTIMIZE="$SLKCFLAGS"
+
+# Install
+install -D -s -m 0755 einstein $PKG/usr/games/einstein
+install -D einstein.res $PKG/usr/share/einstein/res/einstein.res
+install -D $CWD/einstein.desktop $PKG/usr/share/applications/einstein.desktop
+install -D $CWD/einstein.png $PKG/usr/share/pixmaps/einstein.png
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a README $CWD/patches $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+chown -R root:root $PKG/usr/doc/$PRGNAM-$VERSION
+
+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