diff options
author | Dimitris Zlatanidis <d.zlatanidis@gmail.com> | 2014-04-17 12:26:01 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2014-04-23 07:51:38 +0700 |
commit | 27f51eebdf99bf448f565a5969ac139c726fe304 (patch) | |
tree | c06c27de0e89290115852ceab292c494ad890c05 | |
parent | 08e8495840c23843ec580c2330de9d1d731535e0 (diff) | |
download | slackbuilds-27f51eebdf99bf448f565a5969ac139c726fe304.tar.gz |
games/wormblast: Added (remake of Parawormer II).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
-rw-r--r-- | games/wormblast/README | 4 | ||||
-rw-r--r-- | games/wormblast/doinst.sh | 3 | ||||
-rw-r--r-- | games/wormblast/slack-desc | 19 | ||||
-rw-r--r-- | games/wormblast/wormblast.SlackBuild | 105 | ||||
-rw-r--r-- | games/wormblast/wormblast.info | 10 | ||||
-rw-r--r-- | games/wormblast/wormblast.patch | 76 |
6 files changed, 217 insertions, 0 deletions
diff --git a/games/wormblast/README b/games/wormblast/README new file mode 100644 index 0000000000..0cbae8c7d5 --- /dev/null +++ b/games/wormblast/README @@ -0,0 +1,4 @@ +WormBlast is an OpenGL/SDL remake of Parawormer II, probably the most +violent worm action game in the World. 1-2 human players fight against +6 computers on a scrolling area with a bunch of different guns. +Split screen option for two human players. diff --git a/games/wormblast/doinst.sh b/games/wormblast/doinst.sh new file mode 100644 index 0000000000..5fb28930db --- /dev/null +++ b/games/wormblast/doinst.sh @@ -0,0 +1,3 @@ +if [ -x /usr/bin/update-desktop-database ]; then + /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1 +fi diff --git a/games/wormblast/slack-desc b/games/wormblast/slack-desc new file mode 100644 index 0000000000..07a878fd91 --- /dev/null +++ b/games/wormblast/slack-desc @@ -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------------------------------------------------------| +wormblast: wormblast (remake of Parawormer II) +wormblast: +wormblast: WormBlast is an OpenGL/SDL remake of Parawormer II, probably the most +wormblast: violent worm action game in the World. 1-2 human players fight +wormblast: against 6 computers on a scrolling area with a bunch of different +wormblast: guns. Split screen option for two human players. +wormblast: +wormblast: Homepage: http://wormblast.sourceforge.net +wormblast: +wormblast: +wormblast: diff --git a/games/wormblast/wormblast.SlackBuild b/games/wormblast/wormblast.SlackBuild new file mode 100644 index 0000000000..4920f44ad1 --- /dev/null +++ b/games/wormblast/wormblast.SlackBuild @@ -0,0 +1,105 @@ +#!/bin/sh + +# Slackware build script for wormblast + +# Copyright 2014 Dimitris Zlatanidis Greece-Orestiada +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +PRGNAM=wormblast +VERSION=${VERSION:-2.0.2} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i486 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; + esac +fi + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +if [ "$ARCH" = "i486" ]; then + SLKCFLAGS="-O2 -march=i486 -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 + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT $PKG +cd $TMP +rm -rf $PRGNAM-$VERSION +tar xvf $CWD/$PRGNAM-$VERSION.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 {} \; + +patch -p1 < $CWD/wormblast.patch + +mkdir -p build +cd build + cmake \ + -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \ + -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DCMAKE_BUILD_TYPE=Release .. + + make + make install DESTDIR=$PKG +cd .. + +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 + +mkdir -p $PKG/usr/bin +( + cd $PKG/usr/bin + ln -sf /usr/share/games/WormBlast/bin/wormblast wormblast + ln -sf /usr/share/games/WormBlast/bin/wormblast-game.x wormblast-game.x +) + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a AUTHORS CHANGELOG COPYING README $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild + +mkdir -p $PKG/install +cat $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} diff --git a/games/wormblast/wormblast.info b/games/wormblast/wormblast.info new file mode 100644 index 0000000000..5e0d714c27 --- /dev/null +++ b/games/wormblast/wormblast.info @@ -0,0 +1,10 @@ +PRGNAM="wormblast" +VERSION="2.0.2" +HOMEPAGE="http://wormblast.sourceforge.net" +DOWNLOAD="http://downloads.sourceforge.net/project/wormblast/Releases/wormblast-2.0.2/src/wormblast-2.0.2.tar.gz" +MD5SUM="f546569a56aa9ee8dabb1ab01910e5ed" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +REQUIRES="" +MAINTAINER="Dimitris Zlatanidis" +EMAIL="d.zlatanidis@gmail.com" diff --git a/games/wormblast/wormblast.patch b/games/wormblast/wormblast.patch new file mode 100644 index 0000000000..b4f501d93e --- /dev/null +++ b/games/wormblast/wormblast.patch @@ -0,0 +1,76 @@ +--- wormblast-2.0.2/src/game/game.original.cc 2014-04-17 04:44:16.025841490 +0300 ++++ wormblast-2.0.2/src/game/game.cc 2014-04-17 04:45:16.415086521 +0300 +@@ -54,6 +54,7 @@ + // **** C++ standard includes **** + + #include <cmath> ++#include <unistd.h> + + using std::tan; + +--- wormblast-2.0.2/src/gui_new/about_dlg.original.hh 2014-04-17 05:19:09.918664228 +0300 ++++ wormblast-2.0.2/src/gui_new/about_dlg.hh 2014-04-17 05:58:16.569327057 +0300 +@@ -24,7 +24,7 @@ + #include <QWidget> + #include <QResizeEvent> + +-#include "ui_about.h" ++#include "../../build/src/gui_new/ui_about.h" + + //! The about box + class AboutDlg : public QDialog +--- wormblast-2.0.2/src/gui_new/highscores_dlg.original.hh 2014-04-17 06:01:56.538577063 +0300 ++++ wormblast-2.0.2/src/gui_new/highscores_dlg.hh 2014-04-17 06:03:11.096644959 +0300 +@@ -21,7 +21,7 @@ + #define HIGHSCORES_DLG_HH + + #include <QDialog> +-#include "ui_highscores.h" ++#include "../../build/src/gui_new/ui_highscores.h" + #include "config.hh" + + //! Dialog that shows high scores for one-player and two-player games +--- wormblast-2.0.2/src/gui_new/settings_dlg.original.hh 2014-04-17 06:06:55.647837683 +0300 ++++ wormblast-2.0.2/src/gui_new/settings_dlg.hh 2014-04-17 06:07:21.624512930 +0300 +@@ -23,7 +23,7 @@ + #include <QDialog> + #include <QWidget> + +-#include "ui_settings.h" ++#include "../../build/src/gui_new/ui_settings.h" + #include "config.hh" + + //! The settings dialog +--- wormblast-2.0.2/CMakeLists.original.txt 2014-04-17 06:39:16.678571460 +0300 ++++ wormblast-2.0.2/CMakeLists.txt 2014-04-17 07:09:17.741055080 +0300 +@@ -17,7 +17,7 @@ + + # Set install dirs + set(CMAKE_INSTALL_PREFIX /usr) +-set(DEST_PATH /opt/WormBlast) ++set(DEST_PATH /usr/share/games/WormBlast) + set(DATA_PATH ${DEST_PATH}/data) + set(BIN_PATH ${DEST_PATH}/bin) + add_definitions(-DGAME_BINARY_PATH="${BIN_PATH}/wormblast-game.x") +@@ -57,8 +57,8 @@ + add_subdirectory(src/gui_new) + + # Install binaries & data +-install(PROGRAMS bin/game/wormblast-game.x DESTINATION ${BIN_PATH}) +-install(PROGRAMS bin/gui/wormblast DESTINATION ${BIN_PATH}) ++install(PROGRAMS build/bin/game/wormblast-game.x DESTINATION ${BIN_PATH}) ++install(PROGRAMS build/bin/gui/wormblast DESTINATION ${BIN_PATH}) + install(FILES data/sounds.map data/textures.map data/verasans.map DESTINATION ${DATA_PATH}) + install(DIRECTORY data/images DESTINATION ${DATA_PATH} FILES_MATCHING PATTERN "*.jpg") + install(DIRECTORY data/images DESTINATION ${DATA_PATH} FILES_MATCHING PATTERN "*.png") +--- wormblast-2.0.2/data/wormblast.desktop.original 2014-04-17 07:14:57.288810149 +0300 ++++ wormblast-2.0.2/data/wormblast.desktop 2014-04-17 07:16:06.055950441 +0300 +@@ -2,7 +2,7 @@ + Name=WormBlast + Comment[fi]=Action matopeli 1-2 pelaajalle + Comment=Worm action game for 1-2 players +-Exec=/opt/WormBlast/bin/wormblast ++Exec=wormblast + Icon=wormblast-32 + Terminal=false + Type=Application |