Does cargo-multivers support producing static libraries? #12
-
cargo-multivers doesn't support producing multiple target CPU static libraries, correct? I'm building static libraries which are linked by another (non-Rust) codebase. Ideally, I'd like to have the linker grab the appropriately optimized version of the library. Presumably, though, cargo-multivers's outer binary wrapper is the one which determines the correct CPU and there's no way to pass this information to the linker, correct? Thank you for your time. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
You are correct, this is not supported. Yes, |
Beta Was this translation helpful? Give feedback.
-
Just in case, to make it more explicit I added an error message when running |
Beta Was this translation helpful? Give feedback.
You are correct, this is not supported.
Yes,
cargo multivers
binary wrapper (multivers-runner
) is the one determining at runtime the supported CPU features. Currently, the approach used by the wrapper cannot be used in the context of a library. A different approach needs to be implemented for it to work in such a context.I'm not working on this at the moment, so unless someone is motivated to do it, it will not be supported any time soon.