[PATCH] D26715: [CMake] Error when LTO and lld are enabled on Darwin
Petr Hosek via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 15 16:30:27 PST 2016
phosek created this revision.
phosek added reviewers: mehdi_amini, beanz.
phosek added a subscriber: llvm-commits.
phosek set the repository for this revision to rL LLVM.
Herald added a subscriber: mgorny.
lld on Darwin does not currently support LTO.
Repository:
rL LLVM
https://reviews.llvm.org/D26715
Files:
cmake/modules/HandleLLVMOptions.cmake
Index: cmake/modules/HandleLLVMOptions.cmake
===================================================================
--- cmake/modules/HandleLLVMOptions.cmake
+++ cmake/modules/HandleLLVMOptions.cmake
@@ -96,6 +96,9 @@
set(LLVM_PLUGIN_EXT ${CMAKE_SHARED_LIBRARY_SUFFIX})
if(APPLE)
+ if(LLVM_ENABLE_LLD AND LLVM_ENABLE_LTO)
+ message(FATAL_ERROR "lld does not support LTO on Darwin")
+ endif()
# Darwin-specific linker flags for loadable modules.
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
endif()
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D26715.78095.patch
Type: text/x-patch
Size: 576 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161116/45765d83/attachment.bin>
More information about the llvm-commits
mailing list