summaryrefslogtreecommitdiff
blob: e9e3823330842a8cd7acff5e3b7f6b183417ad2f (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
# Copyright 1999-2004 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/games-puzzle/cuyo/cuyo-1.8.1.ebuild,v 1.3 2004/02/03 00:41:11 mr_bones_ Exp $

inherit games

S=${WORKDIR}/${P/_}
DESCRIPTION="highly addictive and remotely related to tetris"
HOMEPAGE="http://www.karimmi.de/cuyo/"
SRC_URI="http://savannah.nongnu.org/download/cuyo/${P//_}.tar.gz"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="x86 ppc"

DEPEND="virtual/glibc
	virtual/x11
	=x11-libs/qt-2*"

src_unpack() {
	unpack ${A}
	cd ${S}
	sed -i 's:-O2:@CXXFLAGS@:' src/Makefile.in
}

src_compile() {
#	local qtver=
#	has_version =x11-libs/qt-3* \
#		&& qtver=3 \
#		|| qtver=2
	qtver=2
	egamesconf \
		--with-qt \
		--with-qt-dir=/usr/qt/${qtver} \
		--with-x \
		|| die
	emake || die
}

src_install() {
	sed -i \
		's: $(pkgdatadir: $(DESTDIR)$(pkgdatadir:' \
		data/Makefile
	make install DESTDIR=${D} || die
	dogamesbin ${D}/${GAMES_PREFIX}/games/cuyo
	rm -rf ${D}/${GAMES_PREFIX}/games
	dodoc AUTHORS INSTALL NEWS README TODO ChangeLog

	prepgamesdirs
}