Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This is a followup to aosp/2776434 that added a proto dep to one of the genrules. `libperfetto_client_experimental` depends on several other generated headers, so we need to identify the implicit deps of the other genrules as well. Implementation details - Create a "root" filegroup for every proto_library. The srcs to this will be the .proto files - Replace the srcs of the cpp and h generating genrules with the "root" filegroup - For the cpp and h generating genrules, add the "root" filegroup of target.proto_deps and target.transitive_proto_deps to `srcs`. This ensures that these transitive .proto dependencies get copied to the execution sandbox when these modules are built with sandboxing turned on in Soong. `srcs` was chosen instead of `tool_files` because the latter requires a --proto_path specific to Soong's sandbox impl. `outs` will ensure that extraneous generated files do not get propagated to rdeps. Bug: 305049201 Bug: 304495403 Test: tools/gen_android_bp Test: mmma external/perfetto (Soong) Test: GENRULE_SANDBOXING=true m libperfetto_client_experimental (Soong with sandboxing turned on). Test: b clean --expunge && b build //external/perfetto:libperfetto_client_experimental --config=android (Bazel) Change-Id: I88b420a98a6e72d14d2fe426d0d90f1481cdf9bf
- Loading branch information