bazel icon indicating copy to clipboard operation
bazel copied to clipboard

No matching toolchains found for types @bazel_tools//tools/cpp:toolchain_type.

Open rajhlinux opened this issue 3 years ago • 4 comments

Description of the bug:

ERROR: /usr/home/user/.cache/bazel/_bazel_user/dce2e5f5daa25516313b94e75e515765/external/com_google_protobuf/BUILD:515:10: While resolving toolchains for target @com_google_protobuf//:protoc: No matching toolchains found for types @bazel_tools//tools/cpp:toolchain_type. Maybe --incompatible_use_cc_configure_from_rules_cc has been flipped and there is no default C++ toolchain added in the WORKSPACE file? See https://github.com/bazelbuild/bazel/issues/10134 for details and migration instructions.

ERROR: Analysis of target '//mediapipe/examples/desktop/hello_world:hello_world' failed; build aborted: 

Pastebin to the error: https://pastebin.com/Cu57nw0b

screenshot

What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.

I followed the installation for c++:

$ bazel build --copt -DMESA_EGL_NO_X11_HEADERS --copt -DEGL_NO_X11 Then wanted to run c++ hello world example:

$ bazel run --copt -DMESA_EGL_NO_X11_HEADERS --copt -DEGL_NO_X11 mediapipe/examples/desktop/hello_world:hello_world

I get the error mentioned above.

Which operating system are you running Bazel on?

FreeBSD 13.1

What is the output of bazel info release?

release 5.3.0

If bazel info release returns development version or (@non-git), tell us how you built Bazel.

No response

What's the output of git remote get-url origin; git rev-parse master; git rev-parse HEAD ?

https://github.com/google/mediapipe.git
6cdc6443b6a7ed662744e2a2ce2d58d9c83e6d6f
6cdc6443b6a7ed662744e2a2ce2d58d9c83e6d6f

Have you found anything relevant by searching the web?

https://github.com/bazelbuild/bazel/issues/10134

Any other information, logs, or outputs that you want to share?

Pastebin to the error: https://pastebin.com/Cu57nw0b

I have an AMD Radeon RX 580 GPU and would like to use MediaPipe using my GPU for the examples.

rajhlinux avatar Sep 11 '22 04:09 rajhlinux

Hello @rajhlinux, Could you please confirm are you seeing the above issue with 5.3.0 ? Its resolved in 5.2.0. from this PR . Thanks!

sgowroji avatar Sep 12 '22 04:09 sgowroji

Hello @rajhlinux, Could you please respond to my above comments. Otherwise its hard to provide any resolution to your query. Thanks!

sgowroji avatar Sep 20 '22 05:09 sgowroji

@sgowroji I am seeing this same error on bazel 5.3.2

abetterbuilder avatar Mar 23 '23 16:03 abetterbuilder

Thank you for contributing to the Bazel repository! This issue has been marked as stale since it has not had any activity in the last 1+ years. It will be closed in the next 90 days unless any other activity occurs. If you think this issue is still relevant and should stay open, please post any comment here and the issue will no longer be marked as stale.

github-actions[bot] avatar May 27 '24 01:05 github-actions[bot]