I accidentally took this discussion off-list. Here's some further
explanation of rust's versioning.
On 11/01/2011 10:23 AM, Brendan Eich wrote:
On Nov 1, 2011, at 10:16 AM, Brian Anderson wrote:
On 11/01/2011 10:04 AM, Brendan Eich wrote:
On Nov 1, 2011, at 8:52 AM, Patrick Walton wrote:
We recently renamed libstd.so to libruststd.so to avoid stomping on a libstd
that might exist in /usr/lib. Perhaps we should attack this in a more holistic
way: either (a) all Rust libraries should start with rust* or (b) Rust
libraries should install themselves into /usr/lib/rust.
The latter seems to be more common among language runtimes, but I'm not sure
if there are going to be library path issues on some systems if we go down that
route.
Let's find out. It seems much better to use the filesystem than mangle the
filenames.
Our envisioned (but unimplemented) library versioning scheme entailed
attaching sha-1's (of the types in the crate + metadata) to file names.
But also in metadata in the files? Names change and get (truly, as in
accidentally) mangled.
Sorry to be out of touch on this library versioning scheme. Sure, Linux has a
naming scheme that lacks crypto-hashes. Are we trying to improve that by making
names based on contents, instead of making up version numbers? How will the
user choose?
/be
The decision of which library to link is made solely by the metadata
within the libraries. The file naming scheme is to allow different
versions and configurations to live alongside each other in a way that
is OS-agnostic. The user doesn't choose what library they want by
filename - they specify some amount of metadata in their 'use'
statements and rustc picks the right crate to link.
To clarify, I looked up the proposed naming scheme and it's
'libname-hash-version.so' where the hash is a hash of the exported
metadata (type hashes don't come into play here).
_______________________________________________
Rust-dev mailing list
Rust-dev@mozilla.org
https://mail.mozilla.org/listinfo/rust-dev