diff --git a/CMakeLists.txt b/CMakeLists.txt index 86df46c34..5ba4bf2c6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -51,8 +51,9 @@ configure_file( ######################################################################## # Options ######################################################################## -option(DisableMEX "DisableMEX" ON) -option(StaticMKL "StaticMKL" OFF) +option(DisableMEX "DisableMEX" ON) +option(StaticMKL "StaticMKL" OFF) +option(DisableBladeRF "DisableBladeRF" OFF) ######################################################################## # Install Dirs @@ -102,14 +103,14 @@ if(CMAKE_COMPILER_IS_GNUCC) if(${CMAKE_BUILD_TYPE} STREQUAL "Debug") find_package(SSE) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0") if(HAVE_AVX) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=native -mfpmath=sse -mavx -DLV_HAVE_AVX -DLV_HAVE_SSE") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -march=native -mfpmath=sse -mavx -DLV_HAVE_AVX -DLV_HAVE_SSE") elseif(HAVE_SSE) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=native -mfpmath=sse -msse4.1 -DLV_HAVE_SSE") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -march=native -mfpmath=sse -msse4.1 -DLV_HAVE_SSE") endif(HAVE_AVX) else(${CMAKE_BUILD_TYPE} STREQUAL "Debug") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O3") find_package(SSE) if(HAVE_AVX) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -march=native -mfpmath=sse -mavx -DLV_HAVE_AVX -DLV_HAVE_SSE") diff --git a/srslte/CMakeLists.txt b/srslte/CMakeLists.txt index 0ecf9ddf6..d4f336d57 100644 --- a/srslte/CMakeLists.txt +++ b/srslte/CMakeLists.txt @@ -61,11 +61,13 @@ if(UHD_FOUND) link_directories(${UHD_LIBRARY_DIRS}) endif(UHD_FOUND) -find_package(bladeRF) -if(BLADERF_FOUND) - include_directories(${BLADERF_INCLUDE_DIRS}) - link_directories(${BLADERF_LIBRARY_DIRS}) -endif(BLADERF_FOUND) +if(NOT DisableBladeRF) + find_package(bladeRF) + if(BLADERF_FOUND) + include_directories(${BLADERF_INCLUDE_DIRS}) + link_directories(${BLADERF_LIBRARY_DIRS}) + endif(BLADERF_FOUND) +endif(NOT DisableBladeRF) if(BLADERF_FOUND OR UHD_FOUND) set(RF_FOUND TRUE CACHE INTERNAL "RF frontend found")