summaryrefslogtreecommitdiff
path: root/games/commandergenius
diff options
context:
space:
mode:
authorB. Watson <yalhcru@gmail.com>2017-03-01 02:27:29 -0500
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2017-03-04 07:26:37 +0700
commita1d9976b46a398b965de6e73955f060069e35725 (patch)
treed63e5f5f81534118cbdbbc3811771e70e86bb11d /games/commandergenius
parentc19d3dd2b4441df919ad9d021234633e41520ad9 (diff)
downloadslackbuilds-a1d9976b46a398b965de6e73955f060069e35725.tar.gz
games/commandergenius: Updated for version 1.9.8.7beta.
Signed-off-by: B. Watson <yalhcru@gmail.com>
Diffstat (limited to 'games/commandergenius')
-rw-r--r--games/commandergenius/README5
-rw-r--r--games/commandergenius/a67003b_sdl_12_compatibility.diff16
-rw-r--r--games/commandergenius/commandergenius.614
-rw-r--r--games/commandergenius/commandergenius.SlackBuild17
-rw-r--r--games/commandergenius/commandergenius.info6
-rw-r--r--games/commandergenius/commandergenius.rst12
6 files changed, 52 insertions, 18 deletions
diff --git a/games/commandergenius/README b/games/commandergenius/README
index a74c26cca6..9efc8616f5 100644
--- a/games/commandergenius/README
+++ b/games/commandergenius/README
@@ -41,5 +41,6 @@ If you *don't* want the HQP to be used, use different directory names
for the above (e.g. ckeen2 and ckeen3).
commandergenius can be built with either SDL 1.2 or SDL 2.0. By default,
-SDL2 is used if found, otherwise SDL1 is used. To build with SDL1 even
-if SDL2 is installed, set 'SDL2=no' in the script's environment.
+SDL2 is used if SDL2 and SDL2_image are both found, otherwise SDL1 is
+used. To build with SDL1 even if SDL2 and SDL2_image are installed, set
+'SDL2=no' in the script's environment.
diff --git a/games/commandergenius/a67003b_sdl_12_compatibility.diff b/games/commandergenius/a67003b_sdl_12_compatibility.diff
new file mode 100644
index 0000000000..614082de80
--- /dev/null
+++ b/games/commandergenius/a67003b_sdl_12_compatibility.diff
@@ -0,0 +1,16 @@
+diff --git a/src/engine/keen/galaxy/CPassive.cpp b/src/engine/keen/galaxy/CPassive.cpp
+index dfc2dbe..34ccc8c 100755
+--- a/src/engine/keen/galaxy/CPassive.cpp
++++ b/src/engine/keen/galaxy/CPassive.cpp
+@@ -392,7 +392,11 @@ void CPassiveGalaxy::processTitle()
+ darkener.create(0, gameRes.w, gameRes.h, 32,
+ 0, 0, 0, 0);
+
++
++#if SDL_VERSION_ATLEAST(2, 0, 0)
+ darkener.setBlendMode(SDL_BLENDMODE_BLEND);
++#endif
++
+ darkener.setAlpha(128);
+
+ auto *sfc = mBackgroundStarWars.getSDLSurface();
diff --git a/games/commandergenius/commandergenius.6 b/games/commandergenius/commandergenius.6
index 5732294b09..dc848ab2cc 100644
--- a/games/commandergenius/commandergenius.6
+++ b/games/commandergenius/commandergenius.6
@@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText.
.
-.TH COMMANDERGENIUS 6 "2016-08-21" "1.9.5.3-Beta" "SlackBuilds.org"
+.TH COMMANDERGENIUS 6 "2017-03-01" "1.9.8.7-Beta" "SlackBuilds.org"
.SH NAME
commandergenius \- open source engine for Commander Keen games
.
@@ -46,7 +46,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.sp
commandergenius [\fIdir=dir\fP] [\fIfinale=<on|off>\fP]
.sp
-CGeniusExe [\fIdir=dir\fP] [\fIfinale=<on|off>\fP]
+CGeniusExe [\fIdir=dir\fP] [\fIfinale=<on|off>\fP] [\fIlevel=level\fP]
.SH DESCRIPTION
.sp
Commander Genius is an open\-source clone of Commander Keen which allows
@@ -62,7 +62,7 @@ fan\-made mods.
This man page is a brief summary. Full documentation can be found
in:
.sp
-/usr/doc/commandergenius\-1953beta/README
+/usr/doc/commandergenius\-1987beta/README
.SH OPTIONS
.INDENT 0.0
.TP
@@ -73,6 +73,10 @@ are not allowed.
.TP
.B \fIfinale=<on|off>\fP
Skip directly to the finale (ending) of the game.
+.TP
+.B \fIlevel=<level>\fP
+Starting level. Only valid if \fIdir\fP is given, and only if the given
+game is episode 4, 5, or 6.
.UNINDENT
.SH FILES
.INDENT 0.0
@@ -106,10 +110,10 @@ users may manually copy game data files here and add them to
.UNINDENT
.SH COPYRIGHT
.sp
-See the file /usr/doc/commandergenius\-1953beta/COPYRIGHT for license information.
+See the file /usr/doc/commandergenius\-1987beta/COPYRIGHT for license information.
.SH AUTHORS
.sp
-commandergenius was written by Gerstrong <\fI\%gerstrong@gmail.com\fP>.
+commandergenius was written by Gerhard Stein <\fI\%gerstrong@gmail.com\fP>.
.sp
This man page written for the SlackBuilds.org project
by B. Watson, and is licensed under the WTFPL.
diff --git a/games/commandergenius/commandergenius.SlackBuild b/games/commandergenius/commandergenius.SlackBuild
index c05627ef76..0323dab4fa 100644
--- a/games/commandergenius/commandergenius.SlackBuild
+++ b/games/commandergenius/commandergenius.SlackBuild
@@ -6,10 +6,16 @@
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
-# 20170122 bkw: updated for 1.9.8.1beta
+# 20170301 bkw:
+# - updated for 1.9.8.7beta
+# - fix the build for the case where SDL2 is installed but SDL2_image is not.
+# - update man page (level= option, correct author's full name)
+# - use github long-form URL
+
+# 20170122 bkw: updated for 1.9.8.1beta.
PRGNAM=commandergenius
-VERSION=${VERSION:-1.9.8.1beta}
+VERSION=${VERSION:-1.9.8.7beta}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -59,7 +65,7 @@ rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $SRCNAM-$SRCVER
-tar xvf $CWD/$SRCNAM-$SRCVER.tar.gz || tar xvf $CWD/v$SRCVER.tar.gz
+tar xvf $CWD/$SRCNAM-$SRCVER.tar.gz
cd $SRCNAM-$SRCVER
chown -R root:root .
@@ -70,10 +76,13 @@ find -L . -type d -a -exec chmod 755 '{}' '+'
# placate desktop-file-validate
sed -i 's,Application;,,' share/$DESKTOP
+# Apply upstream fix for building with SDL-1.2
+patch -p1 < $CWD/a67003b_sdl_12_compatibility.diff
+
# SDL 2 is optional. I prefer it, others may not.
SDLOPT="-DUSE_SDL2=no"
SDLVER=1
-if sdl2-config --version 2>/dev/null && [ "${SDL2:-yes}" != "no" ]; then
+if pkg-config --exists sdl2 SDL2_image && [ "${SDL2:-yes}" != "no" ]; then
SDLOPT="-DUSE_SDL2=yes"
SDLVER=2
fi
diff --git a/games/commandergenius/commandergenius.info b/games/commandergenius/commandergenius.info
index b6eee12d42..eeb7a2a200 100644
--- a/games/commandergenius/commandergenius.info
+++ b/games/commandergenius/commandergenius.info
@@ -1,8 +1,8 @@
PRGNAM="commandergenius"
-VERSION="1.9.8.1beta"
+VERSION="1.9.8.7beta"
HOMEPAGE="https://github.com/gerstrong/Commander-Genius"
-DOWNLOAD="https://github.com/gerstrong/Commander-Genius/archive/v1981beta.tar.gz"
-MD5SUM="1e7d28c3065dcad3e46412935c4b4c21"
+DOWNLOAD="https://github.com/gerstrong/Commander-Genius/archive/v1987beta/Commander-Genius-1987beta.tar.gz"
+MD5SUM="21c2936c7e801542319a1a4cc0991516"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES=""
diff --git a/games/commandergenius/commandergenius.rst b/games/commandergenius/commandergenius.rst
index 2609fb6b83..47821741d1 100644
--- a/games/commandergenius/commandergenius.rst
+++ b/games/commandergenius/commandergenius.rst
@@ -2,8 +2,8 @@
.. rst2man.py commandergenius.rst > commandergenius.6
.. rst2man.py comes from the SBo development/docutils package.
-.. |version| replace:: 1.9.5.3-Beta
-.. |dotlessversion| replace:: 1953beta
+.. |version| replace:: 1.9.8.7-Beta
+.. |dotlessversion| replace:: 1987beta
.. |date| date::
.. converting from pod:
@@ -28,7 +28,7 @@ SYNOPSIS
commandergenius [*dir=dir*] [*finale=<on|off>*]
-CGeniusExe [*dir=dir*] [*finale=<on|off>*]
+CGeniusExe [*dir=dir*] [*finale=<on|off>*] [*level=level*]
DESCRIPTION
===========
@@ -59,6 +59,10 @@ OPTIONS
*finale=<on|off>*
Skip directly to the finale (ending) of the game.
+*level=<level>*
+ Starting level. Only valid if *dir* is given, and only if the given
+ game is episode 4, 5, or 6.
+
FILES
=====
@@ -97,7 +101,7 @@ See the file /usr/doc/commandergenius-|dotlessversion|/COPYRIGHT for license inf
AUTHORS
=======
-commandergenius was written by Gerstrong <gerstrong@gmail.com>.
+commandergenius was written by Gerhard Stein <gerstrong@gmail.com>.
This man page written for the SlackBuilds.org project
by B. Watson, and is licensed under the WTFPL.