Created
January 15, 2024 23:42
cmake file used for building libmirisdr-4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# FindLibUSB.cmake - Try to find the Hiredis library | |
# Once done this will define | |
# | |
# LIBUSB_FOUND - System has libusb | |
# LIBUSB_INCLUDE_DIR - The libusb include directory | |
# LIBUSB_LIBRARIES - The libraries needed to use libusb | |
# LIBUSB_DEFINITIONS - Compiler switches required for using libusb | |
find_path(LIBUSB_INCLUDE_DIR | |
NAMES libusb.h | |
PATHS | |
/usr | |
/usr/local | |
/opt | |
C:\\development\\miri_sdr\\libusb-1.0.26-binaries\\libusb-MinGW-Win32\\include\\libusb-1.0 | |
"${CMAKE_BINARY_DIR}\\include" | |
PATH_SUFFIXES libusb-1.0 | |
) | |
SET(CMAKE_FIND_LIBRARY_PREFIXES "lib") | |
SET(CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll") | |
find_library(LIBUSB_LIBRARIES | |
NAMES usb-1.0 | |
PATHS | |
/usr | |
/usr/local | |
/opt | |
C:\\development\\miri_sdr\\libusb-1.0.26-binaries\\libusb-MinGW-Win32\\bin | |
"${CMAKE_BINARY_DIR}/MS64/static" | |
"${CMAKE_BINARY_DIR}/MS64/dll" | |
) | |
message(${LIBUSB_INCLUDE_DIR}) | |
message("${CMAKE_BINARY_DIR}\\MS64\\dll") | |
message("LIBUSB_LIBRARIES: ${LIBUSB_LIBRARIES}") | |
INCLUDE(FindPackageHandleStandardArgs) | |
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Libusb DEFAULT_MSG LIBUSB_LIBRARIES LIBUSB_INCLUDE_DIR) | |
MARK_AS_ADVANCED(LIBUSB_INCLUDE_DIR LIBUSB_LIBRARIES) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment