put the embedded blob code section in .rodata to fix x-only

discussed with deraadt@, kettenis@, tb@
This commit is contained in:
robert 2023-01-19 12:43:44 +00:00
parent 8f64011107
commit aa589542d8
4 changed files with 34 additions and 0 deletions

View File

@ -12,6 +12,8 @@ COMMENT= Iridium browser
V= 2023.01.109
REVISION= 0
DISTNAME= iridium-browser-${V}
PKGNAME= iridium-${V}
DISTFILES= ${DISTNAME}${EXTRACT_SUFX}

View File

@ -0,0 +1,15 @@
Index: v8/src/snapshot/embedded/embedded-file-writer.cc
--- v8/src/snapshot/embedded/embedded-file-writer.cc.orig
+++ v8/src/snapshot/embedded/embedded-file-writer.cc
@@ -137,7 +137,11 @@ void EmbeddedFileWriter::WriteCodeSection(PlatformEmbe
w->Comment(
"The embedded blob code section starts here. It contains the builtin");
w->Comment("instruction streams.");
+#if V8_TARGET_OS_OPENBSD
+ w->SectionRoData();
+#else
w->SectionText();
+#endif
#if V8_TARGET_ARCH_IA32 || V8_TARGET_ARCH_X64
// UMA needs an exposed function-type label at the start of the embedded

View File

@ -10,6 +10,8 @@ COMMENT= Chromium browser sans integration with Google
V= 109.0.5414.74
UGV= ${V}-1
REVISION= 0
DISTNAME= ungoogled-chromium-${V}
DISTFILES+= ${CHROMIUM_DISTFILES} \

View File

@ -0,0 +1,15 @@
Index: v8/src/snapshot/embedded/embedded-file-writer.cc
--- v8/src/snapshot/embedded/embedded-file-writer.cc.orig
+++ v8/src/snapshot/embedded/embedded-file-writer.cc
@@ -137,7 +137,11 @@ void EmbeddedFileWriter::WriteCodeSection(PlatformEmbe
w->Comment(
"The embedded blob code section starts here. It contains the builtin");
w->Comment("instruction streams.");
+#if V8_TARGET_OS_OPENBSD
+ w->SectionRoData();
+#else
w->SectionText();
+#endif
#if V8_TARGET_ARCH_IA32 || V8_TARGET_ARCH_X64
// UMA needs an exposed function-type label at the start of the embedded