summaryrefslogtreecommitdiff
blob: 4be12a94c0b99e574c9196888d7b1f88205f080c (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
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/games-simulation/simutrans/simutrans-0.82.10.ebuild,v 1.6 2004/07/14 14:59:12 agriffis Exp $

inherit games

MY_PV=${PV//./_}
DESCRIPTION="A free Transport Tycoon clone"
HOMEPAGE="http://www.simutrans.de/"
# 0_82_10 was a bugfix release and it uses the 0_82_9 base file.
SRC_URI="http://www.simugraph.com/simutrans/data/simubase-0_82_9exp.zip
	http://www.simugraph.com/simutrans/data/simulinux-${MY_PV}exp.tar.gz"

LICENSE="as-is"
SLOT="0"
KEYWORDS="-* x86"
IUSE=""

DEPEND="app-arch/unzip
	>=sys-apps/sed-4"
RDEPEND="media-libs/libsdl"

S=${WORKDIR}/${PN}

src_install() {
	local dir="${GAMES_PREFIX_OPT}/${PN}"

	dogamesbin "${FILESDIR}/simutrans" || die "dogamesbin failed"
	dodir "${dir}"                     || die "dodir failed"
	cp -R * "${D}/${dir}/"             || die "cp failed"
	sed -i \
		-e "s:GENTOO_DIR:${dir}:" "${D}${GAMES_BINDIR}/simutrans" || \
			die "sed simutrans failed"

	prepgamesdirs
	keepdir "${GAMES_PREFIX_OPT}/${PN}/save"
	fperms 2775 "${GAMES_PREFIX_OPT}/${PN}/save"
}