Make crate hash stable and externally computable.
This replaces the link meta attributes with a pkgid attribute and uses a hash of this as the crate hash. This makes the crate hash computable by things other than the Rust compiler. It also switches the hash function ot SHA1 since that is much more likely to be available in shell, Python, etc than SipHash. Fixes #10188, #8523.
This commit is contained in:
parent
29ca4350c8
commit
b349036e5f
111 changed files with 1260 additions and 603 deletions
|
@ -43,6 +43,8 @@
|
|||
//!
|
||||
//! use std::prelude::*;
|
||||
|
||||
#[pkgid="std#0.9-pre"];
|
||||
// NOTE: remove after the next snapshot
|
||||
#[link(name = "std",
|
||||
package_id = "std",
|
||||
vers = "0.9-pre",
|
||||
|
@ -69,13 +71,13 @@
|
|||
// When testing libstd, bring in libuv as the I/O backend so tests can print
|
||||
// things and all of the std::io tests have an I/O interface to run on top
|
||||
// of
|
||||
#[cfg(test)] extern mod rustuv(vers = "0.9-pre");
|
||||
#[cfg(test)] extern mod rustuv = "rustuv#0.9-pre";
|
||||
|
||||
// Make extra accessible for benchmarking
|
||||
#[cfg(test)] extern mod extra(vers = "0.9-pre");
|
||||
#[cfg(test)] extern mod extra = "extra#0.9-pre";
|
||||
|
||||
// Make std testable by not duplicating lang items. See #2912
|
||||
#[cfg(test)] extern mod realstd(name = "std");
|
||||
#[cfg(test)] extern mod realstd = "std#0.9-pre";
|
||||
#[cfg(test)] pub use kinds = realstd::kinds;
|
||||
#[cfg(test)] pub use ops = realstd::ops;
|
||||
#[cfg(test)] pub use cmp = realstd::cmp;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue