1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-01-31 20:51:52 +01:00

Don't use -fvisibility-inlines-hidden on mingw to try to avoid a lot of

warnings from gcc.

llvm-svn: 148539
This commit is contained in:
Rafael Espindola 2012-01-20 13:10:10 +00:00
parent 7b50829b7f
commit cd18a7720d

View File

@ -89,12 +89,16 @@ if( LLVM_ENABLE_PIC )
message(WARNING "-fPIC not supported.") message(WARNING "-fPIC not supported.")
endif() endif()
if( WIN32 OR CYGWIN)
# MinGW warns if -fvisibility-inlines-hidden is used.
else()
check_cxx_compiler_flag("-fvisibility-inlines-hidden" SUPPORTS_FVISIBILITY_INLINES_HIDDEN_FLAG) check_cxx_compiler_flag("-fvisibility-inlines-hidden" SUPPORTS_FVISIBILITY_INLINES_HIDDEN_FLAG)
if( SUPPORTS_FVISIBILITY_INLINES_HIDDEN_FLAG ) if( SUPPORTS_FVISIBILITY_INLINES_HIDDEN_FLAG )
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility-inlines-hidden") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility-inlines-hidden")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fvisibility-inlines-hidden") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fvisibility-inlines-hidden")
endif() endif()
endif() endif()
endif()
endif() endif()
if( CMAKE_SIZEOF_VOID_P EQUAL 8 AND NOT WIN32 ) if( CMAKE_SIZEOF_VOID_P EQUAL 8 AND NOT WIN32 )