mirror of
https://github.com/RPCS3/llvm.git
synced 2024-12-03 09:21:02 +00:00
cmake: pass -fvisibility-inlines-hidden if it is supported. In a
Release+Asserts build with -DBUILD_SHARED_LIBS=ON, the install directory goes from 72MB to 70MB. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148530 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
a48678332b
commit
b28885057e
@ -88,6 +88,12 @@ if( LLVM_ENABLE_PIC )
|
||||
else( SUPPORTS_FPIC_FLAG )
|
||||
message(WARNING "-fPIC not supported.")
|
||||
endif()
|
||||
|
||||
check_cxx_compiler_flag("-fvisibility-inlines-hidden" SUPPORTS_FVISIBILITY_INLINES_HIDDEN_FLAG)
|
||||
if( SUPPORTS_FVISIBILITY_INLINES_HIDDEN_FLAG )
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility-inlines-hidden")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fvisibility-inlines-hidden")
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user