File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed
clang/unittests/Interpreter Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -49,6 +49,11 @@ add_distinct_clang_unittest(ClangReplInterpreterTests
49
49
)
50
50
51
51
if (EMSCRIPTEN )
52
+ # Without the above you try to link to LLVMSupport twice, and end
53
+ # up with a duplicate symbol error when creating the main module
54
+ get_target_property (LINKED_LIBS ClangReplInterpreterTests LINK_LIBRARIES )
55
+ list (REMOVE_ITEM LINKED_LIBS LLVMSupport )
56
+ set_target_properties (ClangReplInterpreterTests PROPERTIES LINK_LIBRARIES "${LINKED_LIBS} " )
52
57
target_link_options (ClangReplInterpreterTests
53
58
PUBLIC "SHELL: -s MAIN_MODULE=1"
54
59
PUBLIC "SHELL: -s ALLOW_MEMORY_GROWTH=1"
Original file line number Diff line number Diff line change @@ -1764,9 +1764,7 @@ function(add_unittest test_suite test_name)
1764
1764
set(LLVM_REQUIRES_RTTI OFF)
1765
1765
endif()
1766
1766
1767
- if(NOT EMSCRIPTEN)
1768
- list(APPEND LLVM_LINK_COMPONENTS Support) # gtest needs it for raw_ostream
1769
- endif()
1767
+ list(APPEND LLVM_LINK_COMPONENTS Support) # gtest needs it for raw_ostream
1770
1768
add_llvm_executable(${test_name} IGNORE_EXTERNALIZE_DEBUGINFO NO_INSTALL_RPATH ${ARGN} )
1771
1769
get_subproject_title(subproject_title)
1772
1770
set_target_properties(${test_name} PROPERTIES FOLDER " ${subproject_title} /Tests/Unit ")
You can’t perform that action at this time.
0 commit comments