diff options
Diffstat (limited to 'games/chocolate-doom/chocolate-doom.SlackBuild')
-rw-r--r-- | games/chocolate-doom/chocolate-doom.SlackBuild | 28 |
1 files changed, 18 insertions, 10 deletions
diff --git a/games/chocolate-doom/chocolate-doom.SlackBuild b/games/chocolate-doom/chocolate-doom.SlackBuild index 8fdfaa4555..a1482a9a97 100644 --- a/games/chocolate-doom/chocolate-doom.SlackBuild +++ b/games/chocolate-doom/chocolate-doom.SlackBuild @@ -1,11 +1,12 @@ -#!/bin/sh +#!/bin/bash # Slackware build script for chocolate-doom -# 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. +# 20210727 bkw: fix build on -current (does no harm on 14.2), BUILD=2. # 20201019 bkw: update for v3.0.1. # 20180101 bkw: # - Update for v3.0.0. Building 2.3.0 still works, if someone needs it. @@ -23,10 +24,13 @@ # - get rid of no-longer-needed disable_windres.diff # - update README and slack-desc +cd $(dirname $0) ; CWD=$(pwd) + PRGNAM=chocolate-doom VERSION=${VERSION:-3.0.1} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} if [ -z "$ARCH" ]; then case "$( uname -m )" in @@ -36,7 +40,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} @@ -73,11 +81,11 @@ rm -rf $PRGNAM-$REALVER $PRGNAM-$PRGNAM-$REALVER tar xvf $CWD/$PRGNAM-$REALVER.tar.gz || tar xvf $CWD/$PRGNAM-$PRGNAM-$REALVER.tar.gz cd $PRGNAM-$REALVER || cd $PRGNAM-$PRGNAM-$REALVER chown -R root:root . -find -L . \ - \( -perm 777 -o -perm 775 -o -perm 750 -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 {} \; +find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \ + \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+ + +# upstream fix from git, easier to use sed than make a diff. +sed -i '/^boolean demoextend/d' src/hexen/mn_menu.c [ -x configure ] || sh autogen.sh @@ -130,4 +138,4 @@ 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.${PKGTYPE:-tgz} +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE |