This revision was automatically updated to reflect the committed changes. Closed by commit rG6c6c4f6a9b3e: [CMake] Support passing arguments to build tool (bootstrap). (authored by CarlosAlbertoEnciso).
Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131665/new/ https://reviews.llvm.org/D131665 Files: clang/CMakeLists.txt Index: clang/CMakeLists.txt =================================================================== --- clang/CMakeLists.txt +++ clang/CMakeLists.txt @@ -787,6 +787,14 @@ endif() endforeach() + # Build arguments for native tool used in CMake. + set(build_configuration "$<CONFIG>") + set(build_tool_args "${LLVM_EXTERNAL_PROJECT_BUILD_TOOL_ARGS}") + if(NOT build_tool_args STREQUAL "") + string(PREPEND build_tool_args "-- ") + separate_arguments(build_tool_args UNIX_COMMAND "${build_tool_args}") + endif() + ExternalProject_Add(${NEXT_CLANG_STAGE} DEPENDS clang-bootstrap-deps PREFIX ${NEXT_CLANG_STAGE} @@ -809,6 +817,9 @@ ${${CLANG_STAGE}_RANLIB} ${${CLANG_STAGE}_OBJCOPY} ${${CLANG_STAGE}_STRIP} + BUILD_COMMAND ${CMAKE_COMMAND} --build ${BINARY_DIR} + --config ${build_configuration} + ${build_tool_args} INSTALL_COMMAND "" STEP_TARGETS configure build USES_TERMINAL_CONFIGURE 1
Index: clang/CMakeLists.txt =================================================================== --- clang/CMakeLists.txt +++ clang/CMakeLists.txt @@ -787,6 +787,14 @@ endif() endforeach() + # Build arguments for native tool used in CMake. + set(build_configuration "$<CONFIG>") + set(build_tool_args "${LLVM_EXTERNAL_PROJECT_BUILD_TOOL_ARGS}") + if(NOT build_tool_args STREQUAL "") + string(PREPEND build_tool_args "-- ") + separate_arguments(build_tool_args UNIX_COMMAND "${build_tool_args}") + endif() + ExternalProject_Add(${NEXT_CLANG_STAGE} DEPENDS clang-bootstrap-deps PREFIX ${NEXT_CLANG_STAGE} @@ -809,6 +817,9 @@ ${${CLANG_STAGE}_RANLIB} ${${CLANG_STAGE}_OBJCOPY} ${${CLANG_STAGE}_STRIP} + BUILD_COMMAND ${CMAKE_COMMAND} --build ${BINARY_DIR} + --config ${build_configuration} + ${build_tool_args} INSTALL_COMMAND "" STEP_TARGETS configure build USES_TERMINAL_CONFIGURE 1
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits