-
Notifications
You must be signed in to change notification settings - Fork 790
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
[bazel] Migrate rules_python
and dependents to bzlmod
#25650
Conversation
293cec3
to
97a5734
Compare
97a5734
to
efbd579
Compare
Signed-off-by: Amaury Pouly <[email protected]> Co-authored-by: James Wainwright <[email protected]>
Signed-off-by: James Wainwright <[email protected]>
These `external` paths hardcoded into linker scripts are not stable and in fact change when bzlmod is enabled. This commit adds the `-Wl,-L` flag to the linker for each included file, causing the linker to search the correct external directory for it. Signed-off-by: James Wainwright <[email protected]>
Signed-off-by: James Wainwright <[email protected]>
Signed-off-by: James Wainwright <[email protected]>
Signed-off-by: James Wainwright <[email protected]>
Signed-off-by: James Wainwright <[email protected]>
efbd579
to
8ad4435
Compare
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.
This looks great. One small nit but I'll leave it up to you: would it make sense to split [bazel] Fix external includes in linker scripts
into two: the bazel change, and the use of this change to fix linker scripts?
Yeah they could be split. I think it's unlikely I'll need to revert just one so I'm fine with leaving it as one |
This PR migrates
rules_python
and the modules that depend on it to bzlmod.These depending modules use python interpreters in their actual rule implementations, so they have to be migrated at the same time. The first commits add bzlmod support for each module before they're all switched over in the second-to-last commit.
bazel_skylib
must also be migrated as it's needed for the Tock repositories (viabare_repository
).There is also a fix for the
INCLUDE
paths of linker scripts inside theexternal
directory which is unstable and has to have its paths generated by Bazel.The modules migrated are:
bazel_skylib
.lowrisc_misc_linters
(license checker).rules_fuzzing
.rules_python
.