[PATCH] D76527: Don't export symbols from clang/opt/llc if plugins are disabled.
Eli Friedman via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 23 12:33:51 PDT 2020
This revision was automatically updated to reflect the committed changes.
Closed by commit rG896335bfb8ea: Don't export symbols from clang/opt/llc if plugins are disabled. (authored by efriedma).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D76527/new/
https://reviews.llvm.org/D76527
Files:
clang/tools/driver/CMakeLists.txt
llvm/cmake/modules/AddLLVM.cmake
llvm/tools/bugpoint/CMakeLists.txt
llvm/tools/llc/CMakeLists.txt
llvm/tools/llvm-stress/CMakeLists.txt
llvm/tools/opt/CMakeLists.txt
llvm/unittests/Passes/CMakeLists.txt
Index: llvm/unittests/Passes/CMakeLists.txt
===================================================================
--- llvm/unittests/Passes/CMakeLists.txt
+++ llvm/unittests/Passes/CMakeLists.txt
@@ -16,7 +16,7 @@
add_llvm_unittest(PluginsTests
PluginsTest.cpp
)
- export_executable_symbols(PluginsTests)
+ export_executable_symbols_for_plugins(PluginsTests)
target_link_libraries(PluginsTests PRIVATE LLVMTestingSupport)
set(LLVM_LINK_COMPONENTS)
Index: llvm/tools/opt/CMakeLists.txt
===================================================================
--- llvm/tools/opt/CMakeLists.txt
+++ llvm/tools/opt/CMakeLists.txt
@@ -39,7 +39,7 @@
intrinsics_gen
SUPPORT_PLUGINS
)
-export_executable_symbols(opt)
+export_executable_symbols_for_plugins(opt)
if(LLVM_BUILD_EXAMPLES)
target_link_libraries(opt PRIVATE ExampleIRTransforms)
Index: llvm/tools/llvm-stress/CMakeLists.txt
===================================================================
--- llvm/tools/llvm-stress/CMakeLists.txt
+++ llvm/tools/llvm-stress/CMakeLists.txt
@@ -10,4 +10,3 @@
DEPENDS
intrinsics_gen
)
-export_executable_symbols(llvm-stress)
Index: llvm/tools/llc/CMakeLists.txt
===================================================================
--- llvm/tools/llc/CMakeLists.txt
+++ llvm/tools/llc/CMakeLists.txt
@@ -27,4 +27,4 @@
SUPPORT_PLUGINS
)
-export_executable_symbols(llc)
+export_executable_symbols_for_plugins(llc)
Index: llvm/tools/bugpoint/CMakeLists.txt
===================================================================
--- llvm/tools/bugpoint/CMakeLists.txt
+++ llvm/tools/bugpoint/CMakeLists.txt
@@ -38,4 +38,4 @@
intrinsics_gen
SUPPORT_PLUGINS
)
-export_executable_symbols(bugpoint)
+export_executable_symbols_for_plugins(bugpoint)
Index: llvm/cmake/modules/AddLLVM.cmake
===================================================================
--- llvm/cmake/modules/AddLLVM.cmake
+++ llvm/cmake/modules/AddLLVM.cmake
@@ -1029,6 +1029,13 @@
endif()
endfunction()
+# Export symbols if LLVM plugins are enabled.
+function(export_executable_symbols_for_plugins target)
+ if(LLVM_ENABLE_PLUGINS)
+ export_executable_symbols(${target})
+ endif()
+endfunction()
+
if(NOT LLVM_TOOLCHAIN_TOOLS)
set (LLVM_TOOLCHAIN_TOOLS
llvm-ar
Index: clang/tools/driver/CMakeLists.txt
===================================================================
--- clang/tools/driver/CMakeLists.txt
+++ clang/tools/driver/CMakeLists.txt
@@ -57,7 +57,7 @@
# Support plugins.
if(CLANG_PLUGIN_SUPPORT)
- export_executable_symbols(clang)
+ export_executable_symbols_for_plugins(clang)
endif()
add_dependencies(clang clang-resource-headers)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D76527.252121.patch
Type: text/x-patch
Size: 2680 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200323/3d709853/attachment.bin>
More information about the llvm-commits
mailing list