summaryrefslogtreecommitdiff
blob: 54d79cf9b6209d19f4513bb26c0f49aa469648df (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
48
49
50
51
52
53
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

inherit desktop flag-o-matic toolchain-funcs

DESCRIPTION="Guide the blob along the conveyer belt collecting the red blobs"
HOMEPAGE="https://wiki.gentoo.org/wiki/No_homepage"
SRC_URI="
	mirror://gentoo/${P/-/.}.tar
	https://dev.gentoo.org/~ionen/distfiles/${PN}.png"
S="${WORKDIR}"

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

RDEPEND="
	media-libs/libsdl[sound,video]
	media-libs/sdl-mixer"
DEPEND="${RDEPEND}"
BDEPEND="virtual/pkgconfig"

PATCHES=(
	"${FILESDIR}"/${P}-arrays.patch
	"${FILESDIR}"/${P}-audio.patch
	"${FILESDIR}"/${P}-speed.patch
	"${FILESDIR}"/${P}-clang16.patch
)

src_compile() {
	tc-export CC

	append-cppflags $($(tc-getPKG_CONFIG) --cflags sdl SDL_mixer || die) \
		-DDATA_PREFIX="'\"${EPREFIX}/usr/share/${PN}/\"'" \
		-DENABLE_SOUND
	append-libs $($(tc-getPKG_CONFIG) --libs sdl SDL_mixer || die)

	emake main LDLIBS="${LIBS}"
}

src_install() {
	newbin main ${PN}

	insinto /usr/share/${PN}
	doins -r gfx levels sounds

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

	dodoc readme
}