Skip to content

Commit

Permalink
Add dependency from //headless:gen_devtools_client_api to :protocol_s…
Browse files Browse the repository at this point in the history
…ources

At least types_inspector.h generated by gen_devtools_client_api needs
base_string_adapter.h generated by protocol_sources. The dependency
ensures that we generate base_string_adapter.h before generating
and compiling types_inspector.cc.

Previously without the dependency, some CL [1] failed to compile on
some bots [2].

[1] https://chromium-review.googlesource.com/c/chromium/src/+/3312656/3
[2] https://cr-buildbucket.appspot.com/build/8828631760542807537

Bug: 1277317
Change-Id: I7a0d7e21f70b230c7bcaddbb9872a8d95136c9a2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3316146
Reviewed-by: Andrey Kosyakov <caseq@chromium.org>
Commit-Queue: Xianzhu Wang <wangxianzhu@chromium.org>
Cr-Commit-Position: refs/heads/main@{#948788}
  • Loading branch information
wangxianzhu authored and Chromium LUCI CQ committed Dec 7, 2021
1 parent 1d99d5b commit e625036
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions headless/BUILD.gn
Expand Up @@ -187,7 +187,10 @@ foreach(domain, devtools_domains) {

action("gen_devtools_client_api") {
script = "lib/browser/devtools_api/client_api_generator.py"
deps = [ "//third_party/blink/public/devtools_protocol:protocol_version" ]
deps = [
":protocol_sources",
"//third_party/blink/public/devtools_protocol:protocol_version",
]
inputs = [
"$root_gen_dir/third_party/blink/public/devtools_protocol/protocol.json",
]
Expand Down Expand Up @@ -229,7 +232,10 @@ if (headless_fontconfig_utils && !is_fuchsia) {
}

inspector_protocol_generate("protocol_sources") {
visibility = [ "//headless:backend_cdp_bindings" ]
visibility = [
":backend_cdp_bindings",
":gen_devtools_client_api",
]
deps = [ "//third_party/blink/public/devtools_protocol:protocol_version" ]
_blink_protocol_path = rebase_path(
"$root_gen_dir/third_party/blink/public/devtools_protocol/protocol.json",
Expand Down

0 comments on commit e625036

Please sign in to comment.