tikv/grpc-rs

Unable to compile w/ prost-codec, missing proto files in grpcio-sys directory?

rdaum opened this issue · 3 comments

Fails in build.rs phase for grpcio-sys

Tried with both Rust 1.76.0 and 1.68.2:

(Trying to compile with no SSL implementation (intranet) if that means anything, but it seems to fail in the same way with with openssl as well.)

Dep:

grpcio = { version = "0.13.0", default-features = false, features = ["prost-codec"] }

Failure:

  CMake Warning at third_party/abseil-cpp/CMakeLists.txt:72 (message):
    A future Abseil release will default ABSL_PROPAGATE_CXX_STD to ON for CMake
    3.8 and up.  We recommend enabling this option to ensure your project still
    builds correctly.


  CMake Warning at cmake/protobuf.cmake:51 (message):
    gRPC_PROTOBUF_PROVIDER is "module" but PROTOBUF_ROOT_DIR is wrong
  Call Stack (most recent call first):
    CMakeLists.txt:322 (include)


  CMake Warning at cmake/ssl.cmake:55 (message):
    gRPC_SSL_PROVIDER is "module" but BORINGSSL_ROOT_DIR is wrong
  Call Stack (most recent call first):
    CMakeLists.txt:324 (include)


  CMake Error at CMakeLists.txt:501 (file):
    file COPY cannot find
    "/home/ryan/.cargo/registry/src/source.raven.engineering-ee1dc3c3c2b9f46d/grpcio-sys-0.13.0+1.56.2-patched/grpc/test/core/event_engine/fuzzing_event_engine/fuzzing_event_engine.proto":
    No such file or directory.
  Call Stack (most recent call first):
    CMakeLists.txt:771 (protobuf_generate_grpc_cpp_with_import_path_correction)


  CMake Error at CMakeLists.txt:501 (file):
    file COPY cannot find
    "/home/ryan/.cargo/registry/src/source.raven.engineering-ee1dc3c3c2b9f46d/grpcio-sys-0.13.0+1.56.2-patched/grpc/test/core/tsi/alts/fake_handshaker/handshaker.proto":
    No such file or directory.
  Call Stack (most recent call first):
    CMakeLists.txt:774 (protobuf_generate_grpc_cpp_with_import_path_correction)


  CMake Error at CMakeLists.txt:501 (file):
    file COPY cannot find
    "/home/ryan/.cargo/registry/src/source.raven.engineering-ee1dc3c3c2b9f46d/grpcio-sys-0.13.0+1.56.2-patched/grpc/test/core/tsi/alts/fake_handshaker/transport_security_common.proto":
    No such file or directory.
  Call Stack (most recent call first):
    CMakeLists.txt:777 (protobuf_generate_grpc_cpp_with_import_path_correction)


  thread 'main' panicked at '
  command did not execute successfully, got: exit status: 1

  build script failed, must exit now', /home/ryan/.cargo/registry/src/source.raven.engineering-ee1dc3c3c2b9f46d/cmake-0.1.50/src/lib.rs:1098:5
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Looks like the cmake build is looking for these artifacts under e.g. grpc/test/core/tsi/alts/fake_handshaker/handshaker.proto

but in my directory they live at e.g. grpc/src/core/tsi/alts/handshaker/proto/handshaker.proto

and some aren't there at all (e.g. fuzzing_event_engine.proto)

Building with a git = or path = dependency instead of version from crates.io works fine, so something odd about the published 0.13.0 or the grpc-sys crate maybe?

I can't reproduce the error on both MacOS and CentOS. Can you provide a minimal reproduce repo?