From 3216b20e3c22028bdc22a3b1726288b2f7e6e451 Mon Sep 17 00:00:00 2001 From: woodser Date: Fri, 4 Dec 2020 11:48:41 -0500 Subject: [PATCH] add -framework AppKit for Apple --- CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index dd8977532..0e66cbd18 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -982,10 +982,12 @@ list(APPEND EXTRA_LIBRARIES ${CMAKE_DL_LIBS}) if (HIDAPI_FOUND OR LibUSB_COMPILE_TEST_PASSED) if (APPLE) if(DEPENDS) - list(APPEND EXTRA_LIBRARIES "-framework Foundation -framework IOKit") + list(APPEND EXTRA_LIBRARIES "-framework Foundation -framework AppKit -framework IOKit") else() find_library(COREFOUNDATION CoreFoundation) + find_library(APPKIT AppKit) find_library(IOKIT IOKit) + list(APPEND EXTRA_LIBRARIES ${APPKIT}) list(APPEND EXTRA_LIBRARIES ${IOKIT}) list(APPEND EXTRA_LIBRARIES ${COREFOUNDATION}) endif()