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

WIP cross-compilation support #1470

Closed
wants to merge 1 commit into from
Closed

Conversation

fasterthanlime
Copy link
Contributor

No description provided.

Cargo.toml Outdated Show resolved Hide resolved
@fasterthanlime
Copy link
Contributor Author

To make this PR thinner, I'd love to get a ✅ on axodotdev/axoasset#212 (and then a cargo publish, and a bump on the version of axoasset that cargo-dist pulls in).

I'd also love to get these merged separately:

  • fast profile: c249d81 — this can just be what we make dev be, I'd love that actually, then I wouldn't need to build twice. pretty much, I need the deps to be optimized otherwise we're wasting CPU cycles doing xz compression
  • eb14745 — supports a cargo_dist_url_override setting, which lets me serve cargo-dist from, say, https://dl.bearcove.cloud/dump/ in CI — which is how I got this run to finish in 1m48s instead of like, 14m

The rest of the PR is pretty radioactive for now, it has a bunch of .unwrap(), I want to use Triple (the structured version, from target_lexicon) more aggressively, but keep the original (non-parsed) version around, just in case we can't parse it?

My guess is that for now if target_lexicon cannot parse it, chances are we cannot do anything useful with it anyway, but it just sucks to have to parse it again and again just because the thing we're parsing around is a thinly-veiled string.

fasterthanlime added a commit that referenced this pull request Oct 30, 2024
This has been extracted out of #1470
and it's part of making a faster "edit-compile-test-in-ci" cycle when working
on cross-compilation.

The rationale is included as inline comments.
@fasterthanlime fasterthanlime force-pushed the cross branch 3 times, most recently from 5fe6657 to dde1c27 Compare October 31, 2024 10:07
fasterthanlime added a commit that referenced this pull request Oct 31, 2024
This has been extracted out of #1470
and it's part of making a faster "edit-compile-test-in-ci" cycle when working
on cross-compilation.

The rationale is included as inline comments.
@fasterthanlime
Copy link
Contributor Author

Quick piece of insight I had while looking at:

CleanShot 2024-11-01 at 17 05 35@2x

in the absence of other info, we can assume that the custom runners have the arch they're being used for.

Since cargo-dist did not support cross when that config format was invented.

Later, we can disallow doing something like:

[dist.github-custom-runners]
aarch64-unknown-linux-gnu = "my-fast-runner"
x86_64-unknown-linux-gnu = "my-fast-runner"

With something like "what's the target triple for github runner 'my-fast-runner'? tell us by doing this:

[dist.github-custom-runner-specs]
my-fast-runner = { triple = "aarch64-unknown-linux-gnu" }

...or whatever makes sense to us.

@fasterthanlime fasterthanlime changed the base branch from main to cargo-dist-url-override November 6, 2024 17:44
@fasterthanlime fasterthanlime force-pushed the cross branch 2 times, most recently from fdd571a to 842a721 Compare November 6, 2024 17:50
@fasterthanlime
Copy link
Contributor Author

Closing in favor of #1529

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

Successfully merging this pull request may close these issues.

2 participants