diff options
author | B. Watson <yalhcru@gmail.com> | 2021-10-26 23:43:27 -0400 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2021-10-29 17:07:25 +0700 |
commit | 2b6fe88c16d9044b0c718d5debd227c734d29243 (patch) | |
tree | 3e95eff3c7e8d4db05291a97ca128554e49ca2f7 /games/opentyrian | |
parent | 5b4925d2522529580de4525935f6169219e046e2 (diff) |
games/opentyrian: Fix -current build.
Signed-off-by: B. Watson <yalhcru@gmail.com>
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'games/opentyrian')
-rw-r--r-- | games/opentyrian/README | 6 | ||||
-rw-r--r-- | games/opentyrian/doinst.sh | 6 | ||||
-rw-r--r-- | games/opentyrian/opentyrian.SlackBuild | 42 | ||||
-rw-r--r-- | games/opentyrian/opentyrian.info | 4 | ||||
-rw-r--r-- | games/opentyrian/slack-desc | 8 |
5 files changed, 42 insertions, 24 deletions
diff --git a/games/opentyrian/README b/games/opentyrian/README index ccc9e80bfdebc..cff9d021c1195 100644 --- a/games/opentyrian/README +++ b/games/opentyrian/README @@ -1,8 +1,8 @@ opentyrian (arcade-style vertical scrolling shooter) -OpenTyrian is a port of the DOS shoot-em-up Tyrian. The story is set in -20,031 where you play as Trent Hawkins, a skilled fighter-pilot employed -to fight Microsol and save the galaxy. +OpenTyrian is a port of the MS-DOS shoot-em-up Tyrian. The story is +set in 20,031 where you play as Trent Hawkins, a skilled fighter pilot +employed to fight Microsol and save the galaxy. Gameplay is similar to the arcade game Raiden. For gameplay help, see README and manual.txt in /usr/doc/opentyrian-$VERSION/. diff --git a/games/opentyrian/doinst.sh b/games/opentyrian/doinst.sh index 5fb28930db0b9..3e5691a052b5b 100644 --- a/games/opentyrian/doinst.sh +++ b/games/opentyrian/doinst.sh @@ -1,3 +1,9 @@ if [ -x /usr/bin/update-desktop-database ]; then /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1 fi + +if [ -e usr/share/icons/hicolor/icon-theme.cache ]; then + if [ -x /usr/bin/gtk-update-icon-cache ]; then + /usr/bin/gtk-update-icon-cache usr/share/icons/hicolor >/dev/null 2>&1 + fi +fi diff --git a/games/opentyrian/opentyrian.SlackBuild b/games/opentyrian/opentyrian.SlackBuild index 7854c7f534b35..8a4ed2f577dc6 100644 --- a/games/opentyrian/opentyrian.SlackBuild +++ b/games/opentyrian/opentyrian.SlackBuild @@ -6,6 +6,11 @@ # Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details. +# 20211026 bkw: BUILD=2 +# - fix build on -current. +# - /usr/share/opentyrian => /usr/share/games/opentyrian +# - new-style icons. + # 20170620 bkw: fix compile on -current (still works fine on 14.2) cd $(dirname $0) ; CWD=$(pwd) @@ -24,9 +29,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 @@ -62,21 +64,21 @@ rm -rf $PRGNAM-$VERSION tar xvf $CWD/$PRGNAM-$VERSION-src.tar.gz 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 640 -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 {} \+ + +sed -i 's,/usr/share,/usr/share/games,' src/file.c mkdir -p \ $PKG/usr/games \ - $PKG/usr/share/$PRGNAM/data \ + $PKG/usr/share/games/$PRGNAM/data \ $PKG/usr/man/man6 \ $PKG/usr/share/pixmaps \ $PKG/usr/share/applications \ $PKG/usr/doc/$PRGNAM-$VERSION \ $PKG/install +SLKCFLAGS+=" -fcommon" sed -i "s,-g0,$SLKCFLAGS," Makefile sed -i "s,-g3.*\$,$SLKCFLAGS," Makefile make @@ -87,9 +89,9 @@ install -s $PRGNAM $PKG/usr/games # need the DOS executables or their docs (except manual.doc which # has the game story). cat <<EOF > $PKG/usr/doc/$PRGNAM-$VERSION/manual.txt -20140429 bkw: This is the original manual from the DOS game. The install -instructions are obsolete, but the backstory and gameplay instructions -are still relevant [beginning with V) THE STORY]. +20140429 bkw: This is the original manual from the MS-DOS game. The +install instructions are obsolete, but the backstory and gameplay +instructions are still relevant [beginning with "V) THE STORY"]. EOF @@ -98,12 +100,22 @@ cd tyrian$DATAVER chmod 644 * sed 's/\r//' manual.doc >> $PKG/usr/doc/$PRGNAM-$VERSION/manual.txt rm -f *.exe *.doc - mv * $PKG/usr/share/$PRGNAM/data + mv * $PKG/usr/share/games/$PRGNAM/data cd - +for i in linux/icons/*.png; do + px=$( basename $i | cut -d. -f1 | cut -d- -f2 ) + size=${px}x${px} + dir=$PKG/usr/share/icons/hicolor/$size/apps + mkdir -p $dir + cat $i > $dir/$PRGNAM.png +done + +ln -s ../icons/hicolor/48x48/apps/$PRGNAM.png $PKG/usr/share/pixmaps/$PRGNAM.png + gzip -9c < linux/man/$PRGNAM.6 > $PKG/usr/man/man6/$PRGNAM.6.gz -cat linux/icons/tyrian-128.png > $PKG/usr/share/pixmaps/$PRGNAM.png -cat linux/$PRGNAM.desktop > $PKG/usr/share/applications/$PRGNAM.desktop +sed 's,Exec=,&/usr/games/,' linux/$PRGNAM.desktop \ + > $PKG/usr/share/applications/$PRGNAM.desktop chmod 644 CREDITS cp -a COPYING CREDITS NEWS README \ diff --git a/games/opentyrian/opentyrian.info b/games/opentyrian/opentyrian.info index 47c0bd02aebbe..b4df0329c8a44 100644 --- a/games/opentyrian/opentyrian.info +++ b/games/opentyrian/opentyrian.info @@ -1,8 +1,8 @@ PRGNAM="opentyrian" VERSION="2.1.20130907" HOMEPAGE="https://bitbucket.org/opentyrian/opentyrian/wiki/Home" -DOWNLOAD="http://www.camanis.net/opentyrian/releases/opentyrian-2.1.20130907-src.tar.gz \ - http://camanis.net/tyrian/tyrian21.zip" +DOWNLOAD="https://www.camanis.net/opentyrian/releases/opentyrian-2.1.20130907-src.tar.gz \ + https://camanis.net/tyrian/tyrian21.zip" MD5SUM="978686c5a1dfbac69a2161aadf084c2b \ 2a3b206a6de25ed4b771af073f8ca904" DOWNLOAD_x86_64="" diff --git a/games/opentyrian/slack-desc b/games/opentyrian/slack-desc index 35b9e7aa37d67..e70c67bd9997d 100644 --- a/games/opentyrian/slack-desc +++ b/games/opentyrian/slack-desc @@ -8,12 +8,12 @@ |-----handy-ruler------------------------------------------------------| opentyrian: opentyrian (arcade-style vertical scrolling shooter) opentyrian: -opentyrian: OpenTyrian is a port of the DOS shoot-em-up Tyrian. The story is set -opentyrian: in 20,031 where you play as Trent Hawkins, a skilled fighter-pilot +opentyrian: OpenTyrian is a port of the MS-DOS shoot-em-up Tyrian. The story is +opentyrian: set in 20,031 where you play as Trent Hawkins, a skilled fighter pilot opentyrian: employed to fight Microsol and save the galaxy. opentyrian: -opentyrian: Gameplay is similar to the arcade game Raiden. -opentyrian: +opentyrian: Gameplay is similar to the arcade game Raiden. For gameplay help, see +opentyrian: README and manual.txt in /usr/doc/opentyrian-$VERSION/. opentyrian: opentyrian: opentyrian: |