Skip to content
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

Tweak BUILD setup to make the layering check change less disruptive (cherry-pick) #15838

Merged
merged 1 commit into from
Feb 14, 2024

Conversation

acozzette
Copy link
Member

We recently updated the codebase to comply with the Bazel layering check, which essentially requires any C++ header inclusion to be matched with a build dependency on a target providing that header.

As part of that, I removed a handful of dependencies from the //:protobuf target, since these dependencies were not set up in a way that respected the layering check. However, I realized that this may cause a number of breakages, especially since we did not provide the correct public targets until very recently.

This change effectively adds back in the missing dependencies, so that projects which do not yet adhere to the layering check can continue to depend on them indirectly. This way, we still adhere to the layering check and make it possible for projects that depend on us to do so, but in most cases we won't immediately break anyone.

PiperOrigin-RevId: 607021111

We recently updated the codebase to comply with the Bazel layering check, which
essentially requires any C++ header inclusion to be matched with a build
dependency on a target providing that header.

As part of that, I removed a handful of dependencies from the `//:protobuf`
target, since these dependencies were not set up in a way that respected the
layering check. However, I realized that this may cause a number of breakages,
especially since we did not provide the correct public targets until very
recently.

This change effectively adds back in the missing dependencies, so that projects
which do not yet adhere to the layering check can continue to depend on them
indirectly. This way, we still adhere to the layering check and make it
possible for projects that depend on us to do so, but in most cases we won't
immediately break anyone.

PiperOrigin-RevId: 607021111
@acozzette acozzette requested a review from a team as a code owner February 14, 2024 18:05
@acozzette acozzette requested review from zhangskz and removed request for a team February 14, 2024 18:05
@acozzette acozzette added the 🅰️ safe for tests Mark a commit as safe to run presubmits over label Feb 14, 2024
@github-actions github-actions bot removed the 🅰️ safe for tests Mark a commit as safe to run presubmits over label Feb 14, 2024
@acozzette acozzette merged commit 52aa150 into protocolbuffers:26.x Feb 14, 2024
153 of 154 checks passed
@acozzette acozzette deleted the cherry-pick branch February 14, 2024 19:21
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.

2 participants