summaryrefslogtreecommitdiff
blob: f7fe40bfa93383cb5f15eaa3ffd96ca8f659e0cf (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
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/games-rpg/nwmouse/nwmouse-0.1.ebuild,v 1.3 2006/09/15 20:05:11 wolf31o2 Exp $

inherit games

DESCRIPTION="Hardware mouse cursors for Neverwinter Nights"
HOMEPAGE="http://home.woh.rr.com/nwmovies/nwmouse/"
SRC_URI="http://home.woh.rr.com/nwmovies/cursors.tar.gz
	http://dev.gentoo.org/~wolf31o2/sources/dump/${P}.tar.bz2"

LICENSE="as-is"
SLOT="0"
KEYWORDS="~amd64 ~x86"
# I've looked at this stuff, and I can't find the problem myself, so I'm just
# removing the warnings.  If someone feels like finding the patch, that would be
# great and I'll gladly include it.
QA_EXECSTACK="${GAMES_PREFIX_OPT:1}/nwn/nwmouse.so"
QA_TEXTRELS="${GAMES_PREFIX_OPT:1}/nwn/nwmouse.so"
IUSE=""
RESTRICT="strip mirror"

RDEPEND="sys-libs/glibc
	games-rpg/nwn-data
	amd64? (
		app-emulation/emul-linux-x86-xlibs
		app-emulation/emul-linux-x86-sdl )
	games-rpg/nwn
	x86? (
		|| (
			(
				x11-libs/libXcursor
				x11-libs/libXext
				x11-libs/libX11 )
			virtual/x11 )
		media-libs/libsdl )"

S="${WORKDIR}/${PN}"
dir="${GAMES_PREFIX_OPT}/nwn"

pkg_setup() {
	games_pkg_setup
	einfo "This package is pre-compiled so it will work on both x86 and amd64."
}

src_unpack() {
	unpack ${P}.tar.bz2 || die
	mkdir ${S}/cursors || die
	cd ${S}/cursors || die
	unpack cursors.tar.gz || die
}

src_install() {
	exeinto "${dir}"
	doexe nwmouse.so || die
	exeinto "${dir}/lib"
	doexe libelf/libelf.so.1
	exeinto "${dir}/nwmouse/libdis"
	doexe libdis/libdisasm.so || die
	insinto "${dir}/nwmouse/cursors"
	doins cursors/* || die
	prepgamesdirs
}

pkg_postinst() {
	games_pkg_postinst
	einfo "When starting nwn the next time, nwmouse will scan the nwmain"
	einfo "binary for its hooks, store this information in:"
	einfo "  ${dir}/nwmouse.ini"
	einfo "and exit. This is normal."
	einfo
	einfo "You will have to remove this file whenever you update nwn."
}