• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# NOTE: The tools are organized into groups of four consisting of one large and
2# three small executables. This is done to minimize memory load in parallel
3# builds.  Please retain this ordering.
4
5# If polly exists and is not disabled compile it and add it to the LLVM tools.
6option(LLVM_BUILD_POLLY "Compile polly" ON)
7if( EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/polly/CMakeLists.txt )
8  if (LLVM_BUILD_POLLY)
9    add_subdirectory( ${CMAKE_CURRENT_SOURCE_DIR}/polly)
10  endif (LLVM_BUILD_POLLY)
11endif( EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/polly/CMakeLists.txt )
12
13if( NOT WIN32 OR MSYS OR CYGWIN )
14  # It is useful to build llvm-config before the other tools, so we
15  # have a fresh LibDeps.txt for regenerating the hard-coded library
16  # dependencies. llvm-config/CMakeLists.txt takes care of this but we
17  # must keep llvm-config as the first entry on the list of tools to
18  # be built.
19  add_subdirectory(llvm-config)
20endif()
21
22add_subdirectory(opt)
23add_subdirectory(llvm-as)
24add_subdirectory(llvm-dis)
25add_subdirectory(llvm-mc)
26
27add_subdirectory(llc)
28add_subdirectory(llvm-ranlib)
29add_subdirectory(llvm-ar)
30add_subdirectory(llvm-nm)
31
32add_subdirectory(llvm-ld)
33add_subdirectory(llvm-prof)
34add_subdirectory(llvm-link)
35add_subdirectory(lli)
36
37add_subdirectory(llvm-extract)
38add_subdirectory(llvm-diff)
39add_subdirectory(macho-dump)
40add_subdirectory(llvm-objdump)
41add_subdirectory(llvm-rtdyld)
42
43add_subdirectory(bugpoint)
44add_subdirectory(bugpoint-passes)
45add_subdirectory(llvm-bcanalyzer)
46add_subdirectory(llvm-stub)
47add_subdirectory(edis)
48add_subdirectory(llvmc)
49
50if( NOT WIN32 )
51  add_subdirectory(lto)
52endif()
53
54if( LLVM_ENABLE_PIC )
55  # TODO: support other systems:
56  if( CMAKE_SYSTEM_NAME STREQUAL "Linux" )
57    add_subdirectory(gold)
58  endif()
59endif()
60
61if( EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/clang/CMakeLists.txt )
62  option(LLVM_BUILD_CLANG "Whether to build Clang as part of LLVM" ON)
63  if (${LLVM_BUILD_CLANG})
64    add_subdirectory( ${CMAKE_CURRENT_SOURCE_DIR}/clang )
65  endif()
66endif( EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/clang/CMakeLists.txt )
67
68set(LLVM_COMMON_DEPENDS ${LLVM_COMMON_DEPENDS} PARENT_SCOPE)
69