Skip to content

Commit 2e18f63

Browse files
committed
Fix some unit tests for LLVM_ENABLE_EXPORTED_SYMBOLS_IN_EXECUTABLES=Off.
Building with -DLLVM_ENABLE_EXPORTED_SYMBOLS_IN_EXECUTABLES=Off should not prevent the PluginsTests and DynamicLibraryTests unit tests from working. This fix uses the approach implemented in #101741. rdar://135849875
1 parent d5f0969 commit 2e18f63

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

llvm/unittests/Passes/Plugins/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,9 @@ if (NOT WIN32 AND NOT CYGWIN)
66
set(LLVM_LINK_COMPONENTS Support Passes Core AsmParser)
77
add_llvm_unittest(PluginsTests
88
PluginsTest.cpp
9+
10+
EXPORT_SYMBOLS
911
)
10-
export_executable_symbols_for_plugins(PluginsTests)
1112
target_link_libraries(PluginsTests PRIVATE LLVMTestingSupport)
1213

1314
unset(LLVM_LINK_COMPONENTS)

llvm/unittests/Support/DynamicLibrary/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,10 @@ set_output_directory(DynamicLibraryLib
1717

1818
add_llvm_unittest(DynamicLibraryTests
1919
DynamicLibraryTest.cpp
20+
21+
EXPORT_SYMBOLS
2022
)
2123
target_link_libraries(DynamicLibraryTests PRIVATE DynamicLibraryLib)
22-
export_executable_symbols(DynamicLibraryTests)
2324

2425
function(dynlib_add_module NAME)
2526
add_library(${NAME} MODULE

0 commit comments

Comments
 (0)