Hide all symbols in llvm namespace (#63272)

Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/63272

Test Plan: Imported from OSS

Reviewed By: nikithamalgifb

Differential Revision: D30331695

Pulled By: bertmaher

fbshipit-source-id: d35130c96f7e2a31fa86d9d80de59002e96301df
This commit is contained in:
Bert Maher
2021-08-15 11:28:23 -07:00
committed by Facebook GitHub Bot
parent 045c4cb82f
commit 0ce4d30c44
3 changed files with 3 additions and 7 deletions

View File

@ -815,7 +815,7 @@ if(USE_LLVM AND LLVM_FOUND)
elseif(UNIX)
set(LINKER_SCRIPT "${CMAKE_CURRENT_SOURCE_DIR}/version_script.lds")
set_target_properties(torch_cpu PROPERTIES LINK_DEPENDS ${LINKER_SCRIPT})
set_target_properties(torch_cpu PROPERTIES LINK_FLAGS "-Wl,--version-script=${LINKER_SCRIPT}")
target_link_libraries(torch_cpu PRIVATE "-Wl,--version-script=${LINKER_SCRIPT}")
endif()
endif(USE_LLVM AND LLVM_FOUND)

View File

@ -1,2 +1 @@
__ZN4llvm*
__ZNK4llvm*
*4llvm*

View File

@ -1,7 +1,4 @@
pytorch {
global:
*;
local:
_ZN4llvm*;
_ZNK4llvm*;
*4llvm*;
};