cargo vendor is not consistent about paths and symbolic links on Windows vs. other platforms #14965
Labels
C-bug
Category: bug
Command-vendor
O-windows
OS: Windows
S-triage
Status: This issue is waiting on initial triage.
Problem
About paths:
when a crate contains paths for e.g. dependencies in a workspace,
cargo vendor
uses / on Unices and \ on Windows, changing whatever the original path was.About symbolic links:
when a crate contains symbolic links to another file in a workspace,
cargo vendor
expands the content on Unices and replaces it with the path of the link target on Windows.Steps
cargo new foo
cd foo
cargo add libz-rs-sys
cargo vendor
On Linux or Mac, you end up with a proper
vendor/libz-rs-sys/LICENSE
file, andvendor/libz-rs-sys/Cargo.toml
hasdependencies.zlib-rs.path = "../zlib-rs"
.On Windows,
vendor/libz-rs-sys/LICENSE
literally contains../LICENSE
, andvendor/libz-rs-sys/Cargo.toml
hasdependencies.zlib-rs.path = "..\zlib-rs"
.Possible Solution(s)
cargo vendor should be consistent, wherever it's run.
Notes
No response
Version
The text was updated successfully, but these errors were encountered: