mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-17 14:06:39 +00:00

This pr relands https://github.com/llvm/llvm-project/pull/133302. It resolves two issues: - Linking error during build, [here](https://github.com/llvm/llvm-project/pull/133302#issuecomment-2767259848). There was a missing dependency for `clangLex` for the `ParseHLSLRootSignatureTest.cpp` unit testing. This library was added to the dependencies to resolve the error. It wasn't caught previously as the library was transitively linked in most build environments - Warning of unused declaration, [here](https://github.com/llvm/llvm-project/pull/133302#issuecomment-2767091368). There was a usability line in `LexHLSLRootSignature.h` of the form `using TokenKind = enum RootSignatureToken::Kind` which causes this error. The declaration is removed from the header file to be used locally in the `.cpp` files that use it. Notably, the original pr would also exposed `clang::hlsl::TokenKind` to everywhere it was included, which had a name clash with `tok::TokenKind`. This is another motivation to change to the proposed resolution. --------- Co-authored-by: Finn Plummer <finnplummer@microsoft.com>
39 lines
557 B
CMake
39 lines
557 B
CMake
set(LLVM_LINK_COMPONENTS
|
|
FrontendOpenMP
|
|
MC
|
|
MCParser
|
|
Support
|
|
TargetParser
|
|
)
|
|
|
|
add_clang_library(clangParse
|
|
ParseAST.cpp
|
|
ParseCXXInlineMethods.cpp
|
|
ParseDecl.cpp
|
|
ParseDeclCXX.cpp
|
|
ParseExpr.cpp
|
|
ParseExprCXX.cpp
|
|
ParseHLSL.cpp
|
|
ParseHLSLRootSignature.cpp
|
|
ParseInit.cpp
|
|
ParseObjc.cpp
|
|
ParseOpenMP.cpp
|
|
ParsePragma.cpp
|
|
ParseStmt.cpp
|
|
ParseStmtAsm.cpp
|
|
ParseTemplate.cpp
|
|
ParseTentative.cpp
|
|
Parser.cpp
|
|
ParseOpenACC.cpp
|
|
|
|
LINK_LIBS
|
|
clangAST
|
|
clangBasic
|
|
clangLex
|
|
clangSema
|
|
|
|
DEPENDS
|
|
omp_gen
|
|
ClangDriverOptions
|
|
)
|