bindgen: Pass `-resource-dir` Clang flag to bindgen-cli. (#3591) For some cc_toolchain configurations, this is required to find the builtin headers. So far, the bindgen rules had assumed that the builtin headers can be found through `cc_toolchain.built_in_include_directories`. This is, however, not guaranteed to be the case; indeed, `built_in_include_directories` is not really intended for finding builtin headers but merely for filtering out diagnostics in builtin headers. Clang itself finds the resource directory relative to its own binary, and then finds the builtin headers in the "include" subdirectory of the resource directory. bindgen-cli may, however, be located in a different directory than Clang, so we pass a `-resource-dir` flag on the command line.
This repository provides rules for building Rust projects with Bazel.
General discussions and announcements take place in the GitHub Discussions, but there are additional places where community members gather to discuss rules_rust.
Please refer to the full documentation.