[arch-commits] Commit in electron14/trunk (4 files)

Nicola Squartini tensor5 at gemini.archlinux.org
Fri Feb 18 19:59:48 UTC 2022


    Date: Friday, February 18, 2022 @ 19:59:47
  Author: tensor5
Revision: 1134169

upgpkg: electron14 14.2.6-1

Added:
  electron14/trunk/breakpad-fix-for-non-constant-SIGSTKSZ.patch
  electron14/trunk/sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch
Modified:
  electron14/trunk/PKGBUILD
Deleted:
  electron14/trunk/chromium-93-ffmpeg-4.4.patch

------------------------------------------------------------+
 PKGBUILD                                                   |   25 +++----
 breakpad-fix-for-non-constant-SIGSTKSZ.patch               |   35 +++++++++
 chromium-93-ffmpeg-4.4.patch                               |   36 ----------
 sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch |   39 +++++++++++
 4 files changed, 86 insertions(+), 49 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2022-02-18 19:53:39 UTC (rev 1134168)
+++ PKGBUILD	2022-02-18 19:59:47 UTC (rev 1134169)
@@ -1,12 +1,12 @@
 # Maintainer: Nicola Squartini <tensor5 at gmail.com>
 
 _use_suffix=1
-pkgver=14.2.5
-_commit=f6798c5e994f9e1d7f88812ef6e5877e85b9c0eb
+pkgver=14.2.6
+_commit=38a6fb9a5387a43af3047764d3fd1c56eefd6dcd
 _chromiumver=93.0.4577.82
 _gcc_patchset=6
 # shellcheck disable=SC2034
-pkgrel=2
+pkgrel=1
 
 _major_ver=${pkgver%%.*}
 if [[ ${_use_suffix} != 0 ]]; then
@@ -28,7 +28,8 @@
 # shellcheck disable=SC2034
 makedepends=('clang' 'git' 'gn' 'gperf' 'harfbuzz-icu' 'http-parser'
              'java-runtime-headless' 'jsoncpp' 'libnotify' 'lld' 'llvm' 'ninja'
-             'npm' 'pciutils' 'pipewire' 'python' 'wget' 'yarn')
+             'npm' 'pciutils' 'pipewire' 'python' 'python-httplib2'
+             'python-pyparsing' 'python-six' 'wget' 'yarn')
 # shellcheck disable=SC2034
 optdepends=('kde-cli-tools: file deletion support (kioclient5)'
             'libappindicator-gtk3: StatusNotifierItem support'
@@ -60,10 +61,11 @@
         'gn-visibility-webrtc.patch'
         'replace-blacklist-with-ignorelist.patch'
         'sql-make-VirtualCursor-standard-layout-type.patch'
-        'chromium-93-ffmpeg-4.4.patch'
+        'breakpad-fix-for-non-constant-SIGSTKSZ.patch'        
         'chromium-94-ffmpeg-roll.patch'
         'chromium-93-pdfium-include.patch'
         'chromium-harfbuzz-3.0.0.patch'
+        'sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch'
         'skia-harfbuzz-3.0.0.patch'
        )
 # shellcheck disable=SC2034
@@ -83,10 +85,11 @@
             '574785a21168c3e9b7aa82630713ceb6ced12f699133db66b10fc84b7bb2c631'
             'd3344ba39b8c6ed202334ba7f441c70d81ddf8cdb15af1aa8c16e9a3a75fbb35'
             'dd317f85e5abfdcfc89c6f23f4c8edbcdebdd5e083dcec770e5da49ee647d150'
-            '1a9e074f417f8ffd78bcd6874d8e2e74a239905bf662f76a7755fa40dc476b57'
+            'b4d28867c1fabde6c50a2cfa3f784730446c4d86e5191e0f0000fbf7b0f91ecf'
             '56acb6e743d2ab1ed9f3eb01700ade02521769978d03ac43226dec94659b3ace'
             '7c0c47f4b67d96515bcfa68ffd34d515d03f1e9e41c063459f39e4169de0324c'
             '7ce947944a139e66774dfc7249bf7c3069f07f83a0f1b2c1a1b14287a7e15928'
