Changes Announced on January 16, 2026
Prebuilt proto compiler (protoc) for Bazel
In an effort to speed up builds, Bazel 9 provides an option to skip re-compiling Protobuf tools and runtimes and use a pre-built protoc binary. Using a pre-built protoc also avoids build failures from incompatible or non-hermetic C++ compilation toolchain installed on your machine.
To use the prebuilt protoc, you must be using Bazel 9 or later, which itself
requires protobuf version 33.4 or later. Set the
--@protobuf//bazel/toolchains:prefer_prebuilt_protoc flag to use the prebuilt
protoc. The default will be changed to use the prebuilt protoc with the breaking
v34 release.
Reasons not to use the prebuilt compiler
There are some use cases in which using the prebuilt protoc is not recommended:
- Your corporate security policy requires all dependencies be built from source.
- You need to build for the exec platform with a specific compiler or specific compiler flags.
- You are making changes to protoc, itself, and want to ensure that those changes are tested.
For more information on other changes in Bazel 9 that affect Protocol Buffers, see https://bazel.build/about/roadmap.