mirror of
https://github.com/RPCSX/llvm.git
synced 2024-11-25 12:50:00 +00:00
[CMake] Add DARWIN_LTO_LIBRARY option to allow overriding -lto_library.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@247308 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
a37234f8c4
commit
4b5f4e5618
@ -543,6 +543,13 @@ else(UNIX)
|
||||
endif(NOT DEFINED CMAKE_INSTALL_RPATH)
|
||||
endif()
|
||||
|
||||
if(APPLE AND DARWIN_LTO_LIBRARY)
|
||||
set(CMAKE_EXE_LINKER_FLAGS
|
||||
"${CMAKE_EXE_LINKER_FLAGS} -Wl,-lto_library -Wl,${DARWIN_LTO_LIBRARY}")
|
||||
set(CMAKE_SHARED_LINKER_FLAGS
|
||||
"${CMAKE_SHARED_LINKER_FLAGS} -Wl,-lto_library -Wl,${DARWIN_LTO_LIBRARY}")
|
||||
endif()
|
||||
|
||||
# Work around a broken bfd ld behavior. When linking a binary with a
|
||||
# foo.so library, it will try to find any library that foo.so uses and
|
||||
# check its symbols. This is wasteful (the check was done when foo.so
|
||||
|
Loading…
Reference in New Issue
Block a user