summaryrefslogtreecommitdiff
blob: 0638df397134d4186a4c5810c98992f0f8537b2f (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
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
inherit libtool

DESCRIPTION="Cell SPE examples"
HOMEPAGE=""
SRC_URI="http://dev.gentoo.org/~lu_zero/distfiles/spe-samples-1.0.tar.bz2"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~ppc ~ppc64"
IUSE=""

DEPEND=">=sys-libs/libspe2-2.0"
RDEPEND=""

# fixme: provide an spu eclass to do basic checks and autostuff fixes

src_unpack() {
	unpack ${A}
	# make sure it uses the right compiler.
	sed -i -e "s:spu-gcc:spu-elf-gcc:g" ${S}/*/spe/configure*
	# fixme: kill c++/fortran checks!
	cd ${S}
	elibtoolize
}

src_compile() {
	# just to be sure
	unset CFLAGS
	unset CXXFLAGS
	unset CFLAGS_ppc64
	unset CFLAGS_ppc
	unset LDFLAGS_ppc64
	unset LDFLAGS_ppc
	./configure --prefix=/usr || die "configure failed"
	emake || die "build failed"
}