summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'games-board')
-rw-r--r--games-board/pouetchess/files/pouetchess-0.2.0-fix-sdl-version-list.patch11
-rw-r--r--games-board/pouetchess/files/pouetchess-0.2.0-gcc43.patch4
-rw-r--r--games-board/pouetchess/files/pouetchess-0.2.0-nvidia_glext.patch4
-rw-r--r--games-board/pouetchess/files/pouetchess-0.2.0-sconstruct-sandbox.patch4
-rw-r--r--games-board/pouetchess/files/pouetchess-0.2.0-segfaults.patch20
-rw-r--r--games-board/pouetchess/pouetchess-0.2.0-r2.ebuild64
6 files changed, 91 insertions, 16 deletions
diff --git a/games-board/pouetchess/files/pouetchess-0.2.0-fix-sdl-version-list.patch b/games-board/pouetchess/files/pouetchess-0.2.0-fix-sdl-version-list.patch
new file mode 100644
index 000000000000..06b9aff2c2d8
--- /dev/null
+++ b/games-board/pouetchess/files/pouetchess-0.2.0-fix-sdl-version-list.patch
@@ -0,0 +1,11 @@
+--- a/pouetChess.py
++++ b/pouetChess.py
+@@ -228,7 +228,7 @@
+ sdlver = sdlobj.read()
+ sdlerr = sdlobj.close()
+ print sdlver,
+- if sdlver.split('.') >= ['1','2','8']:
++ if sdlver.split('.') >= [1,2,8]:
+ env.ParseConfig(sdlcfg+" --cflags --libs")
+ else:
+ print "You need LibSDL version 1.2.8 or greater for this program"
diff --git a/games-board/pouetchess/files/pouetchess-0.2.0-gcc43.patch b/games-board/pouetchess/files/pouetchess-0.2.0-gcc43.patch
index 0a60c2117da8..ef2ba1575825 100644
--- a/games-board/pouetchess/files/pouetchess-0.2.0-gcc43.patch
+++ b/games-board/pouetchess/files/pouetchess-0.2.0-gcc43.patch
@@ -1,5 +1,5 @@
---- src/sxmlgui/XMLUtils.h.orig 2008-06-14 14:50:16.000000000 +0000
-+++ src/sxmlgui/XMLUtils.h 2008-06-14 14:50:33.000000000 +0000
+--- a/src/sxmlgui/XMLUtils.h.orig 2008-06-14 14:50:16.000000000 +0000
++++ b/src/sxmlgui/XMLUtils.h 2008-06-14 14:50:33.000000000 +0000
@@ -38,6 +38,8 @@
#include <stdio.h>
#include <assert.h>
diff --git a/games-board/pouetchess/files/pouetchess-0.2.0-nvidia_glext.patch b/games-board/pouetchess/files/pouetchess-0.2.0-nvidia_glext.patch
index 952f6dc85add..b7077feb6a38 100644
--- a/games-board/pouetchess/files/pouetchess-0.2.0-nvidia_glext.patch
+++ b/games-board/pouetchess/files/pouetchess-0.2.0-nvidia_glext.patch
@@ -1,5 +1,5 @@
---- src/sxmlgui/GenUtils.h 2006-05-27 03:22:57.000000000 +0200
-+++ src/sxmlgui/GenUtils.h.new 2006-06-12 20:35:32.000000000 +0200
+--- a/src/sxmlgui/GenUtils.h 2006-05-27 03:22:57.000000000 +0200
++++ b/src/sxmlgui/GenUtils.h.new 2006-06-12 20:35:32.000000000 +0200
@@ -5,6 +5,9 @@
#include <iostream>
#include <fstream>
diff --git a/games-board/pouetchess/files/pouetchess-0.2.0-sconstruct-sandbox.patch b/games-board/pouetchess/files/pouetchess-0.2.0-sconstruct-sandbox.patch
index cea3a5a451af..5d4cf9c00b4c 100644
--- a/games-board/pouetchess/files/pouetchess-0.2.0-sconstruct-sandbox.patch
+++ b/games-board/pouetchess/files/pouetchess-0.2.0-sconstruct-sandbox.patch
@@ -1,5 +1,5 @@
---- SConstruct
-+++ SConstruct
+--- a/SConstruct
++++ b/SConstruct
@@ -22,14 +22,24 @@
diff --git a/games-board/pouetchess/files/pouetchess-0.2.0-segfaults.patch b/games-board/pouetchess/files/pouetchess-0.2.0-segfaults.patch
index 58780e1b275e..346ee1248ab3 100644
--- a/games-board/pouetchess/files/pouetchess-0.2.0-segfaults.patch
+++ b/games-board/pouetchess/files/pouetchess-0.2.0-segfaults.patch
@@ -1,5 +1,5 @@
---- src/faile/search.c
-+++ src/faile/search.c
+--- a/src/faile/search.c
++++ b/src/faile/search.c
@@ -805,6 +805,7 @@
for (j = 0; j < indent; j++) {
fputc (' ', output);
@@ -8,8 +8,8 @@
print_move (&moves[0], i, output);
fprintf (output, "\n");
---- src/faile/utils.c
-+++ src/faile/utils.c
+--- a/src/faile/utils.c
++++ b/src/faile/utils.c
@@ -125,7 +125,7 @@
rank (target) < 1 || rank (target) > 8 ||
file (target) < 1 || file (target) > 8)
@@ -19,8 +19,8 @@
return;
}
---- src/main.cpp
-+++ src/main.cpp
+--- a/src/main.cpp
++++ b/src/main.cpp
@@ -184,6 +184,9 @@
// first scene is SCENE_INIT.
pGlobalInfos->SetCurrentScene(GAME_SCENE_INIT);
@@ -31,8 +31,8 @@
// main game loop
while( pGlobalInfos->IsGameRunning() )
{
---- src/scene_main_game.cpp
-+++ src/scene_main_game.cpp
+--- a/src/scene_main_game.cpp
++++ b/src/scene_main_game.cpp
@@ -245,7 +245,7 @@
if (pGlobalInfos->OnLeftMouseButtonDown())
@@ -42,8 +42,8 @@
{
// if a piece was already selected, this means the player want to move this piece
if (SquareXSelected>-1 && SquareZSelected>-1)
---- src/graphic_chessboard.cpp.old 2011-03-23 08:08:40.000000000 +0100
-+++ src/graphic_chessboard.cpp 2011-03-23 08:33:04.000000000 +0100
+--- a/src/graphic_chessboard.cpp
++++ b/src/graphic_chessboard.cpp
@@ -122,8 +122,8 @@
for(int i=0;i<6;i++)
diff --git a/games-board/pouetchess/pouetchess-0.2.0-r2.ebuild b/games-board/pouetchess/pouetchess-0.2.0-r2.ebuild
new file mode 100644
index 000000000000..6786484105d6
--- /dev/null
+++ b/games-board/pouetchess/pouetchess-0.2.0-r2.ebuild
@@ -0,0 +1,64 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit eutils scons-utils toolchain-funcs
+
+MY_PN=${PN/c/C}
+
+DESCRIPTION="3D and open source chess game"
+HOMEPAGE="http://pouetchess.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${PN}_src_${PV}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="debug"
+
+DEPEND="
+ media-libs/libsdl:0[opengl,video]
+ media-libs/sdl-image[jpeg,png]
+ virtual/glu
+ virtual/opengl"
+RDEPEND=${DEPEND}
+
+S=${WORKDIR}/${PN}_src_${PV}
+
+PATCHES=(
+ "${FILESDIR}"/${P}-sconstruct-sandbox.patch
+ "${FILESDIR}"/${P}-nvidia_glext.patch
+ "${FILESDIR}"/${P}-segfaults.patch
+ "${FILESDIR}"/${P}-gcc43.patch
+ "${FILESDIR}"/${P}-gcc6-cmath.patch
+ # Fix for LibSDL >= 1.2.10 detection
+ "${FILESDIR}"/${P}-fix-sdl-version-list.patch
+)
+
+src_configure() {
+ tc-export CC CXX
+
+ # turn off the hackish optimization setting code (bug #230127)
+ scons configure \
+ strip=false \
+ optimize=false \
+ prefix="${EPREFIX}"/usr \
+ datadir="${EPREFIX}"/usr/share/${PN} \
+ $(use debug && echo debug=1) || die
+}
+
+src_compile() {
+ escons
+}
+
+src_install() {
+ dobin bin/${MY_PN}
+
+ insinto /usr/share/${PN}
+ doins -r data/.
+
+ einstalldocs
+
+ doicon data/icons/${MY_PN}.png
+ make_desktop_entry ${MY_PN} ${MY_PN} ${MY_PN} "KDE;Qt;Game;BoardGame"
+}