From 7290051f8edcb956d607df02d6c0663e68da4c88 Mon Sep 17 00:00:00 2001 From: Xpol Wan Date: Tue, 24 May 2016 11:41:54 +0800 Subject: [PATCH] Fixes visual studio static compile warings about dll interface. --- cmake/xlnt.cmake | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cmake/xlnt.cmake b/cmake/xlnt.cmake index 01229b2b..ad0959f1 100644 --- a/cmake/xlnt.cmake +++ b/cmake/xlnt.cmake @@ -102,6 +102,9 @@ endif() if(STATIC) add_library(xlnt.static STATIC ${HEADERS} ${SOURCES} ${MINIZ} ${PUGIXML}) + if(MSVC) + target_compile_definitions(xlnt.static PRIVATE XLNT_API=) + endif() install(TARGETS xlnt.static LIBRARY DESTINATION ${LIB_DEST_DIR} ARCHIVE DESTINATION ${LIB_DEST_DIR}