fix PR13550: add a cmake WITH_POLLY option

llvm-svn: 203486
This commit is contained in:
Sebastian Pop 2014-03-10 20:47:39 +00:00
parent d47a5c2d3f
commit e3cd1429e5
2 changed files with 12 additions and 1 deletions

View File

@ -565,3 +565,9 @@ if (NOT LLVM_INSTALL_TOOLCHAIN_ONLY)
)
endif()
option(WITH_POLLY "Build LLVM with Polly" ON)
if(WITH_POLLY)
if(NOT EXISTS ${LLVM_MAIN_SRC_DIR}/tools/polly/CMakeLists.txt)
set(WITH_POLLY OFF)
endif()
endif(WITH_POLLY)

View File

@ -66,7 +66,12 @@ add_llvm_external_project(clang)
if( NOT LLVM_INCLUDE_TOOLS STREQUAL "bootstrap-only" )
add_llvm_external_project(lld)
add_llvm_external_project(lldb)
add_llvm_external_project(polly)
if(WITH_POLLY)
add_llvm_external_project(polly)
else(WITH_POLLY)
list(APPEND LLVM_IMPLICIT_PROJECT_IGNORE "${CMAKE_CURRENT_SOURCE_DIR}/polly")
endif(WITH_POLLY)
# Automatically add remaining sub-directories containing a 'CMakeLists.txt'
# file as external projects.