build: move libcc patches to electron repo (#14104)
In the GN build, libchromiumcontent is no longer a distinct library, but merely a container for a set of scripts and patches. Maintaining those patches in a separate repository is tedious and error-prone, so merge them into the main repo. Once this is merged and GN is the default way to build Electron, the libchromiumcontent repository can be archived.
This commit is contained in:
parent
9e85bdb02c
commit
76c5f5cc8a
147 changed files with 86931 additions and 6 deletions
6
patches/mips64el/v8/.patches.yaml
Normal file
6
patches/mips64el/v8/.patches.yaml
Normal file
|
@ -0,0 +1,6 @@
|
|||
repo: src/v8
|
||||
patches:
|
||||
-
|
||||
author: Cheng Zhao <zcbenz@gmail.com>
|
||||
file: Fix-v8-loongson-page-size.patch
|
||||
description: null
|
38
patches/mips64el/v8/Fix-v8-loongson-page-size.patch
Normal file
38
patches/mips64el/v8/Fix-v8-loongson-page-size.patch
Normal file
|
@ -0,0 +1,38 @@
|
|||
diff --git a/src/base/platform/platform-posix.cc b/src/base/platform/platform-posix.cc
|
||||
index 31da953..14c6c55 100644
|
||||
--- a/src/base/platform/platform-posix.cc
|
||||
+++ b/src/base/platform/platform-posix.cc
|
||||
@@ -97,7 +97,11 @@ int OS::ActivationFrameAlignment() {
|
||||
|
||||
|
||||
intptr_t OS::CommitPageSize() {
|
||||
+#if V8_TARGET_ARCH_MIPS64
|
||||
+ static intptr_t page_size = 16384;
|
||||
+#else
|
||||
static intptr_t page_size = getpagesize();
|
||||
+#endif
|
||||
return page_size;
|
||||
}
|
||||
|
||||
@@ -241,7 +245,7 @@ void* OS::GetRandomMmapAddr() {
|
||||
|
||||
|
||||
size_t OS::AllocateAlignment() {
|
||||
- return static_cast<size_t>(sysconf(_SC_PAGESIZE));
|
||||
+ return 16384;
|
||||
}
|
||||
|
||||
|
||||
diff --git a/src/base/sys-info.cc b/src/base/sys-info.cc
|
||||
index 1b6d393..2a93061 100644
|
||||
--- a/src/base/sys-info.cc
|
||||
+++ b/src/base/sys-info.cc
|
||||
@@ -90,7 +90,7 @@ int64_t SysInfo::AmountOfPhysicalMemory() {
|
||||
return static_cast<int64_t>(result) * 1024L;
|
||||
#elif V8_OS_POSIX
|
||||
long pages = sysconf(_SC_PHYS_PAGES); // NOLINT(runtime/int)
|
||||
- long page_size = sysconf(_SC_PAGESIZE); // NOLINT(runtime/int)
|
||||
+ long page_size = 16384; // NOLINT(runtime/int)
|
||||
if (pages == -1 || page_size == -1) {
|
||||
return 0;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue