aboutsummaryrefslogtreecommitdiff
blob: ecb4faf768fda4ffc5acb0629a6de458e3b69f24 (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
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI=5

inherit autotools-utils fortran-2 multibuild

DESCRIPTION="Parallel 3d FFT"
HOMEPAGE="http://www-user.tu-chemnitz.de/~mpip/software.php"

if [[ $PV = *9999 ]] ; then
	inherit git-r3
	EGIT_REPO_URI="https://github.com/mpip/pfft.git"
	KEYWORDS=""
	AUTOTOOLS_AUTORECONF=1
else
	SRC_URI="http://www-user.tu-chemnitz.de/~mpip/software/${P//_/-}.tar.gz"
	KEYWORDS="~x86 ~amd64"
	S="${WORKDIR}/${P//_/-}"
fi

LICENSE="GPL-3"
SLOT="0"
IUSE="static-libs"

RDEPEND="
	sci-libs/fftw:3.0[mpi,fortran]
	virtual/mpi
	"

DEPEND="
	${RDEPEND}
	"

src_configure() {
	MULTIBUILD_VARIANTS=( single double long-double )
	my_src_configure() {
		local myeconfargs=(
			$([[ ${MULTIBUILD_VARIANT} != double ]] && echo "--enable-${MULTIBUILD_VARIANT}")
		)
		autotools-utils_src_configure
	}

	multibuild_parallel_foreach_variant my_src_configure
}

src_compile() {
	multibuild_foreach_variant autotools-utils_src_compile
}

src_install() {
	multibuild_parallel_foreach_variant autotools-utils_src_install
}