blob: 07d7393fbfd2c02db2dc247a505778f95ee99d96 (
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
|
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
inherit versionator games
MY_PV=$(delete_all_version_separators)
DESCRIPTION="Unreal-themed single-player campaign"
HOMEPAGE="http://www.planetunreal.com/teamvortex/help/"
SRC_URI="ftp://ftp.planetmirror.com/pub/moddb/2005/07/1263-ONP${MY_PV}_Umod.zip"
LICENSE="as-is"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
RDEPEND="|| (
>=games-fps/unreal-tournament-436
>=games-fps/unreal-tournament-goty-436 )"
DEPEND="games-util/umodpack
app-arch/unzip"
S=${WORKDIR}
dir=${GAMES_PREFIX_OPT}/unreal-tournament
docdir=op-napali
src_unpack() {
local f lcn n
unpack ${A}
for f in *.umod ; do
umod -x "${f}" || die "umod ${f} failed"
done
rm *.umod
cd "${S}"
unpack ./*.zip
rm *.{txt,zip}
mv -f *.unr Maps
mv -f *.u System
# Fix filenames in HTML
sed -i data/docs/*.html \
-e "s:\.JPG:\.jpg:" \
-e "s:\.PNG:\.png:" \
-e "s:TVshortie:tvshortie:" \
|| die "sed docs failed"
sed -i *.html \
-e "s:data/docs:${docdir}/docs:" \
|| die "sed help doc failed"
for n in Skaarj Nali Mercenary Krall Brute ; do
lcn=$(echo "${n}" | tr [:upper:] [:lower:])
sed -i data/docs/*.html \
-e "s:${n}\.jpg:${lcn}\.jpg:" \
|| die "sed ${n} failed"
done
# Remove Gamespy ads
sed -i data/docs/faq.html \
-e '9,12d' \
|| die "sed faq failed"
mv "Operation NaPali Help Doc.html" "${docdir}.html"
mv data "${docdir}"
}
src_install() {
insinto "${dir}"
doins -r * || die "doins -r failed"
prepgamesdirs
}
pkg_postinst() {
games_pkg_postinst
einfo "For instructions and story, read:"
einfo "${dir}/${docdir}.html"
echo
}
|