bazelbuild / bazelbuild/rules_rust
rust_bindgen should not require a static library
- Dominant language
- Starlark
- Stars
- 843
- Forks
- 651
- Avg merge
- 2d 18h
- Merged PRs (30d)
- 15
Description
`rust_bindgen` currently asserts that the cc_lib has an associated static library to link: https://github.com/bazelbuild/rules_rust/blob/main/bindgen/private/bindgen.bzl#L140. This is problematic for use cases where this cannot be satisfied.
Example use cases:
* 3rd party vendor provides a pre-compiled shared object and header only (used via cc_library + cc_import)
* generating rust constants from a header file without any code to link to
Ideally rust_bindgen should just be a code generator that does not impose any additional requirements not needed by bindgen itself, or a separate un-opinionated interoperable code generation rule should be provided.
Contributor guide
Assessment
This issue has not been assessed yet.