-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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] Change --extra_toolchains
precedence to last-wins, instead of first…
#20031
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…-wins. This only changes the precedence within all uses of `--extra_toolchains`, it does not change the precedence for `register_toolchains` calls. After this, the priority order for toolchains is: 1. Consider toolchains registered via `--extra_toolchains` 1. Within this set, the last mentioned toolchain has highest priority 2. Consider toolchains registered via `register_toolchains` 1. Within this set, the first mentioned toolchain has highest priority In all cases, pseudo-targets like `:all` and `/...` are ordered by Bazel's package loading mechanism, which is currently using a lexicographic ordering. Fixes bazelbuild#19945. Closes bazelbuild#19942. PiperOrigin-RevId: 578850060 Change-Id: Ibd9c32e5479a6a27717734852b875f9b3f31b510
layus
approved these changes
Nov 2, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Documentation is always nice ! Thanks for pushing this forward
bazel \ | ||
build \ | ||
"//${pkg}/demo:use" &> $TEST_log || fail "Build failed" | ||
expect_log 'Using toolchain: rule message: "this is the rule", toolchain extra_str: "foo from toolchain_2"' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The two first tests here are not absolutely needed.
keertk
pushed a commit
that referenced
this pull request
Nov 17, 2023
…-wins. This only changes the precedence within all uses of `--extra_toolchains`, it does not change the precedence for `register_toolchains` calls. After this, the priority order for toolchains is: 1. Consider toolchains registered via `--extra_toolchains` 1. Within this set, the last mentioned toolchain has highest priority 2. Consider toolchains registered via `register_toolchains` 1. Within this set, the first mentioned toolchain has highest priority In all cases, pseudo-targets like `:all` and `/...` are ordered by Bazel's package loading mechanism, which is currently using a lexicographic ordering. Fixes #19945. Closes #19942. Closes #20031. PiperOrigin-RevId: 579845262 Change-Id: Ibd9c32e5479a6a27717734852b875f9b3f31b510
keertk
added a commit
that referenced
this pull request
Nov 17, 2023
…of first-wins. (#20239) This only changes the precedence within all uses of `--extra_toolchains`, it does not change the precedence for `register_toolchains` calls. After this, the priority order for toolchains is: 1. Consider toolchains registered via `--extra_toolchains` 1. Within this set, the last mentioned toolchain has highest priority 2. Consider toolchains registered via `register_toolchains` 1. Within this set, the first mentioned toolchain has highest priority In all cases, pseudo-targets like `:all` and `/...` are ordered by Bazel's package loading mechanism, which is currently using a lexicographic ordering. Fixes #19945. Closes #19942. Closes #20031. PiperOrigin-RevId: 579845262 Change-Id: Ibd9c32e5479a6a27717734852b875f9b3f31b510 Co-authored-by: Guillaume Maudoux <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
…-wins.
This only changes the precedence within all uses of
--extra_toolchains
, it does not change the precedence forregister_toolchains
calls.After this, the priority order for toolchains is:
--extra_toolchains
register_toolchains
In all cases, pseudo-targets like
:all
and/...
are ordered by Bazel's package loading mechanism, which is currently using a lexicographic ordering.Fixes #19945.
Closes #19942.
PiperOrigin-RevId: 578850060
Change-Id: Ibd9c32e5479a6a27717734852b875f9b3f31b510