summaryrefslogtreecommitdiff
path: root/games/z26/z26.SlackBuild
diff options
context:
space:
mode:
authorB. Watson <yalhcru@gmail.com>2021-12-15 00:20:13 -0500
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2021-12-27 16:20:25 +0700
commit0788bf4363a15ecf8585638be5dd9c1719d7c543 (patch)
tree8863b1efa3ec747a86154c22885dd4083020605a /games/z26/z26.SlackBuild
parent8d61cecb26caf2dcae7542c7eb15d94af9d03f0c (diff)
downloadslackbuilds-0788bf4363a15ecf8585638be5dd9c1719d7c543.tar.gz
games/z26: Fix build on -current. Again.
Signed-off-by: B. Watson <yalhcru@gmail.com> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'games/z26/z26.SlackBuild')
-rw-r--r--games/z26/z26.SlackBuild22
1 files changed, 20 insertions, 2 deletions
diff --git a/games/z26/z26.SlackBuild b/games/z26/z26.SlackBuild
index 4534915c20..0742744f5b 100644
--- a/games/z26/z26.SlackBuild
+++ b/games/z26/z26.SlackBuild
@@ -7,6 +7,13 @@
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
+# 20211214 bkw:
+# - BUILD=3
+# - update for -current, which involves building with 14.2's nasm.
+# there's probably a better way to fix it, but it's been 16+ years
+# since I looked at z26's asm source and the details elude me now.
+# - TODO: fix the statified binary for x86_64 use.
+
# 20180123 bkw:
# - move binary to /usr/games, man page to section 6
# - 64-bit support via statified binary (see statify.sh)
@@ -16,7 +23,7 @@ cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=z26
VERSION=${VERSION:-2.13}
-BUILD=${BUILD:-2}
+BUILD=${BUILD:-3}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@@ -58,12 +65,17 @@ fi
set -e
+# 20211214 bkw: recent versions of nasm won't build this, so use
+# an older one (the one from Slackware 14.2, actually).
+NASMVER=${NASMVER:-2.13.01}
+
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $SNAPVER
tar xvf $CWD/$TARBALL
cd $SNAPVER
+tar xvf $CWD/nasm-$NASMVER.tar.xz
chown -R root:root .
find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \
\! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+
@@ -76,7 +88,13 @@ if [ "$ARCH" = "x86_64" ]; then
chmod 755 $PRGNAM
cp conf/config_linux-static.mak config.mak
else
- make linux CFLAGS="$SLKCFLAGS"
+ cd nasm-$NASMVER
+ CFLAGS="$SLKCFLAGS -Wno-error" ./configure --disable-werror
+ # neither CFLAGS="-Wno-error" nor --disable-werror actually works.
+ sed -i 's,-Werror[^ ]*,,g' Makefile
+ make
+ cd -
+ make linux NASM="$(pwd)/nasm-$NASMVER/nasm" CFLAGS="$SLKCFLAGS"
fi
make $PRGNAM.man
make docs