mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-09 07:39:26 +01:00
Don't use hidapi-hidraw without udev.
This commit is contained in:
parent
7fa14169e9
commit
8970c1a793
@ -754,15 +754,22 @@ if(NOT ANDROID)
|
||||
include_directories(${HIDAPI_INCLUDE_DIRS})
|
||||
list(APPEND LIBS ${HIDAPI_LIBRARIES})
|
||||
else()
|
||||
set(HIDAPI_FOUND 1)
|
||||
include_directories(Externals/hidapi/hidapi)
|
||||
if(APPLE)
|
||||
message(STATUS "Using static hidapi from Externals")
|
||||
add_subdirectory(Externals/hidapi/mac)
|
||||
list(APPEND LIBS hidapi)
|
||||
elseif(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
|
||||
message(STATUS "Using static hidapi-hidraw from Externals")
|
||||
add_subdirectory(Externals/hidapi/linux)
|
||||
list(APPEND LIBS hidapi-hidraw udev)
|
||||
find_package(Libudev)
|
||||
if(LIBUDEV_FOUND)
|
||||
message(STATUS "Using static hidapi-hidraw from Externals")
|
||||
add_subdirectory(Externals/hidapi/linux)
|
||||
list(APPEND LIBS hidapi-hidraw udev)
|
||||
else()
|
||||
message(STATUS "Could not find udev, disabling hidapi")
|
||||
set(HIDAPI_FOUND 0)
|
||||
endif()
|
||||
elseif(MSVC)
|
||||
message(STATUS "Using static hidapi-hid from Externals")
|
||||
add_subdirectory(Externals/hidapi/windows)
|
||||
@ -773,8 +780,9 @@ if(NOT ANDROID)
|
||||
list(APPEND LIBS hidapi-libusb)
|
||||
endif()
|
||||
endif()
|
||||
set(HIDAPI_FOUND 1)
|
||||
add_definitions(-DHAVE_HIDAPI=1)
|
||||
if(HIDAPI_FOUND)
|
||||
add_definitions(-DHAVE_HIDAPI=1)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(NOT DISABLE_WX)
|
||||
|
Loading…
x
Reference in New Issue
Block a user