Merge remote-tracking branch 'cnjinhao/hotfix-1.6.1' into CMake
# Conflicts: # CMakeLists.txt
This commit is contained in:
commit
05e6e1f92e
@ -156,26 +156,26 @@ endif()
|
|||||||
if(CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang")
|
if(CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang")
|
||||||
if(NANA_CMAKE_SHARED_LIB)
|
if(NANA_CMAKE_SHARED_LIB)
|
||||||
list(APPEND NANA_LINKS -lgcc -lstdc++ -pthread)
|
list(APPEND NANA_LINKS -lgcc -lstdc++ -pthread)
|
||||||
|
else()
|
||||||
|
if(MINGW)
|
||||||
|
set(CMAKE_EXE_LINKER_FLAGS "-static -pthread")
|
||||||
else()
|
else()
|
||||||
set(CMAKE_EXE_LINKER_FLAGS "-static-libgcc -static-libstdc++ -pthread")
|
set(CMAKE_EXE_LINKER_FLAGS "-static-libgcc -static-libstdc++ -pthread")
|
||||||
# message("Setting NANA_LINKS to -static-libgcc -static-libstdc++ -pthread or ${NANA_LINKS}")
|
endif()
|
||||||
endif(NANA_CMAKE_SHARED_LIB)
|
endif(NANA_CMAKE_SHARED_LIB)
|
||||||
|
|
||||||
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.0)
|
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.0)
|
||||||
# GCC 4.9
|
# GCC 4.9
|
||||||
list(APPEND NANA_LINKS "-lboost_system -lboost_thread")
|
list(APPEND NANA_LINKS "-lboost_system -lboost_thread")
|
||||||
|
|
||||||
elseif(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.3)
|
elseif(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.3)
|
||||||
# IS_GNUCXX < 5.3
|
# IS_GNUCXX < 5.3
|
||||||
else()
|
else()
|
||||||
list(APPEND NANA_LINKS -lstdc++fs)
|
list(APPEND NANA_LINKS -lstdc++fs)
|
||||||
endif()
|
endif()
|
||||||
|
endif()
|
||||||
endif(CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang") # AND NOT MINGW
|
|
||||||
|
|
||||||
|
|
||||||
if (APPLE AND "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang") # APPLE Clang
|
if (APPLE AND "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang") # APPLE Clang
|
||||||
# set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -stdlib=libstdc++")
|
|
||||||
list(APPEND NANA_LINKS -stdlib=libstdc++)
|
list(APPEND NANA_LINKS -stdlib=libstdc++)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user