forked from OSchip/llvm-project
[CMake] Deprecate CLANG_RUNTIME_OUTPUT_INTDIR and CLANG_LIBRARY_OUTPUT_INTDIR.
LLVM_*_OUTPUT_INTDIR should be available everywhere. It was my mistake when I introduced INTDIR stuff. llvm-svn: 199597
This commit is contained in:
parent
ee13ed8dbb
commit
c28a9a2c33
|
@ -13,7 +13,7 @@ else ()
|
|||
set(LLVM_BUILD_MODE "%(build_mode)s")
|
||||
endif ()
|
||||
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${LLVM_BUILD_MODE} CLANG_TOOLS_DIR ${CLANG_RUNTIME_OUTPUT_INTDIR})
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${LLVM_BUILD_MODE} CLANG_TOOLS_DIR ${LLVM_RUNTIME_OUTPUT_INTDIR})
|
||||
|
||||
configure_lit_site_cfg(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.in
|
||||
|
|
|
@ -178,9 +178,6 @@ set(CLANG_VENDOR_UTI "org.llvm.clang" CACHE STRING
|
|||
set(CLANG_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR})
|
||||
set(CLANG_BINARY_DIR ${CMAKE_CURRENT_BINARY_DIR})
|
||||
|
||||
set(CLANG_RUNTIME_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/bin)
|
||||
set(CLANG_LIBRARY_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/lib)
|
||||
|
||||
if( CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR AND NOT MSVC_IDE )
|
||||
message(FATAL_ERROR "In-source builds are not allowed. CMake would overwrite "
|
||||
"the makefiles distributed with LLVM. Please create a directory and run cmake "
|
||||
|
@ -310,7 +307,7 @@ macro(add_clang_library name)
|
|||
endif()
|
||||
add_library( ${name} ${libkind} ${srcs} )
|
||||
add_dead_strip( ${name} )
|
||||
set_output_directory(${name} ${CLANG_RUNTIME_OUTPUT_INTDIR} ${CLANG_LIBRARY_OUTPUT_INTDIR})
|
||||
set_output_directory(${name} ${LLVM_RUNTIME_OUTPUT_INTDIR} ${LLVM_LIBRARY_OUTPUT_INTDIR})
|
||||
if( LLVM_COMMON_DEPENDS )
|
||||
add_dependencies( ${name} ${LLVM_COMMON_DEPENDS} )
|
||||
endif( LLVM_COMMON_DEPENDS )
|
||||
|
@ -340,7 +337,6 @@ endmacro(add_clang_library)
|
|||
macro(add_clang_executable name)
|
||||
add_llvm_executable( ${name} ${ARGN} )
|
||||
set_target_properties(${name} PROPERTIES FOLDER "Clang executables")
|
||||
set_output_directory(${name} ${CLANG_RUNTIME_OUTPUT_INTDIR} ${CLANG_LIBRARY_OUTPUT_INTDIR})
|
||||
endmacro(add_clang_executable)
|
||||
|
||||
include_directories(BEFORE
|
||||
|
|
|
@ -47,7 +47,7 @@ set(files
|
|||
module.map
|
||||
)
|
||||
|
||||
set(output_dir ${CLANG_LIBRARY_OUTPUT_INTDIR}/clang/${CLANG_VERSION}/include)
|
||||
set(output_dir ${LLVM_LIBRARY_OUTPUT_INTDIR}/clang/${CLANG_VERSION}/include)
|
||||
|
||||
# Generate arm_neon.h
|
||||
clang_tablegen(arm_neon.h -gen-arm-neon
|
||||
|
|
|
@ -7,7 +7,7 @@ else ()
|
|||
set(LLVM_BUILD_MODE "%(build_mode)s")
|
||||
endif ()
|
||||
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${LLVM_BUILD_MODE} CLANG_TOOLS_DIR ${CLANG_RUNTIME_OUTPUT_INTDIR})
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${LLVM_BUILD_MODE} CLANG_TOOLS_DIR ${LLVM_RUNTIME_OUTPUT_INTDIR})
|
||||
|
||||
configure_lit_site_cfg(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.in
|
||||
|
|
|
@ -64,23 +64,23 @@ if(UNIX)
|
|||
set(clang_binary "clang${CMAKE_EXECUTABLE_SUFFIX}")
|
||||
else()
|
||||
set(CLANGXX_LINK_OR_COPY copy)
|
||||
set(clang_binary "${CLANG_RUNTIME_OUTPUT_INTDIR}/clang${CMAKE_EXECUTABLE_SUFFIX}")
|
||||
set(clang_binary "${LLVM_RUNTIME_OUTPUT_INTDIR}/clang${CMAKE_EXECUTABLE_SUFFIX}")
|
||||
endif()
|
||||
|
||||
# Create the clang++ symlink in the build directory.
|
||||
set(clang_pp "${CLANG_RUNTIME_OUTPUT_INTDIR}/clang++${CMAKE_EXECUTABLE_SUFFIX}")
|
||||
set(clang_pp "${LLVM_RUNTIME_OUTPUT_INTDIR}/clang++${CMAKE_EXECUTABLE_SUFFIX}")
|
||||
add_custom_command(TARGET clang POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E ${CLANGXX_LINK_OR_COPY} "${clang_binary}" "${clang_pp}"
|
||||
WORKING_DIRECTORY "${CLANG_RUNTIME_OUTPUT_INTDIR}")
|
||||
WORKING_DIRECTORY "${LLVM_RUNTIME_OUTPUT_INTDIR}")
|
||||
|
||||
set_property(DIRECTORY APPEND
|
||||
PROPERTY ADDITIONAL_MAKE_CLEAN_FILES ${clang_pp})
|
||||
|
||||
# Create the clang-cl symlink in the build directory.
|
||||
set(clang_cl "${CLANG_RUNTIME_OUTPUT_INTDIR}/clang-cl${CMAKE_EXECUTABLE_SUFFIX}")
|
||||
set(clang_cl "${LLVM_RUNTIME_OUTPUT_INTDIR}/clang-cl${CMAKE_EXECUTABLE_SUFFIX}")
|
||||
add_custom_command(TARGET clang POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E ${CLANGXX_LINK_OR_COPY} "${clang_binary}" "${clang_cl}"
|
||||
WORKING_DIRECTORY "${CLANG_RUNTIME_OUTPUT_INTDIR}")
|
||||
WORKING_DIRECTORY "${LLVM_RUNTIME_OUTPUT_INTDIR}")
|
||||
|
||||
set_property(DIRECTORY APPEND
|
||||
PROPERTY ADDITIONAL_MAKE_CLEAN_FILES ${clang_cl})
|
||||
|
|
|
@ -11,4 +11,3 @@ add_tablegen(clang-tblgen CLANG
|
|||
NeonEmitter.cpp
|
||||
TableGen.cpp
|
||||
)
|
||||
set_output_directory(clang-tblgen ${CLANG_RUNTIME_OUTPUT_INTDIR} ${CLANG_LIBRARY_OUTPUT_INTDIR})
|
||||
|
|
Loading…
Reference in New Issue