rules_rust icon indicating copy to clipboard operation
rules_rust copied to clipboard

Remove failure when bindgen cc_lib does not contain static library

Open jwnrt opened this issue 1 year ago • 4 comments

I don't think this failure is required: it's fine to bindgen a library with only headers and no static library. Should this error instead be triggering when the cc_library has non-header files but isn't static?

Fixes #2704

jwnrt avatar Jul 15 '24 13:07 jwnrt

Thanks @jwnrt, the PR makes sense. Would you mind adding a separate example in examples/bindgen (for example a header that is used from both Rust and C++, and both libraries meet in a common binary) showing everything links together well?

hlopko avatar Jul 16 '24 08:07 hlopko

Sure, I've added an example, let me know if it matches what you expected EDIT: also rebased.

jwnrt avatar Jul 16 '24 10:07 jwnrt

Fixed those formatting problems (hopefully you folks don't mind me rebasing to keep the branch up to date)

jwnrt avatar Aug 14 '24 09:08 jwnrt

Friendly bump: this is ready for review again. We can apply this as a patch downstream, so no rush from me.

jwnrt avatar Sep 13 '24 18:09 jwnrt