mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2024-12-14 04:00:34 +00:00
Fixes for modern OpenCL versions
This commit is contained in:
parent
a2dcf223f0
commit
9318fe540d
@ -68,6 +68,7 @@ endif()
|
||||
|
||||
target_link_libraries(acquisition_gr_blocks
|
||||
PUBLIC
|
||||
algorithms_libs
|
||||
Gnuradio::runtime
|
||||
Gnuradio::fft
|
||||
Volk::volk
|
||||
@ -79,7 +80,7 @@ target_link_libraries(acquisition_gr_blocks
|
||||
Glog::glog
|
||||
Matio::matio
|
||||
Volkgnsssdr::volkgnsssdr
|
||||
algorithms_libs
|
||||
|
||||
)
|
||||
|
||||
target_include_directories(acquisition_gr_blocks
|
||||
@ -91,6 +92,10 @@ target_include_directories(acquisition_gr_blocks
|
||||
|
||||
if(OPENCL_FOUND)
|
||||
target_link_libraries(acquisition_gr_blocks PUBLIC OpenCL::OpenCL)
|
||||
target_include_directories(acquisition_gr_blocks
|
||||
PUBLIC
|
||||
${CMAKE_SOURCE_DIR}/src/algorithms/libs/opencl
|
||||
)
|
||||
endif()
|
||||
|
||||
if(ENABLE_CLANG_TIDY)
|
||||
@ -105,4 +110,5 @@ endif()
|
||||
set_property(TARGET acquisition_gr_blocks
|
||||
APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
|
||||
$<BUILD_INTERFACE:${CMAKE_SOURCE_DIR}/src/algorithms/libs/opencl>
|
||||
)
|
||||
|
@ -51,8 +51,10 @@
|
||||
#ifndef GNSS_SDR_PCPS_OPENCL_ACQUISITION_CC_H_
|
||||
#define GNSS_SDR_PCPS_OPENCL_ACQUISITION_CC_H_
|
||||
|
||||
#define CL_SILENCE_DEPRECATION
|
||||
#include "channel_fsm.h"
|
||||
#include "gnss_synchro.h"
|
||||
#include "opencl/cl.hpp"
|
||||
#include "opencl/fft_internal.h"
|
||||
#include <gnuradio/block.h>
|
||||
#include <gnuradio/fft/fft.h>
|
||||
@ -62,13 +64,6 @@
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#ifdef __APPLE__
|
||||
#define CL_SILENCE_DEPRECATION
|
||||
#include "opencl/cl.hpp"
|
||||
#else
|
||||
#include <CL/cl.hpp>
|
||||
#endif
|
||||
|
||||
class pcps_opencl_acquisition_cc;
|
||||
|
||||
typedef boost::shared_ptr<pcps_opencl_acquisition_cc> pcps_opencl_acquisition_cc_sptr;
|
||||
|
@ -120,6 +120,7 @@ endif()
|
||||
|
||||
if(OPENCL_FOUND)
|
||||
message(STATUS "Adding processing blocks implemented using OpenCL")
|
||||
target_link_libraries(core_receiver PUBLIC algorithms_libs OpenCL::OpenCL)
|
||||
target_compile_definitions(core_receiver PRIVATE -DOPENCL_BLOCKS=1)
|
||||
else()
|
||||
target_compile_definitions(core_receiver PRIVATE -DOPENCL_BLOCKS=0)
|
||||
|
Loading…
Reference in New Issue
Block a user