summaryrefslogtreecommitdiff
blob: 781143c48544228a6e3b6cccef6033030f09b0c0 (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
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-cluster/mpi-dotnet/mpi-dotnet-1.0.0.ebuild,v 1.2 2009/05/11 22:15:32 mabi Exp $

WANT_AUTOTOOLS="2.5"
inherit autotools mono

# "." is not allowed as part of a package name
MY_PN="mpi.net"
MY_P="${MY_PN}-${PV}"
S="${WORKDIR}/${MY_P}"

DESCRIPTION="C# bindings for various MPI-implementations"
HOMEPAGE="http://www.osl.iu.edu/research/mpi.net"
SRC_URI="http://www.osl.iu.edu/research/mpi.net/files/${PV}/${MY_P}.tar.gz"

LICENSE="Boost-1.0"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86"
IUSE="doc examples"

RDEPEND="virtual/mpi
		>=dev-lang/mono-2.0"
DEPEND="${RDEPEND}
		dev-lang/perl"

MPICC="${CC}"

# tests hang at one point
RESTRICT="test"

src_unpack() {
	unpack ${A}
	cd "${S}"

	epatch "${FILESDIR}/configure.ac.patch"
	epatch "${FILESDIR}/Makefile.am.patch"
	epatch "${FILESDIR}/Unsafe.pl.patch"

	# MPI/Makefile seems broken, fix it
	eautoreconf
}

src_compile() {
	# policy requires us to build shared and static libs alongside
	econf --enable-shared --enable-static
	emake
}

src_install() {
	emake DESTDIR="${D}" install || die "Install failed"

	if use examples ; then
		insinto "${ROOT}/usr/share/doc/${PF}"
		doins -r Examples
	fi
	use doc && dodoc Documentation/MPI.NET\ Tutorial{,\ Python}.doc
}

src_test() {
	make check -k
}