+            'f910be9370c880de6e1d61cc30383c069e421d7acf406166e4fbfad324fc7d61'
             'dae11dec5088eb1b14045d8c9862801a342609c15701d7c371e1caccf46e1ffd')
 
 _system_libs=('ffmpeg'
@@ -183,14 +186,9 @@
   patch -Np1 -i ../patches/chromium-93-DevToolsEmbedderMessageDispatcher-include.patch
   patch -Np1 -i ../patches/chromium-93-ScopedTestDialogAutoConfirm-include.patch
 
+  patch -Np1 -d third_party/breakpad/breakpad < ../breakpad-fix-for-non-constant-SIGSTKSZ.patch
+  patch -Np1 -i ../chromium-93-pdfium-include.patch
   patch -Np1 -i ../chromium-94-ffmpeg-roll.patch
-  # Patches to build with ffmpeg 4.4; remove when ffmpeg 5.0 moves to stable
-  if ! pkg-config --atleast-version 59 libavformat; then
-    patch -Np1 -i ../chromium-93-ffmpeg-4.4.patch
-    patch -Rp1 -i ../chromium-94-ffmpeg-roll.patch
-  fi
-
-  patch -Np1 -i ../chromium-93-pdfium-include.patch
   patch -Np1 -i ../chromium-harfbuzz-3.0.0.patch
   patch -d third_party/jinja2 -Np1 -i ../../../jinja-python-3.10.patch
   patch -Np1 -d third_party/skia <../skia-harfbuzz-3.0.0.patch
@@ -201,6 +199,7 @@
   patch -Np1 -i ../gn-visibility-mojo.patch
   patch -Np1 -i ../gn-visibility-webrtc.patch
   patch -Rp1 -i ../replace-blacklist-with-ignorelist.patch
+  patch -Np1 -i ../sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch
   patch -Np1 -i ../sql-make-VirtualCursor-standard-layout-type.patch
   patch -d third_party/electron_node/tools/inspector_protocol/jinja2 \
       -Np1 -i ../../../../../../jinja-python-3.10.patch

Added: breakpad-fix-for-non-constant-SIGSTKSZ.patch
===================================================================
--- breakpad-fix-for-non-constant-SIGSTKSZ.patch	                        (rev 0)
+++ breakpad-fix-for-non-constant-SIGSTKSZ.patch	2022-02-18 19:59:47 UTC (rev 1134169)
@@ -0,0 +1,35 @@
+From 605c51ed96ad44b34c457bbca320e74e194c317e Mon Sep 17 00:00:00 2001
+From: David Faure <david.faure at kdab.com>
+Date: Wed, 15 Dec 2021 22:26:40 +0100
+Subject: [PATCH] Fix for non-constant SIGSTKSZ
+
+On glibc > 2.33, `SIGSTKSZ` might not be constant (in which case
+it expands to a call to `sysconf` which returns a `long int`); see
+https://sourceware.org/pipermail/libc-alpha/2020-October/118513.html
+
+Pass unsigned explicitly to std::max, to avoid relying on template
+argument deduction. This works both with the old-style constant
+`SIGSTKSZ` and the new configurable one.
+
+Initially based on https://chromium-review.googlesource.com/c/2776379
+
+Change-Id: I9fc95337f973e871b84735ce822b5e11ba73ea8c
+Reviewed-on: https://chromium-review.googlesource.com/c/breakpad/breakpad/+/3340721
+Reviewed-by: Mark Mentovai <mark at chromium.org>
+---
+ src/client/linux/handler/exception_handler.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/client/linux/handler/exception_handler.cc b/src/client/linux/handler/exception_handler.cc
+index ca353c40..499be0a9 100644
+--- a/src/client/linux/handler/exception_handler.cc
++++ b/src/client/linux/handler/exception_handler.cc
+@@ -138,7 +138,7 @@ void InstallAlternateStackLocked() {
+   // SIGSTKSZ may be too small to prevent the signal handlers from overrunning
+   // the alternative stack. Ensure that the size of the alternative stack is
+   // large enough.
+-  static const unsigned kSigStackSize = std::max(16384, SIGSTKSZ);
++  const unsigned kSigStackSize = std::max<unsigned>(16384, SIGSTKSZ);
+ 
+   // Only set an alternative stack if there isn't already one, or if the current
+   // one is too small.

Deleted: chromium-93-ffmpeg-4.4.patch
===================================================================
--- chromium-93-ffmpeg-4.4.patch	2022-02-18 19:53:39 UTC (rev 1134168)
+++ chromium-93-ffmpeg-4.4.patch	2022-02-18 19:59:47 UTC (rev 1134169)
@@ -1,36 +0,0 @@
-diff --git a/media/filters/ffmpeg_demuxer.cc b/media/filters/ffmpeg_demuxer.cc
-index ac4713b07268..492a9a37d096 100644
---- a/media/filters/ffmpeg_demuxer.cc
-+++ b/media/filters/ffmpeg_demuxer.cc
-@@ -427,11 +427,11 @@ void FFmpegDemuxerStream::EnqueuePacket(ScopedAVPacket packet) {
-   scoped_refptr<DecoderBuffer> buffer;
- 
-   if (type() == DemuxerStream::TEXT) {
--    size_t id_size = 0;
-+    int id_size = 0;
-     uint8_t* id_data = av_packet_get_side_data(
-         packet.get(), AV_PKT_DATA_WEBVTT_IDENTIFIER, &id_size);
- 
--    size_t settings_size = 0;
-+    int settings_size = 0;
-     uint8_t* settings_data = av_packet_get_side_data(
-         packet.get(), AV_PKT_DATA_WEBVTT_SETTINGS, &settings_size);
- 
-@@ -443,7 +443,7 @@ void FFmpegDemuxerStream::EnqueuePacket(ScopedAVPacket packet) {
-     buffer = DecoderBuffer::CopyFrom(packet->data, packet->size,
-                                      side_data.data(), side_data.size());
-   } else {
--    size_t side_data_size = 0;
-+    int side_data_size = 0;
-     uint8_t* side_data = av_packet_get_side_data(
-         packet.get(), AV_PKT_DATA_MATROSKA_BLOCKADDITIONAL, &side_data_size);
- 
-@@ -504,7 +504,7 @@ void FFmpegDemuxerStream::EnqueuePacket(ScopedAVPacket packet) {
-                                        packet->size - data_offset);
-     }
- 
--    size_t skip_samples_size = 0;
-+    int skip_samples_size = 0;
-     const uint32_t* skip_samples_ptr =
-         reinterpret_cast<const uint32_t*>(av_packet_get_side_data(
-             packet.get(), AV_PKT_DATA_SKIP_SAMPLES, &skip_samples_size));

Added: sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch
===================================================================
--- sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch	                        (rev 0)
+++ sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch	2022-02-18 19:59:47 UTC (rev 1134169)
@@ -0,0 +1,39 @@
+From 28ac6a15411d01301e171b8a8b0019abd57589b9 Mon Sep 17 00:00:00 2001
+From: Stephan Hartmann <stha09 at googlemail.com>
+Date: Mon, 7 Feb 2022 20:09:57 +0000
+Subject: [PATCH] sandbox: build if glibc 2.34+ dynamic stack size is enabled
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Compilation of sandbox fails when using dynamic stack size in glibc
+2.34 or newer. This is because the value is not a literal anymore but
+obtained through sysconf.
+
+To avoid this, use memset to put zeros in the buffer.
+
+Change-Id: Ia479e0f799b77a10a00197aaaa0500e62546f458
+Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3436947
+Reviewed-by: Jorge Lucangeli Obes <jorgelo at chromium.org>
+Commit-Queue: José Dapena Paz <jdapena at igalia.com>
+Cr-Commit-Position: refs/heads/main@{#967943}
+---
+ sandbox/linux/services/credentials.cc | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/sandbox/linux/services/credentials.cc b/sandbox/linux/services/credentials.cc
+index ca6b5954798..c933eafd163 100644
+--- a/sandbox/linux/services/credentials.cc
++++ b/sandbox/linux/services/credentials.cc
+@@ -100,7 +100,10 @@ bool ChrootToSafeEmptyDir() {
+   // TODO(crbug.com/1247458) Broken in MSan builds after LLVM f1bb30a4956f.
+   clone_flags |= CLONE_VM | CLONE_VFORK | CLONE_SETTLS;
+ 
+-  char tls_buf[PTHREAD_STACK_MIN] = {0};
++  // PTHREAD_STACK_MIN can be dynamic in glibc2.34+, so it is not possible to
++  // zeroify tls_buf assigning { 0 }
++  char tls_buf[PTHREAD_STACK_MIN];
++  memset(tls_buf, 0, PTHREAD_STACK_MIN);
+   tls = tls_buf;
+ #endif
+ 



More information about the arch-commits mailing list