From 7e91f81957a021be675e7e19cc92da565735b2d9 Mon Sep 17 00:00:00 2001 From: WarmUpTill <19472752+WarmUpTill@users.noreply.github.com> Date: Sun, 15 Jun 2025 14:07:17 +0200 Subject: [PATCH] Ease development with dirty dependency directory --- plugins/http/CMakeLists.txt | 4 ++++ plugins/twitch/CMakeLists.txt | 4 ++++ plugins/usb/CMakeLists.txt | 5 +++-- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/plugins/http/CMakeLists.txt b/plugins/http/CMakeLists.txt index a0bad197..d9bd2b3b 100644 --- a/plugins/http/CMakeLists.txt +++ b/plugins/http/CMakeLists.txt @@ -40,6 +40,10 @@ if(OS_MACOS) target_link_libraries(${PROJECT_NAME} PRIVATE "-framework Security") endif() +if(MSVC) + target_compile_options(${PROJECT_NAME} PRIVATE /wd4834) +endif() + target_sources( ${PROJECT_NAME} PRIVATE macro-action-http.cpp macro-action-http.hpp key-value-list.cpp key-value-list.hpp) diff --git a/plugins/twitch/CMakeLists.txt b/plugins/twitch/CMakeLists.txt index d1d67b68..794c4ba0 100644 --- a/plugins/twitch/CMakeLists.txt +++ b/plugins/twitch/CMakeLists.txt @@ -72,6 +72,10 @@ if(OS_MACOS) target_link_libraries(${PROJECT_NAME} PRIVATE "-framework Security") endif() +if(MSVC) + target_compile_options(${PROJECT_NAME} PRIVATE /wd4834) +endif() + target_sources( ${PROJECT_NAME} PRIVATE category-selection.cpp diff --git a/plugins/usb/CMakeLists.txt b/plugins/usb/CMakeLists.txt index 86093d3c..367113f0 100644 --- a/plugins/usb/CMakeLists.txt +++ b/plugins/usb/CMakeLists.txt @@ -77,13 +77,14 @@ if(NOT libusb_HEADER_DIR) "libusb sources are available under: ${libusb_DEPS_DIR}") return() endif() -if(NOT libusb_LINK_LIBRARIES) +if(NOT libusb_LINK_LIBRARIES OR NOT EXISTS "${libusb_LINK_LIBRARIES}") message(WARNING "libusb library not found. Make sure libusb is installed. " "USB condition will be disabled!\n\n" "libusb sources are available under: ${libusb_DEPS_DIR}") return() endif() -if(NOT OS_LINUX AND NOT libusb_RUNTIME_LIBRARY) +if(NOT OS_LINUX AND (NOT libusb_RUNTIME_LIBRARY OR NOT EXISTS + "${libusb_RUNTIME_LIBRARY}")) message( WARNING "libusb runtime library not found. Make sure libusb is installed. " "USB condition will be disabled!\n\n"