fix: re-enable PartitionAlloc on macOS (#32442)

* fix: re-enable PartitionAlloc on macOS

* no need to copy ignore_result on linux

* factor out FixStdioStreams

* include buildflags.h in electron_main_linux

* #include electron/fuses

* more missing includes
This commit is contained in:
Jeremy Rose 2022-01-16 23:46:33 -08:00 committed by GitHub
parent fac61122d5
commit 6e6f5efad9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 197 additions and 182 deletions

View file

@ -109,7 +109,6 @@ mas_gate_private_enterprise_APIs.patch
load_v8_snapshot_in_browser_process.patch
fix_patch_out_permissions_checks_in_exclusive_access.patch
fix_aspect_ratio_with_max_size.patch
build_disable_partitionalloc_on_mac.patch
revert_stop_using_nsrunloop_in_renderer_process.patch
fix_dont_delete_SerialPortManager_on_main_thread.patch
feat_add_data_transfer_to_requestsingleinstancelock.patch

View file

@ -1,22 +0,0 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: clavin <cwatford@slack-corp.com>
Date: Tue, 21 Dec 2021 10:17:37 -0700
Subject: build: disable PartitionAlloc on mac
PartitionAlloc on mac requires some restructuring in Electron as well as considerations about the mas build. In the mean time, disabling it should be fine.
This patch can be removed once the mac app runs safely with PartitionAlloc on (i.e. removing dependency to //base in the main app) & the situation with mas is figured out.
diff --git a/base/allocator/allocator.gni b/base/allocator/allocator.gni
index 7d579d6e2297c047415eeeb641c70871b5c3f80d..e6edb52dd15af0f369160696fb2a34b0f80680a4 100644
--- a/base/allocator/allocator.gni
+++ b/base/allocator/allocator.gni
@@ -18,7 +18,7 @@ _is_using_sanitizers = is_asan || is_hwasan || is_lsan || is_tsan || is_msan
# - Windows: debug CRT is not compatible, see below.
_disable_partition_alloc = is_component_build || (is_win && is_debug)
_is_partition_alloc_platform =
- is_android || is_win || is_mac || is_linux || is_chromeos
+ is_android || is_win || is_linux || is_chromeos
# The debug CRT on Windows has some debug features that are incompatible with
# the shim. NaCl in particular does seem to link some binaries statically