mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-20 19:41:34 +01:00
games/commandergenius: Added (engine for Commander Keen games).
Signed-off-by: David Spencer <idlemoor@slackbuilds.org>
This commit is contained in:
parent
143c95cef2
commit
86734105b5
7 changed files with 444 additions and 0 deletions
45
games/commandergenius/README
Normal file
45
games/commandergenius/README
Normal file
|
@ -0,0 +1,45 @@
|
|||
commandergenius (engine for Commander Keen games)
|
||||
|
||||
Commander Genius is an open-source clone of Commander Keen which allows
|
||||
you to play the games, and some of the mods made for it. All of the
|
||||
original data files are required to do so, however the authors have
|
||||
provided convenient way to download some of the games (choose "Game
|
||||
Center" at the main menu). It's also possible to use the data files from
|
||||
an installed copy of one or more of the games.
|
||||
|
||||
Supported games:
|
||||
|
||||
Keen 1 - Version 1.33 [*]
|
||||
Keen 2 - Version 1.33
|
||||
Keen 3 - Version 1.33
|
||||
Keen 4 - Version 1.4 (EGA) [*]
|
||||
Keen 5 - Version 1.4 (EGA)
|
||||
Keen 6 - Version 1.4 (EGA) (version 1.5 known not to work!)
|
||||
Keen Dreams - Version v1.13 (EGA) [*]
|
||||
|
||||
[*] = downloadable from Game Center
|
||||
|
||||
Other versions might work, but there are no guarantees. For the games not
|
||||
available via the in-game Game Center, place the data files somewhere
|
||||
under /usr/share/games/commandergenius or ~/.CommanderGenius, and edit
|
||||
~/.CommanderGenius/games.cfg to tell the game where to find the files.
|
||||
|
||||
commandergenius also has a HQP (High Quality Pack) with enhanced graphics
|
||||
and sound for Keen 1 through 4. For Keen 1 and Keen 4, choose "Keen 1
|
||||
Special" and "Keen 4 Special" from the Game Center, to get the HQP versions
|
||||
of the games. For Keen 2 and Keen 3, the HQP will automatically be used
|
||||
if the games are installed to ~/.CommanderGenius/games/keen2 and
|
||||
~/.CommanderGenius/games/keen3, with games.cfg entries like so:
|
||||
|
||||
&Dir=games/keen2/keen2.exe
|
||||
/Name=keen2
|
||||
|
||||
&Dir=games/keen3/keen3.exe
|
||||
/Name=keen3
|
||||
|
||||
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.
|
122
games/commandergenius/commandergenius.6
Normal file
122
games/commandergenius/commandergenius.6
Normal file
|
@ -0,0 +1,122 @@
|
|||
.\" Man page generated from reStructuredText.
|
||||
.
|
||||
.TH COMMANDERGENIUS 6 "2016-08-21" "1.9.5.3-Beta" "SlackBuilds.org"
|
||||
.SH NAME
|
||||
commandergenius \- open source engine for Commander Keen games
|
||||
.
|
||||
.nr rst2man-indent-level 0
|
||||
.
|
||||
.de1 rstReportMargin
|
||||
\\$1 \\n[an-margin]
|
||||
level \\n[rst2man-indent-level]
|
||||
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
|
||||
-
|
||||
\\n[rst2man-indent0]
|
||||
\\n[rst2man-indent1]
|
||||
\\n[rst2man-indent2]
|
||||
..
|
||||
.de1 INDENT
|
||||
.\" .rstReportMargin pre:
|
||||
. RS \\$1
|
||||
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
|
||||
. nr rst2man-indent-level +1
|
||||
.\" .rstReportMargin post:
|
||||
..
|
||||
.de UNINDENT
|
||||
. RE
|
||||
.\" indent \\n[an-margin]
|
||||
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
|
||||
.nr rst2man-indent-level -1
|
||||
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
|
||||
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
|
||||
..
|
||||
.\" RST source for commandergenius(6) man page. Convert with:
|
||||
.
|
||||
.\" rst2man.py commandergenius.rst > commandergenius.6
|
||||
.
|
||||
.\" rst2man.py comes from the SBo development/docutils package.
|
||||
.
|
||||
.\" converting from pod:
|
||||
.
|
||||
.\" s/B<\([^>]*\)>/**\1**/g
|
||||
.
|
||||
.\" s/I<\([^>]*\)>/*\1*/g
|
||||
.
|
||||
.SH SYNOPSIS
|
||||
.sp
|
||||
commandergenius [\fIdir=dir\fP] [\fIfinale=<on|off>\fP]
|
||||
.sp
|
||||
CGeniusExe [\fIdir=dir\fP] [\fIfinale=<on|off>\fP]
|
||||
.SH DESCRIPTION
|
||||
.sp
|
||||
Commander Genius is an open\-source clone of Commander Keen which allows
|
||||
you to play the games, and some of the mods made for it. All of the
|
||||
original data files are required to do so, however the authors have
|
||||
provided convenient way to download some of the games (choose "Game
|
||||
Center" at the main menu). It\(aqs also possible to use the data files from
|
||||
an installed copy of one or more of the games.
|
||||
.sp
|
||||
Supported games are Keen 1 through 6, plus Keen Dreams and several
|
||||
fan\-made mods.
|
||||
.sp
|
||||
This man page is a brief summary. Full documentation can be found
|
||||
in:
|
||||
.sp
|
||||
/usr/doc/commandergenius\-1953beta/README
|
||||
.SH OPTIONS
|
||||
.INDENT 0.0
|
||||
.TP
|
||||
.B \fIdir=dir\fP
|
||||
Launch game in the given directory. This is a relative path from
|
||||
one of the directories configured in \fIcgenius.cfg\fP; absolute paths
|
||||
are not allowed.
|
||||
.TP
|
||||
.B \fIfinale=<on|off>\fP
|
||||
Skip directly to the finale (ending) of the game.
|
||||
.UNINDENT
|
||||
.SH FILES
|
||||
.INDENT 0.0
|
||||
.TP
|
||||
.B \fI/usr/share/games/commandergenius\fP
|
||||
System\-wide directory. Games may be installed here for use by
|
||||
multiple players, in the \fIgames/\fP subdirectory. Also, content from
|
||||
the HQP (high quality pack) is installed here.
|
||||
.TP
|
||||
.B \fI~/.CommanderGenius\fP
|
||||
Per\-user directory, containing any games downloaded from the in\-game
|
||||
Game Center. Also contains these files:
|
||||
.TP
|
||||
.B \fIcgenius.cfg\fP
|
||||
Main config file, rewritten on game exit. Contains user preferences.
|
||||
Normally not edited by hand, but it\(aqs possible to do so.
|
||||
.TP
|
||||
.B \fIgames.cfg\fP
|
||||
List of installed games and their directory paths.
|
||||
.TP
|
||||
.B \fICGLog.html\fP
|
||||
Log file created by the game.
|
||||
.TP
|
||||
.B \fIdownloads/\fP
|
||||
Zip files downloaded within the Game Center are saved here.
|
||||
.TP
|
||||
.B \fIgames/\fP
|
||||
Files extracted from downloaded zip files are stored here. Also,
|
||||
users may manually copy game data files here and add them to
|
||||
\fIgames.cfg\fP, to install games not available from the Game Center.
|
||||
.UNINDENT
|
||||
.SH COPYRIGHT
|
||||
.sp
|
||||
See the file /usr/doc/commandergenius\-1953beta/COPYRIGHT for license information.
|
||||
.SH AUTHORS
|
||||
.sp
|
||||
commandergenius was written by Gerstrong <\fI\%gerstrong@gmail.com\fP>.
|
||||
.sp
|
||||
This man page written for the SlackBuilds.org project
|
||||
by B. Watson, and is licensed under the WTFPL.
|
||||
.SH SEE ALSO
|
||||
.sp
|
||||
The commandergenius homepage:
|
||||
.sp
|
||||
\fI\%https://github.com/gerstrong/Commander\-Genius\fP
|
||||
.\" Generated by docutils manpage writer.
|
||||
.
|
129
games/commandergenius/commandergenius.SlackBuild
Normal file
129
games/commandergenius/commandergenius.SlackBuild
Normal file
|
@ -0,0 +1,129 @@
|
|||
#!/bin/sh
|
||||
|
||||
# Slackware build script for commandergenius
|
||||
|
||||
# Written by B. Watson (yalhcru@gmail.com)
|
||||
|
||||
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
|
||||
|
||||
PRGNAM=commandergenius
|
||||
VERSION=${VERSION:-1.9.5.3beta}
|
||||
BUILD=${BUILD:-1}
|
||||
TAG=${TAG:-_SBo}
|
||||
|
||||
if [ -z "$ARCH" ]; then
|
||||
case "$( uname -m )" in
|
||||
i?86) ARCH=i586 ;;
|
||||
arm*) ARCH=arm ;;
|
||||
*) ARCH=$( uname -m ) ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
CWD=$(pwd)
|
||||
TMP=${TMP:-/tmp/SBo}
|
||||
PKG=$TMP/package-$PRGNAM
|
||||
OUTPUT=${OUTPUT:-/tmp}
|
||||
|
||||
# note that upstream has -O3 hardcoded *after* the specified flags,
|
||||
# so the -O2 here doesn't actually do anything. The -fPIC and arch/tune
|
||||
# stuff still applies though.
|
||||
if [ "$ARCH" = "i586" ]; then
|
||||
SLKCFLAGS="-O2 -march=i586 -mtune=i686"
|
||||
LIBDIRSUFFIX=""
|
||||
elif [ "$ARCH" = "i686" ]; then
|
||||
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
|
||||
LIBDIRSUFFIX=""
|
||||
elif [ "$ARCH" = "x86_64" ]; then
|
||||
SLKCFLAGS="-O2 -fPIC"
|
||||
LIBDIRSUFFIX="64"
|
||||
else
|
||||
SLKCFLAGS="-O2"
|
||||
LIBDIRSUFFIX=""
|
||||
fi
|
||||
|
||||
set -e
|
||||
|
||||
# I wish upstream would pick a name and stick with it... they also use
|
||||
# ~/.CommanderGenius for user data, and their README mentions CGenius.
|
||||
SRCNAM="Commander-Genius"
|
||||
EXENAME="CGeniusExe"
|
||||
DESKTOP="cgenius.desktop"
|
||||
|
||||
# the real VERSION is from version.h in the source. the tarball names
|
||||
# omit the dots.
|
||||
SRCVER="$( echo $VERSION | sed 's,\.,,g' )"
|
||||
|
||||
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
|
||||
cd $SRCNAM-$SRCVER
|
||||
chown -R root:root .
|
||||
|
||||
# permissions are blethcherous, please don't revert to template here.
|
||||
find -L . -type f -a -exec chmod 644 '{}' '+'
|
||||
find -L . -type d -a -exec chmod 755 '{}' '+'
|
||||
|
||||
# placate desktop-file-validate
|
||||
sed -i 's,Application;,,' share/$DESKTOP
|
||||
|
||||
# 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
|
||||
SDLOPT="-DUSE_SDL2=yes"
|
||||
SDLVER=2
|
||||
fi
|
||||
|
||||
echo "=== Building with $SDLOPT"
|
||||
|
||||
mkdir -p build
|
||||
cd build
|
||||
cmake \
|
||||
$SDLOPT \
|
||||
-DGAMES_SHAREDIR:STRING=/usr/share/games \
|
||||
-DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
|
||||
-DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
|
||||
-DCMAKE_INSTALL_PREFIX=/usr \
|
||||
-DLIB_SUFFIX=${LIBDIRSUFFIX} \
|
||||
-DMAN_INSTALL_DIR=/usr/man \
|
||||
-DCMAKE_BUILD_TYPE=Release ..
|
||||
make VERBOSE=1
|
||||
make install/strip DESTDIR=$PKG
|
||||
cd ..
|
||||
|
||||
# upstream installs 2 identical-looking (but not byte-identical) icons
|
||||
rm -f $PKG/usr/share/icons/hicolor/512x512/apps/CGLogo.png
|
||||
ln -s ../../../../games/$PRGNAM/cglogo512.png \
|
||||
$PKG/usr/share/icons/hicolor/512x512/apps/CGLogo.png
|
||||
|
||||
# grrrr. don't force command-line users to remember the name is CGeniusExe
|
||||
ln -s $EXENAME $PKG/usr/games/$PRGNAM
|
||||
|
||||
# the High Quality Pack. this is redundant for Keen 1 and 4 (just download
|
||||
# the Special versions of these games), so we only install the data for
|
||||
# 2 and 3. strace shows the files are being loaded, but TBH I haven't
|
||||
# played these games enough to notice the difference with/without the HQP.
|
||||
rm -rf hqp/games/keen1 hqp/games/keen4
|
||||
cp -a hqp/* $PKG/usr/share/games/$PRGNAM
|
||||
|
||||
# man page written for this SlackBuild.
|
||||
mkdir -p $PKG/usr/man/man6
|
||||
gzip -9c < $CWD/$PRGNAM.6 > $PKG/usr/man/man6/$PRGNAM.6.gz
|
||||
ln -s $PRGNAM.6.gz $PKG/usr/man/man6/$EXENAME.6.gz
|
||||
|
||||
# upstream installs most of the docs in /usr/share/games/$PRGNAM...
|
||||
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cp -a COPYRIGHT $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
for i in README changelog.txt Readme_hqp.txt; do
|
||||
ln -s ../../share/games/$PRGNAM/$i $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
done
|
||||
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
|
||||
|
||||
mkdir -p $PKG/install
|
||||
sed "s,@SDLVER@,$SDLVER," < $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}
|
10
games/commandergenius/commandergenius.info
Normal file
10
games/commandergenius/commandergenius.info
Normal file
|
@ -0,0 +1,10 @@
|
|||
PRGNAM="commandergenius"
|
||||
VERSION="1.9.5.3beta"
|
||||
HOMEPAGE="https://github.com/gerstrong/Commander-Genius"
|
||||
DOWNLOAD="https://github.com/gerstrong/Commander-Genius/archive/v1953beta.tar.gz"
|
||||
MD5SUM="7226389ae8a423dc9086936a9b403111"
|
||||
DOWNLOAD_x86_64=""
|
||||
MD5SUM_x86_64=""
|
||||
REQUIRES=""
|
||||
MAINTAINER="B. Watson"
|
||||
EMAIL="yalhcru@gmail.com"
|
110
games/commandergenius/commandergenius.rst
Normal file
110
games/commandergenius/commandergenius.rst
Normal file
|
@ -0,0 +1,110 @@
|
|||
.. RST source for commandergenius(6) man page. Convert with:
|
||||
.. 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
|
||||
.. |date| date::
|
||||
|
||||
.. converting from pod:
|
||||
.. s/B<\([^>]*\)>/**\1**/g
|
||||
.. s/I<\([^>]*\)>/*\1*/g
|
||||
|
||||
===============
|
||||
commandergenius
|
||||
===============
|
||||
|
||||
-------------------------------------------
|
||||
open source engine for Commander Keen games
|
||||
-------------------------------------------
|
||||
|
||||
:Manual section: 6
|
||||
:Manual group: SlackBuilds.org
|
||||
:Date: |date|
|
||||
:Version: |version|
|
||||
|
||||
SYNOPSIS
|
||||
========
|
||||
|
||||
commandergenius [*dir=dir*] [*finale=<on|off>*]
|
||||
|
||||
CGeniusExe [*dir=dir*] [*finale=<on|off>*]
|
||||
|
||||
DESCRIPTION
|
||||
===========
|
||||
|
||||
Commander Genius is an open-source clone of Commander Keen which allows
|
||||
you to play the games, and some of the mods made for it. All of the
|
||||
original data files are required to do so, however the authors have
|
||||
provided convenient way to download some of the games (choose "Game
|
||||
Center" at the main menu). It's also possible to use the data files from
|
||||
an installed copy of one or more of the games.
|
||||
|
||||
Supported games are Keen 1 through 6, plus Keen Dreams and several
|
||||
fan-made mods.
|
||||
|
||||
This man page is a brief summary. Full documentation can be found
|
||||
in:
|
||||
|
||||
/usr/doc/commandergenius-|dotlessversion|/README
|
||||
|
||||
OPTIONS
|
||||
=======
|
||||
|
||||
*dir=dir*
|
||||
Launch game in the given directory. This is a relative path from
|
||||
one of the directories configured in *cgenius.cfg*; absolute paths
|
||||
are not allowed.
|
||||
|
||||
*finale=<on|off>*
|
||||
Skip directly to the finale (ending) of the game.
|
||||
|
||||
FILES
|
||||
=====
|
||||
|
||||
*/usr/share/games/commandergenius*
|
||||
System-wide directory. Games may be installed here for use by
|
||||
multiple players, in the *games/* subdirectory. Also, content from
|
||||
the HQP (high quality pack) is installed here.
|
||||
|
||||
*~/.CommanderGenius*
|
||||
Per-user directory, containing any games downloaded from the in-game
|
||||
Game Center. Also contains these files:
|
||||
|
||||
*cgenius.cfg*
|
||||
Main config file, rewritten on game exit. Contains user preferences.
|
||||
Normally not edited by hand, but it's possible to do so.
|
||||
|
||||
*games.cfg*
|
||||
List of installed games and their directory paths.
|
||||
|
||||
*CGLog.html*
|
||||
Log file created by the game.
|
||||
|
||||
*downloads/*
|
||||
Zip files downloaded within the Game Center are saved here.
|
||||
|
||||
*games/*
|
||||
Files extracted from downloaded zip files are stored here. Also,
|
||||
users may manually copy game data files here and add them to
|
||||
*games.cfg*, to install games not available from the Game Center.
|
||||
|
||||
COPYRIGHT
|
||||
=========
|
||||
|
||||
See the file /usr/doc/commandergenius-|dotlessversion|/COPYRIGHT for license information.
|
||||
|
||||
AUTHORS
|
||||
=======
|
||||
|
||||
commandergenius was written by Gerstrong <gerstrong@gmail.com>.
|
||||
|
||||
This man page written for the SlackBuilds.org project
|
||||
by B. Watson, and is licensed under the WTFPL.
|
||||
|
||||
SEE ALSO
|
||||
========
|
||||
|
||||
The commandergenius homepage:
|
||||
|
||||
https://github.com/gerstrong/Commander-Genius
|
9
games/commandergenius/doinst.sh
Normal file
9
games/commandergenius/doinst.sh
Normal file
|
@ -0,0 +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
|
19
games/commandergenius/slack-desc
Normal file
19
games/commandergenius/slack-desc
Normal file
|
@ -0,0 +1,19 @@
|
|||
# HOW TO EDIT THIS FILE:
|
||||
# The "handy ruler" below makes it easier to edit a package description.
|
||||
# Line up the first '|' above the ':' following the base package name, and
|
||||
# the '|' on the right side marks the last column you can put a character in.
|
||||
# You must make exactly 11 lines for the formatting to be correct. It's also
|
||||
# customary to leave one space after the ':' except on otherwise blank lines.
|
||||
|
||||
|-----handy-ruler------------------------------------------------------|
|
||||
commandergenius: commandergenius (engine for Commander Keen games)
|
||||
commandergenius:
|
||||
commandergenius: Commander Genius is an open-source clone of Commander Keen which
|
||||
commandergenius: allows you to play the games, and some of the mods made for it. All
|
||||
commandergenius: of the original data files are required to do so.
|
||||
commandergenius:
|
||||
commandergenius: This package was built with SDL @SDLVER@.
|
||||
commandergenius:
|
||||
commandergenius:
|
||||
commandergenius:
|
||||
commandergenius:
|
Loading…
Reference in a new issue