Linux: use chrome_crashpad_handler instead of crashpad_handler
Linux needs to use our custom chrome_crashpad_handler instead of crashpad's upstream default crashpad_handler, like Windows and Mac, in order to add custom chrome-specific GWP-ASAN stack traces. Installers should bundle the chrome_crashpad_handler executable rather than crashpad_handler. Bug: 1233008 Change-Id: I71291dcf4a420252b300ee3954c55eafd4b01729 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3054290 Commit-Queue: Matthew Denton <mpdenton@chromium.org> Reviewed-by: Mark Mentovai <mark@chromium.org> Reviewed-by: Lei Zhang <thestig@chromium.org> Reviewed-by: Dirk Pranke <dpranke@google.com> Reviewed-by: Peter Beverloo <peter@chromium.org> Cr-Commit-Position: refs/heads/master@{#908155}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
72301c57c5
commit
f9d1fd9bfa
build/lacros
chrome
components/crash/core/app
content/shell
infra/config
tools/bisect_repackage
@ -98,7 +98,8 @@ _TRACKED_GROUPS = [
|
||||
title='File: chrome',
|
||||
track_stripped=True,
|
||||
track_compressed=True),
|
||||
_Group(paths=['crashpad_handler'], title='File: crashpad_handler'),
|
||||
_Group(paths=['chrome_crashpad_handler'],
|
||||
title='File: chrome_crashpad_handler'),
|
||||
_Group(paths=['icudtl.dat'], title='File: icudtl.dat'),
|
||||
_Group(paths=['nacl_helper'], title='File: nacl_helper'),
|
||||
_Group(paths=['nacl_irt_x86_64.nexe'], title='File: nacl_irt_x86_64.nexe'),
|
||||
|
@ -273,6 +273,8 @@ if (!is_android && !is_mac) {
|
||||
"//chrome/common:buildflags",
|
||||
]
|
||||
|
||||
data_deps += [ "//components/crash/core/app:chrome_crashpad_handler" ]
|
||||
|
||||
ldflags = []
|
||||
|
||||
# Chrome OS debug builds for arm need to pass --long-plt to the linker.
|
||||
@ -1681,8 +1683,8 @@ if (is_linux || is_chromeos) {
|
||||
deps = [
|
||||
":angle_egl_symbols",
|
||||
":angle_gles_symbols",
|
||||
":chrome_crashpad_symbols",
|
||||
":chrome_symbols",
|
||||
":crashpad_symbols",
|
||||
":swiftshader_egl_symbols",
|
||||
":swiftshader_gles_symbols",
|
||||
]
|
||||
@ -1705,8 +1707,8 @@ if (is_linux || is_chromeos) {
|
||||
|
||||
deps = [ ":chrome" ]
|
||||
}
|
||||
extract_symbols("crashpad_symbols") {
|
||||
binary = "$root_out_dir/crashpad_handler"
|
||||
extract_symbols("chrome_crashpad_symbols") {
|
||||
binary = "$root_out_dir/chrome_crashpad_handler"
|
||||
|
||||
if (current_cpu == "x86") {
|
||||
# GYP used "ia32" so keep that naming for back-compat.
|
||||
@ -1715,7 +1717,7 @@ if (is_linux || is_chromeos) {
|
||||
symbol_file = "$root_out_dir/crashpad.breakpad.$current_cpu"
|
||||
}
|
||||
|
||||
deps = [ "//third_party/crashpad/crashpad/handler:crashpad_handler" ]
|
||||
deps = [ "//components/crash/core/app:chrome_crashpad_handler" ]
|
||||
}
|
||||
extract_symbols("swiftshader_egl_symbols") {
|
||||
binary = "$root_out_dir/swiftshader/libEGL.so"
|
||||
|
@ -34,8 +34,8 @@ assert(is_linux || is_chromeos)
|
||||
|
||||
packaging_files_executables = [
|
||||
"$root_out_dir/chrome",
|
||||
"$root_out_dir/chrome_crashpad_handler",
|
||||
"$root_out_dir/chrome_sandbox",
|
||||
"$root_out_dir/crashpad_handler",
|
||||
]
|
||||
packaging_files_shlibs = []
|
||||
|
||||
@ -322,8 +322,8 @@ group("installer_deps") {
|
||||
"//chrome",
|
||||
"//chrome:packed_resources",
|
||||
"//chrome/browser/resources/media/mei_preload:component",
|
||||
"//components/crash/core/app:chrome_crashpad_handler",
|
||||
"//sandbox/linux:chrome_sandbox",
|
||||
"//third_party/crashpad/crashpad/handler:crashpad_handler",
|
||||
]
|
||||
if (enable_nacl) {
|
||||
public_deps += [
|
||||
|
@ -143,11 +143,11 @@ stage_install_common() {
|
||||
install -m 755 "${STRIPPEDFILE}" "${STAGEDIR}/${INSTALLDIR}/${PROGNAME}"
|
||||
|
||||
# crashpad
|
||||
buildfile="${OUTPUTDIR}/crashpad_handler"
|
||||
buildfile="${OUTPUTDIR}/chrome_crashpad_handler"
|
||||
strippedfile="${buildfile}.stripped"
|
||||
debugfile="${buildfile}.debug"
|
||||
"${OUTPUTDIR}/installer/common/eu-strip" -o "${strippedfile}" -f "${debugfile}" "${buildfile}"
|
||||
install -m 755 "${strippedfile}" "${STAGEDIR}/${INSTALLDIR}/crashpad_handler"
|
||||
install -m 755 "${strippedfile}" "${STAGEDIR}/${INSTALLDIR}/chrome_crashpad_handler"
|
||||
|
||||
# resources
|
||||
install -m 644 "${OUTPUTDIR}/resources.pak" "${STAGEDIR}/${INSTALLDIR}/"
|
||||
|
@ -47,7 +47,7 @@ FILES = [
|
||||
'buildtype': ['dev', 'official'],
|
||||
},
|
||||
{
|
||||
'filename': 'crashpad_handler',
|
||||
'filename': 'chrome_crashpad_handler',
|
||||
'buildtype': ['dev', 'official'],
|
||||
},
|
||||
{
|
||||
|
@ -48,7 +48,7 @@ FILES = [
|
||||
'buildtype': ['dev', 'official'],
|
||||
},
|
||||
{
|
||||
'filename': 'crashpad_handler',
|
||||
'filename': 'chrome_crashpad_handler',
|
||||
'buildtype': ['dev', 'official'],
|
||||
},
|
||||
{
|
||||
|
@ -128,10 +128,6 @@ static_library("app") {
|
||||
if (is_ios) {
|
||||
sources += [ "crashpad_ios.mm" ]
|
||||
}
|
||||
|
||||
if (is_linux || is_chromeos) {
|
||||
data_deps = [ "//third_party/crashpad/crashpad/handler:crashpad_handler" ]
|
||||
}
|
||||
}
|
||||
|
||||
if (is_win) {
|
||||
@ -214,7 +210,7 @@ if (is_win) {
|
||||
}
|
||||
}
|
||||
|
||||
if (is_mac || is_android) {
|
||||
if (is_mac || is_android || is_linux || is_chromeos) {
|
||||
# We build a chromium-specific crashpad_handler executable so that we can
|
||||
# define custom UserStreamDataSources.
|
||||
executable("chrome_crashpad_handler") {
|
||||
|
@ -115,7 +115,7 @@ base::FilePath PlatformCrashpadInitialization(
|
||||
if (!base::PathService::Get(base::DIR_EXE, &handler_path)) {
|
||||
return database_path;
|
||||
}
|
||||
handler_path = handler_path.Append("crashpad_handler");
|
||||
handler_path = handler_path.Append("chrome_crashpad_handler");
|
||||
|
||||
// When --use-cros-crash-reporter is set (below), the handler passes dumps
|
||||
// to ChromeOS's /sbin/crash_reporter which in turn passes the dump to
|
||||
|
@ -538,9 +538,11 @@ if (is_android) {
|
||||
}
|
||||
}
|
||||
|
||||
if (is_win || is_linux || is_chromeos) {
|
||||
if (is_win) {
|
||||
data_deps +=
|
||||
[ "//third_party/crashpad/crashpad/handler:crashpad_handler" ]
|
||||
} else if (is_linux || is_chromeos) {
|
||||
data_deps += [ "//components/crash/core/app:chrome_crashpad_handler" ]
|
||||
}
|
||||
|
||||
if ((is_linux || is_chromeos) && !is_component_build) {
|
||||
|
@ -38144,7 +38144,7 @@ buckets {
|
||||
' "chrome",'
|
||||
' "chrome_100_percent.pak",'
|
||||
' "chrome_200_percent.pak",'
|
||||
' "crashpad_handler",'
|
||||
' "chrome_crashpad_handler",'
|
||||
' "headless_lib.pak",'
|
||||
' "icudtl.dat",'
|
||||
' "nacl_helper",'
|
||||
@ -39623,7 +39623,7 @@ buckets {
|
||||
' "chrome",'
|
||||
' "chrome_100_percent.pak",'
|
||||
' "chrome_200_percent.pak",'
|
||||
' "crashpad_handler",'
|
||||
' "chrome_crashpad_handler",'
|
||||
' "headless_lib.pak",'
|
||||
' "icudtl.dat",'
|
||||
' "libminigbm.so",'
|
||||
|
@ -1846,7 +1846,7 @@ ci.chromiumos_builder(
|
||||
"chrome",
|
||||
"chrome_100_percent.pak",
|
||||
"chrome_200_percent.pak",
|
||||
"crashpad_handler",
|
||||
"chrome_crashpad_handler",
|
||||
"headless_lib.pak",
|
||||
"icudtl.dat",
|
||||
"nacl_helper",
|
||||
@ -3306,7 +3306,7 @@ ci.fyi_builder(
|
||||
"chrome",
|
||||
"chrome_100_percent.pak",
|
||||
"chrome_200_percent.pak",
|
||||
"crashpad_handler",
|
||||
"chrome_crashpad_handler",
|
||||
"headless_lib.pak",
|
||||
"icudtl.dat",
|
||||
"libminigbm.so",
|
||||
|
@ -45,7 +45,7 @@ CHROME_REQUIRED_FILES = {
|
||||
'chrome_100_percent.pak',
|
||||
'chrome_200_percent.pak',
|
||||
'chromedriver',
|
||||
'crashpad_handler',
|
||||
'chrome_crashpad_handler',
|
||||
'default_apps/',
|
||||
'icudtl.dat',
|
||||
'ClearKeyCdm/',
|
||||
@ -97,7 +97,7 @@ CHROME_WHITELIST_FILES = {
|
||||
CHROME_STRIP_LIST = {
|
||||
'linux': [
|
||||
'chrome',
|
||||
'crashpad_handler',
|
||||
'chrome_crashpad_handler',
|
||||
'nacl_helper'
|
||||
]
|
||||
}
|
||||
|
Reference in New Issue
Block a user