forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
grimrock-20150707.ebuild
66 lines (50 loc) · 1.34 KB
/
grimrock-20150707.ebuild
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-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit desktop unpacker xdg
MY_PN="Grimrock"
MY_TIMESTAMP="${PV:0:4}-${PV:4:2}-${PV:6:2}"
DESCRIPTION="Legend of Grimrock: The ultimate dungeon crawling RPG + modding engine"
HOMEPAGE="http://www.grimrock.net/"
SRC_URI="Grimrock-Linux-${MY_TIMESTAMP}.sh"
S="${WORKDIR}"
LICENSE="all-rights-reserved"
SLOT="0"
KEYWORDS="-* ~amd64 ~x86"
RESTRICT="bindist fetch"
QA_PREBUILT="opt/${PN}/${MY_PN}.bin"
RDEPEND="
media-libs/freeimage
media-libs/freetype:2
media-libs/libsdl2[opengl,sound,video]
media-libs/libvorbis
media-libs/openal
sys-libs/zlib[minizip]
virtual/opengl
x11-libs/libX11"
pkg_nofetch() {
einfo "Please buy and download ${SRC_URI} from:"
einfo " ${HOMEPAGE}"
einfo "and move it to your distfiles directory."
}
src_unpack() {
MY_ARCH=$(usex amd64 x86_64 x86)
unpack_makeself
local i
for i in subarch instarchive_all instarchive_linux_${MY_ARCH}; do
ln -snf ${i} ${i}.tar.xz || die
unpack ./${i}.tar.xz
done
}
src_install() {
local dir=/opt/${PN}
insinto ${dir}
doins ${PN}.{dat,png}
exeinto ${dir}
newexe ${MY_PN}.bin{.${MY_ARCH},}
dosym ../..${dir}/${MY_PN}.bin /usr/bin/${PN}
doicon -s 256 ${PN}.png
newicon -s 64 ${MY_PN}.png ${PN}.png
make_desktop_entry ${PN} "Legend of ${MY_PN}"
dodoc README.linux
}