Files
nixpkgs/pkgs/by-name/cl/clfft/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

60 lines
1.2 KiB
Nix

{
lib,
gccStdenv,
fetchFromGitHub,
cmake,
fftw,
fftwFloat,
boost,
opencl-clhpp,
ocl-icd,
}:
let
stdenv = gccStdenv;
in
stdenv.mkDerivation rec {
pname = "clfft";
version = "2.12.2";
src = fetchFromGitHub {
owner = "clMathLibraries";
repo = "clFFT";
rev = "v${version}";
hash = "sha256-yp7u6qhpPYQpBw3d+VLg0GgMyZONVII8BsBCEoRZm4w=";
};
sourceRoot = "${src.name}/src";
postPatch = ''
sed -i '/-m64/d;/-m32/d' CMakeLists.txt
'';
nativeBuildInputs = [ cmake ];
buildInputs = [
fftw
fftwFloat
boost
]
++ lib.optionals stdenv.hostPlatform.isLinux [
opencl-clhpp
ocl-icd
];
# https://github.com/clMathLibraries/clFFT/issues/237
CXXFLAGS = "-std=c++98";
meta = with lib; {
description = "Library containing FFT functions written in OpenCL";
longDescription = ''
clFFT is a software library containing FFT functions written in OpenCL.
In addition to GPU devices, the library also supports running on CPU devices to facilitate debugging and heterogeneous programming.
'';
license = licenses.asl20;
homepage = "http://clmathlibraries.github.io/clFFT/";
platforms = platforms.unix;
maintainers = with maintainers; [ chessai ];
};
}