From 24ac0330f05c73dcadb1414858aa388edacee156 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Riku=20Palom=C3=A4ki?= Date: Wed, 27 Feb 2019 19:16:35 +0000 Subject: [PATCH] Linux: Fix cefclient when using component build and tcmalloc. Link to libbase.so to fix FATAL:content_main_runner_impl.cc(731)] Check failed: base::allocator::IsAllocatorInitialized(). --- BUILD.gn | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/BUILD.gn b/BUILD.gn index e0ea85826..05a24e0ec 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -2096,7 +2096,13 @@ if (is_mac) { ] } - if (!is_component_build) { + if (is_component_build) { + if (use_allocator=="tcmalloc") { + # Link to base to initialize tcmalloc allocator shims, otherwise + # base::allocator::IsAllocatorInitialized check fails + deps += [ "//base" ] + } + } else { # Set rpath to find our own libfreetype even in a non-component build. configs += [ "//build/config/gcc:rpath_for_built_shared_libraries" ] }