[Lldb-commits] [PATCH] D64823: [CMake] Default LLDB_PATH_TO_LLVM_BUILD to LLVM_DIR
Stefan Gränitz via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Wed Jul 17 05:03:06 PDT 2019
sgraenitz requested changes to this revision.
sgraenitz added a comment.
This revision now requires changes to proceed.
We shouldn't do the sole change here, but instead remove all `LLDB_PATH_TO_<xy>_BUILD` variables in favor of CMake standard `<package>_DIR` variables. Summarizing a discussion on this a while ago:
LLDB_PATH_TO_LLVM_BUILD used to be something like `/path/to/llvm-build-tree`
LLVM_DIR, however, is `/path/to/llvm-build-tree/lib/cmake/llvm`. Fine so far, but initializing..
LLDB_PATH_TO_CLANG_BUILD with the same value is incorrect, because it should be `/path/to/llvm-build-tree/lib/cmake/clang`!
In the past we also had (and downstream still have) things that would break, like:
set(CLANG_RESOURCE_PATH "${LLDB_PATH_TO_CLANG_BUILD}/lib${LLVM_LIBDIR_SUFFIX}/clang/${CLANG_VERSION}")
Fortunately most of it was cleaned up in the meantime. It looks like the only remaining blocker is the one below.
================
Comment at: lldb/cmake/modules/LLDBStandalone.cmake:45
if(CMAKE_CROSSCOMPILING)
set(LLVM_NATIVE_BUILD "${LLDB_PATH_TO_LLVM_BUILD}/NATIVE")
if (NOT EXISTS "${LLVM_NATIVE_BUILD}")
----------------
@xiaobai Can this be changed to something like `${LLVM_DIR}/../../../NATIVE`?
Repository:
rLLDB LLDB
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D64823/new/
https://reviews.llvm.org/D64823
More information about the lldb-commits
mailing list