1set(LLVM_LINK_COMPONENTS
2  ${LLVM_TARGETS_TO_BUILD}
3  Analysis
4  BitWriter
5  CodeGen
6  Core
7  IPA
8  IPO
9  IRReader
10  InstCombine
11  Instrumentation
12  MC
13  ObjCARCOpts
14  ScalarOpts
15  Support
16  Target
17  TransformUtils
18  Vectorize
19  Passes
20  )
21
22# Support plugins.
23set(LLVM_NO_DEAD_STRIP 1)
24
25add_llvm_tool(opt
26  AnalysisWrappers.cpp
27  BreakpointPrinter.cpp
28  GraphPrinters.cpp
29  NewPMDriver.cpp
30  PassPrinters.cpp
31  PrintSCC.cpp
32  opt.cpp
33  )
34export_executable_symbols(opt)
35
36if(WITH_POLLY AND LINK_POLLY_INTO_TOOLS)
37  target_link_libraries(opt Polly)
38  if(POLLY_LINK_LIBS)
39    foreach(lib ${POLLY_LINK_LIBS})
40      target_link_libraries(opt ${lib})
41    endforeach(lib)
42  endif(POLLY_LINK_LIBS)
43endif(WITH_POLLY AND LINK_POLLY_INTO_TOOLS)
44