summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTristan Heaven <nyhm@gentoo.org>2009-06-16 20:28:29 +0000
committerTristan Heaven <nyhm@gentoo.org>2009-06-16 20:28:29 +0000
commit1a06e1005ca042ac1b0cc713d7c1cea92f752cad (patch)
treea6631cf8e847d43f21fb65828918bafd404867b8 /games-puzzle/kiki
parentStable on alpha, bug #272980 (diff)
downloadgentoo-2-1a06e1005ca042ac1b0cc713d7c1cea92f752cad.tar.gz
gentoo-2-1a06e1005ca042ac1b0cc713d7c1cea92f752cad.tar.bz2
gentoo-2-1a06e1005ca042ac1b0cc713d7c1cea92f752cad.zip
Fix building with latest python versions, bug #273600
(Portage version: 2.2_rc33/cvs/Linux i686)
Diffstat (limited to 'games-puzzle/kiki')
-rw-r--r--games-puzzle/kiki/ChangeLog8
-rw-r--r--games-puzzle/kiki/files/kiki-1.0.2-build.patch45
-rw-r--r--games-puzzle/kiki/kiki-1.0.2-r2.ebuild44
3 files changed, 70 insertions, 27 deletions
diff --git a/games-puzzle/kiki/ChangeLog b/games-puzzle/kiki/ChangeLog
index 2e8af68609a6..8473f1de9647 100644
--- a/games-puzzle/kiki/ChangeLog
+++ b/games-puzzle/kiki/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for games-puzzle/kiki
-# Copyright 2000-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/games-puzzle/kiki/ChangeLog,v 1.14 2008/11/18 22:38:40 mr_bones_ Exp $
+# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/games-puzzle/kiki/ChangeLog,v 1.15 2009/06/16 20:28:29 nyhm Exp $
+
+ 16 Jun 2009; Tristan Heaven <nyhm@gentoo.org> kiki-1.0.2-r2.ebuild,
+ +files/kiki-1.0.2-build.patch:
+ Fix building with latest python versions, bug #273600
18 Nov 2008; Michael Sterrett <mr_bones_@gentoo.org>
+files/kiki-1.0.2-gcc43.patch, kiki-1.0.2-r2.ebuild:
diff --git a/games-puzzle/kiki/files/kiki-1.0.2-build.patch b/games-puzzle/kiki/files/kiki-1.0.2-build.patch
new file mode 100644
index 000000000000..b3798678f81a
--- /dev/null
+++ b/games-puzzle/kiki/files/kiki-1.0.2-build.patch
@@ -0,0 +1,45 @@
+--- kodilib/linux/Makefile
++++ kodilib/linux/Makefile
+@@ -21,7 +21,7 @@
+
+ INCLUDES = $(KODI_INCLUDES) $(X11_INCLUDES) $(SDL_INCLUDES)
+
+-CXXFLAGS = $(INCLUDES) $(SDL_CFLAGS)
++CXXFLAGS += $(INCLUDES) $(SDL_CFLAGS)
+
+ src = \
+ $(KODISRCDIR)/handler/KEventHandler.cpp \
+--- linux/Makefile
++++ linux/Makefile
+@@ -14,11 +14,7 @@
+
+ GLLIBS = -lglut -lGLU -lGL
+
+-PYTHONHOME = /usr/lib/python$(PYTHON_VERSION)/
+-PYTHONLIBS = $(PYTHONHOME)/config/libpython$(PYTHON_VERSION).a -lutil \
+- $(PYTHONHOME)/lib-dynload/math.so \
+- $(PYTHONHOME)/lib-dynload/time.so \
+- $(PYTHONHOME)/lib-dynload/_random.so
++PYTHONLIBS = -lpython$(PYTHON_VERSION) -lutil
+
+ # change this, if the kodilib directory isn't parallel to the kiki directory
+
+@@ -46,7 +42,7 @@
+
+ INCLUDES = $(KIKI_INCLUDES) $(X11_INCLUDES) $(PYTHON_INCLUDES)
+
+-CXXFLAGS = $(INCLUDES) $(SDLCFLAGS)
++CXXFLAGS += $(INCLUDES) $(SDLCFLAGS)
+
+ src = \
+ $(KIKISRC)/base/KikiAction.cpp \
+@@ -105,8 +101,7 @@
+ obj = $(src:.cpp=.o)
+
+ kiki: $(KIKISRC)/../SWIG/KikiPy_wrap.cpp $(obj)
+- -(cd ../SWIG; swig -c++ -python -globals kiki -o KikiPy_wrap.cpp KikiPy.i; cp kiki.py ../py)
+- $(CXX) $(obj) $(KODILIB) -o kiki $(GLLIBS) $(SDLLIBS) $(PYTHONLIBS)
++ $(CXX) $(CXXFLAGS) $(LDFLAGS) $(obj) $(KODILIB) -o kiki $(GLLIBS) $(SDLLIBS) $(PYTHONLIBS)
+
+ obj-clean:
+ $(RM) -f $(obj)
diff --git a/games-puzzle/kiki/kiki-1.0.2-r2.ebuild b/games-puzzle/kiki/kiki-1.0.2-r2.ebuild
index 17f8c8adcb11..7d9b9900b7a1 100644
--- a/games-puzzle/kiki/kiki-1.0.2-r2.ebuild
+++ b/games-puzzle/kiki/kiki-1.0.2-r2.ebuild
@@ -1,7 +1,8 @@
-# Copyright 1999-2008 Gentoo Foundation
+# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/games-puzzle/kiki/kiki-1.0.2-r2.ebuild,v 1.3 2008/11/18 22:38:40 mr_bones_ Exp $
+# $Header: /var/cvsroot/gentoo-x86/games-puzzle/kiki/kiki-1.0.2-r2.ebuild,v 1.4 2009/06/16 20:28:29 nyhm Exp $
+EAPI=2
inherit eutils python toolchain-funcs games
DESCRIPTION="Fun 3D puzzle game using SDL/OpenGL"
@@ -13,26 +14,26 @@ SLOT="0"
KEYWORDS="ppc x86"
IUSE=""
-RDEPEND=">=media-libs/libsdl-1.2
- >=media-libs/sdl-image-1.2.2
- >=media-libs/sdl-mixer-1.2.5
- >=dev-lang/python-2.2
+RDEPEND="media-libs/libsdl[opengl]
+ media-libs/sdl-image
+ media-libs/sdl-mixer
+ dev-lang/python
+ virtual/opengl
+ virtual/glu
virtual/glut"
DEPEND="${RDEPEND}
dev-lang/swig"
S=${WORKDIR}/${PN}
-src_unpack() {
- unpack ${A}
- cd "${S}"
+src_prepare() {
epatch \
- "${FILESDIR}/${P}"-gcc41.patch \
- "${FILESDIR}/${P}"-freeglut.patch \
- "${FILESDIR}/${P}"-gcc43.patch
- # There are CVS directories in the tgz file
- rm -rf $(find -name CVS -type d)
- rm -rf $(find -name .cvsignore)
+ "${FILESDIR}"/${P}-gcc41.patch \
+ "${FILESDIR}"/${P}-freeglut.patch \
+ "${FILESDIR}"/${P}-gcc43.patch \
+ "${FILESDIR}"/${P}-build.patch
+ ecvs_clean
+ rm -f py/runkiki
# Change the hard-coded data dir for sounds, etc...
sed -i \
@@ -41,13 +42,6 @@ src_unpack() {
-e "s:KConsole\:\:printf(\" ... assuming resources in current directory\");::g" \
src/main/KikiController.cpp \
|| die "sed KikiController.cpp failed"
- python_version
- sed -i \
- -e "/^PYTHON_VERSION/s/2.3/${PYVER}/" \
- -e '/lib-dynload/d' \
- -e '/^PYTHONLIBS/s:\\:-lpython$(PYTHON_VERSION):' \
- linux/Makefile \
- || die "sed kiki_src/kiki/linux/Makefile failed"
# Bug 139570
cd SWIG
@@ -56,9 +50,9 @@ src_unpack() {
}
src_compile() {
- tc-export AR CXX
- emake -C kodilib/linux || die "emake in kodilib/linux failed"
- emake -C linux || die "emake in linux failed"
+ emake -C kodilib/linux AR="$(tc-getAR)" || die "emake kodilib failed"
+ python_version
+ emake -C linux PYTHON_VERSION="${PYVER}" || die "emake linux failed"
}
src_install() {