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

Correct cpu and os values of local_config_cc_toolchains targets #14844

Conversation

thii
Copy link
Member

@thii thii commented Feb 17, 2022

These aren't being used now, but some of them are clearly defined
incorrectly. Fix them now to avoid surprises in the future. Also change
aarch64 to arm64 since aarch64 is an alias of arm64.

These aren't being used now, but some of them are clearly defined
incorrectly. Fix them now to avoid surprises in the future. Also change
`aarch64` to `arm64` since `aarch64` is an alias of `arm64`.
@thii thii marked this pull request as ready for review February 17, 2022 08:34
@aiuto aiuto requested a review from allevato February 26, 2022 01:51
@gregestren
Copy link
Contributor

@keith

@gregestren gregestren added the team-Rules-CPP Issues for C++ rules label Mar 7, 2022
Copy link
Member

@allevato allevato left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Being pedantic, arm64 should probably be an alias for aarch64 and not the other way around, but I don't know whether it's worth drilling that deep at this point.

These changes seem fine, otherwise.

@keith
Copy link
Member

keith commented Mar 7, 2022

@gregestren it seems like the github owners aren't working correctly since we didn't get cc'd here?

Comment on lines 55 to 58
"tvos_sim_arm64": [
"@platforms//os:ios",
"@platforms//cpu:aarch64",
"@platforms//os:tvos",
"@platforms//cpu:arm64",
],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wondered this in another context but is this one correct? since it's not actually different from tvos_arm64? maybe the name difference is enough?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A while back we checked in environment constraints for simulator, device, and catalyst into https://github.com/bazelbuild/apple_support/blob/master/constraints/BUILD, but I don't know enough about Bazel's toolchains in a multi-repo situation to know if those would be accessible from here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah yea, those wouldn't from here

Comment on lines 43 to 46
"ios_sim_arm64": [
"@platforms//os:ios",
"@platforms//cpu:aarch64",
"@platforms//cpu:arm64",
],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some question as tvos

@gregestren
Copy link
Contributor

@gregestren it seems like the github owners aren't working correctly since we didn't get cc'd here?

Github is reporting errors on https://github.com/bazelbuild/bazel/pull/14614/files. @aiuto can you diagnose?

@gregestren
Copy link
Contributor

I'm not sure if you want a merge now or if the comments above are still pending. I'm happy to merge on the signal.

@keith
Copy link
Member

keith commented Mar 7, 2022

I think we can merge now, this is an improvement as is, we might need to make more improvements in the future, but without this change it's far off in a lot of places

@bazel-io bazel-io closed this in b858ec3 Mar 7, 2022
@thii thii deleted the correct-cpu-and-os-values-of-local_config_cc_toolchains-targets branch March 8, 2022 01:07
@brentleyjones
Copy link
Contributor

@bazel-io fork 5.1

brentleyjones pushed a commit to brentleyjones/bazel that referenced this pull request Mar 8, 2022
These aren't being used now, but some of them are clearly defined
incorrectly. Fix them now to avoid surprises in the future. Also change
`aarch64` to `arm64` since `aarch64` is an alias of `arm64`.

Closes bazelbuild#14844.

PiperOrigin-RevId: 433061989
(cherry picked from commit b858ec3)
brentleyjones pushed a commit to brentleyjones/bazel that referenced this pull request Mar 8, 2022
These aren't being used now, but some of them are clearly defined
incorrectly. Fix them now to avoid surprises in the future. Also change
`aarch64` to `arm64` since `aarch64` is an alias of `arm64`.

Closes bazelbuild#14844.

PiperOrigin-RevId: 433061989
(cherry picked from commit b858ec3)
Wyverald pushed a commit that referenced this pull request Mar 8, 2022
…4995)

These aren't being used now, but some of them are clearly defined
incorrectly. Fix them now to avoid surprises in the future. Also change
`aarch64` to `arm64` since `aarch64` is an alias of `arm64`.

Closes #14844.

PiperOrigin-RevId: 433061989
(cherry picked from commit b858ec3)

Co-authored-by: Thi Doan <t@thi.im>
sluongng added a commit to sluongng/copybara that referenced this pull request Sep 5, 2022
In Bazel versions from 5.1.0 and older, there was a change [1] which
prevents copybara from compiling on Apple Silicon by default.

The solution recommended in [2] was to pin `platforms` repository to a
newer version where the constraints value for CPP toolchain could be
correctly resolved.

Without this change, we would need to use Bazel 5.0.0 or older to
compile copybara successfully on Apple Silicon.

[1]: bazelbuild/bazel#14844
[2]: bazelbuild/bazel#15175
copybara-staging bot pushed a commit to google/copybara that referenced this pull request Sep 7, 2022
In Bazel versions from 5.1.0 and older, there was a change [1] which
prevents copybara from compiling on Apple Silicon by default.

The solution recommended in [2] was to pin `platforms` repository to a
newer version where the constraints value for CPP toolchain could be
correctly resolved.

Without this change, we would need to use Bazel 5.0.0 or older to
compile copybara successfully on Apple Silicon.

[1]: bazelbuild/bazel#14844
[2]: bazelbuild/bazel#15175

Fixes #207

Change-Id: I8f71518f3c569de794fd60acb899d835323fccc9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
team-Rules-CPP Issues for C++ rules
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants