From d630f65613120e20e949798c23944c01b07c8b18 Mon Sep 17 00:00:00 2001 From: mjvankampen Date: Sat, 30 Jan 2021 15:26:15 +0100 Subject: [PATCH] Adds windows shared build support under cmake (#18) * Adds windows shared build support under cmake * makes public --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 58a95d0..deebaab 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -121,6 +121,10 @@ target_compile_options(norm PUBLIC ${PLATFORM_FLAGS}) target_include_directories(norm PRIVATE ${CMAKE_CURRENT_BINARY_DIR}) target_include_directories(norm PUBLIC $ $) +if(BUILD_SHARED_LIBS AND WIN32) + target_compile_definitions(norm PUBLIC NORM_USE_DLL) +endif() + # Install target install( TARGETS norm protokit EXPORT normTargets RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}