Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@copybara-service
Copy link

feat(bazel): wire up prebuilt protoc toolchain (#24115)

Upstreamed from my https://github.com/aspect-build/toolchains_protoc which provided this feature outside the protobuf repo.

Adds:

  • private API: module_extension + tag protoc.prebuilt_toolchain to provide and register toolchain for bzlmod users
  • WORKSPACE users can live with the inconvenience of having to create toolchains themselves
  • example of proto_library rule with intentionally non-functional cc toolchain, exercising the feature

This needs work with @thesayyn to:

Work towards #19558

Closes #24115

COPYBARA_INTEGRATE_REVIEW=#24115 from protocolbuffers:alexeagle/use_prebuilt_toolchain b18667d
FUTURE_COPYBARA_INTEGRATE_REVIEW=#24115 from protocolbuffers:alexeagle/use_prebuilt_toolchain b18667d

Upstreamed from my https://github.com/aspect-build/toolchains_protoc which provided this feature outside the protobuf repo.

Adds:
- private API: module_extension + tag `protoc.prebuilt_toolchain` to provide and register toolchain for bzlmod users
- WORKSPACE users can live with the inconvenience of having to create toolchains themselves
- example of proto_library rule with intentionally non-functional cc toolchain, exercising the feature

This needs work with @thesayyn to:
- constrain users to choosing a protoc version agreeing with design doc
https://docs.google.com/document/d/16N-eU-0zHbWmxEuaUAIFTJwQLekIXZ8zIC3K4XDr20E/edit
- also register lang toolchains when the flag is enabled

Work towards #19558

Closes #24115

COPYBARA_INTEGRATE_REVIEW=#24115 from protocolbuffers:alexeagle/use_prebuilt_toolchain b18667d
FUTURE_COPYBARA_INTEGRATE_REVIEW=#24115 from protocolbuffers:alexeagle/use_prebuilt_toolchain b18667d
PiperOrigin-RevId: 843732324
@copybara-service copybara-service bot closed this Dec 16, 2025
@copybara-service copybara-service bot deleted the test_843732324 branch December 16, 2025 16:36
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.

1 participant