aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoratkawa7 <atkawa7@yahoo.com>2017-06-23 16:37:25 -0700
committeratkawa7 <atkawa7@yahoo.com>2017-06-23 16:37:25 -0700
commit9eca90f2d1c4f2ddc0cd0153b7addbff3757bac4 (patch)
tree4956ea6647bd7cba5ffe3d28b1d098d29ae8173c
parent2100e95c25db8b76058d9e125c5b2fcdce9fd74a (diff)
downloadvcpkg-9eca90f2d1c4f2ddc0cd0153b7addbff3757bac4.tar.gz
vcpkg-9eca90f2d1c4f2ddc0cd0153b7addbff3757bac4.zip
Small fix BUILD_SHARED_LIBS use vcpkg lib linkage
-rw-r--r--ports/rtmidi/CMakeLists.txt7
1 files changed, 7 insertions, 0 deletions
diff --git a/ports/rtmidi/CMakeLists.txt b/ports/rtmidi/CMakeLists.txt
index f334a598e..0603fdcb8 100644
--- a/ports/rtmidi/CMakeLists.txt
+++ b/ports/rtmidi/CMakeLists.txt
@@ -12,6 +12,13 @@ set(RTMIDI_HEADERS
include_directories(${RTMIDI_HEADERS})
+if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
+ set(BUILD_SHARED_LIBS ON)
+else()
+ set(BUILD_SHARED_LIBS OFF)
+endif()
+
+
if(BUILD_SHARED_LIBS)
add_library(rtmidi SHARED ${RTMIDI_SOURCES})
target_compile_definitions(rtmidi PRIVATE -DRTMIDI_EXPORT)