aboutsummaryrefslogtreecommitdiff
path: root/games/megaglest
diff options
context:
space:
mode:
authorLarry Hajali <larryhaja@gmail.com>2013-12-01 09:05:06 +0100
committerRobby Workman <rworkman@slackbuilds.org>2013-12-02 00:58:03 -0600
commit2af9b17988fad0439c8e30c47f46b3a243b7857c (patch)
tree176cac55f1f39e34c7ae0b92f3dfa74067201da7 /games/megaglest
parentb00d17583d82f47b42f54fdc450c589898af1da9 (diff)
games/megaglest: Updated for version 3.9.0.4, added a license.
Cleanups and noted the optional dependency p7zip Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'games/megaglest')
-rw-r--r--games/megaglest/README2
-rw-r--r--games/megaglest/megaglest-3.6.0.2-help2man.patch11
-rw-r--r--games/megaglest/megaglest-3.9.0-help2man.patch12
-rw-r--r--games/megaglest/megaglest.SlackBuild48
-rw-r--r--games/megaglest/megaglest.info14
5 files changed, 51 insertions, 36 deletions
diff --git a/games/megaglest/README b/games/megaglest/README
index 6c2485721a24..d0547643244d 100644
--- a/games/megaglest/README
+++ b/games/megaglest/README
@@ -4,7 +4,7 @@ Magic, Egyptians, Indians, Norsemen, Persian or Romans. The game
is setup in one of 16 naturally looking settings, which (like the
unit models) are crafted with great appreciation for detail.
-Optional dependencies: libircclient, miniupnpc, vlc
+Optional dependencies: libircclient, miniupnpc, vlc, p7zip
Note to parallel builders: don't user more than 2 jobs or build
will break.
diff --git a/games/megaglest/megaglest-3.6.0.2-help2man.patch b/games/megaglest/megaglest-3.6.0.2-help2man.patch
deleted file mode 100644
index 6c71b8afe567..000000000000
--- a/games/megaglest/megaglest-3.6.0.2-help2man.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- megaglest-3.6.0.2/source/g3d_viewer/CMakeLists.txt.orig 2012-01-01 12:28:16.744930699 -0200
-+++ megaglest-3.6.0.2/source/g3d_viewer/CMakeLists.txt 2012-01-01 12:29:41.693429413 -0200
-@@ -157,7 +157,7 @@ IF(BUILD_MEGAGLEST_MODEL_VIEWER)
- MESSAGE("***-- Found xvfb-run: ${XVFB_EXEC} about to build manpage with it.")
-
- add_custom_target(${TARGET_NAME_MANPAGE} ALL
-- COMMAND ${XVFB_EXEC} --auto-servernum --server-num=770 ${HELP2MAN} --name='${MG_MANPAGE_DESCRIPTION}' --section=6 -N -o ${EXECUTABLE_OUTPUT_PATH}/${TARGET_NAME_MANPAGE} ${EXECUTABLE_OUTPUT_PATH}/${TARGET_NAME}
-+ COMMAND ${XVFB_EXEC} --auto-servernum ${HELP2MAN} --name='${MG_MANPAGE_DESCRIPTION}' --section=6 -N -o ${EXECUTABLE_OUTPUT_PATH}/${TARGET_NAME_MANPAGE} ${EXECUTABLE_OUTPUT_PATH}/${TARGET_NAME}
- DEPENDS ${TARGET_NAME})
- ELSE()
- add_custom_target(${TARGET_NAME_MANPAGE} ALL
diff --git a/games/megaglest/megaglest-3.9.0-help2man.patch b/games/megaglest/megaglest-3.9.0-help2man.patch
new file mode 100644
index 000000000000..78598b8729bb
--- /dev/null
+++ b/games/megaglest/megaglest-3.9.0-help2man.patch
@@ -0,0 +1,12 @@
+diff -Naur megaglest-3.9.0.orig/source/g3d_viewer/CMakeLists.txt megaglest-3.9.0/source/g3d_viewer/CMakeLists.txt
+--- megaglest-3.9.0.orig/source/g3d_viewer/CMakeLists.txt 2013-11-18 23:10:38.000000000 +0000
++++ megaglest-3.9.0/source/g3d_viewer/CMakeLists.txt 2013-11-19 07:19:28.601093314 +0000
+@@ -167,7 +167,7 @@
+ MESSAGE("***-- Found xvfb-run: ${XVFB_EXEC} about to build manpage with it.")
+
+ add_custom_target(${TARGET_NAME_MANPAGE} ALL
+- COMMAND ${XVFB_EXEC} --auto-servernum --server-num=770 ${HELP2MAN} --name='${MG_MANPAGE_DESCRIPTION}' --section=6 -N -o ${HELP2MAN_OUT_PATH}${TARGET_NAME_MANPAGE} ${HELP2MAN_OUT_PATH}${TARGET_NAME}
++ COMMAND ${XVFB_EXEC} --auto-servernum ${HELP2MAN} --name='${MG_MANPAGE_DESCRIPTION}' --section=6 -N -o ${HELP2MAN_OUT_PATH}${TARGET_NAME_MANPAGE} ${HELP2MAN_OUT_PATH}${TARGET_NAME}
+ DEPENDS ${TARGET_NAME})
+ ELSE()
+ add_custom_target(${TARGET_NAME_MANPAGE} ALL
diff --git a/games/megaglest/megaglest.SlackBuild b/games/megaglest/megaglest.SlackBuild
index 771703220c08..b7c36a385303 100644
--- a/games/megaglest/megaglest.SlackBuild
+++ b/games/megaglest/megaglest.SlackBuild
@@ -2,10 +2,29 @@
# Slackware build script for megaglest
-# Written by Larry Hajali <larryhaj[at]gmail[dot]com>
+# Copyright 2011-2013 Larry Hajali <larryhaj[at]gmail[dot]com>
+# 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=megaglest
-VERSION=${VERSION:-3.7.1}
+VERSION=${VERSION:-3.9.0.4}
+DATAVERSION=${DATAVERSION:-3.9.0}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -24,7 +43,7 @@ OUTPUT=${OUTPUT:-/tmp}
# Directory names don't always follow the $PRGNAM-$VERSION convention.
SRCDIR=$(tar -tf $CWD/$PRGNAM-source-$VERSION.tar.xz | head -1)
-DATADIR=$(tar -tf $CWD/$PRGNAM-data-$VERSION.tar.xz | head -1)
+DATADIR=$(tar -tf $CWD/$PRGNAM-data-$DATAVERSION.tar.xz | head -1)
if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
@@ -47,10 +66,9 @@ mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $SRCDIR
tar xvf $CWD/$PRGNAM-source-$VERSION.tar.xz
-tar xvf $CWD/$PRGNAM-source-embedded-$VERSION.tar.xz
-tar xvf $CWD/$PRGNAM-data-$VERSION.tar.xz -C $SRCDIR
+tar xvf $CWD/$PRGNAM-source-embedded-$DATAVERSION.tar.xz
+tar xvf $CWD/$PRGNAM-data-$DATAVERSION.tar.xz -C $SRCDIR
cd $SRCDIR
-find . -type l -exec rm -f '{}' \;
chown -R root:root .
find -L . \
\( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 -o -perm 511 \) \
@@ -58,15 +76,11 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
-# Fix version string.
-sed -i "/^const string glestVersionString/ s|=.*|= \"v${VERSION}\";|" \
- source/glest_game/facilities/game_util.cpp
-
# Fix megaglest help2man when no X display is available. Use a wrapper
-# script from upstream for Xvfb that create a temporary *fake* framebuffer
-install -m 0755 -D $CWD/xvfb-run $TMP/$SRCDIR/bin/xvfb-run
+# script from upstream for Xvfb that creates a temporary *fake* framebuffer
+install -D -m 0755 $CWD/xvfb-run $TMP/$SRCDIR/bin/xvfb-run
export PATH="$PATH:$TMP/$SRCDIR/bin"
-patch -p1 < $CWD/megaglest-3.6.0.2-help2man.patch
+patch -p1 < $CWD/megaglest-3.9.0-help2man.patch
mkdir build
cd build
@@ -80,8 +94,8 @@ cd build
-DCMAKE_BUILD_TYPE=Release ..
make VERBOSE=1
- make install DESTDIR=$PKG
-cd ..
+ make -j1 install DESTDIR=$PKG
+cd -
# Now install the game data
cd $DATADIR
@@ -90,12 +104,12 @@ cd $DATADIR
-DCMAKE_BUILD_TYPE=Release .
make install DESTDIR=$PKG
-cd ..
+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
-[ -d "$PKG/usr/man" ] && gzip -9 $PKG/usr/man/man?/*.?
+find $PKG/usr/man -type f -exec gzip -9 '{}' \;
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a \
diff --git a/games/megaglest/megaglest.info b/games/megaglest/megaglest.info
index 156c10c265b2..734cd02f67c3 100644
--- a/games/megaglest/megaglest.info
+++ b/games/megaglest/megaglest.info
@@ -1,12 +1,12 @@
PRGNAM="megaglest"
-VERSION="3.7.1"
+VERSION="3.9.0.4"
HOMEPAGE="http://megaglest.org/"
-DOWNLOAD="http://downloads.sourceforge.net/megaglest/megaglest-source-3.7.1.tar.xz \
- http://downloads.sourceforge.net/megaglest/megaglest-data-3.7.1.tar.xz \
- http://downloads.sourceforge.net/megaglest/megaglest-source-embedded-3.7.1.tar.xz"
-MD5SUM="e7a960ec73784aa0f7b951d2ad963456 \
- a73205fe02b684547dfe1fedc2d712b2 \
- 9852ab186c23580950a2dfe995e3b9b6"
+DOWNLOAD="http://downloads.sourceforge.net/megaglest/megaglest-source-3.9.0.4.tar.xz \
+ http://downloads.sourceforge.net/megaglest/megaglest-data-3.9.0.tar.xz \
+ http://downloads.sourceforge.net/megaglest/megaglest-source-embedded-3.9.0.tar.xz"
+MD5SUM="b2957c106250ec0d0e52c41811558afc \
+ bf59d83b38e78bbe82325467a6672447 \
+ 0ee2ac4e7111b66be3937c5c0721fde1"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="xerces-c OpenAL lua ftgl wxPython"