This is an archive of the discontinued LLVM Phabricator instance.

build: with -DCLANGD_ENABLE_REMOTE=ON, search for grpc++ dependencies too
ClosedPublic

Authored by sylvestre.ledru on Jan 5 2023, 5:59 AM.

Diff Detail

Event Timeline

sylvestre.ledru created this revision.Jan 5 2023, 5:59 AM
Herald added a project: Restricted Project. · View Herald TranscriptJan 5 2023, 5:59 AM
sylvestre.ledru requested review of this revision.Jan 5 2023, 5:59 AM
cmake/Modules/FindGRPC.cmake
85

Shouldn't this be ${GPRC_OPTS}?

95

same here

100

and here?

add the missing {}

sylvestre.ledru marked 3 inline comments as done.Jan 5 2023, 6:39 AM
bmahjour removed a subscriber: bmahjour.Jan 5 2023, 6:44 AM

LGTM, assuming, you actually tested that locally.

This revision is now accepted and ready to land.Jan 10 2023, 11:51 AM
This revision was landed with ongoing or failed builds.Jan 10 2023, 12:02 PM
This revision was automatically updated to reflect the committed changes.
kadircet added inline comments.Jan 12 2023, 9:13 AM
clang/cmake/modules/AddGRPC.cmake
7

Hi @sylvestre.ledru this seem to have broken clangd bots (also doesn't work for local dev environment anymore) https://lab.llvm.org/buildbot/#/builders/131/builds/38935 (buildbot was broken before that for a different reason).

I believe the issue is because you're looking for gpr/grpc only in the absence of target grpc++, but in other setups, e.g. the one used by buildbot and the only one supported in theory, that uses grpc build from sources. You can find a repro setup in details here https://github.com/clangd/clangd/blob/master/.github/workflows/autobuild.yaml#L206. Required configuration for LLVM looks like:
cmake -G Ninja ../llvm/ -DCMAKE_BUILD_TYPE=RELEASE -DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra" -DCLANGD_ENABLE_REMOTE=1 -DGRPC_INSTALL_PATH=$HOME/.local (assuming you run grpc installation to $HOME/.local).

I'll revert to unblock development (and to be able to investigate the other issue on the build bot).

thanks. reverting is fine :)