Fix name of static library when targeting MinGW.

This commit is contained in:
Markus Mützel 2024-11-19 15:29:47 +01:00
parent bd25fc5ea0
commit 62ea371df1

View File

@ -143,7 +143,7 @@ if(BUILD_STATIC_LIBS)
# avoid name clashes on windows as the shared import lib is also named jsoncpp.lib
if(NOT DEFINED STATIC_SUFFIX AND BUILD_SHARED_LIBS)
if (WIN32)
if (MSVC OR ("${CMAKE_C_SIMULATE_ID}" STREQUAL "MSVC"))
set(STATIC_SUFFIX "_static")
else()
set(STATIC_SUFFIX "")