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

Add x86_64-unknown-none as a Tier 2 target #1263

Closed
SlyMarbo opened this issue Apr 14, 2022 · 5 comments · Fixed by #1967
Closed

Add x86_64-unknown-none as a Tier 2 target #1263

SlyMarbo opened this issue Apr 14, 2022 · 5 comments · Fixed by #1967

Comments

@SlyMarbo
Copy link

As announced in rust-lang/rust#95705, x86_64-unknown-none is now a Tier 2 target with distributed build artefacts. It would be great to be able to use this in extra_target_triples in rust_register_toolchains, but it's currently missing from some of the lists in rust/platform/tiple_mappings.bzl.

Would it be possible to add this? I reckon it should take us a lot of the way to being able to cross-compile to x86_64-unknown-none natively. I'm very happy to help out with testing if that would help. Many thanks.

@UebelAndre
Copy link
Collaborator

What would this platform be represented as? The problem with some of the triples supported by rust is that some platforms are indistinguishable from others given the lack of constraints commonly available in Bazel (related to bazelbuild/platforms#38). As long as the triple isn't going to conflict with another, I think it'd be fine to add.

@SlyMarbo
Copy link
Author

Good question. I'll have a think about how you'd represent it.

@SlyMarbo
Copy link
Author

Would the combination of cpu = "x86_64" and os = "none" work? Sorry if I've misunderstood the question.

@UebelAndre
Copy link
Collaborator

UebelAndre commented Apr 16, 2022

Would the combination of cpu = "x86_64" and os = "none" work? Sorry if I've misunderstood the question.

This sounds reasonable to me and that the combination of those constraints wouldn't match another platform triple. Seems like a reasonable addition to me. Do you want to open a pull request? I'd be happy to review 😄

@SlyMarbo
Copy link
Author

I'm happy to try, but I'm not familiar with the code in rust/platform/triple_mappings.bzl so I'm not confident I'd make all the necessary changes.

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

Successfully merging a pull request may close this issue.

2 participants