mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-27 20:47:49 +08:00
20 lines
714 B
Diff
20 lines
714 B
Diff
|
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||
|
index 9424838..080cefa 100644
|
||
|
--- a/CMakeLists.txt
|
||
|
+++ b/CMakeLists.txt
|
||
|
@@ -6,9 +6,12 @@ option(MSGPACK11_BUILD_TESTS "Build unit tests" ON)
|
||
|
set(CMAKE_CXX_STANDARD 11)
|
||
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||
|
|
||
|
-add_library(msgpack11 msgpack11.cpp)
|
||
|
+add_library(msgpack11 STATIC msgpack11.cpp)
|
||
|
target_include_directories(msgpack11 PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
|
||
|
-target_compile_options(msgpack11 PRIVATE -fno-rtti -Wall -Wextra -Werror)
|
||
|
+target_compile_options(msgpack11 PRIVATE -fno-rtti)
|
||
|
+if(NOT MSVC)
|
||
|
+ target_compile_options(msgpack11 PRIVATE -Wall -Wextra -Werror)
|
||
|
+endif()
|
||
|
configure_file("msgpack11.pc.in" "msgpack11.pc" @ONLY)
|
||
|
|
||
|
if (MSGPACK11_BUILD_TESTS)
|