Add ability to omit protozero dep in protozero_library

In Chromium, //base depends on //third_party/perfetto, as documented in https://docs.google.com/document/d/1UQ4Ez7B-TeowijOUuMXuoWj1amZcQ7E2abt3s4jaAEY/edit#heading=h.jkzl3mb2kwbo

In order to use Chromium-specific extensions, base needs to depend on Protozero-generated code. protozero_library is the build rule that provides such generation, but the direct dependency on Protozero sources instead of libperfetto leads to including the same symbols twice, resulting in ODR violation for binaries that include both base with tracing and libperfetto.

A new flag in protozero_library would be used in Chromium to avoid that.

Bug: 171790119
Change-Id: I6649a487d4546b6a9dad6a61563aa28e1203fdcb
1 file changed
tree: 6aa18753bd4110ad18ba71fa3295fc5d9ce45db0
  1. .github/
  2. bazel/
  3. build_overrides/
  4. buildtools/
  5. debian/
  6. docs/
  7. examples/
  8. gn/
  9. include/
  10. infra/
  11. protos/
  12. src/
  13. test/
  14. tools/
  15. ui/
  16. .clang-format
  17. .clang-tidy
  18. .gitignore
  19. .gn
  20. .style.yapf
  21. Android.bp
  22. Android.bp.extras
  23. BUILD
  24. BUILD.extras
  25. BUILD.gn
  26. CHANGELOG
  27. codereview.settings
  28. heapprofd.rc
  29. LICENSE
  30. METADATA
  31. MODULE_LICENSE_APACHE2
  32. OWNERS
  33. perfetto.rc
  34. PRESUBMIT.py
  35. README.chromium
  36. README.md
  37. TEST_MAPPING
  38. traced_perf.rc
  39. WORKSPACE
README.md

Perfetto - System profiling, app tracing and trace analysis

Perfetto is a production-grade open-source stack for performance instrumentation and trace analysis. It offers services and libraries and for recording system-level and app-level traces, native + java heap profiling, a library for analyzing traces using SQL and a web-based UI to visualize and explore multi-GB traces.

See https://perfetto.dev/docs or the /docs/ directory for documentation.