rust-osdev / cargo-xbuild

Automatically cross-compiles the sysroot crates core, compiler_builtins, and alloc.
Apache License 2.0
260 stars 25 forks source link

Remove fs2 dependency for broader platform support #91

Closed pfmooney closed 4 years ago

pfmooney commented 4 years ago

The use of fs2 for file locking limits the platforms where cargo-xbuild can be built/installed. Upstream cargo was updated to make the locking calls itself, as fs2 is effectively unmaintained (and thus not merging patches to support new platforms). This PR replicates that change, so cargo-xbuild is effectively freed of the platform constraints of fs2.

Thanks

phil-opp commented 4 years ago

Published as v0.6.1.

phil-opp commented 4 years ago

Seems like this PR has compilation issues on Windows: https://github.com/rust-osdev/cargo-xbuild/issues/92

Maybe you can look into this @pfmooney? For now I yanked version 0.6.1 again.

phil-opp commented 4 years ago

I think you forgot to add the winapi dependency in the Cargo.toml.

(We should really set up a CI workflow for this repo so that we detect such problems in the future.)

pfmooney commented 4 years ago

I think you forgot to add the winapi dependency in the Cargo.toml.

(We should really set up a CI workflow for this repo so that we detect such problems in the future.)

Ah, sorry about that! I'll have PRs posted shortly to do both pieces (fix the winapi piece, and setup a github action to test run cargo build)

pfmooney commented 4 years ago

(You might also want to consider using cargo's new build-std feature instead of this crate.)

Yep, totally agreed. In this case, I wanted to reduce friction for building an existing project which is setup to use cargo-xbuild.