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

Make aarch64 an alias of arm64 #22

Merged
merged 1 commit into from
Jan 13, 2021

Conversation

thii
Copy link
Member

@thii thii commented Dec 10, 2020

On Apple silicon Macs, auto-detected host platform constraints' cpu is
aarch64, but arm64 is used everywhere else. This change ensures that you
will get the same cpu when your target depends on an arm64 or an aarch64
cpu contraint.

On Apple silicon Macs, auto-detected host platform constraints' cpu is
aarch64, but arm64 is used everywhere else. This change ensures that you
will get the same cpu when your target depends on an arm64 or an aarch64
cpu contraint.
@google-cla google-cla bot added the cla: yes label Dec 10, 2020
@thii thii marked this pull request as ready for review December 10, 2020 11:15
@comius
Copy link
Contributor

comius commented Dec 10, 2020

cc @katre, @philwo

@katre
Copy link
Member

katre commented Dec 10, 2020

Are these actually the same CPU? I don't know anything about ARM chips. Should we possibly be distinguishing Apple's M1 from other 64-bit ARM chips?

@thii
Copy link
Member Author

thii commented Dec 10, 2020

On Apple platforms, I think they refer to the same cpu, not sure about others.

Or we can fix the autodetecting toolchain on macOS to use arm64 instead of aarch64.

@katre
Copy link
Member

katre commented Dec 11, 2020

I'm trying to get some clarification on the details of different ARM cpus from some of my colleagues, and I'll report back once I have something.

@katre
Copy link
Member

katre commented Jan 12, 2021

Thanks for your patience. I talked to my colleagues, and this PR makes sense. Once this and #11 are in we may need to do another pass to rationalize arm cpus, but this can submit as is. I'll work on merging it today.

@bazel-io bazel-io merged commit 090d3b1 into bazelbuild:master Jan 13, 2021
@thii thii deleted the make-aarch64-an-alias-of-arm64 branch January 13, 2021 17:03
@byronyi
Copy link

byronyi commented Mar 22, 2021

Gentle ping @katre

@katre
Copy link
Member

katre commented Mar 22, 2021

This should be in release https://github.com/bazelbuild/platforms/releases/tag/0.0.4, sorry I didn't comment back here that it was done.

hanwen pushed a commit to GerritCodeReview/gerrit that referenced this pull request Apr 26, 2022
Running the bazel build on Mac M1 yields the following error:

Configurable attribute "actual" doesn't match this configuration:
Could not find a JDK for host execution environment, please explicitly
provide one using `--host_javabase.`

Follow hints in [1] and fix this by loading bazel platforms 0.0.5
which contains a fix [2] making aarch64 an alias of arm64.

[1] bazelbuild/bazel#13573
[2] bazelbuild/platforms#22

Release-Notes: Fix bazel build on Mac M1 (aarch64)
Change-Id: I5a4ebcd50012a53e5ff92a12e4fa8ba766aed0a7
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.

6 participants