2018-01-10 20:21:29 -05:00
|
|
|
if(NOT LIBAIRSPYHF_FOUND)
|
|
|
|
|
|
|
|
pkg_check_modules (LIBAIRSPYHF_PKG libairspyhf)
|
2019-07-25 20:04:42 -04:00
|
|
|
|
|
|
|
find_path(LIBAIRSPYHF_INCLUDE_DIR
|
2019-01-02 15:33:45 -05:00
|
|
|
NAMES libairspyhf/airspyhf.h
|
2019-07-25 20:04:42 -04:00
|
|
|
HINTS ${AIRSPYHF_DIR}/include
|
2019-01-02 15:33:45 -05:00
|
|
|
${LIBAIRSPYHF_PKG_INCLUDE_DIRS}
|
2019-07-25 20:04:42 -04:00
|
|
|
PATHS /usr/include
|
2019-01-02 15:33:45 -05:00
|
|
|
/usr/local/include
|
2018-01-10 20:21:29 -05:00
|
|
|
)
|
|
|
|
|
2019-07-25 20:04:42 -04:00
|
|
|
find_library(LIBAIRSPYHF_LIBRARIES
|
2019-01-02 15:33:45 -05:00
|
|
|
NAMES airspyhf
|
2019-07-25 20:04:42 -04:00
|
|
|
HINTS ${AIRSPYHF_DIR}/lib
|
2019-01-02 15:33:45 -05:00
|
|
|
${LIBAIRSPYHF_PKG_LIBRARY_DIRS}
|
2019-07-25 20:04:42 -04:00
|
|
|
PATHS /usr/lib
|
2019-01-02 15:33:45 -05:00
|
|
|
/usr/local/lib
|
2018-01-10 20:21:29 -05:00
|
|
|
)
|
|
|
|
|
|
|
|
if(LIBAIRSPYHF_INCLUDE_DIR AND LIBAIRSPYHF_LIBRARIES)
|
|
|
|
set(LIBAIRSPYHF_FOUND TRUE CACHE INTERNAL "libairspyhf found")
|
|
|
|
message(STATUS "Found libairspyhf: ${LIBAIRSPYHF_INCLUDE_DIR}, ${LIBAIRSPYHF_LIBRARIES}")
|
|
|
|
else(LIBAIRSPYHF_INCLUDE_DIR AND LIBAIRSPYHF_LIBRARIES)
|
|
|
|
set(LIBAIRSPYHF_FOUND FALSE CACHE INTERNAL "libairspyhf found")
|
|
|
|
message(STATUS "libairspyhf not found.")
|
|
|
|
endif(LIBAIRSPYHF_INCLUDE_DIR AND LIBAIRSPYHF_LIBRARIES)
|
|
|
|
|
|
|
|
mark_as_advanced(LIBAIRSPYHF_INCLUDE_DIR LIBAIRSPYHF_LIBRARIES)
|
|
|
|
|
|
|
|
endif(NOT LIBAIRSPYHF_FOUND)
|