games/widelands: Updated for version build17.

Signed-off-by: Heinz Wiesinger <pprkut@slackbuilds.org>
This commit is contained in:
Heinz Wiesinger 2012-09-04 14:34:09 +02:00 committed by Robby Workman
parent d24750f2f9
commit c4a3c42e0f
5 changed files with 33 additions and 67 deletions

View File

@ -1,4 +1 @@
Widelands is a strategy game based on Settlers II.
If you want integration with the GGZ Gaming Zone,
you will also need ggz-base-libs.

View File

@ -1,49 +0,0 @@
--- src/editor/ui_menus/editor_main_menu_random_map.cc.old 2010-05-18 17:17:15.000000000 +0200
+++ src/editor/ui_menus/editor_main_menu_random_map.cc 2010-05-18 17:18:29.000000000 +0200
@@ -251,7 +251,7 @@
posx, posy, width, height,
g_gr->get_picture(PicMod_UI, "pics/but1.png"),
&Main_Menu_New_Random_Map::button_clicked, *this, 8,
- Widelands::World::World(m_worlds[m_currentworld].c_str()).get_name());
+ Widelands::World(m_worlds[m_currentworld].c_str()).get_name());
posy += height + spacing + spacing + spacing;
@@ -322,7 +322,7 @@
if (m_currentworld == m_worlds.size())
m_currentworld = 0;
m_world->set_title
- (Widelands::World::World(m_worlds[m_currentworld].c_str()).get_name());
+ (Widelands::World(m_worlds[m_currentworld].c_str()).get_name());
break;
case 9:
break;
@@ -476,7 +476,7 @@
(strcmp(mapInfo.worldName.c_str(), m_worlds[m_currentworld].c_str()))
++m_currentworld;
m_world->set_title
- (Widelands::World::World(m_worlds[m_currentworld].c_str()).get_name());
+ (Widelands::World(m_worlds[m_currentworld].c_str()).get_name());
button_clicked(-1); // Update other values in UI as well
--- src/editor/ui_menus/editor_main_menu_new_map.cc.old 2010-05-18 17:38:29.000000000 +0200
+++ src/editor/ui_menus/editor_main_menu_new_map.cc 2010-05-18 17:38:55.000000000 +0200
@@ -113,7 +113,7 @@
posx, posy, width, height,
g_gr->get_picture(PicMod_UI, "pics/but1.png"),
&Main_Menu_New_Map::button_clicked, *this, 4,
- Widelands::World::World(m_worlds[m_currentworld].c_str()).get_name());
+ Widelands::World(m_worlds[m_currentworld].c_str()).get_name());
posy += height + spacing + spacing + spacing;
@@ -142,7 +142,7 @@
if (m_currentworld == m_worlds.size())
m_currentworld = 0;
m_world->set_title
- (Widelands::World::World(m_worlds[m_currentworld].c_str()).get_name
+ (Widelands::World(m_worlds[m_currentworld].c_str()).get_name
());
break;
}

View File

@ -0,0 +1,12 @@
=== modified file 'src/main.cc'
--- src/main.cc 2012-02-15 21:25:34 +0000
+++ src/main.cc 2012-05-02 07:43:01 +0000
@@ -28,6 +28,7 @@
#include <iostream>
#include <stdexcept>
#include <typeinfo>
+#include <unistd.h>
#include <SDL_main.h>

View File

@ -2,7 +2,7 @@
# Slackware build script for widelands
# Copyright 2008-2010 Heinz Wiesinger, Amsterdam, The Netherlands
# Copyright 2008-2012 Heinz Wiesinger, Amsterdam, The Netherlands
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@ -23,8 +23,8 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=widelands
VERSION=build15
BUILD=${BUILD:-2}
VERSION=build17
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
@ -65,13 +65,19 @@ cd $PRGNAM-$VERSION-src
chown -R root:root .
chmod -R u+w,go+r-w,a-s .
patch -p0 < $CWD/widelands-0.15-gcc45.patch
# Fix compiling with gcc 4.7
patch -p0 -i $CWD/widelands-gcc47.patch
# make locale install dir configurable
localedir="WLBUILD_INSTALL_LOCALEDIR"
old="$localedir \"\${CMAKE_INSTALL_PREFIX}/\${WL_INSTALL_DATADIR}/locale\""
new="$localedir \${WL_INSTALL_LOCALEDIR}"
sed -i "s|$old|$new|" CMakeLists.txt
# Don't use static boost libraries
sed -i "s|Boost_USE_STATIC_LIBS ON|Boost_USE_STATIC_LIBS OFF|" \
CMakeLists.txt
# Fix wrong datadir declaration
old="std::string(INSTALL_PREFIX) + '/' + INSTALL_DATADIR"
sed -i "s|INSTALL_PREFIX \"/\" INSTALL_DATADIR|INSTALL_DATADIR|" \
src/wlapplication.cc
sed -i "s|$old|std::string(INSTALL_DATADIR)|" \
src/wlapplication.cc
mkdir -p build1
cd build1
@ -79,10 +85,10 @@ cd build1
-DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_INSTALL_PREFIX=/usr \
-DLIB_SUFFIX=${LIBDIRSUFFIX} \
-DCMAKE_BUILD_TYPE=Release \
-DWL_INSTALL_LOCALEDIR="/usr/share/locale" \
-DWL_INSTALL_BINDIR="bin" \
-DWL_INSTALL_PREFIX=/usr \
-DWL_INSTALL_DATADIR=/usr/share/widelands \
-DWL_INSTALL_BINDIR=/usr/bin \
..
make
make install DESTDIR=$PKG

View File

@ -1,8 +1,8 @@
PRGNAM="widelands"
VERSION="build15"
VERSION="build17"
HOMEPAGE="http://www.widelands.org"
DOWNLOAD="http://launchpad.net/widelands/build15/build15/+download/widelands-build15-src.tar.bz2"
MD5SUM="5b2e2d0913272f66055e424f91360b1d"
DOWNLOAD="https://launchpad.net/widelands/build17/build-17/+download/widelands-build17-src.tar.bz2"
MD5SUM="bdc9bc0aa631af1aa7fb450507611a58"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="SDL_gfx lua"