summaryrefslogtreecommitdiffstats
path: root/games/LucasChess/LucasChess.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'games/LucasChess/LucasChess.SlackBuild')
-rw-r--r--games/LucasChess/LucasChess.SlackBuild25
1 files changed, 23 insertions, 2 deletions
diff --git a/games/LucasChess/LucasChess.SlackBuild b/games/LucasChess/LucasChess.SlackBuild
index dfd10af1a3..a0c10cdb0f 100644
--- a/games/LucasChess/LucasChess.SlackBuild
+++ b/games/LucasChess/LucasChess.SlackBuild
@@ -30,11 +30,11 @@
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=LucasChess
-VERSION=${VERSION:-R2.11g}
+VERSION=${VERSION:-R2.15a}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
-SRCNAM=${SRCNAM:-LucasChessR2_11g_LINUX.sh}
+SRCNAM=${SRCNAM:-LucasChessR2_15a_LINUX.sh}
ARCHIVELINE=716
if [ -z "$ARCH" ]; then
@@ -59,6 +59,18 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
+LUCASGRP=${LUCASGRP:-lucaschess}
+LUCASGID=${LUCASGID:-385}
+
+# Check for lucaschess group here
+if ! getent group | grep -q ^${LUCASGRP}: 2>/dev/null; then
+ echo "You must have a ${LUCASGRP} group to run this script."
+ echo " # groupadd -g ${LUCASGID} ${LUCASGRP}"
+ echo "Then add your user to this group (then have them log out and back in):"
+ echo " # usermod -a -G ${LUCASGRP} your_username"
+ echo "Exiting..." ; exit 1
+fi
+
set -e
rm -rf $PKG
@@ -104,6 +116,15 @@ ln -sf Fox Fox.exe
rm $PKG/opt/$PRGNAM-$VERSION/bin/Code/Config/Configuration.pyc
cat $CWD/Configuration.py > $PKG/opt/$PRGNAM-$VERSION/bin/Code/Config/Configuration.py
+# stockfish directory needs to be writable by ${LUCASGRP} group. This is for the
+# setup step on first use where it detects the appropriate stockfish build for
+# your system.
+chgrp -R ${LUCASGRP} $PKG/opt/$PRGNAM-$VERSION
+chmod g+w $PKG/opt/$PRGNAM-$VERSION/bin/OS/linux/Engines/stockfish
+
+# Similarly for the alouette directory
+chmod g+w $PKG/opt/$PRGNAM-$VERSION/bin/OS/linux/Engines/alouette
+
# Install desktop launcher
sed "s/VERSION/${VERSION}/g" $CWD/LucasChessR.desktop.in \
> $PKG/usr/share/applications/LucasChessR.desktop