Reland "Revert "protobuf: Prefer compiled version of any.proto""

This reverts commit 4b7501014b0371fe9c951c2da08decae71facf28.

Reason for revert: appears to break compile
see failing build:
https://ci.chromium.org/ui/p/chromium/builders/ci/win-arm64-dbg/13958/overview

Original change's description:
> Revert "Revert "protobuf: Prefer compiled version of any.proto""
>
> This reverts commit 3f1c3b6b7f5806f300a21c185867cbab1715b50d.
>
> Reason for revert:
> LUCI Bisection has identified this change as the culprit of a build failure. See the analysis: https://ci.chromium.org/ui/p/chromium/bisection/compile-analysis/b/8683091695934672897
>
> Sample failed build: https://ci.chromium.org/b/8683091695934672897
>
> If this is a false positive, please report it at http://b.corp.google.com/createIssue?component=1199205&description=Analysis%3A+https%3A%2F%2Fchromium-review.googlesource.com%2Fc%2Fchromium%2Fsrc%2F%2B%2F7806908&format=PLAIN&priority=P3&title=Wrongly+blamed+https%3A%2F%2Fci.chromium.org%2Fui%2Fp%2Fchromium%2Fbisection%2Fcompile-analysis%2Fb%2F8683091695934672897&type=BUG
>
> Original change's description:
> > Revert "protobuf: Prefer compiled version of any.proto"
> >
> > This reverts commit 9889f08a2fd5439fb40081e856bd6899e8798930.
> >
> > Reason for revert: Broke https://ci.chromium.org/ui/p/chromium/builders/ci/win-arm64-dbg
> >
> > Original change's description:
> > > protobuf: Prefer compiled version of any.proto
> > >
> > > Instead of including the bundled version og generated any.pb.h and
> > > any.pb.cc, generate them during build. The bundled version exists only
> > > in order to support CMake builds [1] and normally, protoc generates code
> > > for well known types (such as any.proto).
> > >
> > > The reason why we don't want to use the bundled generated files is
> > > because Chrome supports both protobuf full and protobuf lite, which need
> > > different generated code for well known types. By generating code during
> > > build, we can easily differentiate between full and lite by using
> > > different out directories and we can prevent some full/lite conflicts by
> > > not including full any.proto everywhere.
> > >
> > > The plan is to remove this checked-in generated code [2] as it can cause
> > > build issues difficult to spot [3].
> > >
> > > See also go/chrome-protobuf-wkt.
> > >
> > > [1]
> > > https://github.com/protocolbuffers/protobuf/blob/6e787ec24336503d55e64aa00232857260f1d364/src/google/protobuf/BUILD.bazel#L248-L250
> > > [2] https://crrev.com/c/7789963
> > > [3] https://crrev.com/c/7633343
> > >
> > > Bug: 40198965
> > > Bug: b:506108695
> > > Change-Id: If10ab53587d9334ded00a3d1132d5a9e69c3a5cd
> > > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7790327
> > > Commit-Queue: Kamil Jarosz <kjarosz@google.com>
> > > Owners-Override: Andrew Grieve <agrieve@chromium.org>
> > > Reviewed-by: Andrew Grieve <agrieve@chromium.org>
> > > Reviewed-by: Giovanni Ortuno Urquidi <ortuno@chromium.org>
> > > Cr-Commit-Position: refs/heads/main@{#1623025}
> >
> > Bug: 40198965
> > Bug: b:506108695
> > No-Presubmit: true
> > No-Tree-Checks: true
> > No-Try: true
> > Change-Id: If60528e3f68376de77aba5aa76d2839e954e6c99
> > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7806908
> > Commit-Queue: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
> > Auto-Submit: Rafał Godlewski <rgod@google.com>
> > Owners-Override: Rafał Godlewski <rgod@google.com>
> > Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
> > Cr-Commit-Position: refs/heads/main@{#1623114}
> >
>
> Bug: 40198965
> Bug: b:506108695
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Change-Id: I53b3754190ac7e1dcf4cf9400260ddbce1e25835
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7806689
> Commit-Queue: luci-bisection@appspot.gserviceaccount.com <luci-bisection@appspot.gserviceaccount.com>
> Owners-Override: luci-bisection@appspot.gserviceaccount.com <luci-bisection@appspot.gserviceaccount.com>
> Bot-Commit: luci-bisection@appspot.gserviceaccount.com <luci-bisection@appspot.gserviceaccount.com>
> Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
> Cr-Commit-Position: refs/heads/main@{#1623121}

Bug: 40198965
Bug: b:506108695
Change-Id: I848f89f29ca23a6f03ba1832a37e83362c86413b
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7807931
Commit-Queue: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Owners-Override: Matt Reichhoff <mreichhoff@chromium.org>
Auto-Submit: Matt Reichhoff <mreichhoff@chromium.org>
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#1623290}
3 files changed
tree: 055d8eaa63b93a73f0a6d5ed0cb635b73e1a7e82
  1. .agents/
  2. .claude/
  3. .gemini/
  4. .github/
  5. agents/
  6. android_webview/
  7. apps/
  8. ash/
  9. base/
  10. build/
  11. build_overrides/
  12. buildtools/
  13. cc/
  14. chrome/
  15. chromecast/
  16. chromeos/
  17. codelabs/
  18. components/
  19. content/
  20. crypto/
  21. dbus/
  22. device/
  23. docs/
  24. extensions/
  25. fuchsia_web/
  26. gin/
  27. google_apis/
  28. gpu/
  29. headless/
  30. infra/
  31. ios/
  32. ipc/
  33. media/
  34. mojo/
  35. net/
  36. pdf/
  37. printing/
  38. remoting/
  39. rlz/
  40. sandbox/
  41. services/
  42. skia/
  43. sql/
  44. storage/
  45. styleguide/
  46. testing/
  47. third_party/
  48. tools/
  49. ui/
  50. url/
  51. webkit/
  52. .clang-format
  53. .clang-tidy
  54. .clangd
  55. .cursorignore
  56. .geminiignore
  57. .git-blame-ignore-revs
  58. .gitallowed
  59. .gitattributes
  60. .gitignore
  61. .gitmodules
  62. .gn
  63. .mailmap
  64. .rustfmt.toml
  65. .vpython3
  66. .yapfignore
  67. ATL_OWNERS
  68. AUTHORS
  69. BUILD.gn
  70. CODE_OF_CONDUCT.md
  71. codereview.settings
  72. CPPLINT.cfg
  73. CRYPTO_OWNERS
  74. DEPS
  75. DIR_METADATA
  76. LICENSE
  77. LICENSE.chromium_os
  78. OWNERS
  79. package.json
  80. PRESUBMIT.py
  81. PRESUBMIT_test.py
  82. PRESUBMIT_test_mocks.py
  83. README.md
  84. SECURITY_OWNERS
  85. WATCHLISTS
README.md

Logo Chromium

Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.

The project's web site is https://www.chromium.org.

To check out the source code locally, don't use git clone! Instead, follow the instructions on how to get the code.

Documentation in the source is rooted in docs/README.md.

Learn how to Get Around the Chromium Source Code Directory Structure.

For historical reasons, there are some small top level directories. Now the guidance is that new top level directories are for product (e.g. Chrome, Android WebView, Ash). Even if these products have multiple executables, the code should be in subdirectories of the product.

If you found a bug, please file it at https://crbug.com/new.