Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Clang] Update Interpreter tests to use clang_target_link_libraries #110154

Merged
merged 1 commit into from
Oct 2, 2024

Conversation

fsfod
Copy link
Contributor

@fsfod fsfod commented Sep 26, 2024

This will fix duplicate and missing linker symbol errors when using CLANG_LINK_CLANG_DYLIB on windows and explicit visibility macros are used.
This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and plugins on window.

@llvmbot llvmbot added the clang Clang issues not falling into any other category label Sep 26, 2024
@llvmbot
Copy link
Member

llvmbot commented Sep 26, 2024

@llvm/pr-subscribers-clang

Author: Thomas Fransham (fsfod)

Changes

This will fix duplicate and missing linker symbol errors when using CLANG_LINK_CLANG_DYLIB on windows and explicit visibility macros are used.
This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and plugins on window.


Full diff: https://github.com/llvm/llvm-project/pull/110154.diff

1 Files Affected:

  • (modified) clang/unittests/Interpreter/CMakeLists.txt (+4-2)
diff --git a/clang/unittests/Interpreter/CMakeLists.txt b/clang/unittests/Interpreter/CMakeLists.txt
index ec6f81ea19b960..1ed1216c772e8f 100644
--- a/clang/unittests/Interpreter/CMakeLists.txt
+++ b/clang/unittests/Interpreter/CMakeLists.txt
@@ -16,13 +16,15 @@ add_clang_unittest(ClangReplInterpreterTests
 
   EXPORT_SYMBOLS
   )
-target_link_libraries(ClangReplInterpreterTests PUBLIC
+  
+target_link_libraries(ClangReplInterpreterTests PUBLIC LLVMTestingSupport)
+
+clang_target_link_libraries(ClangReplInterpreterTests PRIVATE
   clangAST
   clangBasic
   clangInterpreter
   clangFrontend
   clangSema
-  LLVMTestingSupport
   )
 
 # Exceptions on Windows are not yet supported.

Copy link
Contributor

@vgvassilev vgvassilev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@vgvassilev vgvassilev force-pushed the exported-api/interp-test-fix branch 3 times, most recently from 5658a27 to a9d8655 Compare September 27, 2024 09:00
@fsfod fsfod force-pushed the exported-api/interp-test-fix branch 2 times, most recently from 064bc85 to e58b244 Compare September 28, 2024 17:21
This will fix duplicate and missing linker symbol errors when using
CLANG_LINK_CLANG_DYLIB on windows and explicit visibility macros are used.
This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and plugins on window.
@vgvassilev vgvassilev force-pushed the exported-api/interp-test-fix branch from e58b244 to 23e9dc9 Compare September 29, 2024 13:16
@vgvassilev vgvassilev merged commit f0858bf into llvm:main Oct 2, 2024
8 checks passed
VitaNuo pushed a commit to VitaNuo/llvm-project that referenced this pull request Oct 2, 2024
…lvm#110154)

This will fix duplicate and missing linker symbol errors when using
CLANG_LINK_CLANG_DYLIB on windows and explicit visibility macros are
used.
This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and plugins on
window.
VitaNuo pushed a commit to VitaNuo/llvm-project that referenced this pull request Oct 2, 2024
…lvm#110154)

This will fix duplicate and missing linker symbol errors when using
CLANG_LINK_CLANG_DYLIB on windows and explicit visibility macros are
used.
This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and plugins on
window.
@fsfod fsfod deleted the exported-api/interp-test-fix branch October 2, 2024 14:46
Sterling-Augustine pushed a commit to Sterling-Augustine/llvm-project that referenced this pull request Oct 3, 2024
…lvm#110154)

This will fix duplicate and missing linker symbol errors when using
CLANG_LINK_CLANG_DYLIB on windows and explicit visibility macros are
used.
This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and plugins on
window.
xgupta pushed a commit to xgupta/llvm-project that referenced this pull request Oct 4, 2024
…lvm#110154)

This will fix duplicate and missing linker symbol errors when using
CLANG_LINK_CLANG_DYLIB on windows and explicit visibility macros are
used.
This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and plugins on
window.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang Clang issues not falling into any other category
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants