7
0
Files
nodejs-electron/gcc-enable-lto.patch
Dominique Leuenberger 612fa607f8 Accepting request 962506 from devel:languages:javascript
- Update to version 17.1.2
  * https://github.com/electron/electron/releases/tag/v17.1.2
  * https://github.com/electron/electron/releases/tag/v17.1.1
  * https://github.com/electron/electron/releases/tag/v17.1.0
  * Added electron-17-breakpad-align-int-types.patch
  * Added chromium-98-compiler.patch
  * Added chromium-98-MiraclePtr-gcc-ice.patch
  * Added chromium-98-WaylandFrameManager-check.patch
  * Added chromium-98-EnumTable-crash.patch
  * Added chromium-ffmpeg-first-dts.patch
  * Added system-libdrm.patch
  * Removed chromium-94-ffmpeg-roll.patch
  * Removed chromium-95-compiler.patch
  * Removed chromium-96-CommandLine-include.patch
  * Removed chromium-96-DrmRenderNodePathFinder-include.patch
  * Removed chromium-96-RestrictedCookieManager-tuple.patch
  * Removed electron-16-node-fix-python3.10-import.patch
- Fix building with gcc-12
  * Added electron-16-fix-swiftshader-template.patch
  * Added electron-16-v8-missing-utility-include.patch
- Fix building on Fedora 36 and newer
- Updated ffmpeg patches

OBS-URL: https://build.opensuse.org/request/show/962506
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/nodejs-electron?expand=0&rev=20
2022-03-18 15:41:41 +00:00

71 lines
2.5 KiB
Diff

Index: electron-17.1.0/build/config/BUILDCONFIG.gn
===================================================================
--- electron-17.1.0.orig/build/config/BUILDCONFIG.gn 2022-03-07 17:38:24.389172130 +0100
+++ electron-17.1.0/build/config/BUILDCONFIG.gn 2022-03-09 08:25:02.246701706 +0100
@@ -138,6 +138,8 @@ declare_args() {
# set "is_official_build" to true for any build intended to ship to end-users.
is_official_build = false
+ gcc_lto = false
+
# Set to true when compiling with the Clang compiler.
is_clang = current_os != "linux" ||
(current_cpu != "s390x" && current_cpu != "s390" &&
@@ -352,6 +354,12 @@ default_compiler_configs = [
"//electron/build/config:mas_build",
]
+if (gcc_lto) {
+ default_compiler_configs += [
+ "//build/config/compiler:gcc_lto",
+ ]
+}
+
if (is_win) {
default_compiler_configs += [
"//build/config/win:default_cfg_compiler",
Index: electron-17.1.0/build/config/compiler/BUILD.gn
===================================================================
--- electron-17.1.0.orig/build/config/compiler/BUILD.gn 2022-03-09 08:24:53.098851231 +0100
+++ electron-17.1.0/build/config/compiler/BUILD.gn 2022-03-09 08:25:02.250701641 +0100
@@ -1880,6 +1880,10 @@ if (is_win) {
}
}
+config("gcc_lto") {
+ cflags = [ "-flto" ]
+}
+
config("default_stack_frames") {
if (is_posix || is_fuchsia) {
if (enable_frame_pointers) {
Index: electron-17.1.0/sandbox/linux/BUILD.gn
===================================================================
--- electron-17.1.0.orig/sandbox/linux/BUILD.gn 2022-03-07 17:20:37.288839348 +0100
+++ electron-17.1.0/sandbox/linux/BUILD.gn 2022-03-09 08:25:02.250701641 +0100
@@ -245,6 +245,9 @@ component("seccomp_bpf") {
"//build:chromeos_buildflags",
"//sandbox:sandbox_buildflags",
]
+ if (gcc_lto) {
+ configs -= [ "//build/config/compiler:gcc_lto" ]
+ }
if (is_android) {
sources += [
Index: electron-17.1.0/base/BUILD.gn
===================================================================
--- electron-17.1.0.orig/base/BUILD.gn 2022-03-07 17:20:29.432807450 +0100
+++ electron-17.1.0/base/BUILD.gn 2022-03-09 08:25:02.250701641 +0100
@@ -2026,6 +2026,10 @@ component("base") {
]
}
+ if (gcc_lto) {
+ configs -= [ "//build/config/compiler:gcc_lto" ]
+ }
+
if (current_cpu == "x64") {
defines += [ "PA_PCSCAN_STACK_SUPPORTED" ]
sources += [ "allocator/partition_allocator/starscan/stack/asm/x64/push_registers_asm.cc" ]