CMakeLists.txt: switch prio between hidapi-libusb and hidapi-hidraw: fix detection issue on WSL2 with cmsisdap (#413)
This commit is contained in:
parent
99147efa27
commit
2535c28e04
|
|
@ -48,10 +48,10 @@ if (USE_PKGCONFIG)
|
||||||
find_package(PkgConfig REQUIRED)
|
find_package(PkgConfig REQUIRED)
|
||||||
pkg_check_modules(LIBFTDI REQUIRED libftdi1)
|
pkg_check_modules(LIBFTDI REQUIRED libftdi1)
|
||||||
pkg_check_modules(LIBUSB REQUIRED libusb-1.0)
|
pkg_check_modules(LIBUSB REQUIRED libusb-1.0)
|
||||||
pkg_check_modules(HIDAPI hidapi-hidraw)
|
pkg_check_modules(HIDAPI hidapi-libusb)
|
||||||
# if hidraw not found try with libusb
|
# if libusb not found try with hidraw
|
||||||
if (NOT HIDAPI_FOUND)
|
if (NOT HIDAPI_FOUND)
|
||||||
pkg_check_modules(HIDAPI hidapi-libusb)
|
pkg_check_modules(HIDAPI hidapi-hidraw)
|
||||||
endif()
|
endif()
|
||||||
if (NOT HIDAPI_FOUND)
|
if (NOT HIDAPI_FOUND)
|
||||||
pkg_check_modules(HIDAPI hidapi)
|
pkg_check_modules(HIDAPI hidapi)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue