mirror of
https://github.com/rust-lang/cargo.git
synced 2025-10-01 11:30:39 +00:00
Fix libraries paths following upstream
This commit is contained in:
parent
0d79ba656c
commit
769ac7cc91
@ -46,7 +46,7 @@ pub fn resolve_std<'cfg>(
|
|||||||
let patches = to_patch
|
let patches = to_patch
|
||||||
.iter()
|
.iter()
|
||||||
.map(|&name| {
|
.map(|&name| {
|
||||||
let source_path = SourceId::for_path(&src_path.join("src").join("tools").join(name))?;
|
let source_path = SourceId::for_path(&src_path.join("library").join(name))?;
|
||||||
let dep = Dependency::parse_no_deprecated(name, None, source_path)?;
|
let dep = Dependency::parse_no_deprecated(name, None, source_path)?;
|
||||||
Ok(dep)
|
Ok(dep)
|
||||||
})
|
})
|
||||||
@ -55,10 +55,10 @@ pub fn resolve_std<'cfg>(
|
|||||||
let mut patch = HashMap::new();
|
let mut patch = HashMap::new();
|
||||||
patch.insert(crates_io_url, patches);
|
patch.insert(crates_io_url, patches);
|
||||||
let members = vec![
|
let members = vec![
|
||||||
String::from("src/libstd"),
|
String::from("library/std"),
|
||||||
String::from("src/libcore"),
|
String::from("library/core"),
|
||||||
String::from("src/liballoc"),
|
String::from("library/alloc"),
|
||||||
String::from("src/libtest"),
|
String::from("library/test"),
|
||||||
];
|
];
|
||||||
let ws_config = crate::core::WorkspaceConfig::Root(crate::core::WorkspaceRootConfig::new(
|
let ws_config = crate::core::WorkspaceConfig::Root(crate::core::WorkspaceRootConfig::new(
|
||||||
&src_path,
|
&src_path,
|
||||||
@ -85,7 +85,7 @@ pub fn resolve_std<'cfg>(
|
|||||||
// other crates need to alter their features, this should be fine, for
|
// other crates need to alter their features, this should be fine, for
|
||||||
// now. Perhaps in the future features will be decoupled from the resolver
|
// now. Perhaps in the future features will be decoupled from the resolver
|
||||||
// and it will be easier to control feature selection.
|
// and it will be easier to control feature selection.
|
||||||
let current_manifest = src_path.join("src/libtest/Cargo.toml");
|
let current_manifest = src_path.join("library/test/Cargo.toml");
|
||||||
// TODO: Consider doing something to enforce --locked? Or to prevent the
|
// TODO: Consider doing something to enforce --locked? Or to prevent the
|
||||||
// lock file from being written, such as setting ephemeral.
|
// lock file from being written, such as setting ephemeral.
|
||||||
let mut std_ws = Workspace::new_virtual(src_path, current_manifest, virtual_manifest, config)?;
|
let mut std_ws = Workspace::new_virtual(src_path, current_manifest, virtual_manifest, config)?;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user