summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTristan Heaven <nyhm@gentoo.org>2008-09-01 23:01:10 +0000
committerTristan Heaven <nyhm@gentoo.org>2008-09-01 23:01:10 +0000
commit557cc4cb6afa5cecef27c7ed569687d690309704 (patch)
treeda1d72c680d50faafa980cd7de126f9694722826 /games-emulation
parentVersion bump. (diff)
downloadgentoo-2-557cc4cb6afa5cecef27c7ed569687d690309704.tar.gz
gentoo-2-557cc4cb6afa5cecef27c7ed569687d690309704.tar.bz2
gentoo-2-557cc4cb6afa5cecef27c7ed569687d690309704.zip
Fix implicit declarations and linking on amd64, bug #206375
(Portage version: 2.2_rc8/cvs/Linux 2.6.26.3 x86_64)
Diffstat (limited to 'games-emulation')
-rw-r--r--games-emulation/nestra/ChangeLog10
-rw-r--r--games-emulation/nestra/files/nestra-0.66-include.patch73
-rw-r--r--games-emulation/nestra/nestra-0.66-r2.ebuild51
3 files changed, 132 insertions, 2 deletions
diff --git a/games-emulation/nestra/ChangeLog b/games-emulation/nestra/ChangeLog
index 27e7ac6cefe0..bd235243b314 100644
--- a/games-emulation/nestra/ChangeLog
+++ b/games-emulation/nestra/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for games-emulation/nestra
-# Copyright 1999-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/games-emulation/nestra/ChangeLog,v 1.13 2006/12/01 21:31:46 wolf31o2 Exp $
+# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/games-emulation/nestra/ChangeLog,v 1.14 2008/09/01 23:01:09 nyhm Exp $
+
+*nestra-0.66-r2 (01 Sep 2008)
+
+ 01 Sep 2008; Tristan Heaven <nyhm@gentoo.org>
+ +files/nestra-0.66-include.patch, +nestra-0.66-r2.ebuild:
+ Fix implicit declarations and linking on amd64, bug #206375
01 Dec 2006; Chris Gianelloni <wolf31o2@gentoo.org> nestra-0.66-r1.ebuild:
Removing old virtual/x11 dependency.
diff --git a/games-emulation/nestra/files/nestra-0.66-include.patch b/games-emulation/nestra/files/nestra-0.66-include.patch
new file mode 100644
index 000000000000..b4733b172bba
--- /dev/null
+++ b/games-emulation/nestra/files/nestra-0.66-include.patch
@@ -0,0 +1,73 @@
+--- comptbl.c
++++ comptbl.c
+@@ -9,6 +9,7 @@
+ #include <stdio.h>
+ #include <string.h>
+ #include <errno.h>
++#include <stdlib.h>
+
+ #define ALLOC_SIZE 0x400000 /* 4MB */
+ #define TBL_BASE ((unsigned char *)0x10000000)
+--- d6502.c
++++ d6502.c
+@@ -1,6 +1,7 @@
+ /* 6502 disassembler */
+ /* Public Domain */
+
++#include <stdio.h>
+ #include "globals.h"
+
+ char Opcodes_6502[256][4]={
+--- emu.c
++++ emu.c
+@@ -12,6 +12,7 @@
+ #include <sys/mman.h>
+ #include <stdio.h>
+ #include <stdlib.h>
++#include <string.h>
+
+ #include "mapper.h"
+ #include "io.h"
+--- fb.c
++++ fb.c
+@@ -2,6 +2,8 @@
+ /* Framebuffer/pixmap rendering */
+ /* Public Domain */
+
++#include <stdlib.h>
++#include <string.h>
+ #include <stdio.h>
+ #include "mapper.h"
+ #include "globals.h"
+--- io.c
++++ io.c
+@@ -5,6 +5,7 @@
+ to do I/O operations. */
+
+ #include <stdio.h>
++#include <string.h>
+ #include "mapper.h"
+ #include "io.h"
+ #include "globals.h"
+--- mapper.c
++++ mapper.c
+@@ -1,6 +1,7 @@
+ /* Nestra mapper.c */
+ /* Public Domain */
+
++#include <string.h>
+ #include "mapper.h"
+ #include "consts.h"
+
+--- x11.c
++++ x11.c
+@@ -1,6 +1,9 @@
+ /* Nestra x11.c */
+ /* Public Domain */
+
++#include <stdlib.h>
++#include <string.h>
++#include <stdio.h>
+ #include <X11/Xlib.h>
+ #include <X11/keysym.h>
+ #include <X11/Xutil.h>
diff --git a/games-emulation/nestra/nestra-0.66-r2.ebuild b/games-emulation/nestra/nestra-0.66-r2.ebuild
new file mode 100644
index 000000000000..2f731885292d
--- /dev/null
+++ b/games-emulation/nestra/nestra-0.66-r2.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/games-emulation/nestra/nestra-0.66-r2.ebuild,v 1.1 2008/09/01 23:01:09 nyhm Exp $
+
+inherit eutils toolchain-funcs flag-o-matic multilib games
+
+PATCH="${P/-/_}-10.diff"
+DESCRIPTION="NES emulation for Linux/x86"
+HOMEPAGE="http://nestra.linuxgames.com/"
+SRC_URI="http://nestra.linuxgames.com/${P}.tar.gz
+ mirror://debian/pool/contrib/n/nestra/${PATCH}.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND="amd64? ( app-emulation/emul-linux-x86-xlibs )
+ x11-libs/libX11"
+
+S=${WORKDIR}/${PN}
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch \
+ "${WORKDIR}"/${PATCH} \
+ "${FILESDIR}"/${P}-exec-stack.patch \
+ "${FILESDIR}"/${P}-include.patch
+ append-ldflags -Wl,-z,noexecstack
+ use amd64 && multilib_toolchain_setup x86
+ sed -i \
+ -e "s:-L/usr/X11R6/lib:${LDFLAGS}:" \
+ -e 's:-O2 ::' \
+ -e "s:gcc:$(tc-getCC) ${CFLAGS}:" \
+ -e "s:ld:$(tc-getLD) -m elf_i386 $(raw-ldflags):" \
+ Makefile \
+ || die "sed failed"
+}
+
+src_compile() {
+ use amd64 && multilib_toolchain_setup x86
+ games_src_compile
+}
+
+src_install() {
+ dogamesbin nestra || die "dogamesbin failed"
+ dodoc BUGS CHANGES README
+ doman nestra.6
+ prepgamesdirs
+}