Skip to content

Commit d15d693

Browse files
committed
disable warn-common on mac (#2374)
1 parent 67ce182 commit d15d693

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,9 @@ else(MSVC)
9595
# We still use c++11 flag in CPU build because gcc5.4 (our default compiler) is
9696
# not fully compatible with c++14 feature.
9797
set(CMAKE_CXX_FLAGS "-O2 -Wall -fPIC -std=c++11 ${CMAKE_CXX_FLAGS}")
98-
set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--warn-common ${CMAKE_SHARED_LINKER_FLAGS}")
98+
if(NOT APPLE)
99+
set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--warn-common ${CMAKE_SHARED_LINKER_FLAGS}")
100+
endif(NOT APPLE)
99101
endif(MSVC)
100102

101103
if(USE_OPENMP)

0 commit comments

Comments
 (0)