summaryrefslogtreecommitdiff
blob: 564ab1a85ef2c7871b155c12453fcfc5f531197a (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
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

EAPI="1"

inherit eutils games

DESCRIPTION="Set of scripts to easily configure wine for numerous Windows(tm) games."
HOMEPAGE="http://playonlinux.com/"
SRC_URI="http://www.playonlinux.com/script_files/PlayOnLinux/${PV}/PlayOnLinux_${PV}.tar.gz"

LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~x86"
IUSE=""

DEPEND=""
RDEPEND="x11-libs/gtk+
		x11-libs/wxGTK:2.8
		dev-python/wxpython:2.8
		app-arch/unzip
		app-arch/cabextract
		x11-terms/xterm
		app-emulation/wine
		media-gfx/imagemagick
		app-arch/lzma-utils"
# lzma-utils is a run dep regarding playonlinux team

S="${WORKDIR}/${PN}"

src_install() {
	# all things without exec permissions
	insinto "${GAMES_DATADIR}/${PN}"
	doins -r "${S}/themes" \
	"${S}/lang"	"${S}/lib" \
	"${S}/etc" || die "installation failed"

	# bin/ install
	exeinto "${GAMES_DATADIR}/${PN}/bin"
	doexe "${S}"/bin/* || die "installation failed"

	# bash/ install
	exeinto "${GAMES_DATADIR}/${PN}/bash"
	doexe "${S}"/bash/* || die "installation failed"
	exeinto "${GAMES_DATADIR}/${PN}/bash/terminals"
	doexe "${S}"/bash/terminals/* || die "installation failed"
	exeinto "${GAMES_DATADIR}/${PN}/bash/expert"
	doexe "${S}"/bash/expert/* || die "installation failed"
	exeinto "${GAMES_DATADIR}/${PN}/bash/options"
	doexe "${S}"/bash/options/* || die "installation failed"

	# python/ install
	exeinto "${GAMES_DATADIR}/${PN}/python"
	doexe "${S}"/python/* || die "installation failed"
	exeinto "${GAMES_DATADIR}/${PN}/python/tools"
	doexe "${S}"/python/tools/* || die "installation failed"
	# sub dir without exec permissions
	insinto "${GAMES_DATADIR}/${PN}/python"
	doins -r "${S}"/python/lib || die "installation failed"

	# main executable files
	exeinto "${GAMES_DATADIR}/${PN}"
	doexe "${S}/${PN}" || die "installation failed"
	exeinto "${GAMES_DATADIR}/${PN}"
	doexe "${S}/${PN}-pkg" || die "installation failed"

	# making a script to run app from ${GAMES_BINDIR}
	echo "#!/bin/bash" > ${PN}_launcher
	echo "cd \"${GAMES_DATADIR}/${PN}\" && ./${PN}" >> ${PN}_launcher
	newgamesbin playonlinux_launcher playonlinux || die "installation failed"

	dodoc CHANGELOG || die "doc installation failed"

	doicon "${S}/etc/${PN}.png"
	make_desktop_entry ${PN} "PlayOnLinux"
	prepgamesdirs
}