From d99dafe2e4a385dd2a6c76da6d8258deb100657b Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Thu, 20 Apr 2017 21:19:10 +0000 Subject: Vendor import of llvm trunk r300890: https://llvm.org/svn/llvm-project/llvm/trunk@300890 --- cmake/modules/AddLLVM.cmake | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'cmake') diff --git a/cmake/modules/AddLLVM.cmake b/cmake/modules/AddLLVM.cmake index 7f7608cff33d..e011bb402757 100755 --- a/cmake/modules/AddLLVM.cmake +++ b/cmake/modules/AddLLVM.cmake @@ -81,8 +81,9 @@ function(add_llvm_symbol_exports target_name export_file) # Gold and BFD ld require a version script rather than a plain list. set(native_export_file "${target_name}.exports") # FIXME: Don't write the "local:" line on OpenBSD. + # in the export file, also add a linker script to version LLVM symbols (form: LLVM_N.M) add_custom_command(OUTPUT ${native_export_file} - COMMAND echo "{" > ${native_export_file} + COMMAND echo "LLVM_${LLVM_VERSION_MAJOR}.${LLVM_VERSION_MINOR} {" > ${native_export_file} COMMAND grep -q "[[:alnum:]]" ${export_file} && echo " global:" >> ${native_export_file} || : COMMAND sed -e "s/$/;/" -e "s/^/ /" < ${export_file} >> ${native_export_file} COMMAND echo " local: *;" >> ${native_export_file} -- cgit v1.2.3