target_compile_options(nana PUBLIC -static -static-libstdc++) for MINGW too

This commit is contained in:
qPCR4vir
2019-05-15 13:05:19 +02:00
parent d96efd11a6
commit fbffbcd75d
2 changed files with 34 additions and 43 deletions

View File

@@ -40,12 +40,7 @@ if(CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang") # AN
if(BUILD_SHARED_LIBS)
target_compile_options(nana PUBLIC -lgcc -lstdc++)
else()
if(MINGW)
target_compile_options(nana PUBLIC -static) # -static ?? cmake knows BUILD_SHARED_LIBS
else()
target_compile_options(nana PUBLIC -static-libgcc -static-libstdc++)
endif()
target_compile_options(nana PUBLIC -static -static-libstdc++)
endif(BUILD_SHARED_LIBS)
endif()