[libc] Switch to using the generic `<gpuintrin.h>` implementations (#121810)
[llvm-project.git] / clang / unittests / Interpreter / CMakeLists.txt
blob95378f9cfe73703aaf86e9088e8d3f9a4e5178f1
1 set(LLVM_LINK_COMPONENTS
2   ${LLVM_TARGETS_TO_BUILD}
3   Core
4   MC
5   OrcJIT
6   Support
7   TargetParser
8   )
10 add_clang_unittest(ClangReplInterpreterTests
11   IncrementalCompilerBuilderTest.cpp
12   IncrementalProcessingTest.cpp
13   InterpreterTest.cpp
14   InterpreterExtensionsTest.cpp
15   CodeCompletionTest.cpp
17   EXPORT_SYMBOLS
18   )
19   
20 target_link_libraries(ClangReplInterpreterTests PUBLIC LLVMTestingSupport)
22 clang_target_link_libraries(ClangReplInterpreterTests PRIVATE
23   clangAST
24   clangBasic
25   clangInterpreter
26   clangFrontend
27   clangSema
28   )
30 # Exceptions on Windows are not yet supported.
31 if(NOT WIN32)
32   add_subdirectory(ExceptionTests)
33 endif()
35 if(MSVC)
36   set_target_properties(ClangReplInterpreterTests PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS 1)
38   # RTTI/C++ symbols
39   set(ClangReplInterpreterTests_exports ${ClangReplInterpreterTests_exports} ??_7type_info@@6B@
40     ?__type_info_root_node@@3U__type_info_node@@A
41     ?nothrow@std@@3Unothrow_t@1@B
42   )
44   # Compiler added symbols for static variables. NOT for VStudio < 2015
45   set(ClangReplInterpreterTests_exports ${ClangReplInterpreterTests_exports} _Init_thread_abort _Init_thread_epoch
46     _Init_thread_footer _Init_thread_header _tls_index
47   )
49   if(CMAKE_SIZEOF_VOID_P EQUAL 8)
50     # new/delete variants needed when linking to static msvc runtime (esp. Debug)
51     set(ClangReplInterpreterTests_exports ${ClangReplInterpreterTests_exports}
52       ??2@YAPEAX_K@Z
53       ??3@YAXPEAX@Z
54       ??_U@YAPEAX_K@Z
55       ??_V@YAXPEAX@Z
56       ??3@YAXPEAX_K@Z
57     )
58   else()
59     set(ClangReplInterpreterTests_exports ${ClangReplInterpreterTests_exports}
60       ??2@YAPAXI@Z
61       ??3@YAXPAX@Z
62       ??3@YAXPAXI@Z
63       ??_U@YAPAXI@Z
64       ??_V@YAXPAX@Z
65       ??_V@YAXPAXI@Z
66     )
67   endif()
69   # List to '/EXPORT:sym0 /EXPORT:sym1 /EXPORT:sym2 ...'
70   list(TRANSFORM ClangReplInterpreterTests_exports PREPEND "LINKER:/EXPORT:")
71   set_property(TARGET ClangReplInterpreterTests APPEND PROPERTY LINK_OPTIONS ${ClangReplInterpreterTests_exports})
73 endif(MSVC)