fix polly buildbot
[oota-llvm.git] / tools / CMakeLists.txt
1 add_llvm_tool_subdirectory(llvm-config)
2
3 add_llvm_tool_subdirectory(opt)
4 add_llvm_tool_subdirectory(llvm-as)
5 add_llvm_tool_subdirectory(llvm-dis)
6 add_llvm_tool_subdirectory(llvm-mc)
7
8 add_llvm_tool_subdirectory(llc)
9 add_llvm_tool_subdirectory(llvm-ar)
10 add_llvm_tool_subdirectory(llvm-nm)
11 add_llvm_tool_subdirectory(llvm-size)
12
13 add_llvm_tool_subdirectory(llvm-cov)
14 add_llvm_tool_subdirectory(llvm-profdata)
15 add_llvm_tool_subdirectory(llvm-link)
16 add_llvm_tool_subdirectory(lli)
17
18 add_llvm_tool_subdirectory(llvm-extract)
19 add_llvm_tool_subdirectory(llvm-diff)
20 add_llvm_tool_subdirectory(macho-dump)
21 add_llvm_tool_subdirectory(llvm-objdump)
22 add_llvm_tool_subdirectory(llvm-readobj)
23 add_llvm_tool_subdirectory(llvm-rtdyld)
24 add_llvm_tool_subdirectory(llvm-dwarfdump)
25 if( LLVM_USE_INTEL_JITEVENTS )
26   add_llvm_tool_subdirectory(llvm-jitlistener)
27 else()
28   ignore_llvm_tool_subdirectory(llvm-jitlistener)
29 endif( LLVM_USE_INTEL_JITEVENTS )
30
31 add_llvm_tool_subdirectory(bugpoint)
32 add_llvm_tool_subdirectory(bugpoint-passes)
33 add_llvm_tool_subdirectory(llvm-bcanalyzer)
34 add_llvm_tool_subdirectory(llvm-stress)
35 add_llvm_tool_subdirectory(llvm-mcmarkup)
36
37 add_llvm_tool_subdirectory(llvm-symbolizer)
38
39 add_llvm_tool_subdirectory(llvm-c-test)
40
41 add_llvm_tool_subdirectory(obj2yaml)
42 add_llvm_tool_subdirectory(yaml2obj)
43
44 if( NOT CYGWIN )
45   add_llvm_tool_subdirectory(lto)
46   add_llvm_tool_subdirectory(llvm-lto)
47 else()
48   ignore_llvm_tool_subdirectory(lto)
49   ignore_llvm_tool_subdirectory(llvm-lto)
50 endif()
51
52 if( LLVM_ENABLE_PIC )
53   # TODO: support other systems:
54   if( (CMAKE_SYSTEM_NAME STREQUAL "Linux")
55       OR (CMAKE_SYSTEM_NAME STREQUAL "FreeBSD") )
56     add_llvm_tool_subdirectory(gold)
57   else()
58     ignore_llvm_tool_subdirectory(gold)
59   endif()
60 else()
61   ignore_llvm_tool_subdirectory(gold)
62 endif()
63
64 add_llvm_external_project(clang)
65
66 if( NOT LLVM_INCLUDE_TOOLS STREQUAL "bootstrap-only" )
67   add_llvm_external_project(lld)
68   add_llvm_external_project(lldb)
69
70   if(WITH_POLLY)
71     add_llvm_external_project(polly)
72   else(WITH_POLLY)
73     list(APPEND LLVM_IMPLICIT_PROJECT_IGNORE "${LLVM_MAIN_SRC_DIR}/tools/polly")
74   endif(WITH_POLLY)
75
76   # Automatically add remaining sub-directories containing a 'CMakeLists.txt'
77   # file as external projects.
78   add_llvm_implicit_external_projects()
79 endif()
80
81 set(LLVM_COMMON_DEPENDS ${LLVM_COMMON_DEPENDS} PARENT_SCOPE)