diff options
Diffstat (limited to 'games/skulltag/skulltag.SlackBuild')
-rw-r--r-- | games/skulltag/skulltag.SlackBuild | 42 |
1 files changed, 26 insertions, 16 deletions
diff --git a/games/skulltag/skulltag.SlackBuild b/games/skulltag/skulltag.SlackBuild index f2a47453fe..542b18d7de 100644 --- a/games/skulltag/skulltag.SlackBuild +++ b/games/skulltag/skulltag.SlackBuild @@ -2,15 +2,18 @@ # Slackware build script for skulltag -# 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. +# 20230111 bkw: BUILD=4, strip libsnes_spc.so +# 20211024 bkw: BUILD=3, binaries in /usr/games, new-style icons + cd $(dirname $0) ; CWD=$(pwd) PRGNAM=skulltag VERSION=${VERSION:-098d} -BUILD=${BUILD:-2} +BUILD=${BUILD:-4} TAG=${TAG:-_SBo} PKGTYPE=${PKGTYPE:-tgz} @@ -22,9 +25,6 @@ if [ -z "$ARCH" ]; then esac fi -# 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 @@ -76,18 +76,18 @@ cd $PRGNAM-$VERSION tar xvf $BASE tar xvf $GAME 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 {} \+ mkdir -p \ $PKG/usr/lib$LIBDIRSUFFIX/$PRGNAM \ - $PKG/usr/bin \ + $PKG/usr/games \ $PKG/usr/share/$PRGNAM \ $PKG/usr/doc/$PRGNAM-$VERSION +# 20230111 bkw: this *one* library isn't already stripped: +strip libsnes_spc.so + mv $PRGNAM $PRGNAM-server *.so $PKG/usr/lib$LIBDIRSUFFIX/$PRGNAM install -m0644 *.pk3 $PKG/usr/share/$PRGNAM install -m0644 *.txt $PKG/usr/doc/$PRGNAM-$VERSION @@ -106,9 +106,9 @@ install -m0755 \ fmodapi*/api/lib*/libfmodex$LIBDIRSUFFIX-*.so \ $PKG/usr/lib$LIBDIRSUFFIX/$PRGNAM -sed "s,@LIB@,lib$LIBDIRSUFFIX,g" < $CWD/$PRGNAM.sh > $PKG/usr/bin/$PRGNAM -chmod 755 $PKG/usr/bin/$PRGNAM -ln -s $PRGNAM $PKG/usr/bin/$PRGNAM-server +sed "s,@LIB@,lib$LIBDIRSUFFIX,g" < $CWD/$PRGNAM.sh > $PKG/usr/games/$PRGNAM +chmod 755 $PKG/usr/games/$PRGNAM +ln -s $PRGNAM $PKG/usr/games/$PRGNAM-server # The included ini file changes the following program defaults: @@ -142,9 +142,19 @@ cat $CWD/$PRGNAM.ini > $PKG/usr/share/$PRGNAM/$PRGNAM.ini.default # the wiki, so let's give the user the URL. cat $CWD/README_docs.txt > $PKG/usr/doc/$PRGNAM-$VERSION/README_docs.txt -# PNG icon converted from a GIF on skulltag.com +# 20211024 bkw: icons extracted from the OSX installer: +# http://www.skulltag.com/download/files/release/st-v098d_macosx.dmg +# and a couple were made by resizing 128.png. +for i in $CWD/icons/*.png; do + px=$( basename $i | cut -d. -f1 ) + size=${px}x${px} + dir=$PKG/usr/share/icons/hicolor/$size/apps + mkdir -p $dir + cat $i > $dir/$PRGNAM.png +done + mkdir -p $PKG/usr/share/pixmaps -cat $CWD/$PRGNAM.png > $PKG/usr/share/pixmaps/$PRGNAM.png +ln -s ../icons/hicolor/48x48/apps/$PRGNAM.png $PKG/usr/share/pixmaps/$PRGNAM.png # .desktop is a modified copy of zdoom.desktop mkdir -p $PKG/usr/share/applications |