Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SORRY FOR BREAKING EVERYTHING #238

Closed
retep998 opened this issue Nov 9, 2015 · 4 comments
Closed

SORRY FOR BREAKING EVERYTHING #238

retep998 opened this issue Nov 9, 2015 · 4 comments

Comments

@retep998
Copy link
Owner

retep998 commented Nov 9, 2015

I published a new major version of kernel32-sys, from 0.1.4 to 0.2.0.
Some crates bumped their dependency to kernel32-sys = "0.2".
kernel32-sys specifies links = "kernel32".
Cargo only allows one dependency to specify links = "foo" for any given foo.
kernel32-sys is often depended on unconditionally because Cargo lacks good platform specific dependencies.
kernel32-sys is a transitive dependency of most projects even on non-windows.
Many projects ended up transitively depending on both kernel32-sys = "0.2" and kernel32-sys = "0.1".
0.2 and 0.1 are semver incompatible and so are considered separate unique dependencies.
Cargo refuses to let them both specify the same links.
Everything breaks.

Sorry.

Issues in other projects caused by this:
PistonDevelopers/conrod#622
time-rs/time#126
shadowsocks/shadowsocks-rust#16
rust-windowing/glutin#656
PistonDevelopers/piston#1004
https://github.com/dpc/mioco/issues/60
maidsafe/sn_routing#766
maidsafe-archive/crust#408

@mitchmindtree
Copy link

Maybe it's worth finding (or posting) an issue at cargo that we can link this issue to.

@dashed
Copy link

dashed commented Nov 9, 2015

For the time being, I'm editing the Cargo.lock file to lock down and use a single version of kernel32-sys.

@laanwj
Copy link

laanwj commented Nov 9, 2015

The workaround that I used is to make a .cargo/config file with

paths = ["/home/user/projects/winapi-rs"]

Pointing it to my own check-out of winapi-rs. This succeeds in making all dependencies use the same version of winapi-rs, of course if the API is incompatible they may cause compile issues later on. But it seems to work for me.

@dashed
Copy link

dashed commented Nov 9, 2015

Thanks for the fix @retep998 ! 👍

I can happily report that updating to 0.2.1 gives no problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants