Search code examples
bazel

Error while building Bazel 0.5.3 on ppc64le


I'm trying to build bazel 0.5.3 on Ubuntu 16.04, Linux ppc64le. I want to know the required PROTOC and GRPC_JAVA_PLUGIN versions for bazel 0.5.3. With protoc 3.2.0 and grpc-java 1.0.0, I'm getting below error-

./compile.sh

INFO: You can skip this first step by providing a path to the bazel binary as second argument: INFO: ./compile.sh compile /path/to/bazel 🍃 Building Bazel from scratch./opt/DL/protobuf/bin/protoc -Isrc/main/protobuf/ -Isrc/main/java/com/google/devtools/build/lib/buildeventstream/proto/ --java_out=/tmp/bazel_ltKtch3G/src --plugin=protoc-gen-grpc=/pkgbuild/bazel/protoc-gen-grpc-java --grpc_out=/tmp/bazel_ltKtch3G/src src/main/java/com/google/devtools/build/lib/buildeventstream/proto/build_event_stream.proto src/main/protobuf/invocation_policy.proto: File not found. build_event_stream.proto: Import "src/main/protobuf/invocation_policy.proto" was not found or had errors. build_event_stream.proto:261:3: "blaze.invocation_policy.InvocationPolicy" is not defined.

I think it is because of incompatible protoc/grpc-java version. Kindly help me on this. Thanks in advance, Nishidha


Solution

  • You can check the versions here:

    https://github.com/bazelbuild/bazel/tree/0.5.3/third_party/protobuf https://github.com/bazelbuild/bazel/tree/0.5.3/third_party/grpc

    So it seems Bazel 0.5.3 depends on grpc 1.3.0 and protobuf 3.2.0.

    Just to make sure, you did download the distribution archive, right? compile.sh doesn't work with cloned git repo.

    FYI, you can also try Bazel 0.5.4 as it was released recently.