blob: 10d6278aec8bfb49c6959e356f6997ebd2277db1 (
plain) (
blame)
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
|
{ autoreconfHook
, fetchurl
, fftwMpi
, gsl
, lib
, llvmPackages
, pfft
, precision ? "double"
, stdenv
}:
assert lib.elem precision [ "single" "double" "long-double" ];
let
fftw' = fftwMpi.override { inherit precision; };
pfft' = pfft.override { inherit precision; };
in
stdenv.mkDerivation (finalAttrs: {
pname = "pnfft-${precision}";
version = "1.0.7-alpha";
src = fetchurl {
url = "https://www-user.tu-chemnitz.de/~potts/workgroup/pippig/software/pnfft-${finalAttrs.version}.tar.gz";
hash = "sha256-/aVY/1fuMRl1Q2O7bmc5M4aA0taGD+fcQgCdhVYr1no=";
};
outputs = [ "out" "dev" ];
nativeBuildInputs = [ autoreconfHook ];
preConfigure = ''
export FCFLAGS="-I${lib.getDev fftw'}/include -I${lib.getDev pfft'}/include"
'';
configureFlags = [
"--enable-threads"
"--enable-portable-binary"
] ++ lib.optional (precision != "double") "--enable-${precision}";
buildInputs = [ gsl ] ++ lib.optional stdenv.cc.isClang llvmPackages.openmp;
propagatedBuildInputs = [ pfft' ];
doCheck = true;
meta = {
description = "Parallel nonequispaced fast Fourier transforms";
homepage = "https://www-user.tu-chemnitz.de/~potts/workgroup/pippig/software.php.en#pnfft";
changelog = "https://github.com/mpip/pnfft/blob/master/ChangeLog";
license = lib.licenses.gpl3Plus;
maintainers = with lib.maintainers; [ hmenke ];
platforms = lib.platforms.linux;
};
})
|