From 8b3a77cdb40e2160111a21752d7a3751ab6cde39 Mon Sep 17 00:00:00 2001 From: Carles Fernandez Date: Sun, 29 Nov 2020 10:18:35 +0100 Subject: [PATCH] Fix building if ENABLE_AD9361=ON bu ENABLE_FPGA=OFF --- .../signal_source/adapters/CMakeLists.txt | 2 +- src/core/libs/CMakeLists.txt | 13 +++++++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/src/algorithms/signal_source/adapters/CMakeLists.txt b/src/algorithms/signal_source/adapters/CMakeLists.txt index f093f36bc..5c87fb920 100644 --- a/src/algorithms/signal_source/adapters/CMakeLists.txt +++ b/src/algorithms/signal_source/adapters/CMakeLists.txt @@ -146,7 +146,7 @@ target_include_directories(signal_source_adapters ${CMAKE_SOURCE_DIR}/src/core/interfaces ) -if(ENABLE_FPGA) +if(ENABLE_FPGA OR ENABLE_AD9361) target_link_libraries(signal_source_adapters PRIVATE core_libs diff --git a/src/core/libs/CMakeLists.txt b/src/core/libs/CMakeLists.txt index 6904295a3..c14fbe529 100644 --- a/src/core/libs/CMakeLists.txt +++ b/src/core/libs/CMakeLists.txt @@ -36,12 +36,21 @@ if(ENABLE_FPGA) ${CORE_LIBS_SOURCES} gnss_sdr_fpga_sample_counter.cc gnss_sdr_time_counter.cc - uio_fpga.cc ) set(CORE_LIBS_HEADERS ${CORE_LIBS_HEADERS} gnss_sdr_fpga_sample_counter.h gnss_sdr_time_counter.h + ) +endif() + +if(ENABLE_FPGA OR ENABLE_AD9361) + set(CORE_LIBS_SOURCES + ${CORE_LIBS_SOURCES} + uio_fpga.cc + ) + set(CORE_LIBS_HEADERS + ${CORE_LIBS_HEADERS} uio_fpga.h ) endif() @@ -116,7 +125,7 @@ if(USE_BOOST_BIND_PLACEHOLDERS) ) endif() -if(ENABLE_FPGA) +if(ENABLE_FPGA OR ENABLE_AD9361) if(FILESYSTEM_FOUND) target_compile_definitions(core_libs PRIVATE -DHAS_STD_FILESYSTEM=1) if(find_experimental)