Finding FFT libraries by CMake

Some tips to find FFT libraries for each backend.

FFTW

If FFTW is offered as a module, our CMake helper would likely find FFTW. Assuming FFTW is installed in <path/to/FFTW>, it is expected that <path/to/FFTW> would be found under LIBRARY_PATH, LD_LIBRARY_PATH, and PATH. It would look like

LIBRARY_PATH=...:<path/to/FFTW>/lib
LD_LIBRARY_PATH=...:<path/to/FFTW>/lib
PATH=...:<path/to/FFTW>/bin

If CMake fails to find FFTW, please try to set FFTWDIR in the following way.

export FFTWDIR=<path/to/FFTW>

cufft

hipfft

rocfft

oneMKL

The most likely scenario to miss oneMKL is that forgetting to initialize oneAPI. Please make sure to initialize oneAPI as

<path/to/oneapi>/setvars.sh --include-intel-llvm