summaryrefslogtreecommitdiff
path: root/extra/wesnoth
diff options
context:
space:
mode:
authorParabola <dev@list.parabolagnulinux.org>2011-04-05 14:26:38 +0000
committerParabola <dev@list.parabolagnulinux.org>2011-04-05 14:26:38 +0000
commit415856bdd4f48ab4f2732996f0bae58595092bbe (patch)
treeede2018b591f6dfb477fe9341ba17b9bc000fab9 /extra/wesnoth
Tue Apr 5 14:26:38 UTC 2011
Diffstat (limited to 'extra/wesnoth')
-rw-r--r--extra/wesnoth/PKGBUILD28
-rw-r--r--extra/wesnoth/wesnoth-libpng-1.4.0.patch14
-rw-r--r--extra/wesnoth/wesnoth.install9
3 files changed, 51 insertions, 0 deletions
diff --git a/extra/wesnoth/PKGBUILD b/extra/wesnoth/PKGBUILD
new file mode 100644
index 000000000..a60a35818
--- /dev/null
+++ b/extra/wesnoth/PKGBUILD
@@ -0,0 +1,28 @@
+# $Id: PKGBUILD 112017 2011-03-03 06:20:54Z eric $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+# Contributor: Tobias Powalowski <tpowa@archlinux.org>
+# Contributor: Jacobo Arvelo <unix4all@ya.com>
+# Contributor: Douglas Soares de Andrade <douglas@archlinux.org>
+
+pkgname=wesnoth
+pkgver=1.8.5
+pkgrel=3
+pkgdesc="A turn-based strategy game on a fantasy world"
+arch=('i686' 'x86_64')
+license=('GPL')
+url="http://www.wesnoth.org/"
+depends=('sdl_ttf' 'sdl_net' 'sdl_mixer' 'sdl_image' 'fribidi' 'boost-libs' 'pango' 'lua' "wesnoth-data=${pkgver}" 'dbus-core')
+makedepends=('boost')
+install=wesnoth.install
+source=(http://downloads.sourceforge.net/sourceforge/${pkgname}/${pkgname}-${pkgver}.tar.bz2
+ wesnoth-libpng-1.4.0.patch)
+md5sums=('a800285d1406690755dd0ea22b98b6df'
+ 'ca7412ffc4682ef55ddf82d56b0e2f08')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i ../wesnoth-libpng-1.4.0.patch
+ ./autogen.sh
+ ./configure --prefix=/usr --localstatedir=/var --enable-tools --enable-editor --enable-server
+ make DESTDIR="${pkgdir}" install-exec
+}
diff --git a/extra/wesnoth/wesnoth-libpng-1.4.0.patch b/extra/wesnoth/wesnoth-libpng-1.4.0.patch
new file mode 100644
index 000000000..be8adfcaa
--- /dev/null
+++ b/extra/wesnoth/wesnoth-libpng-1.4.0.patch
@@ -0,0 +1,14 @@
+diff -Nur wesnoth-1.8.orig/src/tools/exploder_utils.cpp wesnoth-1.8/src/tools/exploder_utils.cpp
+--- wesnoth-1.8.orig/src/tools/exploder_utils.cpp 2010-01-01 15:16:49.000000000 +0200
++++ wesnoth-1.8/src/tools/exploder_utils.cpp 2010-04-08 17:38:03.066201123 +0300
+@@ -174,8 +174,8 @@
+ //TODO: review whether providing NULL error handlers is something
+ //sensible
+ png_struct* png_ptr = png_create_write_struct
+- (PNG_LIBPNG_VER_STRING, reinterpret_cast<png_voidp>(png_voidp_NULL),
+- png_error_ptr_NULL, png_error_ptr_NULL);
++ (PNG_LIBPNG_VER_STRING, reinterpret_cast<png_voidp>(NULL),
++ NULL, NULL);
+ if(!png_ptr)
+ throw exploder_failure("Unable to initialize the png write structure");
+
diff --git a/extra/wesnoth/wesnoth.install b/extra/wesnoth/wesnoth.install
new file mode 100644
index 000000000..4f1e419ae
--- /dev/null
+++ b/extra/wesnoth/wesnoth.install
@@ -0,0 +1,9 @@
+# arg 1: the new package version
+post_install() {
+cat << EOF
+Note:
+==> If you experience sound problems try setting your SDL_AUDIODRIVER environment variable to "dma"
+==> eg. export SDL_AUDIODRIVER="dma" ; wesnoth
+==> If "dma" doesn't work,other options are: dsp,alsa,artsc,esd,nas try to find the right output.
+EOF
+}