1set(LLVM_LINK_COMPONENTS
2  Analysis
3  BitReader
4  BitWriter
5  Core
6  IPO
7  IRReader
8  InstCombine
9  Instrumentation
10  Linker
11  MC
12  ObjCARCOpts
13  Object
14  ProfileData
15  ScalarOpts
16  Support
17  Target
18  TransformUtils
19  )
20
21# In a standard Clang+LLVM build, we need to generate intrinsics before
22# building codegen. In a standalone build, LLVM is already built and we don't
23# need this dependency. Furthermore, LLVM doesn't export it so we can't have
24# this dependency.
25set(codegen_deps intrinsics_gen)
26if (CLANG_BUILT_STANDALONE)
27  set(codegen_deps)
28endif()
29
30add_clang_library(clangCodeGen
31  BackendUtil.cpp
32  CGAtomic.cpp
33  CGBlocks.cpp
34  CGBuiltin.cpp
35  CGCUDABuiltin.cpp
36  CGCUDANV.cpp
37  CGCUDARuntime.cpp
38  CGCXX.cpp
39  CGCXXABI.cpp
40  CGCall.cpp
41  CGClass.cpp
42  CGCleanup.cpp
43  CGDebugInfo.cpp
44  CGDecl.cpp
45  CGDeclCXX.cpp
46  CGException.cpp
47  CGExpr.cpp
48  CGExprAgg.cpp
49  CGExprCXX.cpp
50  CGExprComplex.cpp
51  CGExprConstant.cpp
52  CGExprScalar.cpp
53  CGLoopInfo.cpp
54  CGObjC.cpp
55  CGObjCGNU.cpp
56  CGObjCMac.cpp
57  CGObjCRuntime.cpp
58  CGOpenCLRuntime.cpp
59  CGOpenMPRuntime.cpp
60  CGOpenMPRuntimeNVPTX.cpp
61  CGRecordLayoutBuilder.cpp
62  CGStmt.cpp
63  CGStmtOpenMP.cpp
64  CGVTT.cpp
65  CGVTables.cpp
66  CodeGenABITypes.cpp
67  CodeGenAction.cpp
68  CodeGenFunction.cpp
69  CodeGenModule.cpp
70  CodeGenPGO.cpp
71  CodeGenTBAA.cpp
72  CodeGenTypes.cpp
73  CoverageMappingGen.cpp
74  ItaniumCXXABI.cpp
75  MicrosoftCXXABI.cpp
76  ModuleBuilder.cpp
77  ObjectFilePCHContainerOperations.cpp
78  SanitizerMetadata.cpp
79  SwiftCallingConv.cpp
80  TargetInfo.cpp
81
82  DEPENDS
83  ${codegen_deps}
84
85  LINK_LIBS
86  clangAST
87  clangBasic
88  clangFrontend
89  clangLex
90  )
91