Closed Bug 1502964 Opened 6 years ago Closed 5 years ago

vendor winapi crate with aarch64 support

Categories

(Firefox Build System :: General, enhancement)

enhancement
Not set
normal

Tracking

(firefox65 fixed)

RESOLVED FIXED
mozilla65
Tracking Status
firefox65 --- fixed

People

(Reporter: froydnj, Assigned: froydnj)

References

(Blocks 1 open bug)

Details

Attachments

(2 files, 2 obsolete files)

The upstream pull request:

https://github.com/retep998/winapi-rs/pull/677

that adds aarch64 support has been merged.  From conversations with the maintainer, it's not clear to me when an updated crate version with those changes will be released.  Until that time, we're just going to have to redirect to our own copy of winapi-rs
Pulling this change out separately so it's easier to review.
Attachment #9020895 - Flags: review?(core-build-config-reviews)
It's not clear when upstream will do a new release with the aarch64
changes we need, so to unblock ourselves, let's just use a forked
version for now.
Attachment #9020896 - Flags: review?(core-build-config-reviews)
Comment on attachment 9020895 [details] [diff] [review]
part 1 - tweak vendoring for pulling in winapi from a git repo branch

Review of attachment 9020895 [details] [diff] [review]:
-----------------------------------------------------------------

This sucks. :-/ Can we get a followup bug to track updating to the next winapi release (whenever that happens) so we can remove this?
Attachment #9020895 - Flags: review?(core-build-config-reviews) → review+
Attachment #9020896 - Flags: review?(core-build-config-reviews) → review+
Pushed by nfroyd@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/6015a119c154
part 1 - tweak vendoring for pulling in winapi from a git repo branch; r=ted.mielczarek
https://hg.mozilla.org/integration/mozilla-inbound/rev/26815a566707
part 2 - update winapi to froydnj/winapi-rs#aarch64; r=ted.mielczarek
Ugh, it looks like cargo really does checksum all the files we deleted:

error: failed to calculate checksum of: Z:\build\build\src\third_party\rust\winapi\x86_64/lib/libwinapi_imagehlp.a

so we'd have to solve https://github.com/alexcrichton/cargo-vendor/issues/137, which asks cargo-vendor to honor [package.include], and we'd have to figure out how to make cargo-vendor determine which paths can be excluded as vendored crates (not filed).
Flags: needinfo?(nfroyd)
OK, ideally https://github.com/alexcrichton/cargo-vendor/pull/139 will be accepted and we'll get a new cargo-vendor release, and we can try this again with fewer hacks.
That revision landed (yay!), but it turns out there was a regression in an earlier version that caused `cargo vendor` to fail (boo!).  That issue is being tracked at https://github.com/alexcrichton/cargo-vendor/issues/140, and we'll see if that can be fixed easily.
The newer version features the usual crop of bugfixes we need.

Ted OK'd this on IRC, but this change also means that other people who want to
vendor things won't run into weird bugs, and we don't have to include the
vendor_rust.py hacks (which didn't actually work...) that I had proposed previously.
Attachment #9022125 - Flags: review+
Attachment #9020895 - Attachment is obsolete: true
This vendoring is a little more invasive, but that's because the rules for what
cargo-vendor includes have changed, so other crates are affected as well.
Attachment #9022126 - Flags: review+
Attachment #9020896 - Attachment is obsolete: true
Pushed by nfroyd@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/225f2ad3cf2f
part 1 - bump the minimum required version of cargo-vendor; r=ted.mielczarek
https://hg.mozilla.org/integration/mozilla-inbound/rev/12bca041cda6
part 2 - update winapi to froydnj/winapi-rs#aarch64; r=ted.mielczarek
Pushed by nfroyd@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/088cccfcaa08
part 1 - bump the minimum required version of cargo-vendor; r=ted.mielczarek
https://hg.mozilla.org/integration/mozilla-inbound/rev/d229433e0f47
part 2 - update winapi to froydnj/winapi-rs#aarch64; r=ted.mielczarek
https://hg.mozilla.org/mozilla-central/rev/088cccfcaa08
https://hg.mozilla.org/mozilla-central/rev/d229433e0f47
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla65
Thanks very much, Nathan! I can now build a clean tree (modulo the known issues in webrtc). This is going to make my trees much more sane.
Flags: needinfo?(nfroyd)
You need to log in before you can comment on or make changes to this bug.