From 16517397f52491c95318d5cb5b42c9603ee1c2fd Mon Sep 17 00:00:00 2001 From: Andre Puschmann Date: Thu, 28 Nov 2019 11:59:24 +0100 Subject: [PATCH] add CMake option to force usage of MKL while default is fftw --- CMakeLists.txt | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a161cf092..0a9608c48 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -84,6 +84,7 @@ option(ENABLE_TIDY "Enable clang tidy" OFF) option(USE_LTE_RATES "Use standard LTE sampling rates" OFF) option(USE_GLIBC_IPV6 "Use glibc's own ipv6.h" ON) +option(USE_MKL "Use MKL instead of fftw" OFF) set(GCC_ARCH native CACHE STRING "GCC compile for specific architecture.") @@ -96,12 +97,12 @@ set(GCC_ARCH native CACHE STRING "GCC compile for specific architecture.") find_package(Threads REQUIRED) # FFT -find_package(MKL) -if(MKL_FOUND) +if(USE_MKL) + find_package(MKL REQUIRED) include_directories(${MKL_INCLUDE_DIRS}) link_directories(${MKL_LIBRARY_DIRS}) set(FFT_LIBRARIES "${MKL_STATIC_LIBRARIES}") # Static by default -else(MKL_FOUND) +else(USE_MKL) find_package(FFTW3F REQUIRED) if(FFTW3F_FOUND) include_directories(${FFTW3F_INCLUDE_DIRS}) @@ -113,7 +114,7 @@ else(MKL_FOUND) endif(BUILD_STATIC) message(STATUS "FFT_LIBRARIES: " ${FFT_LIBRARIES}) endif(FFTW3F_FOUND) -endif(MKL_FOUND) +endif(USE_MKL) # Crypto find_package(Polarssl)