diff options
| author | Tom Stellard <tstellar@redhat.com> | 2019-06-11 03:21:13 +0000 |
|---|---|---|
| committer | Tom Stellard <tstellar@redhat.com> | 2019-06-11 03:21:13 +0000 |
| commit | 4b0b26199b25014b70ea3b2eb05b0dd9154bd830 (patch) | |
| tree | 0c1cd98d8b4229dc4b79613c4fb27112ac0d614f /llvm/utils/unittest | |
| parent | eaf3f569247afc9e681d87905c28189dfb0c1293 (diff) | |
| download | bcm5719-llvm-4b0b26199b25014b70ea3b2eb05b0dd9154bd830.tar.gz bcm5719-llvm-4b0b26199b25014b70ea3b2eb05b0dd9154bd830.zip | |
Revert CMake: Make most target symbols hidden by default
This reverts r362990 (git commit 374571301dc8e9bc9fdd1d70f86015de198673bd)
This was causing linker warnings on Darwin:
ld: warning: direct access in function 'llvm::initializeEvexToVexInstPassPass(llvm::PassRegistry&)'
from file '../../lib/libLLVMX86CodeGen.a(X86EvexToVex.cpp.o)' to global weak symbol
'void std::__1::__call_once_proxy<std::__1::tuple<void* (&)(llvm::PassRegistry&),
std::__1::reference_wrapper<llvm::PassRegistry>&&> >(void*)' from file '../../lib/libLLVMCore.a(Verifier.cpp.o)'
means the weak symbol cannot be overridden at runtime. This was likely caused by different translation
units being compiled with different visibility settings.
llvm-svn: 363028
Diffstat (limited to 'llvm/utils/unittest')
| -rw-r--r-- | llvm/utils/unittest/CMakeLists.txt | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/llvm/utils/unittest/CMakeLists.txt b/llvm/utils/unittest/CMakeLists.txt index 5aad048f2c3..0850d49e3a3 100644 --- a/llvm/utils/unittest/CMakeLists.txt +++ b/llvm/utils/unittest/CMakeLists.txt @@ -71,23 +71,3 @@ add_llvm_library(gtest ) add_subdirectory(UnitTestMain) - -# When LLVM_LINK_LLVM_DYLIB is enabled, libLLVM.so is added to the interface -# link libraries for gtest and gtest_main. This means that any target, like -# unittests for example, that links against gtest will be forced to link -# against libLLVM.so. In some cases we may want to statically unittests if they -# need access to symbols that are marked private in libLLVM.so. The only -# way we can make this work is to remove libLLVM.so from the list of interface -# link libraries for gtest and then make gtest users responsible for explicitly -# adding libLLVM.so to their targets link libraries if they need it. - -function (gtest_remove_dylib_from_link_interface target) - get_target_property(interface_libs ${target} INTERFACE_LINK_LIBRARIES) - if (interface_libs) - list(REMOVE_ITEM interface_libs LLVM) - set_target_properties(${target} PROPERTIES INTERFACE_LINK_LIBRARIES "${interface_libs}") - endif() -endfunction() - -gtest_remove_dylib_from_link_interface(gtest) -gtest_remove_dylib_from_link_interface(gtest_main) |

