[PATCH] D126308: cmake: use llvm dir variables for clang/utils/hmaptool

Matheus Izvekov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon May 30 04:27:20 PDT 2022


mizvekov added a comment.

In D126308#3545410 <https://reviews.llvm.org/D126308#3545410>, @nikic wrote:

> It looks like this change breaks the standalone build for clang. From what I can see, while LLVM_TOOLS_BINARY_DIR and LLVM_TOOLS_INSTALL_DIR are exported in llvm/cmake/modules/LLVMConfig.cmake.in, LLVM_UTILS_INSTALL_DIR is not, resulting in an "install PROGRAMS given no DESTINATION" error. Presumably we either need to export that variable, or it's not intended to be used outside LLVM.

Interesting, had not realized we need to export them for standalone builds.

llvm/cmake/modules/AddLLVM.cmake exports a macro `add_llvm_utility` that uses this variable, and this file included from clang CMakeLists.

Since this macro would not be usable without this variable, then either add_llvm_utility is not intended to be exported, or it's intended and it was an oversight to not export LLVM_UTILS_INSTALL_DIR .


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D126308/new/

https://reviews.llvm.org/D126308



More information about the cfe-commits mailing list