summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteven J Newbury <steve@snewbury.org.uk>2009-04-08 02:11:28 +0100
committerSteven J Newbury <steve@snewbury.org.uk>2009-04-08 02:11:28 +0100
commit65bf909602b8dad16a38367d09ef5c7ff8331b91 (patch)
treefe3b80650df09aecc823324c310c33781eaf9404 /games-emulation/zsnes/zsnes-1.51-r2.ebuild
parentUpdate dev-libs/libpcre: Add deps on zlib and bzip2 as well as make (diff)
downloadmultilib-portage-65bf909602b8dad16a38367d09ef5c7ff8331b91.tar.gz
multilib-portage-65bf909602b8dad16a38367d09ef5c7ff8331b91.tar.bz2
multilib-portage-65bf909602b8dad16a38367d09ef5c7ff8331b91.zip
Added games-emulation/zsnes
Diffstat (limited to 'games-emulation/zsnes/zsnes-1.51-r2.ebuild')
-rw-r--r--games-emulation/zsnes/zsnes-1.51-r2.ebuild82
1 files changed, 82 insertions, 0 deletions
diff --git a/games-emulation/zsnes/zsnes-1.51-r2.ebuild b/games-emulation/zsnes/zsnes-1.51-r2.ebuild
new file mode 100644
index 000000000..9abc4ad2b
--- /dev/null
+++ b/games-emulation/zsnes/zsnes-1.51-r2.ebuild
@@ -0,0 +1,82 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/games-emulation/zsnes/zsnes-1.51-r2.ebuild,v 1.5 2009/03/31 13:23:07 darkside Exp $
+
+EAPI=2
+
+inherit eutils autotools flag-o-matic toolchain-funcs multilib games
+
+DESCRIPTION="SNES (Super Nintendo) emulator that uses x86 assembly"
+HOMEPAGE="http://www.zsnes.com/ http://ipherswipsite.com/zsnes/"
+SRC_URI="mirror://sourceforge/zsnes/${PN}${PV//./}src.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="-* amd64 ~x86 ~x86-fbsd"
+IUSE="ao custom-cflags opengl png"
+
+RDEPEND="media-libs/libsdl[lib32?]
+ >=sys-libs/zlib-1.2.3-r1[lib32?]
+ ao? ( media-libs/libao[lib32?] )
+ opengl? ( virtual/opengl[lib32?] )
+ png? ( media-libs/libpng[lib32?] )"
+DEPEND="${RDEPEND}
+ dev-lang/nasm
+ amd64? ( >=sys-apps/portage-2.1 )"
+
+S=${WORKDIR}/${PN}_${PV//./_}/src
+
+src_prepare() {
+ cd "${S}"
+
+ # Fixing compilation without libpng installed
+ epatch "${FILESDIR}"/${P}-libpng.patch
+ # Fix bug #186111
+ epatch "${FILESDIR}"/${P}-archopt-july-23-update.patch
+ epatch "${FILESDIR}"/${P}-gcc43.patch
+ # Fix bug #214697
+ epatch "${FILESDIR}"/${P}-libao-thread.patch
+ # Fix bug #170108
+ epatch "${FILESDIR}"/${P}-depbuild.patch
+ # Fix bug #260247
+ epatch "${FILESDIR}"/${P}-CC-quotes.patch
+
+ # Remove hardcoded CFLAGS and LDFLAGS
+ sed -i \
+ -e '/^CFLAGS=.*local/s:-pipe.*:-Wall -I.":' \
+ -e '/^LDFLAGS=.*local/d' \
+ -e '/\w*CFLAGS=.*fomit/s:-O3.*$STRIP::' \
+ configure.in \
+ || die "sed failed"
+ eautoreconf
+}
+
+src_configure() {
+ tc-export CC
+ use amd64 && multilib_toolchain_setup x86
+ use custom-cflags || strip-flags
+
+ append-flags -U_FORTIFY_SOURCE #257963
+
+ egamesconf \
+ $(use_enable ao libao) \
+ $(use_enable png libpng) \
+ $(use_enable opengl) \
+ --disable-debug \
+ --disable-cpucheck \
+ --enable-release \
+ force_arch=no \
+ || die
+ emake makefile.dep || die "emake makefile.dep failed"
+}
+
+src_install() {
+ dogamesbin zsnes || die "dogamesbin failed"
+ newman linux/zsnes.1 zsnes.6
+ dodoc ../docs/{readme.1st,*.txt,README.LINUX}
+ dodoc ../docs/readme.txt/*
+ dohtml -r ../docs/readme.htm/*
+ make_desktop_entry zsnes ZSNES
+ newicon icons/48x48x32.png ${PN}.png
+ prepgamesdirs
+}