mirror of
https://github.com/oatpp/oatpp.git
synced 2025-01-30 16:59:30 +08:00
link win32 system libraries for mingw (#222)
* link win32 system libraries for mingw * Add 'OR MINGW' to the MSVC line
This commit is contained in:
parent
e0eb7fdd8c
commit
875ec2d826
@ -243,17 +243,17 @@ set(CMAKE_THREAD_PREFER_PTHREAD ON)
|
||||
|
||||
find_package(Threads REQUIRED)
|
||||
|
||||
if(MSVC)
|
||||
if(MSVC OR MINGW)
|
||||
target_link_libraries(oatpp PUBLIC ${CMAKE_THREAD_LIBS_INIT} wsock32 ws2_32)
|
||||
elseif(APPLE)
|
||||
target_link_libraries(oatpp PUBLIC ${CMAKE_THREAD_LIBS_INIT})
|
||||
else(MSVC)
|
||||
else(MSVC OR MINGW)
|
||||
if(${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD")
|
||||
target_link_libraries(oatpp PUBLIC ${CMAKE_THREAD_LIBS_INIT})
|
||||
else(${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD")
|
||||
target_link_libraries(oatpp PUBLIC ${CMAKE_THREAD_LIBS_INIT} atomic)
|
||||
endif(${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD")
|
||||
endif(MSVC)
|
||||
endif(MSVC OR MINGW)
|
||||
|
||||
target_include_directories(oatpp PUBLIC
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
|
||||
|
Loading…
Reference in New Issue
Block a user