From a061e9ef4aa60c251f8c42052fe9ef6eefe896e0 Mon Sep 17 00:00:00 2001 From: "R. van Twisk" Date: Wed, 25 Dec 2019 14:21:37 +0100 Subject: Revert changes to video-ps3eye --- video-ps3eye/CMakeLists.txt | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'video-ps3eye') diff --git a/video-ps3eye/CMakeLists.txt b/video-ps3eye/CMakeLists.txt index 5adcf2b0..d42c83ff 100644 --- a/video-ps3eye/CMakeLists.txt +++ b/video-ps3eye/CMakeLists.txt @@ -4,9 +4,13 @@ if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/ps3eye-driver/CMakeLists.txt") add_subdirectory("ps3eye-driver") if(NOT MSVC) - find_package(LibUSB REQUIRED) - include_directories(SYSTEM ${LibUSB_INCLUDE_DIRS}) - link_libraries(${LibUSB_LIBRARIES} -pthread) + if(PKG_CONFIG_FOUND) + pkg_check_modules(libusb "libusb-1.0" QUIET) + endif() + if(libusb_FOUND) + include_directories(SYSTEM ${libusb_INCLUDE_DIRS}) + link_libraries(${libusb_LIBRARIES}) + endif() else() set(SDK_LIBUSB CACHE PATH "") if(SDK_LIBUSB) @@ -49,4 +53,4 @@ endif() if(TARGET ps3eye-frame-test) install(TARGETS "ps3eye-frame-test" DESTINATION "${opentrack-hier-pfx}") -endif() +endif() \ No newline at end of file -- cgit v1.2.3