Skip to content

Revert "Reference platformclasspath in @bazel_tools"#142

Merged
copybara-service[bot] merged 1 commit intobazelbuild:masterfrom
fmeum:master
Oct 17, 2023
Merged

Revert "Reference platformclasspath in @bazel_tools"#142
copybara-service[bot] merged 1 commit intobazelbuild:masterfrom
fmeum:master

Conversation

@fmeum
Copy link
Copy Markdown
Contributor

@fmeum fmeum commented Oct 17, 2023

This reverts commit 54e89da.

Going through @bazel_tools to reference the bootstrap classpath is no longer needed with Bazel 7, which always uses toolchain macros that define the required bootstrap runtime toolchains.

Since the original problem didn't arise with Bzlmod, where the Java toolchains have always come from rules_java rather than bazel_tools, this fixes bazelbuild/bazel#19837 for Bazel itself by allowing it to use the new bootstrap classpath rule while still being built with Bazel 6.4.0.

This reverts commit 54e89da.

Going through `@bazel_tools` to reference the bootstrap classpath is no
longer needed with Bazel 7, which always uses toolchain macros that
define the required bootstrap runtime toolchains.

Since the original problem didn't arise with Bzlmod, where the Java
toolchains have always come from rules_java rather than bazel_tools,
this fixes bazelbuild/bazel#19837 for Bazel
itself by allowing it to use the new bootstrap classpath rule while
still being built with Bazel 6.4.0.
@fmeum fmeum requested review from a team and comius as code owners October 17, 2023 07:45
@fmeum
Copy link
Copy Markdown
Contributor Author

fmeum commented Oct 17, 2023

CC @hvadehra

@fmeum
Copy link
Copy Markdown
Contributor Author

fmeum commented Oct 17, 2023

Is the next release planned to be 7.0.0? This commit would break compatibility with Bazel 6.

@hvadehra
Copy link
Copy Markdown
Member

hvadehra commented Oct 17, 2023

Is the next release planned to be 7.0.0? This commit would break compatibility with Bazel 6.

Yes, there are also another breaking change in the next release.

Is this change needed for Bazel 7?

@fmeum
Copy link
Copy Markdown
Contributor Author

fmeum commented Oct 17, 2023

Is this change needed for Bazel 7?

It is needed to fix bazelbuild/bazel#19837, which currently blocks bazelbuild/bazel#18262 and that would be great to get into Bazel 7. As an alternative, we could also cherry-pick bazelbuild/bazel@149cbce into 6.4.0, but I don't know whether that is 100% safe.

@copybara-service copybara-service bot merged commit 1ddcbfc into bazelbuild:master Oct 17, 2023
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.

Building Bazel@HEAD results in many Java-related warnings

2 participants