diff options
author | Alexander Söderlund <alexander.soderlund@oktv.se> | 2014-06-17 17:48:01 +0700 |
---|---|---|
committer | Erik Hanson <erik@slackbuilds.org> | 2014-06-18 16:19:03 -0500 |
commit | 139dc4299b9915812b9abd6e0bd919051b4dd512 (patch) | |
tree | e92f80f0990ba1cb6bf51b84df3ef1ec645eeaa6 /games/hnefatafl/hnefatafl.SlackBuild | |
parent | e1c68e407e489d330130373a58160ee39cfe500f (diff) |
games/hnefatafl: Updated for version 140617.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'games/hnefatafl/hnefatafl.SlackBuild')
-rw-r--r-- | games/hnefatafl/hnefatafl.SlackBuild | 58 |
1 files changed, 31 insertions, 27 deletions
diff --git a/games/hnefatafl/hnefatafl.SlackBuild b/games/hnefatafl/hnefatafl.SlackBuild index 02823f8f65e8b..c1290d339bff3 100644 --- a/games/hnefatafl/hnefatafl.SlackBuild +++ b/games/hnefatafl/hnefatafl.SlackBuild @@ -1,15 +1,24 @@ #!/bin/sh -# Slackware 14.0 build script for HNEFATAFL +# Slackware 14.1 build script for Hnefatafl -# Copyright 2013 Alexander Söderlund, Sweden. Revised 2013-09-20. +# Copyright © 2013-2014 Alexander Söderlund, Sweden # -# Script license: CC0, see: -# http://creativecommons.org/publicdomain/zero/1.0/ -# http://creativecommons.org/publicdomain/zero/1.0/legalcode +# Permission to use, copy, modify, and distribute this software for any +# purpose with or without fee is hereby granted, provided that the above +# copyright notice and this permission notice appear in all copies. +# +# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL +# WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED +# WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE +# AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL +# DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR +# PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +# TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +# PERFORMANCE OF THIS SOFTWARE. PRGNAM=hnefatafl -VERSION=${VERSION:-130920} +VERSION=${VERSION:-140617} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} @@ -46,39 +55,34 @@ rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP rm -rf $PRGNAM$VERSION -tar xvf $CWD/$PRGNAM$VERSION.tar.bz2 +tar -xjf $CWD/$PRGNAM$VERSION.tar.bz2 cd $PRGNAM$VERSION 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 {} \; - -if [ ! "${LINK_XLIB:-YES}" = "YES" ]; then - patch -p1 config.mk $CWD/no-link-xlib.diff -fi + \( -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 640 -o -perm 600 -o -perm 444 \ + -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; -# See config.mk for available LANGUAGE ISO 639-2 codes. +# c99 is for restrict pointers; NDEBUG is to compile without asserts. make \ - CFLAGS_OPT="$SLKCFLAGS" \ - LANGUAGE="${LANGUAGE:-eng}" \ - PREFIX="/usr" \ - PREFIX_X11_LIB="/usr/lib${LIBDIRSUFFIX}" - + CC=gcc \ + CFLAGS="-std=c99 -DNDEBUG $SLKCFLAGS" make install \ - LANGUAGE="${LANGUAGE:-eng}" \ - PREFIX="${PKG}/usr" \ - PREFIX_DATA_RULES_CONF="/usr/share/games/${PRGNAM}/rules" + DESTDIR="$PKG" \ + PREFIX=/usr + +# The default language is Swedish. Change it to English: +sed -i 's/^l swe$/l eng/' $PKG/usr/share/games/hnefatafl/hnefataflrc find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true -# "make install" processes, installs, and compresses the man page. Don't -# attempt to do it manually since we'd miss out on the processing part. +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 mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a CHANGES gpl.txt fdl.txt $PKG/usr/doc/$PRGNAM-$VERSION +cp -a CHANGES CONTRIBUTING INSTALL LICENSE README $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild mkdir -p $PKG/install |