aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorSzczepan Zalega <szczepan@nitrokey.com>2017-03-09 18:49:24 +0100
committerSzczepan Zalega <szczepan@nitrokey.com>2017-03-11 15:41:45 +0100
commitadbc664125142c434294bfa795666c90c7608429 (patch)
tree15db66af5acd4422b5e66678dbe45a953b9dbdb0 /CMakeLists.txt
parentc69604e8ba099b1421af86c34d904b0b380f996c (diff)
downloadlibnitrokey-adbc664125142c434294bfa795666c90c7608429.tar.gz
libnitrokey-adbc664125142c434294bfa795666c90c7608429.tar.bz2
Adjust for compilation on Visual Studio 2017
Building works however tests are not. Possibly linking with original hidapi solution would work.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt4
1 files changed, 2 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 2b9f580..e77de6e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -65,7 +65,7 @@ set(SOURCE_FILES
# add_library(hidapi-libusb STATIC hidapi/libusb/hid.c )
#ELSE()
include_directories(hidapi/hidapi)
- add_library(hidapi-libusb STATIC hidapi/windows/hid.c )
+ add_library(hidapi-libusb SHARED hidapi/windows/hid.c )
target_link_libraries(hidapi-libusb setupapi setupapi kernel32 user32 gdi32 winspool comdlg32 advapi32 shell32 ole32 oleaut32 uuid odbc32 odbccp32)
#ENDIF()
@@ -85,7 +85,7 @@ install (FILES ${LIB_INCLUDES} DESTINATION "include")
IF (COMPILE_TESTS)
include_directories(unittest/Catch/include)
- add_library(catch STATIC unittest/catch_main.cpp )
+ add_library(catch SHARED unittest/catch_main.cpp )
add_executable (test_C_API unittest/test_C_API.cpp)
target_link_libraries (test_C_API ${EXTRA_LIBS} ${LIBNAME} catch)