Fix crashpad for PGO generation

This GN arg config repros the failure in the bug:
```
chrome_pgo_phase = 1
is_official_build = true
target_cpu = "arm64"
target_os = "android"
use_remoteexec = true
```

Commenting out either is_official_build or chrome_pgo_phase removes the
compile error, but since many bots build with is_official_build, the
culprit must be chrome_pgo_phase.

Bug: chromium:362787700
Change-Id: I536a098693b85ed93c22e38e639b393fcb480e79
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/5826154
Reviewed-by: Joshua Peraza <jperaza@chromium.org>
This commit is contained in:
Peter Wen 2024-09-03 11:09:14 -04:00 committed by Joshua Peraza
parent f9fa2d112b
commit 915913bd5a

View File

@ -223,10 +223,13 @@ if (crashpad_is_android) {
# Chromium's sanitizer runtime libraries do not include an unwinder, # Chromium's sanitizer runtime libraries do not include an unwinder,
# so add Chromium's standard dependencies to link against the in-tree # so add Chromium's standard dependencies to link against the in-tree
# libunwind. The coverage wrapper similarly requires an unwinder, as # libunwind. The coverage wrapper similarly requires an unwinder, as
# well as a few other bits from libc++abi. # well as a few other bits from libc++abi. There are some issues with pgo
# as well.
import("//build/config/compiler/pgo/pgo.gni")
import("//build/config/coverage/coverage.gni") import("//build/config/coverage/coverage.gni")
import("//build/config/sanitizers/sanitizers.gni") import("//build/config/sanitizers/sanitizers.gni")
no_default_deps = !use_clang_coverage && !using_sanitizer no_default_deps =
!use_clang_coverage && !using_sanitizer && chrome_pgo_phase != 1
remove_configs = remove_configs =
[ "//build/config/android:default_orderfile_instrumentation" ] [ "//build/config/android:default_orderfile_instrumentation" ]
} }