blob: c9bd3b8ce59499dc15326b34f1219a02fab42a52 (
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
54
55
56
57
58
59
60
61
62
63
64
65
66
|
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit desktop toolchain-funcs
DESCRIPTION="Retro side-scrolling shoot'em up based on the editor war story"
HOMEPAGE="https://wordwarvi.sourceforge.net"
SRC_URI="https://downloads.sourceforge.net/wordwarvi/${P}.tar.gz"
LICENSE="GPL-2+ CC-BY-2.0 CC-BY-SA-3.0"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="portaudio"
RDEPEND="
x11-libs/gtk+:2
portaudio? (
media-libs/libvorbis
>=media-libs/portaudio-19_pre1
)
"
DEPEND="${RDEPEND}"
BDEPEND="virtual/pkgconfig"
PATCHES=(
"${FILESDIR}"/${P}-sound.patch
)
src_prepare() {
default
sed -i \
-e "/^WITHAUDIO/s/yes/$(use portaudio && echo yes || echo no)/" \
Makefile || die
sed -i \
-e "s:GENTOO_DATADIR:/usr/share/${PN}:" \
wwviaudio.c || die
}
src_compile() {
tc-export BUILD_CC CC PKG_CONFIG
emake \
PREFIX="/usr" \
DATADIR="/usr/share/${PN}" \
MANDIR="/usr/share/man"
}
src_install() {
emake \
DESTDIR="${D}" \
PREFIX="/usr" \
DATADIR="/usr/share/${PN}" \
MANDIR="/usr/share/man" \
install
if ! use portaudio ; then
rm -rf "${ED}/usr/share" || die
fi
dodoc README AUTHORS changelog.txt AAA_HOW_TO_MAKE_NEW_LEVELS.txt
newicon icons/wordwarvi_icon_128x128.png ${PN}.png
make_desktop_entry ${PN} "Word War vi"
}
|