Reverting "CMake: Don't include tools, unittets, or examples as

available targets unless LLVM_INCLUDE_X is ON. LLVM_BUILD_X implies
LLVM_INCLUDE_X"

It breaks the configuration phase when cmake is invoked without
parameters, it is too complex for the purpose and introduces an
incovenience for the user (as both LLVM_BUILD_X and LLVM_INCLUDE_X
must set to OFF for not including X on the build)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@114795 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Oscar Fuentes
2010-09-25 20:25:25 +00:00
parent 207f8f688b
commit 066de857f8
4 changed files with 14 additions and 28 deletions

View File

@@ -77,9 +77,7 @@ macro(add_llvm_tool name)
if( NOT LLVM_BUILD_TOOLS )
set(EXCLUDE_FROM_ALL ON)
endif()
if( LLVM_INCLUDE_TOOLS OR LLVM_BUILD_TOOLS )
add_llvm_executable(${name} ${ARGN})
endif()
add_llvm_executable(${name} ${ARGN})
if( LLVM_BUILD_TOOLS )
install(TARGETS ${name} RUNTIME DESTINATION bin)
endif()
@@ -91,9 +89,7 @@ macro(add_llvm_example name)
if( NOT LLVM_BUILD_EXAMPLES )
set(EXCLUDE_FROM_ALL ON)
endif()
if( LLVM_INCLUDE_EXAMPLES OR LLVM_BUILD_EXAMPLES )
add_llvm_executable(${name} ${ARGN})
endif()
add_llvm_executable(${name} ${ARGN})
if( LLVM_BUILD_EXAMPLES )
install(TARGETS ${name} RUNTIME DESTINATION examples)
endif()