mirror of
https://github.com/guanzhi/GmSSL.git
synced 2026-05-28 03:06:24 +08:00
fix cmake build error on mingw
This commit is contained in:
@@ -118,7 +118,9 @@ else()
|
|||||||
target_link_libraries(gmssl dl)
|
target_link_libraries(gmssl dl)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if(MINGW)
|
||||||
|
target_link_libraries(gmssl PRIVATE wsock32)
|
||||||
|
endif()
|
||||||
|
|
||||||
SET_TARGET_PROPERTIES(gmssl PROPERTIES VERSION 3.0 SOVERSION 3)
|
SET_TARGET_PROPERTIES(gmssl PROPERTIES VERSION 3.0 SOVERSION 3)
|
||||||
|
|
||||||
@@ -230,6 +232,9 @@ if (NOT ${CMAKE_SYSTEM_NAME} STREQUAL "iOS")
|
|||||||
add_executable(gmssl-bin ${tools})
|
add_executable(gmssl-bin ${tools})
|
||||||
target_link_libraries (gmssl-bin LINK_PUBLIC gmssl)
|
target_link_libraries (gmssl-bin LINK_PUBLIC gmssl)
|
||||||
set_target_properties (gmssl-bin PROPERTIES RUNTIME_OUTPUT_NAME gmssl)
|
set_target_properties (gmssl-bin PROPERTIES RUNTIME_OUTPUT_NAME gmssl)
|
||||||
|
if(MINGW)
|
||||||
|
target_link_libraries(gmssl-bin PRIVATE Ws2_32)
|
||||||
|
endif()
|
||||||
|
|
||||||
enable_testing()
|
enable_testing()
|
||||||
foreach(name ${tests})
|
foreach(name ${tests})
|
||||||
|
|||||||
Reference in New Issue
Block a user