diff options
Diffstat (limited to 'games/crispy-doom/crispy-doom.SlackBuild')
-rw-r--r-- | games/crispy-doom/crispy-doom.SlackBuild | 37 |
1 files changed, 24 insertions, 13 deletions
diff --git a/games/crispy-doom/crispy-doom.SlackBuild b/games/crispy-doom/crispy-doom.SlackBuild index 3b520aa3a1..f0f4cbd804 100644 --- a/games/crispy-doom/crispy-doom.SlackBuild +++ b/games/crispy-doom/crispy-doom.SlackBuild @@ -1,9 +1,9 @@ -#!/bin/sh +#!/bin/bash # Slackware build script for crispy-doom # Copyright 2015 Dugan Chen Canada -# Updates copyright 2019, 2020 Lenard Spencer +# Updates copyright 2019, 2020, 2021 Lenard Spencer # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -23,10 +23,13 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +cd $(dirname $0) ; CWD=$(pwd) + PRGNAM=crispy-doom -VERSION=${VERSION:-5.10.0} +VERSION=${VERSION:-6.0} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} if [ -z "$ARCH" ]; then case "$( uname -m )" in @@ -36,7 +39,14 @@ if [ -z "$ARCH" ]; then esac fi -CWD=$(pwd) +# If the variable PRINT_PACKAGE_NAME is set, then this script will report what +# the name of the created package would be, and then exit. This information +# could be useful to other scripts. +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} @@ -70,15 +80,12 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; -sh autogen.sh +autoreconf -fiv CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ ./configure \ --prefix=/usr \ - --libdir=/usr/lib${LIBDIRSUFFIX} \ - --sysconfdir=/etc \ - --localstatedir=/var \ --mandir=/usr/man \ --docdir=/usr/doc/$PRGNAM \ --bindir=/usr/games \ @@ -93,16 +100,20 @@ find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | gr find $PKG/usr/man -type f -exec gzip -9 {} \; for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done -# Crispy-doom creates its own doc directory, so we'll use that and rename it: +# Remove unnecessary GNOME screensaver desktop entry: +rm -rf $PKG/usr/share/applications/screensavers + mv $PKG/usr/doc/$PRGNAM $PKG/usr/doc/$PRGNAM-$VERSION -cp -n AUTHORS ChangeLog *.md $PKG/usr/doc/$PRGNAM-$VERSION || true +( cd $PKG/usr/doc/$PRGNAM-$VERSION + mkdir -p $PRGNAM + mv *.doom $PRGNAM + mv ../crispy-{heretic,hexen,strife} . + ) cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild -# We'll rename the doc/crispy-heretic folder as well for consistency: -mv $PKG/usr/doc/crispy-heretic $PKG/usr/doc/crispy-heretic-$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.${PKGTYPE:-tgz} +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE |