Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit483e39c

Browse files
chore: cherry-pick 97193a64b431 from chromium (#35184)
Backportshttps://chromium-review.googlesource.com/c/chromium/src/+/3542265Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
1 parentcd7490d commit483e39c

File tree

2 files changed

+55
-0
lines changed

2 files changed

+55
-0
lines changed

‎patches/chromium/.patches‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,3 +140,4 @@ cherry-pick-902f0d144a5b.patch
140140
cherry-pick-664e0d8b4cfb.patch
141141
chore_add_electron_deps_to_gitignores.patch
142142
chore_allow_chromium_to_handle_synthetic_mouse_events_for_touch.patch
143+
do_not_reduce_page_size_from_64k_to_4k_on_linux_arm64.patch
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
2+
From: =?UTF-8?q?Dominik=20Inf=C3=BChr?= <dinfuehr@chromium.org>
3+
Date: Tue, 22 Mar 2022 17:33:03 +0000
4+
Subject: Do not reduce page size from 64K to 4K on Linux/ARM64
5+
MIME-Version: 1.0
6+
Content-Type: text/plain; charset=UTF-8
7+
Content-Transfer-Encoding: 8bit
8+
9+
This fixes build on Asahi Linux which uses 16K pages.
10+
11+
Change-Id: I8cf3664849d98bcb984f339ebf9076d1cfaf5701
12+
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3542265
13+
Reviewed-by: Andrew Grieve <agrieve@chromium.org>
14+
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
15+
Cr-Commit-Position: refs/heads/main@{#983900}
16+
17+
diff --git a/build/config/android/BUILD.gn b/build/config/android/BUILD.gn
18+
index 4fc5565e27a596fe4aa1a093cfc0567fbd24b2a0..69341cea35d0c44aeb5f09b39783bd2abfcdcc43 100644
19+
--- a/build/config/android/BUILD.gn
20+
+++ b/build/config/android/BUILD.gn
21+
@@ -47,6 +47,13 @@ config("compiler") {
22+
"-Wl,--exclude-libs=libvpx_assembly_arm.a",
23+
]
24+
25+
+ if (current_cpu == "arm64") {
26+
+ # Reduce the page size from 65536 in order to reduce binary size slightly
27+
+ # by shrinking the alignment gap between segments. This also causes all
28+
+ # segments to be mapped adjacently, which breakpad relies on.
29+
+ ldflags += [ "-Wl,-z,max-page-size=4096" ]
30+
+ }
31+
+
32+
if (current_cpu == "arm64") {
33+
if (arm_control_flow_integrity == "standard") {
34+
cflags += [ "-mbranch-protection=standard" ]
35+
diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
36+
index 7b9ce0172eedf2b55fe7f3de7baee2f2028f4a7b..8f932d6493ec84f89c69078f95db7fc7ad03ef05 100644
37+
--- a/build/config/compiler/BUILD.gn
38+
+++ b/build/config/compiler/BUILD.gn
39+
@@ -454,14 +454,7 @@ config("compiler") {
40+
41+
# Linux-specific compiler flags setup.
42+
# ------------------------------------
43+
- if ((is_posix || is_fuchsia) && !is_apple && use_lld) {
44+
- if (current_cpu == "arm64") {
45+
- # Reduce the page size from 65536 in order to reduce binary size slightly
46+
- # by shrinking the alignment gap between segments. This also causes all
47+
- # segments to be mapped adjacently, which breakpad relies on.
48+
- ldflags += [ "-Wl,-z,max-page-size=4096" ]
49+
- }
50+
- } else if (use_gold) {
51+
+ if (use_gold) {
52+
ldflags += [ "-fuse-ld=gold" ]
53+
if (!is_android) {
54+
# On Android, this isn't needed. gcc in the NDK knows to look next to

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp