[llvm] r198164 - [CMake] add_llvm_symbol_exports: Use unique name for each target.
NAKAMURA Takumi
geek4civic at gmail.com
Sun Dec 29 08:15:26 PST 2013
Author: chapuni
Date: Sun Dec 29 10:15:26 2013
New Revision: 198164
URL: http://llvm.org/viewvc/llvm-project?rev=198164&view=rev
Log:
[CMake] add_llvm_symbol_exports: Use unique name for each target.
Modified:
llvm/trunk/cmake/modules/AddLLVM.cmake
Modified: llvm/trunk/cmake/modules/AddLLVM.cmake
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/cmake/modules/AddLLVM.cmake?rev=198164&r1=198163&r2=198164&view=diff
==============================================================================
--- llvm/trunk/cmake/modules/AddLLVM.cmake (original)
+++ llvm/trunk/cmake/modules/AddLLVM.cmake Sun Dec 29 10:15:26 2013
@@ -4,7 +4,7 @@ include(LLVM-Config)
function(add_llvm_symbol_exports target_name export_file)
if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
- set(native_export_file "symbol.exports")
+ set(native_export_file "${target_name}.exports")
add_custom_command(OUTPUT ${native_export_file}
COMMAND sed -e "s/^/_/" < ${export_file} > ${native_export_file}
DEPENDS ${export_file}
@@ -14,7 +14,7 @@ function(add_llvm_symbol_exports target_
LINK_FLAGS " -Wl,-exported_symbols_list,${CMAKE_CURRENT_BINARY_DIR}/${native_export_file}")
elseif(LLVM_HAVE_LINK_VERSION_SCRIPT)
# Gold and BFD ld require a version script rather than a plain list.
- set(native_export_file "symbol.exports")
+ set(native_export_file "${target_name}.exports")
# FIXME: Don't write the "local:" line on OpenBSD.
add_custom_command(OUTPUT ${native_export_file}
COMMAND echo "{" > ${native_export_file}
@@ -28,7 +28,7 @@ function(add_llvm_symbol_exports target_
set_property(TARGET ${target_name} APPEND_STRING PROPERTY
LINK_FLAGS " -Wl,--version-script,${CMAKE_CURRENT_BINARY_DIR}/${native_export_file}")
else()
- set(native_export_file "symbol.def")
+ set(native_export_file "${target_name}.def")
set(CAT "type")
if(CYGWIN)
More information about the llvm-commits
mailing list