4 ms·
All projects are independent and binaries are stored in "target" folder. It's a good thing. Even libs nominally same versions can have different source code and
by EugeneOZ 10y ago
All projects are independent and binaries are stored in "target" folder. It's a good thing. Even libs nominally same versions can have different source code and dependencies (because of "replace" or vendoring).
- pjmlp 10y agoNo, it is not a good thing. It is a waste of my development time that I could use for productive work. On other AOT compiled languages that I use at work, I can reuse binaries across projects, including the languages Rust intends to replace. It is a hard sell, if using Rust means having to spend more time compiling than even with C++ (specially now that modules are finally coming, at least for us with VC++).
- EugeneOZ 10y agoFor me is a good thing, because, as I explained, version number is not a guarantee.
- pjmlp 10y agoSo, than cargo needs to be improved so that there is a set of dependency values (name, version, rustc version, etc) that can guarantee the uniqueness of a binary library. To me it seems FOSS undervalues the value of binary libraries in the enterprise, or how they get used in many corporations or companies selling components. Rust improved safety is a good thing™, but not at the expense of continuously seeing the same libraries being compiled over and over, vs reusing binary artifacts across projects.
- EugeneOZ 10y agoCargo needs to be improved, here I agree :)
- p0nce 10y agodub (D build tool) support both of these locations. I can attest stuff gets reused.
- icebraining 10y agoIt doesn't have to use the version, it could hash the source, like ccache.