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  CGCUDANV.cpp
36  CGCUDARuntime.cpp
37  CGCXX.cpp
38  CGCXXABI.cpp
39  CGCall.cpp
40  CGClass.cpp
41  CGCleanup.cpp
42  CGDebugInfo.cpp
43  CGDecl.cpp
44  CGDeclCXX.cpp
45  CGException.cpp
46  CGExpr.cpp
47  CGExprAgg.cpp
48  CGExprCXX.cpp
49  CGExprComplex.cpp
50  CGExprConstant.cpp
51  CGExprScalar.cpp
52  CGLoopInfo.cpp
53  CGObjC.cpp
54  CGObjCGNU.cpp
55  CGObjCMac.cpp
56  CGObjCRuntime.cpp
57  CGOpenCLRuntime.cpp
58  CGOpenMPRuntime.cpp
59  CGRecordLayoutBuilder.cpp
60  CGStmt.cpp
61  CGStmtOpenMP.cpp
62  CGVTT.cpp
63  CGVTables.cpp
64  CodeGenABITypes.cpp
65  CodeGenAction.cpp
66  CodeGenFunction.cpp
67  CodeGenModule.cpp
68  CodeGenPGO.cpp
69  CodeGenTBAA.cpp
70  CodeGenTypes.cpp
71  CoverageMappingGen.cpp
72  ItaniumCXXABI.cpp
73  MicrosoftCXXABI.cpp
74  ModuleBuilder.cpp
75  ObjectFilePCHContainerOperations.cpp
76  SanitizerMetadata.cpp
77  TargetInfo.cpp
78
79  DEPENDS
80  ${codegen_deps}
81
82  LINK_LIBS
83  clangAST
84  clangBasic
85  clangFrontend
86  clangLex
87  )
88