mingw: exclude msvc specific config for libusb

This commit is contained in:
Craig Carnell 2025-12-08 19:07:24 +00:00
parent 0f4304f4f5
commit 01e1a68d34
2 changed files with 9 additions and 1 deletions

View File

@ -9,7 +9,7 @@ add_library(usb STATIC EXCLUDE_FROM_ALL
dolphin_disable_warnings(usb)
set_target_properties(usb PROPERTIES VERSION 1.0.26)
if(WIN32)
if(MSVC)
target_include_directories(usb BEFORE PUBLIC libusb/libusb PRIVATE libusb/msvc)
else()
target_include_directories(usb

View File

@ -1,4 +1,12 @@
add_library(watcher INTERFACE IMPORTED GLOBAL)
if(WIN32)
check_cxx_compiler_flag(-fexceptions HAS_FEXCEPTIONS)
if(HAS_FEXCEPTIONS)
target_compile_options(watcher INTERFACE -fexceptions)
endif()
endif()
set_target_properties(watcher PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES ${CMAKE_CURRENT_LIST_DIR}/watcher/include
)