summaryrefslogtreecommitdiff
blob: cd7d50cc9b406be1c0062552e811b9f7b2377f0f (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-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

inherit desktop toolchain-funcs

DESCRIPTION="Breakout clone written with the SDL library"
HOMEPAGE="http://lgames.sourceforge.net/LBreakout/"
SRC_URI="
	mirror://sourceforge/lgames/${P}.tar.gz
	https://dev.gentoo.org/~ionen/distfiles/${PN}.png"

LICENSE="GPL-2+"
SLOT="0"
KEYWORDS="~amd64 ~x86"

RDEPEND="
	acct-group/gamestat
	media-libs/libsdl[sound,video]"
DEPEND="${RDEPEND}"

HTML_DOCS=( lbreakout/manual/. )

src_prepare() {
	default

	# remove /games from datadir, and use /var/games for highscore file
	sed -e '/^sdir=/s|/games.*||;' \
		-e "/^hdir=/s|=.*|=${EPREFIX}/var/games|" \
		-i configure || die

	tc-export CC CXX
}

src_install() {
	dodir /var/games #655000

	default

	fowners :gamestat /usr/bin/${PN} /var/games/${PN}.hscr
	fperms g+s /usr/bin/${PN}
	fperms 660 /var/games/${PN}.hscr

	doicon "${DISTDIR}"/${PN}.png
	make_desktop_entry ${PN} LBreakout
}