summaryrefslogtreecommitdiff
blob: 7160d64754daa1e3058c050c7dff96e30e2616a6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/games-emulation/stella/stella-1.2.ebuild,v 1.1 2003/09/09 16:26:50 vapier Exp $

DESCRIPTION="Stella Atari 2600 VCS Emulator"
HOMEPAGE="http://stella.sourceforge.net/"
SRC_URI="mirror://sourceforge/stella/${P}-src.tar.gz"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="x86"
IUSE="sdl oss X"

DEPEND="|| (
		X? ( virtual/x11 )
		sdl? ( media-libs/libsdl )
		virtual/x11
	)"

src_compile() {
	if [ `use X` ] || [ -z "`use X``use sdl`" ] ; then
		cd ${S}/src/build
		emake OPTIMIZATIONS="${CFLAGS}" linux-x || die
	fi
	if [ `use sdl` ] ; then
		cd ${S}/src/build
		emake OPTIMIZATIONS="${CFLAGS}" linux-sdl || die
	fi

	if [ `use oss` ] ; then
		cd ${S}/src/ui/sound
		emake CC="${CC} ${CFLAGS}" linux || die
	fi
}

src_install() {
	use X && dobin src/build/stella.x11
	use sdl && dobin src/build/stella.sdl
	[ -z "`use X``use sdl`" ] && dobin src/build/stella.x11
	use oss && dobin src/ui/sound/stella-sound

	insinto /etc
	doins src/stellarc

	dohtml -r docs/
	dodoc *.txt
}