cmake: move check for hackrf_device_list to hackrf subdirectory
This commit is contained in:
parent
f33f30815a
commit
46e95395e0
|
@ -23,12 +23,3 @@ INCLUDE(FindPackageHandleStandardArgs)
|
||||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(LIBHACKRF DEFAULT_MSG LIBHACKRF_LIBRARIES LIBHACKRF_INCLUDE_DIRS)
|
FIND_PACKAGE_HANDLE_STANDARD_ARGS(LIBHACKRF DEFAULT_MSG LIBHACKRF_LIBRARIES LIBHACKRF_INCLUDE_DIRS)
|
||||||
MARK_AS_ADVANCED(LIBHACKRF_LIBRARIES LIBHACKRF_INCLUDE_DIRS)
|
MARK_AS_ADVANCED(LIBHACKRF_LIBRARIES LIBHACKRF_INCLUDE_DIRS)
|
||||||
|
|
||||||
INCLUDE(CheckFunctionExists)
|
|
||||||
set(CMAKE_REQUIRED_LIBRARIES ${LIBHACKRF_LIBRARIES})
|
|
||||||
CHECK_FUNCTION_EXISTS(hackrf_device_list LIBHACKRF_HAVE_DEVICE_LIST)
|
|
||||||
|
|
||||||
if(LIBHACKRF_HAVE_DEVICE_LIST)
|
|
||||||
message(STATUS "HackRF multiple device support enabled")
|
|
||||||
add_definitions(-DLIBHACKRF_HAVE_DEVICE_LIST)
|
|
||||||
endif(LIBHACKRF_HAVE_DEVICE_LIST)
|
|
||||||
|
|
||||||
|
|
|
@ -31,6 +31,15 @@ set(hackrf_srcs
|
||||||
${CMAKE_CURRENT_SOURCE_DIR}/hackrf_sink_c.cc
|
${CMAKE_CURRENT_SOURCE_DIR}/hackrf_sink_c.cc
|
||||||
)
|
)
|
||||||
|
|
||||||
|
INCLUDE(CheckFunctionExists)
|
||||||
|
set(CMAKE_REQUIRED_LIBRARIES ${LIBHACKRF_LIBRARIES})
|
||||||
|
CHECK_FUNCTION_EXISTS(hackrf_device_list LIBHACKRF_HAVE_DEVICE_LIST)
|
||||||
|
|
||||||
|
if(LIBHACKRF_HAVE_DEVICE_LIST)
|
||||||
|
message(STATUS "HackRF multiple device support enabled")
|
||||||
|
add_definitions(-DLIBHACKRF_HAVE_DEVICE_LIST)
|
||||||
|
endif(LIBHACKRF_HAVE_DEVICE_LIST)
|
||||||
|
|
||||||
########################################################################
|
########################################################################
|
||||||
# Append gnuradio-osmosdr library sources
|
# Append gnuradio-osmosdr library sources
|
||||||
########################################################################
|
########################################################################
|
||||||
|
|
Loading…
Reference in New Issue