haowei accepted this revision. haowei added a comment. This revision is now accepted and ready to land.
LGTM, but please wait @phosek to approve it. ================ Comment at: clang/cmake/caches/Fuchsia.cmake:167 +if(FUCHSIA_ENABLE_LLDB) + list(APPEND _FUCHSIA_ENABLE_PROJECTS lldb) +endif() ---------------- mysterymath wrote: > haowei wrote: > > You probably need a `string(REPLACE ";" "|" value > > "${_FUCHSIA_ENABLE_PROJECTS}")` after append a value. As by default cmake > > use `|` to separate items. > > But do you actually need a `_FUCHSIA_ENABLE_PROJECTS` variable, couldn't > > you just append `lldb` at the end of `LLVM_ENABLE_PROJECTS` here? > > You probably need a `string(REPLACE ";" "|" value > > "${_FUCHSIA_ENABLE_PROJECTS}")` after append a value. As by default cmake > > use `|` to separate items. > Hm? CMake's list separator is the semicolon: > https://cmake.org/cmake/help/latest/command/list.html > > > But do you actually need a `_FUCHSIA_ENABLE_PROJECTS` variable, couldn't > > you just append `lldb` at the end of `LLVM_ENABLE_PROJECTS` here? > `(list APPEND ...)` doesn't work on cache variables. If I were to use the > (set CACHE FORCE) idiom instead, it would append lldb each time a configure > occurs. The idea here is to have FUCHSIA_ENABLE_LLDB affect the defaults, but > to respect whatever's already in the CMake cache otherwise. > Hm? CMake's list separator is the semicolon: > https://cmake.org/cmake/help/latest/command/list.html > I see, I am wrong. I thought it is similar to passthrough cmake variables to the next stage. > (list APPEND ...) doesn't work on cache variables. If I were to use the (set > CACHE FORCE) idiom instead, it would append lldb each time a configure > occurs. The idea here is to have FUCHSIA_ENABLE_LLDB affect the defaults, but > to respect whatever's already in the CMake cache otherwise. I see. I didn't know that. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D145449/new/ https://reviews.llvm.org/D145449 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits