summaryrefslogtreecommitdiffstats
path: root/games/nblood/nblood.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'games/nblood/nblood.SlackBuild')
-rw-r--r--games/nblood/nblood.SlackBuild37
1 files changed, 25 insertions, 12 deletions
diff --git a/games/nblood/nblood.SlackBuild b/games/nblood/nblood.SlackBuild
index d96b3e63e0..9a104127d4 100644
--- a/games/nblood/nblood.SlackBuild
+++ b/games/nblood/nblood.SlackBuild
@@ -1,8 +1,8 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for nblood
-# Written by B. Watson (yalhcru@gmail.com)
+# Written by B. Watson (urchlay@slackware.uk)
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
@@ -13,10 +13,18 @@
# the shareware version from eduke32_shareware_data. I expect upstream
# will finish the support for these at a later date...
+# 20230118 bkw: updated for v1.01+20230118_49af62a01, aka latest git.
+# It's not clear to me that the "1.01" is still correct: they don't
+# do releases or tags, and there's no mention of the version number
+# in README.md.
+
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=nblood
-VERSION=${VERSION:-1.01+20200428_069c52b26}
+VERSION=${VERSION:-1.01+20230118_49af62a01}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -26,7 +34,11 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
@@ -55,19 +67,20 @@ find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \
# nblood looks in /usr/share/games/nblood/, which is fine.
-# pcexhumed doesn't look in /usr anywhere, so I'll make up a dir name
-# for it to use.
-sed -i \
- '/^ *addsearchpath(cwd);/aaddsearchpath("/usr/share/games/pcexhumed");' \
- source/exhumed/src/exhumed.cpp
+# pcexhumed now looks in /usr/share/games/pcexhumed, which is also the
+# dir I used to patch it to use.
# The engine wants to write a log file in the current directory where
# it gets run... and segfaults if it can't. The log file is just a copy
# of the process's stderr it looks like, so let's disable it.
sed -i.bak \
's|OSD_SetLogFile(APPBASENAME ".log");|OSD_SetLogFile("/dev/null");|' \
- source/blood/src/blood.cpp \
+ source/duke3d/src/game.cpp \
+ source/tekwar/src/tekgame.cpp \
+ source/sw/src/game.cpp \
source/rr/src/game.cpp \
+ source/blood/src/blood.cpp \
+ source/witchaven/src/witchaven.cpp \
source/exhumed/src/exhumed.cpp
make
@@ -106,7 +119,7 @@ for icon in $CWD/icons/*.png; do
done
mkdir -p $PKG/usr/share/pixmaps
-cat $CWD/icons/64.png > $PKG/usr/share/pixmaps/$PRGNAM.png
+ln -s ../icons/hicolor/48x48/apps/$PRGNAM.png $PKG/usr/share/pixmaps/$PRGNAM.png
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a *.md source/blood/gpl-2.0.txt $PKG/usr/doc/$PRGNAM-$VERSION
@@ -117,4 +130,4 @@ sed "s,@WITHDATA@,$WITHDATA," $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.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE