Open dmkurilov opened 1 year ago
I think this is just that the bzlmod MODULE.bazel file doesn't register the built ninja toolchain by default. You should be able to register the toolchain in your root MODULE.bazel file to work around this.
@jsharpe Sorry can you please provide some details on how to work around this ? I'm facing similar issue wherein a third-party ( libevent) which is a transitive dependency is being built using the cmake rule. But this complains about unable to find toolchain since I'm building this on OL8 arm64 docker running on Apple silicon.
third-party/rules_libevent/BUILD:26:6: While resolving toolchains for target //third-party/rules_libevent:event (47d3177): No matching toolchains found for types @@rules_foreign_cc~//toolchains:ninja_toolchain.
The problem
ninja's prebuilt binaries are available for a limited number of platforms.
For example, if you pick a linux_aarch64, you'll get an error:
How to reproduce
Please, take a look at https://github.com/bazelbuild/rules_foreign_cc/issues/1018, section "How to reproduce".
Expected behavour
ninja is built from source if there is no binary for a platform.