www-client/google-chrome: automated update
[gentoo.git] / games-simulation / senken / senken-0.3.0.ebuild
1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Id$
4
5 EAPI=5
6 inherit eutils games
7
8 DESCRIPTION="city simulation game"
9 HOMEPAGE="http://savannah.nongnu.org/projects/senken/"
10 SRC_URI="mirror://gentoo/${P}.tar.gz"
11
12 LICENSE="GPL-2"
13 SLOT="0"
14 KEYWORDS="amd64 ~ppc x86"
15 IUSE="nls"
16
17 RDEPEND="x11-libs/gtk+:2
18         >=media-libs/libsdl-1.2.4
19         media-libs/sdl-image
20         nls? ( virtual/libintl )"
21 DEPEND="${RDEPEND}
22         nls? ( sys-devel/gettext )"
23
24 src_prepare() {
25         sed -i \
26                 -e "s:/usr/local/share:${GAMES_DATADIR}:" \
27                 lib/utils.h || die
28         epatch \
29                 "${FILESDIR}"/${P}-as-needed.patch \
30                 "${FILESDIR}"/${P}-warnings.patch
31 }
32 src_configure() {
33         egamesconf $(use_enable nls)
34 }
35
36 src_install() {
37         default
38
39         dodir "${GAMES_DATADIR}"
40         mv "${D}/${GAMES_PREFIX}/share/senken" "${D}/${GAMES_DATADIR}/" || die
41         rm -rf "${D}/${GAMES_PREFIX}"/{include,lib,man,share} || die
42
43         insinto "${GAMES_DATADIR}/senken/img"
44         doins img/*.png
45
46         find "${D}/${GAMES_DATADIR}/" -type f -exec chmod a-x \{\} +
47         find "${D}/${GAMES_DATADIR}/" -name "Makefile.*" -exec rm -f \{\} +
48
49         prepgamesdirs
50 }