[arch-commits] Commit in electron15/repos/community-x86_64 (35 files)
Nicola Squartini
tensor5 at gemini.archlinux.org
Fri Mar 25 21:02:30 UTC 2022
Date: Friday, March 25, 2022 @ 21:02:30
Author: tensor5
Revision: 1176687
archrelease: copy trunk to community-x86_64
Added:
electron15/repos/community-x86_64/PKGBUILD
(from rev 1176686, electron15/trunk/PKGBUILD)
electron15/repos/community-x86_64/add-a-TODO-about-a-missing-pnacl-flag.patch
(from rev 1176686, electron15/trunk/add-a-TODO-about-a-missing-pnacl-flag.patch)
electron15/repos/community-x86_64/breakpad-fix-for-non-constant-SIGSTKSZ.patch
(from rev 1176686, electron15/trunk/breakpad-fix-for-non-constant-SIGSTKSZ.patch)
electron15/repos/community-x86_64/default_app-icon.patch
(from rev 1176686, electron15/trunk/default_app-icon.patch)
electron15/repos/community-x86_64/electron-launcher.sh
(from rev 1176686, electron15/trunk/electron-launcher.sh)
electron15/repos/community-x86_64/electron.desktop
(from rev 1176686, electron15/trunk/electron.desktop)
electron15/repos/community-x86_64/gn-visibility-gmock.patch
(from rev 1176686, electron15/trunk/gn-visibility-gmock.patch)
electron15/repos/community-x86_64/gn-visibility-mojo.patch
(from rev 1176686, electron15/trunk/gn-visibility-mojo.patch)
electron15/repos/community-x86_64/gn-visibility-webrtc.patch
(from rev 1176686, electron15/trunk/gn-visibility-webrtc.patch)
electron15/repos/community-x86_64/jinja-python-3.10.patch
(from rev 1176686, electron15/trunk/jinja-python-3.10.patch)
electron15/repos/community-x86_64/replace-blacklist-with-ignorelist.patch
(from rev 1176686, electron15/trunk/replace-blacklist-with-ignorelist.patch)
electron15/repos/community-x86_64/sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch
(from rev 1176686, electron15/trunk/sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch)
electron15/repos/community-x86_64/sql-make-VirtualCursor-standard-layout-type.patch
(from rev 1176686, electron15/trunk/sql-make-VirtualCursor-standard-layout-type.patch)
electron15/repos/community-x86_64/unbundle-fix-visibility-of-build-config-freetype.patch
(from rev 1176686, electron15/trunk/unbundle-fix-visibility-of-build-config-freetype.patch)
electron15/repos/community-x86_64/unexpire-accelerated-video-decode-flag.patch
(from rev 1176686, electron15/trunk/unexpire-accelerated-video-decode-flag.patch)
electron15/repos/community-x86_64/use-ffile-compilation-dir.patch
(from rev 1176686, electron15/trunk/use-ffile-compilation-dir.patch)
electron15/repos/community-x86_64/use-system-libraries-in-node.patch
(from rev 1176686, electron15/trunk/use-system-libraries-in-node.patch)
Deleted:
electron15/repos/community-x86_64/PKGBUILD
electron15/repos/community-x86_64/add-a-TODO-about-a-missing-pnacl-flag.patch
electron15/repos/community-x86_64/breakpad-fix-for-non-constant-SIGSTKSZ.patch
electron15/repos/community-x86_64/default_app-icon.patch
electron15/repos/community-x86_64/electron-launcher.sh
electron15/repos/community-x86_64/electron.desktop
electron15/repos/community-x86_64/gn-visibility-gmock.patch
electron15/repos/community-x86_64/gn-visibility-mojo.patch
electron15/repos/community-x86_64/gn-visibility-webrtc.patch
electron15/repos/community-x86_64/jinja-python-3.10.patch
electron15/repos/community-x86_64/pr-33038.patch
electron15/repos/community-x86_64/replace-blacklist-with-ignorelist.patch
electron15/repos/community-x86_64/sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch
electron15/repos/community-x86_64/sql-make-VirtualCursor-standard-layout-type.patch
electron15/repos/community-x86_64/unbundle-fix-visibility-of-build-config-freetype.patch
electron15/repos/community-x86_64/unexpire-accelerated-video-decode-flag.patch
electron15/repos/community-x86_64/use-ffile-compilation-dir.patch
electron15/repos/community-x86_64/use-system-libraries-in-node.patch
------------------------------------------------------------+
PKGBUILD | 581 ++++-----
add-a-TODO-about-a-missing-pnacl-flag.patch | 56
breakpad-fix-for-non-constant-SIGSTKSZ.patch | 70 -
default_app-icon.patch | 42
electron-launcher.sh | 40
electron.desktop | 14
gn-visibility-gmock.patch | 86 -
gn-visibility-mojo.patch | 72 -
gn-visibility-webrtc.patch | 90 -
jinja-python-3.10.patch | 66 -
pr-33038.patch | 643 -----------
replace-blacklist-with-ignorelist.patch | 392 +++---
sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch | 78 -
sql-make-VirtualCursor-standard-layout-type.patch | 476 ++++----
unbundle-fix-visibility-of-build-config-freetype.patch | 62 -
unexpire-accelerated-video-decode-flag.patch | 22
use-ffile-compilation-dir.patch | 130 +-
use-system-libraries-in-node.patch | 104 -
18 files changed, 1187 insertions(+), 1837 deletions(-)
Deleted: PKGBUILD
===================================================================
--- PKGBUILD 2022-03-25 21:02:02 UTC (rev 1176686)
+++ PKGBUILD 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,294 +0,0 @@
-# Maintainer: Nicola Squartini <tensor5 at gmail.com>
-
-_use_suffix=1
-pkgver=15.4.1
-_commit=8e517202ea5d62e3827d14275904bd48ccbfc3e5
-_chromiumver=94.0.4606.81
-_gcc_patchset=3
-# shellcheck disable=SC2034
-pkgrel=2
-
-_major_ver=${pkgver%%.*}
-if [[ ${_use_suffix} != 0 ]]; then
- pkgname="electron${_major_ver}"
-else
- pkgname=electron
-fi
-# shellcheck disable=SC2034
-pkgdesc='Build cross platform desktop apps with web technologies'
-# shellcheck disable=SC2034
-arch=('x86_64')
-# shellcheck disable=SC2034
-url='https://electronjs.org/'
-# shellcheck disable=SC2034
-license=('MIT' 'custom')
-# shellcheck disable=SC2034
-depends=('c-ares' 'ffmpeg' 'gtk3' 'libevent' 'libxslt' 'minizip' 'nss' 're2'
- 'snappy')
-# shellcheck disable=SC2034
-makedepends=('clang' 'git' 'gn' 'gperf' 'harfbuzz-icu' 'http-parser'
- 'java-runtime-headless' 'jsoncpp' 'libnotify' 'lld' 'llvm' 'ninja'
- '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'
- 'pipewire: WebRTC desktop sharing under Wayland'
- 'trash-cli: file deletion support (trash-put)'
- "xdg-utils: open URLs with desktop's default (xdg-email, xdg-open)")
-if [[ ${_use_suffix} == 0 ]]; then
- # shellcheck disable=SC2034
- conflicts=("electron${_major_ver}")
- # shellcheck disable=SC2034
- provides=("electron${_major_ver}")
-fi
-# shellcheck disable=SC2034
-options=('!lto') # Electron adds its own flags for ThinLTO
-# shellcheck disable=SC2034
-source=('git+https://github.com/electron/electron.git'
- 'git+https://chromium.googlesource.com/chromium/tools/depot_tools.git#branch=main'
- "https://github.com/stha09/chromium-patches/releases/download/chromium-${_chromiumver%%.*}-patchset-${_gcc_patchset}/chromium-${_chromiumver%%.*}-patchset-${_gcc_patchset}.tar.xz"
- "electron-launcher.sh"
- "electron.desktop"
- 'pr-33038.patch'
- 'default_app-icon.patch'
- 'jinja-python-3.10.patch'
- 'use-system-libraries-in-node.patch'
- 'replace-blacklist-with-ignorelist.patch'
- 'sql-make-VirtualCursor-standard-layout-type.patch'
- 'unbundle-fix-visibility-of-build-config-freetype.patch'
- 'gn-visibility-gmock.patch'
- 'gn-visibility-mojo.patch'
- 'gn-visibility-webrtc.patch'
- 'add-a-TODO-about-a-missing-pnacl-flag.patch'
- 'unexpire-accelerated-video-decode-flag.patch'
- 'use-ffile-compilation-dir.patch'
- 'sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch'
- 'breakpad-fix-for-non-constant-SIGSTKSZ.patch'
- )
-# shellcheck disable=SC2034
-sha256sums=('SKIP'
- 'SKIP'
- '22692bddaf2761c6ddf9ff0bc4722972bca4d4c5b2fd3e5dbdac7eb60d914320'
- '3953f532a3ea5fce19ee33600c6ead89dcd066df6a01d3c3ab4c24f96e46fca2'
- '4484200d90b76830b69eea3a471c103999a3ce86bb2c29e6c14c945bf4102bae'
- '38649e1a1f7805b2a4027706d7c466f6539d1d531046d78838c239c56bf070d3'
- '75bac9c4ad32ff9329399b8587f9772e208c009fd822cdfce61b2bd1ee9ac828'
- '09de0ebb4002be7fb4ede63d3977e4f1235637750169c9e71bfdbd75bf750f7a'
- '7cb11fb44aaf4d15f36caca3c0d1b082a723c30d43cd44db147248db5683a2a9'
- 'd3344ba39b8c6ed202334ba7f441c70d81ddf8cdb15af1aa8c16e9a3a75fbb35'
- 'dd317f85e5abfdcfc89c6f23f4c8edbcdebdd5e083dcec770e5da49ee647d150'
- 'd0b17162211dd49e3a58c16d1697e7d8c322dcfd3b7890f0c2f920b711f52293'
- 'b9934e01d8f39beafc8b63784fb86e6befe25ca83e9c43224c8374e5a025d8ef'
- 'cca2d224cf2e9d7cfb4f5729ca76b5b8a7100b1ca39892b41fb296adaced1bf7'
- '574785a21168c3e9b7aa82630713ceb6ced12f699133db66b10fc84b7bb2c631'
- 'd53da216538f2e741a6e048ed103964a91a98e9a3c10c27fdfa34d4692fdc455'
- '2a97b26c3d6821b15ef4ef1369905c6fa3e9c8da4877eb9af4361452a425290b'
- '921010cd8fab5f30be76c68b68c9b39fac9e21f4c4133bb709879592bbdf606e'
- 'f910be9370c880de6e1d61cc30383c069e421d7acf406166e4fbfad324fc7d61'
- 'b4d28867c1fabde6c50a2cfa3f784730446c4d86e5191e0f0000fbf7b0f91ecf')
-
-_system_libs=('ffmpeg'
- 'flac'
- 'fontconfig'
- 'freetype'
- 'harfbuzz-ng'
- 'icu'
- 'libdrm'
- 'libevent'
- 'libjpeg'
- 'libpng'
-# 'libvpx'
- 'libwebp'
- 'libxml'
- 'libxslt'
-# 'openh264'
- 'opus'
- 're2'
- 'snappy'
- 'zlib'
- )
-
-prepare() {
- sed -i "s|@ELECTRON@|${pkgname}|" electron-launcher.sh
- sed -i "s|@ELECTRON@|${pkgname}|" electron.desktop
- if [[ ${_use_suffix} != 0 ]]; then
- sed -i "s|@ELECTRON_NAME@|Electron ${_major_ver}|" electron.desktop
- else
- sed -i "s|@ELECTRON_NAME@|Electron|" electron.desktop
- fi
-
- export PATH="${PATH}:${srcdir:?}/depot_tools"
-
- echo "Fetching chromium..."
- git clone --branch=${_chromiumver} --depth=1 \
- https://chromium.googlesource.com/chromium/src.git
-
- echo "solutions = [
- {
- \"name\": \"src/electron\",
- \"url\": \"file://${srcdir}/electron@${_commit}\",
- \"deps_file\": \"DEPS\",
- \"managed\": False,
- \"custom_deps\": {
- \"src\": None,
- },
- \"custom_vars\": {},
- },
-]" > .gclient
-
- python "${srcdir}/depot_tools/gclient.py" sync \
- --with_branch_heads \
- --with_tags \
- --nohooks
-
- (
- cd src/electron || exit
- patch -Np1 -i ../../pr-33038.patch
- )
-
- echo "Running hooks..."
- # python "${srcdir}/depot_tools/gclient.py" runhooks
- src/build/landmines.py
- src/build/util/lastchange.py -o src/build/util/LASTCHANGE
- src/build/util/lastchange.py -m GPU_LISTS_VERSION \
- --revision-id-only --header src/gpu/config/gpu_lists_version.h
- src/build/util/lastchange.py -m SKIA_COMMIT_HASH \
- -s src/third_party/skia --header src/skia/ext/skia_commit_hash.h
- # Create sysmlink to system clang-format
- ln -s /usr/bin/clang-format src/buildtools/linux64
- # Create sysmlink to system Node.js
- mkdir -p src/third_party/node/linux/node-linux-x64/bin
- ln -sf /usr/bin/node src/third_party/node/linux/node-linux-x64/bin
- src/third_party/depot_tools/download_from_google_storage.py \
- --no_resume --extract --no_auth --bucket chromium-nodejs \
- -s src/third_party/node/node_modules.tar.gz.sha1
- vpython src/tools/download_optimization_profile.py \
- --newest_state=src/chrome/android/profiles/newest.txt \
- --local_state=src/chrome/android/profiles/local.txt \
- --output_name=src/chrome/android/profiles/afdo.prof \
- --gs_url_base=chromeos-prebuilt/afdo-job/llvm
- #vpython src/tools/update_pgo_profiles.py \
- # --target=linux \
- # update \
- # --gs-url-base=chromium-optimization-profiles/pgo_profiles
- src/electron/script/apply_all_patches.py \
- src/electron/patches/config.json
- cd src/electron || exit
- yarn install --frozen-lockfile
- cd ..
-
- echo "Applying local patches..."
- # Fixes for building with libstdc++ instead of libc++
- patch -Np1 -i ../patches/chromium-90-ruy-include.patch
- patch -Np1 -i ../patches/chromium-94-CustomSpaces-include.patch
-
- patch -Np1 -i ../unbundle-fix-visibility-of-build-config-freetype.patch
- patch -Np1 -i ../gn-visibility-gmock.patch
- patch -Np1 -i ../gn-visibility-mojo.patch
- patch -Np1 -i ../gn-visibility-webrtc.patch
- patch -Rp1 -i ../add-a-TODO-about-a-missing-pnacl-flag.patch
- patch -d third_party/jinja2 -Np1 -i ../../../jinja-python-3.10.patch
- patch -Rp1 -i ../replace-blacklist-with-ignorelist.patch
- patch -Np1 -i ../sql-make-VirtualCursor-standard-layout-type.patch
- patch -Np0 -i ../unexpire-accelerated-video-decode-flag.patch
- patch -Rp1 -i ../use-ffile-compilation-dir.patch
- patch -d third_party/electron_node/tools/inspector_protocol/jinja2 \
- -Np1 -i ../../../../../../jinja-python-3.10.patch
- patch -Np1 -i ../use-system-libraries-in-node.patch
- patch -Np1 -i ../default_app-icon.patch # Icon from .desktop file
-
- patch -Np1 -i ../sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch
- patch -Np1 -d third_party/breakpad/breakpad <../breakpad-fix-for-non-constant-SIGSTKSZ.patch
-
- echo "Patching Chromium for using system libraries..."
- sed -i 's/OFFICIAL_BUILD/GOOGLE_CHROME_BUILD/' \
- tools/generate_shim_headers/generate_shim_headers.py
- for lib in $(printf "%s\n" "${_system_libs[@]}" | sed 's/^libjpeg$/&_turbo/'); do
- third_party_dir="third_party/${lib}"
- if [ ! -d "${third_party_dir}" ]; then
- third_party_dir="base/${third_party_dir}"
- fi
- find "${third_party_dir}" -type f \
- \! -path "${third_party_dir}/chromium/*" \
- \! -path "${third_party_dir}/google/*" \
- \! -path 'third_party/harfbuzz-ng/utils/hb_scoped.h' \
- \! -regex '.*\.\(gn\|gni\|isolate\)' \
- -delete
- done
- build/linux/unbundle/replace_gn_files.py \
- --system-libraries \
- "${_system_libs[@]}"
-}
-
-build() {
- export CC=clang
- export CXX=clang++
- export AR=ar
- export NM=nm
-
- CFLAGS="${CFLAGS/-fexceptions/}"
- CXXFLAGS="${CXXFLAGS/-fexceptions/}"
-
- # This appears to cause random segfaults when combined with ThinLTO
- # https://bugs.archlinux.org/task/73518
- CFLAGS=${CFLAGS/-fstack-clash-protection}
- CXXFLAGS=${CXXFLAGS/-fstack-clash-protection}
-
- # Do not warn about unknown warning options
- CFLAGS+=' -Wno-unknown-warning-option'
- CXXFLAGS+=' -Wno-unknown-warning-option'
-
- cd src || exit
- export CHROMIUM_BUILDTOOLS_PATH="${PWD}/buildtools"
- GN_EXTRA_ARGS='
- blink_symbol_level = 0
- chrome_pgo_phase = 0
- clang_use_chrome_plugins = false
- custom_toolchain = "//build/toolchain/linux/unbundle:default"
- host_toolchain = "//build/toolchain/linux/unbundle:default"
- icu_use_data_file = false
- is_component_ffmpeg = false
- link_pulseaudio = true
- rtc_use_pipewire = true
- treat_warnings_as_errors = false
- use_custom_libcxx = false
- use_gnome_keyring = false
- use_sysroot = false
- '
- gn gen out/Release \
- --args="import(\"//electron/build/args/release.gn\") ${GN_EXTRA_ARGS}"
- ninja -C out/Release electron
- # Strip before zip to avoid
- # zipfile.LargeZipFile: Filesize would require ZIP64 extensions
- strip -s out/Release/electron
- ninja -C out/Release electron_dist_zip
- # ninja -C out/Release third_party/electron_node:headers
-}
-
-package() {
- install -dm755 "${pkgdir:?}/usr/lib/${pkgname}"
- bsdtar -xf src/out/Release/dist.zip -C "${pkgdir}/usr/lib/${pkgname}"
-
- chmod u+s "${pkgdir}/usr/lib/${pkgname}/chrome-sandbox"
-
- install -dm755 "${pkgdir}/usr/share/licenses/${pkgname}"
- for l in "${pkgdir}/usr/lib/${pkgname}"/{LICENSE,LICENSES.chromium.html}; do
- ln -s \
- "$(realpath --relative-to="${pkgdir}/usr/share/licenses/${pkgname}" "${l}")" \
- "${pkgdir}/usr/share/licenses/${pkgname}"
- done
-
- install -Dm755 "${srcdir}/electron-launcher.sh" \
- "${pkgdir}/usr/bin/${pkgname}"
- if [[ "${_use_suffix}" == 0 ]]; then
- ln "${pkgdir}/usr/bin/${pkgname}" \
- "${pkgdir}/usr/bin/${pkgname}${_major_ver}"
- fi
-
- # Install .desktop and icon file (see default_app-icon.patch)
- install -Dm644 electron.desktop \
- "${pkgdir}/usr/share/applications/${pkgname}.desktop"
- install -Dm644 src/electron/default_app/icon.png \
- "${pkgdir}/usr/share/pixmaps/${pkgname}.png" # hicolor has no 1024x1024
-}
Copied: electron15/repos/community-x86_64/PKGBUILD (from rev 1176686, electron15/trunk/PKGBUILD)
===================================================================
--- PKGBUILD (rev 0)
+++ PKGBUILD 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,287 @@
+# Maintainer: Nicola Squartini <tensor5 at gmail.com>
+
+_use_suffix=1
+pkgver=15.4.2
+_commit=f043e665dd1c5c2eca65a515eee47062f68d1007
+_chromiumver=94.0.4606.81
+_gcc_patchset=3
+# shellcheck disable=SC2034
+pkgrel=1
+
+_major_ver=${pkgver%%.*}
+if [[ ${_use_suffix} != 0 ]]; then
+ pkgname="electron${_major_ver}"
+else
+ pkgname=electron
+fi
+# shellcheck disable=SC2034
+pkgdesc='Build cross platform desktop apps with web technologies'
+# shellcheck disable=SC2034
+arch=('x86_64')
+# shellcheck disable=SC2034
+url='https://electronjs.org/'
+# shellcheck disable=SC2034
+license=('MIT' 'custom')
+# shellcheck disable=SC2034
+depends=('c-ares' 'ffmpeg' 'gtk3' 'libevent' 'libxslt' 'minizip' 'nss' 're2'
+ 'snappy')
+# shellcheck disable=SC2034
+makedepends=('clang' 'git' 'gn' 'gperf' 'harfbuzz-icu' 'http-parser'
+ 'java-runtime-headless' 'jsoncpp' 'libnotify' 'lld' 'llvm' 'ninja'
+ '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'
+ 'pipewire: WebRTC desktop sharing under Wayland'
+ 'trash-cli: file deletion support (trash-put)'
+ "xdg-utils: open URLs with desktop's default (xdg-email, xdg-open)")
+if [[ ${_use_suffix} == 0 ]]; then
+ # shellcheck disable=SC2034
+ conflicts=("electron${_major_ver}")
+ # shellcheck disable=SC2034
+ provides=("electron${_major_ver}")
+fi
+# shellcheck disable=SC2034
+options=('!lto') # Electron adds its own flags for ThinLTO
+# shellcheck disable=SC2034
+source=('git+https://github.com/electron/electron.git'
+ 'git+https://chromium.googlesource.com/chromium/tools/depot_tools.git#branch=main'
+ "https://github.com/stha09/chromium-patches/releases/download/chromium-${_chromiumver%%.*}-patchset-${_gcc_patchset}/chromium-${_chromiumver%%.*}-patchset-${_gcc_patchset}.tar.xz"
+ "electron-launcher.sh"
+ "electron.desktop"
+ 'default_app-icon.patch'
+ 'jinja-python-3.10.patch'
+ 'use-system-libraries-in-node.patch'
+ 'replace-blacklist-with-ignorelist.patch'
+ 'sql-make-VirtualCursor-standard-layout-type.patch'
+ 'unbundle-fix-visibility-of-build-config-freetype.patch'
+ 'gn-visibility-gmock.patch'
+ 'gn-visibility-mojo.patch'
+ 'gn-visibility-webrtc.patch'
+ 'add-a-TODO-about-a-missing-pnacl-flag.patch'
+ 'unexpire-accelerated-video-decode-flag.patch'
+ 'use-ffile-compilation-dir.patch'
+ 'sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch'
+ 'breakpad-fix-for-non-constant-SIGSTKSZ.patch'
+ )
+# shellcheck disable=SC2034
+sha256sums=('SKIP'
+ 'SKIP'
+ '22692bddaf2761c6ddf9ff0bc4722972bca4d4c5b2fd3e5dbdac7eb60d914320'
+ '3953f532a3ea5fce19ee33600c6ead89dcd066df6a01d3c3ab4c24f96e46fca2'
+ '4484200d90b76830b69eea3a471c103999a3ce86bb2c29e6c14c945bf4102bae'
+ '75bac9c4ad32ff9329399b8587f9772e208c009fd822cdfce61b2bd1ee9ac828'
+ '09de0ebb4002be7fb4ede63d3977e4f1235637750169c9e71bfdbd75bf750f7a'
+ '7cb11fb44aaf4d15f36caca3c0d1b082a723c30d43cd44db147248db5683a2a9'
+ 'd3344ba39b8c6ed202334ba7f441c70d81ddf8cdb15af1aa8c16e9a3a75fbb35'
+ 'dd317f85e5abfdcfc89c6f23f4c8edbcdebdd5e083dcec770e5da49ee647d150'
+ 'd0b17162211dd49e3a58c16d1697e7d8c322dcfd3b7890f0c2f920b711f52293'
+ 'b9934e01d8f39beafc8b63784fb86e6befe25ca83e9c43224c8374e5a025d8ef'
+ 'cca2d224cf2e9d7cfb4f5729ca76b5b8a7100b1ca39892b41fb296adaced1bf7'
+ '574785a21168c3e9b7aa82630713ceb6ced12f699133db66b10fc84b7bb2c631'
+ 'd53da216538f2e741a6e048ed103964a91a98e9a3c10c27fdfa34d4692fdc455'
+ '2a97b26c3d6821b15ef4ef1369905c6fa3e9c8da4877eb9af4361452a425290b'
+ '921010cd8fab5f30be76c68b68c9b39fac9e21f4c4133bb709879592bbdf606e'
+ 'f910be9370c880de6e1d61cc30383c069e421d7acf406166e4fbfad324fc7d61'
+ 'b4d28867c1fabde6c50a2cfa3f784730446c4d86e5191e0f0000fbf7b0f91ecf')
+
+_system_libs=('ffmpeg'
+ 'flac'
+ 'fontconfig'
+ 'freetype'
+ 'harfbuzz-ng'
+ 'icu'
+ 'libdrm'
+ 'libevent'
+ 'libjpeg'
+ 'libpng'
+# 'libvpx'
+ 'libwebp'
+ 'libxml'
+ 'libxslt'
+# 'openh264'
+ 'opus'
+ 're2'
+ 'snappy'
+ 'zlib'
+ )
+
+prepare() {
+ sed -i "s|@ELECTRON@|${pkgname}|" electron-launcher.sh
+ sed -i "s|@ELECTRON@|${pkgname}|" electron.desktop
+ if [[ ${_use_suffix} != 0 ]]; then
+ sed -i "s|@ELECTRON_NAME@|Electron ${_major_ver}|" electron.desktop
+ else
+ sed -i "s|@ELECTRON_NAME@|Electron|" electron.desktop
+ fi
+
+ export PATH="${PATH}:${srcdir:?}/depot_tools"
+
+ echo "Fetching chromium..."
+ git clone --branch=${_chromiumver} --depth=1 \
+ https://chromium.googlesource.com/chromium/src.git
+
+ echo "solutions = [
+ {
+ \"name\": \"src/electron\",
+ \"url\": \"file://${srcdir}/electron@${_commit}\",
+ \"deps_file\": \"DEPS\",
+ \"managed\": False,
+ \"custom_deps\": {
+ \"src\": None,
+ },
+ \"custom_vars\": {},
+ },
+]" > .gclient
+
+ python "${srcdir}/depot_tools/gclient.py" sync \
+ --with_branch_heads \
+ --with_tags \
+ --nohooks
+
+ echo "Running hooks..."
+ # python "${srcdir}/depot_tools/gclient.py" runhooks
+ src/build/landmines.py
+ src/build/util/lastchange.py -o src/build/util/LASTCHANGE
+ src/build/util/lastchange.py -m GPU_LISTS_VERSION \
+ --revision-id-only --header src/gpu/config/gpu_lists_version.h
+ src/build/util/lastchange.py -m SKIA_COMMIT_HASH \
+ -s src/third_party/skia --header src/skia/ext/skia_commit_hash.h
+ # Create sysmlink to system clang-format
+ ln -s /usr/bin/clang-format src/buildtools/linux64
+ # Create sysmlink to system Node.js
+ mkdir -p src/third_party/node/linux/node-linux-x64/bin
+ ln -sf /usr/bin/node src/third_party/node/linux/node-linux-x64/bin
+ src/third_party/depot_tools/download_from_google_storage.py \
+ --no_resume --extract --no_auth --bucket chromium-nodejs \
+ -s src/third_party/node/node_modules.tar.gz.sha1
+ vpython src/tools/download_optimization_profile.py \
+ --newest_state=src/chrome/android/profiles/newest.txt \
+ --local_state=src/chrome/android/profiles/local.txt \
+ --output_name=src/chrome/android/profiles/afdo.prof \
+ --gs_url_base=chromeos-prebuilt/afdo-job/llvm
+ #vpython src/tools/update_pgo_profiles.py \
+ # --target=linux \
+ # update \
+ # --gs-url-base=chromium-optimization-profiles/pgo_profiles
+ src/electron/script/apply_all_patches.py \
+ src/electron/patches/config.json
+ cd src/electron || exit
+ yarn install --frozen-lockfile
+ cd ..
+
+ echo "Applying local patches..."
+ # Fixes for building with libstdc++ instead of libc++
+ patch -Np1 -i ../patches/chromium-90-ruy-include.patch
+ patch -Np1 -i ../patches/chromium-94-CustomSpaces-include.patch
+
+ patch -Np1 -i ../unbundle-fix-visibility-of-build-config-freetype.patch
+ patch -Np1 -i ../gn-visibility-gmock.patch
+ patch -Np1 -i ../gn-visibility-mojo.patch
+ patch -Np1 -i ../gn-visibility-webrtc.patch
+ patch -Rp1 -i ../add-a-TODO-about-a-missing-pnacl-flag.patch
+ patch -d third_party/jinja2 -Np1 -i ../../../jinja-python-3.10.patch
+ patch -Rp1 -i ../replace-blacklist-with-ignorelist.patch
+ patch -Np1 -i ../sql-make-VirtualCursor-standard-layout-type.patch
+ patch -Np0 -i ../unexpire-accelerated-video-decode-flag.patch
+ patch -Rp1 -i ../use-ffile-compilation-dir.patch
+ patch -d third_party/electron_node/tools/inspector_protocol/jinja2 \
+ -Np1 -i ../../../../../../jinja-python-3.10.patch
+ patch -Np1 -i ../use-system-libraries-in-node.patch
+ patch -Np1 -i ../default_app-icon.patch # Icon from .desktop file
+
+ patch -Np1 -i ../sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch
+ patch -Np1 -d third_party/breakpad/breakpad <../breakpad-fix-for-non-constant-SIGSTKSZ.patch
+
+ echo "Patching Chromium for using system libraries..."
+ sed -i 's/OFFICIAL_BUILD/GOOGLE_CHROME_BUILD/' \
+ tools/generate_shim_headers/generate_shim_headers.py
+ for lib in $(printf "%s\n" "${_system_libs[@]}" | sed 's/^libjpeg$/&_turbo/'); do
+ third_party_dir="third_party/${lib}"
+ if [ ! -d "${third_party_dir}" ]; then
+ third_party_dir="base/${third_party_dir}"
+ fi
+ find "${third_party_dir}" -type f \
+ \! -path "${third_party_dir}/chromium/*" \
+ \! -path "${third_party_dir}/google/*" \
+ \! -path 'third_party/harfbuzz-ng/utils/hb_scoped.h' \
+ \! -regex '.*\.\(gn\|gni\|isolate\)' \
+ -delete
+ done
+ build/linux/unbundle/replace_gn_files.py \
+ --system-libraries \
+ "${_system_libs[@]}"
+}
+
+build() {
+ export CC=clang
+ export CXX=clang++
+ export AR=ar
+ export NM=nm
+
+ CFLAGS="${CFLAGS/-fexceptions/}"
+ CXXFLAGS="${CXXFLAGS/-fexceptions/}"
+
+ # This appears to cause random segfaults when combined with ThinLTO
+ # https://bugs.archlinux.org/task/73518
+ CFLAGS=${CFLAGS/-fstack-clash-protection}
+ CXXFLAGS=${CXXFLAGS/-fstack-clash-protection}
+
+ # Do not warn about unknown warning options
+ CFLAGS+=' -Wno-unknown-warning-option'
+ CXXFLAGS+=' -Wno-unknown-warning-option'
+
+ cd src || exit
+ export CHROMIUM_BUILDTOOLS_PATH="${PWD}/buildtools"
+ GN_EXTRA_ARGS='
+ blink_symbol_level = 0
+ chrome_pgo_phase = 0
+ clang_use_chrome_plugins = false
+ custom_toolchain = "//build/toolchain/linux/unbundle:default"
+ host_toolchain = "//build/toolchain/linux/unbundle:default"
+ icu_use_data_file = false
+ is_component_ffmpeg = false
+ link_pulseaudio = true
+ rtc_use_pipewire = true
+ treat_warnings_as_errors = false
+ use_custom_libcxx = false
+ use_gnome_keyring = false
+ use_sysroot = false
+ '
+ gn gen out/Release \
+ --args="import(\"//electron/build/args/release.gn\") ${GN_EXTRA_ARGS}"
+ ninja -C out/Release electron
+ # Strip before zip to avoid
+ # zipfile.LargeZipFile: Filesize would require ZIP64 extensions
+ strip -s out/Release/electron
+ ninja -C out/Release electron_dist_zip
+ # ninja -C out/Release third_party/electron_node:headers
+}
+
+package() {
+ install -dm755 "${pkgdir:?}/usr/lib/${pkgname}"
+ bsdtar -xf src/out/Release/dist.zip -C "${pkgdir}/usr/lib/${pkgname}"
+
+ chmod u+s "${pkgdir}/usr/lib/${pkgname}/chrome-sandbox"
+
+ install -dm755 "${pkgdir}/usr/share/licenses/${pkgname}"
+ for l in "${pkgdir}/usr/lib/${pkgname}"/{LICENSE,LICENSES.chromium.html}; do
+ ln -s \
+ "$(realpath --relative-to="${pkgdir}/usr/share/licenses/${pkgname}" "${l}")" \
+ "${pkgdir}/usr/share/licenses/${pkgname}"
+ done
+
+ install -Dm755 "${srcdir}/electron-launcher.sh" \
+ "${pkgdir}/usr/bin/${pkgname}"
+ if [[ "${_use_suffix}" == 0 ]]; then
+ ln "${pkgdir}/usr/bin/${pkgname}" \
+ "${pkgdir}/usr/bin/${pkgname}${_major_ver}"
+ fi
+
+ # Install .desktop and icon file (see default_app-icon.patch)
+ install -Dm644 electron.desktop \
+ "${pkgdir}/usr/share/applications/${pkgname}.desktop"
+ install -Dm644 src/electron/default_app/icon.png \
+ "${pkgdir}/usr/share/pixmaps/${pkgname}.png" # hicolor has no 1024x1024
+}
Deleted: add-a-TODO-about-a-missing-pnacl-flag.patch
===================================================================
--- add-a-TODO-about-a-missing-pnacl-flag.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ add-a-TODO-about-a-missing-pnacl-flag.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,28 +0,0 @@
-From 7a23987acb698c2934958cb42a5e7b1cd73fe142 Mon Sep 17 00:00:00 2001
-From: Nico Weber <thakis at chromium.org>
-Date: Tue, 20 Jul 2021 21:54:09 +0000
-Subject: [PATCH] build: Add a TODO about a missing pnacl flag
-
-Change-Id: I1700d185a23afe4120e14c755782450b1bf89289
-Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3041785
-Commit-Queue: Nico Weber <thakis at chromium.org>
-Commit-Queue: Hans Wennborg <hans at chromium.org>
-Auto-Submit: Nico Weber <thakis at chromium.org>
-Reviewed-by: Hans Wennborg <hans at chromium.org>
-Cr-Commit-Position: refs/heads/master@{#903659}
----
- build/config/compiler/BUILD.gn | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
-index b6e095b705..ef6d1dfc12 100644
---- a/build/config/compiler/BUILD.gn
-+++ b/build/config/compiler/BUILD.gn
-@@ -1217,6 +1217,7 @@ config("compiler_deterministic") {
- # we build same files with same compile flag.
- # Other paths are already given in relative, no need to normalize them.
- if (is_nacl) {
-+ # TODO(https://crbug.com/1231236): Use -ffile-compilation-dir= here.
- cflags += [
- "-Xclang",
- "-fdebug-compilation-dir",
Copied: electron15/repos/community-x86_64/add-a-TODO-about-a-missing-pnacl-flag.patch (from rev 1176686, electron15/trunk/add-a-TODO-about-a-missing-pnacl-flag.patch)
===================================================================
--- add-a-TODO-about-a-missing-pnacl-flag.patch (rev 0)
+++ add-a-TODO-about-a-missing-pnacl-flag.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,28 @@
+From 7a23987acb698c2934958cb42a5e7b1cd73fe142 Mon Sep 17 00:00:00 2001
+From: Nico Weber <thakis at chromium.org>
+Date: Tue, 20 Jul 2021 21:54:09 +0000
+Subject: [PATCH] build: Add a TODO about a missing pnacl flag
+
+Change-Id: I1700d185a23afe4120e14c755782450b1bf89289
+Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3041785
+Commit-Queue: Nico Weber <thakis at chromium.org>
+Commit-Queue: Hans Wennborg <hans at chromium.org>
+Auto-Submit: Nico Weber <thakis at chromium.org>
+Reviewed-by: Hans Wennborg <hans at chromium.org>
+Cr-Commit-Position: refs/heads/master@{#903659}
+---
+ build/config/compiler/BUILD.gn | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
+index b6e095b705..ef6d1dfc12 100644
+--- a/build/config/compiler/BUILD.gn
++++ b/build/config/compiler/BUILD.gn
+@@ -1217,6 +1217,7 @@ config("compiler_deterministic") {
+ # we build same files with same compile flag.
+ # Other paths are already given in relative, no need to normalize them.
+ if (is_nacl) {
++ # TODO(https://crbug.com/1231236): Use -ffile-compilation-dir= here.
+ cflags += [
+ "-Xclang",
+ "-fdebug-compilation-dir",
Deleted: breakpad-fix-for-non-constant-SIGSTKSZ.patch
===================================================================
--- breakpad-fix-for-non-constant-SIGSTKSZ.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ breakpad-fix-for-non-constant-SIGSTKSZ.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,35 +0,0 @@
-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.
Copied: electron15/repos/community-x86_64/breakpad-fix-for-non-constant-SIGSTKSZ.patch (from rev 1176686, electron15/trunk/breakpad-fix-for-non-constant-SIGSTKSZ.patch)
===================================================================
--- breakpad-fix-for-non-constant-SIGSTKSZ.patch (rev 0)
+++ breakpad-fix-for-non-constant-SIGSTKSZ.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -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: default_app-icon.patch
===================================================================
--- default_app-icon.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ default_app-icon.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,21 +0,0 @@
---- a/electron/default_app/default_app.ts
-+++ b/electron/default_app/default_app.ts
-@@ -59,7 +59,7 @@
- };
-
- if (process.platform === 'linux') {
-- options.icon = path.join(__dirname, 'icon.png');
-+ options.icon = '/usr/share/pixmaps/electron.png';
- }
-
- mainWindow = new BrowserWindow(options);
---- a/electron/filenames.gni
-+++ b/electron/filenames.gni
-@@ -6,7 +6,6 @@
- ]
-
- default_app_static_sources = [
-- "default_app/icon.png",
- "default_app/index.html",
- "default_app/package.json",
- "default_app/styles.css",
Copied: electron15/repos/community-x86_64/default_app-icon.patch (from rev 1176686, electron15/trunk/default_app-icon.patch)
===================================================================
--- default_app-icon.patch (rev 0)
+++ default_app-icon.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,21 @@
+--- a/electron/default_app/default_app.ts
++++ b/electron/default_app/default_app.ts
+@@ -59,7 +59,7 @@
+ };
+
+ if (process.platform === 'linux') {
+- options.icon = path.join(__dirname, 'icon.png');
++ options.icon = '/usr/share/pixmaps/electron.png';
+ }
+
+ mainWindow = new BrowserWindow(options);
+--- a/electron/filenames.gni
++++ b/electron/filenames.gni
+@@ -6,7 +6,6 @@
+ ]
+
+ default_app_static_sources = [
+- "default_app/icon.png",
+ "default_app/index.html",
+ "default_app/package.json",
+ "default_app/styles.css",
Deleted: electron-launcher.sh
===================================================================
--- electron-launcher.sh 2022-03-25 21:02:02 UTC (rev 1176686)
+++ electron-launcher.sh 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,20 +0,0 @@
-#!/usr/bin/bash
-
-set -euo pipefail
-
-name=@ELECTRON@
-flags_file="${XDG_CONFIG_HOME:-$HOME/.config}/${name}-flags.conf"
-
-declare -a flags
-
-if [[ -f "${flags_file}" ]]; then
- mapfile -t < "${flags_file}"
-fi
-
-for line in "${MAPFILE[@]}"; do
- if [[ ! "${line}" =~ ^[[:space:]]*#.* ]]; then
- flags+=("${line}")
- fi
-done
-
-exec /usr/lib/${name}/electron "$@" "${flags[@]}"
Copied: electron15/repos/community-x86_64/electron-launcher.sh (from rev 1176686, electron15/trunk/electron-launcher.sh)
===================================================================
--- electron-launcher.sh (rev 0)
+++ electron-launcher.sh 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,20 @@
+#!/usr/bin/bash
+
+set -euo pipefail
+
+name=@ELECTRON@
+flags_file="${XDG_CONFIG_HOME:-$HOME/.config}/${name}-flags.conf"
+
+declare -a flags
+
+if [[ -f "${flags_file}" ]]; then
+ mapfile -t < "${flags_file}"
+fi
+
+for line in "${MAPFILE[@]}"; do
+ if [[ ! "${line}" =~ ^[[:space:]]*#.* ]]; then
+ flags+=("${line}")
+ fi
+done
+
+exec /usr/lib/${name}/electron "$@" "${flags[@]}"
Deleted: electron.desktop
===================================================================
--- electron.desktop 2022-03-25 21:02:02 UTC (rev 1176686)
+++ electron.desktop 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,7 +0,0 @@
-[Desktop Entry]
-Type=Application
-Name=@ELECTRON_NAME@
-Icon=@ELECTRON@
-Exec=@ELECTRON@ %u
-Categories=Development;GTK;
-StartupNotify=true
Copied: electron15/repos/community-x86_64/electron.desktop (from rev 1176686, electron15/trunk/electron.desktop)
===================================================================
--- electron.desktop (rev 0)
+++ electron.desktop 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,7 @@
+[Desktop Entry]
+Type=Application
+Name=@ELECTRON_NAME@
+Icon=@ELECTRON@
+Exec=@ELECTRON@ %u
+Categories=Development;GTK;
+StartupNotify=true
Deleted: gn-visibility-gmock.patch
===================================================================
--- gn-visibility-gmock.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ gn-visibility-gmock.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,43 +0,0 @@
-From fc3c737210873e9bee311391e9f6b48130e84983 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Tomasz=20=C5=9Aniatowski?= <tsniatowski at vewd.com>
-Date: Sat, 4 Sep 2021 07:13:49 +0000
-Subject: [PATCH] Fix config visibility violation in //testing/gmock
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-//third_party/googletest:gtest_config has restricted visibility, current
-code works by accident because gn only enforces visibility on 'configs'.
-Fix by not referencing the configs at all as it should be unnecessary:
-//testing/gmock gets them via a public dependency chain anyway.
-
-This is one of a few fixes needed to roll gn past the upcoming
-enforcement change, landing in small parts because removing config
-usages feels a bit subtle.
-
-Bug: gn:252
-Change-Id: Ie1438862831ecee49162d9f8f7872a568d69c2fb
-Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3139927
-Reviewed-by: Dirk Pranke <dpranke at google.com>
-Commit-Queue: Tomasz Śniatowski <tsniatowski at vewd.com>
-Cr-Commit-Position: refs/heads/main@{#918357}
----
- testing/gmock/BUILD.gn | 5 -----
- 1 file changed, 5 deletions(-)
-
-diff --git a/testing/gmock/BUILD.gn b/testing/gmock/BUILD.gn
-index 0248d146d7397..e285fb84e471a 100644
---- a/testing/gmock/BUILD.gn
-+++ b/testing/gmock/BUILD.gn
-@@ -14,11 +14,6 @@ source_set("gmock") {
- "include/gmock/gmock.h",
- ]
- public_deps = [ "//third_party/googletest:gmock" ]
--
-- public_configs = [
-- "//third_party/googletest:gmock_config",
-- "//third_party/googletest:gtest_config",
-- ]
- }
-
- # The file/directory layout of Google Test is not yet considered stable. Until
Copied: electron15/repos/community-x86_64/gn-visibility-gmock.patch (from rev 1176686, electron15/trunk/gn-visibility-gmock.patch)
===================================================================
--- gn-visibility-gmock.patch (rev 0)
+++ gn-visibility-gmock.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,43 @@
+From fc3c737210873e9bee311391e9f6b48130e84983 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Tomasz=20=C5=9Aniatowski?= <tsniatowski at vewd.com>
+Date: Sat, 4 Sep 2021 07:13:49 +0000
+Subject: [PATCH] Fix config visibility violation in //testing/gmock
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+//third_party/googletest:gtest_config has restricted visibility, current
+code works by accident because gn only enforces visibility on 'configs'.
+Fix by not referencing the configs at all as it should be unnecessary:
+//testing/gmock gets them via a public dependency chain anyway.
+
+This is one of a few fixes needed to roll gn past the upcoming
+enforcement change, landing in small parts because removing config
+usages feels a bit subtle.
+
+Bug: gn:252
+Change-Id: Ie1438862831ecee49162d9f8f7872a568d69c2fb
+Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3139927
+Reviewed-by: Dirk Pranke <dpranke at google.com>
+Commit-Queue: Tomasz Śniatowski <tsniatowski at vewd.com>
+Cr-Commit-Position: refs/heads/main@{#918357}
+---
+ testing/gmock/BUILD.gn | 5 -----
+ 1 file changed, 5 deletions(-)
+
+diff --git a/testing/gmock/BUILD.gn b/testing/gmock/BUILD.gn
+index 0248d146d7397..e285fb84e471a 100644
+--- a/testing/gmock/BUILD.gn
++++ b/testing/gmock/BUILD.gn
+@@ -14,11 +14,6 @@ source_set("gmock") {
+ "include/gmock/gmock.h",
+ ]
+ public_deps = [ "//third_party/googletest:gmock" ]
+-
+- public_configs = [
+- "//third_party/googletest:gmock_config",
+- "//third_party/googletest:gtest_config",
+- ]
+ }
+
+ # The file/directory layout of Google Test is not yet considered stable. Until
Deleted: gn-visibility-mojo.patch
===================================================================
--- gn-visibility-mojo.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ gn-visibility-mojo.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,36 +0,0 @@
-From 40f10bf0e683f6b499b5c3c7555111193db03abf Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Tomasz=20=C5=9Aniatowski?= <tsniatowski at vewd.com>
-Date: Tue, 7 Sep 2021 20:13:53 +0000
-Subject: [PATCH] Fix config visibility violation in //mojo/public/cpp/bindings
-
-//third_party/blink/renderer:config has restricted visibility, current
-code works by accident because gn only enforces visibility on 'configs'.
-Fix by removing the direct config usage as it looks historical and not
-actually needed.
-
-This is one of a few fixes needed to roll gn past the upcoming
-enforcement change, landing in small parts because removing config
-usages feels a bit subtle.
-
-Bug: gn:252
-Change-Id: I2e0d2e314ef3714dd19b11b7ae29bdcf5074cfda
-Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3140593
-Commit-Queue: Ken Rockot <rockot at google.com>
-Reviewed-by: Ken Rockot <rockot at google.com>
-Cr-Commit-Position: refs/heads/main@{#918914}
----
- mojo/public/cpp/bindings/BUILD.gn | 2 --
- 1 file changed, 2 deletions(-)
-
-diff --git a/mojo/public/cpp/bindings/BUILD.gn b/mojo/public/cpp/bindings/BUILD.gn
-index 13ad53b3ed305..d90318de106e4 100644
---- a/mojo/public/cpp/bindings/BUILD.gn
-+++ b/mojo/public/cpp/bindings/BUILD.gn
-@@ -281,7 +281,5 @@ if (!is_ios) {
- "//third_party/blink/renderer/platform:platform_export",
- "//third_party/blink/renderer/platform/wtf",
- ]
--
-- public_configs = [ "//third_party/blink/renderer:config" ]
- }
- }
Copied: electron15/repos/community-x86_64/gn-visibility-mojo.patch (from rev 1176686, electron15/trunk/gn-visibility-mojo.patch)
===================================================================
--- gn-visibility-mojo.patch (rev 0)
+++ gn-visibility-mojo.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,36 @@
+From 40f10bf0e683f6b499b5c3c7555111193db03abf Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Tomasz=20=C5=9Aniatowski?= <tsniatowski at vewd.com>
+Date: Tue, 7 Sep 2021 20:13:53 +0000
+Subject: [PATCH] Fix config visibility violation in //mojo/public/cpp/bindings
+
+//third_party/blink/renderer:config has restricted visibility, current
+code works by accident because gn only enforces visibility on 'configs'.
+Fix by removing the direct config usage as it looks historical and not
+actually needed.
+
+This is one of a few fixes needed to roll gn past the upcoming
+enforcement change, landing in small parts because removing config
+usages feels a bit subtle.
+
+Bug: gn:252
+Change-Id: I2e0d2e314ef3714dd19b11b7ae29bdcf5074cfda
+Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3140593
+Commit-Queue: Ken Rockot <rockot at google.com>
+Reviewed-by: Ken Rockot <rockot at google.com>
+Cr-Commit-Position: refs/heads/main@{#918914}
+---
+ mojo/public/cpp/bindings/BUILD.gn | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/mojo/public/cpp/bindings/BUILD.gn b/mojo/public/cpp/bindings/BUILD.gn
+index 13ad53b3ed305..d90318de106e4 100644
+--- a/mojo/public/cpp/bindings/BUILD.gn
++++ b/mojo/public/cpp/bindings/BUILD.gn
+@@ -281,7 +281,5 @@ if (!is_ios) {
+ "//third_party/blink/renderer/platform:platform_export",
+ "//third_party/blink/renderer/platform/wtf",
+ ]
+-
+- public_configs = [ "//third_party/blink/renderer:config" ]
+ }
+ }
Deleted: gn-visibility-webrtc.patch
===================================================================
--- gn-visibility-webrtc.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ gn-visibility-webrtc.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,45 +0,0 @@
-From 72c4d9fc95c336f61d7a8417b78f947a400ce792 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Tomasz=20=C5=9Aniatowski?= <tsniatowski at vewd.com>
-Date: Tue, 14 Sep 2021 10:33:37 +0000
-Subject: [PATCH] Relax googletest gn config visibility for webrtc
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-An upcoming gn roll will start enforcing config visibility on
-public_configs and all_dependent_configs. Normally, configs with
-limited visibility have corresponding helper targets that push the
-configs using public_configs and are propagated with public_deps.
-However, webrtc prefers to avoid public_deps, and pushes the gtest
-config using all_dependent_configs. This requires direct visibility,
-so tweak gtest BUILD.gn to make things work.
-
-Bug: gn:252, 1249254
-Change-Id: Ic7be22f7bf129255fb0ac51f437cd6dd3989e3a3
-Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3158065
-Commit-Queue: Tomasz Śniatowski <tsniatowski at vewd.com>
-Reviewed-by: Victor Costan <pwnall at chromium.org>
-Cr-Commit-Position: refs/heads/main@{#921126}
----
- third_party/googletest/BUILD.gn | 8 +++++++-
- 1 file changed, 7 insertions(+), 1 deletion(-)
-
-diff --git a/third_party/googletest/BUILD.gn b/third_party/googletest/BUILD.gn
-index fe240ebe954b6..d2bde47d75eab 100644
---- a/third_party/googletest/BUILD.gn
-+++ b/third_party/googletest/BUILD.gn
-@@ -5,7 +5,13 @@
- import("//build_overrides/build.gni")
-
- config("gtest_config") {
-- visibility = [ ":*" ] # gmock also shares this config.
-+ # webrtc wants to push this config without a public_dep chain
-+ # TODO(crbug.com/1249254): figure out what to do with this
-+ visibility = [
-+ ":*", # gmock also shares this config.
-+ "//test:*", # webrts standalone setup
-+ "//third_party/webrtc/test:*",
-+ ]
-
- defines = [
- # Chromium always links googletest statically, so no API qualifier is
Copied: electron15/repos/community-x86_64/gn-visibility-webrtc.patch (from rev 1176686, electron15/trunk/gn-visibility-webrtc.patch)
===================================================================
--- gn-visibility-webrtc.patch (rev 0)
+++ gn-visibility-webrtc.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,45 @@
+From 72c4d9fc95c336f61d7a8417b78f947a400ce792 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Tomasz=20=C5=9Aniatowski?= <tsniatowski at vewd.com>
+Date: Tue, 14 Sep 2021 10:33:37 +0000
+Subject: [PATCH] Relax googletest gn config visibility for webrtc
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+An upcoming gn roll will start enforcing config visibility on
+public_configs and all_dependent_configs. Normally, configs with
+limited visibility have corresponding helper targets that push the
+configs using public_configs and are propagated with public_deps.
+However, webrtc prefers to avoid public_deps, and pushes the gtest
+config using all_dependent_configs. This requires direct visibility,
+so tweak gtest BUILD.gn to make things work.
+
+Bug: gn:252, 1249254
+Change-Id: Ic7be22f7bf129255fb0ac51f437cd6dd3989e3a3
+Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3158065
+Commit-Queue: Tomasz Śniatowski <tsniatowski at vewd.com>
+Reviewed-by: Victor Costan <pwnall at chromium.org>
+Cr-Commit-Position: refs/heads/main@{#921126}
+---
+ third_party/googletest/BUILD.gn | 8 +++++++-
+ 1 file changed, 7 insertions(+), 1 deletion(-)
+
+diff --git a/third_party/googletest/BUILD.gn b/third_party/googletest/BUILD.gn
+index fe240ebe954b6..d2bde47d75eab 100644
+--- a/third_party/googletest/BUILD.gn
++++ b/third_party/googletest/BUILD.gn
+@@ -5,7 +5,13 @@
+ import("//build_overrides/build.gni")
+
+ config("gtest_config") {
+- visibility = [ ":*" ] # gmock also shares this config.
++ # webrtc wants to push this config without a public_dep chain
++ # TODO(crbug.com/1249254): figure out what to do with this
++ visibility = [
++ ":*", # gmock also shares this config.
++ "//test:*", # webrts standalone setup
++ "//third_party/webrtc/test:*",
++ ]
+
+ defines = [
+ # Chromium always links googletest statically, so no API qualifier is
Deleted: jinja-python-3.10.patch
===================================================================
--- jinja-python-3.10.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ jinja-python-3.10.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,33 +0,0 @@
---- a/runtime.py
-+++ b/runtime.py
-@@ -315,7 +315,7 @@ class Context(with_metaclass(ContextMeta
-
- # register the context as mapping if possible
- try:
-- from collections import Mapping
-+ from collections.abc import Mapping
- Mapping.register(Context)
- except ImportError:
- pass
---- a/sandbox.py
-+++ b/sandbox.py
-@@ -14,7 +14,7 @@
- """
- import types
- import operator
--from collections import Mapping
-+from collections.abc import Mapping
- from jinja2.environment import Environment
- from jinja2.exceptions import SecurityError
- from jinja2._compat import string_types, PY2
---- a/tests.py
-+++ b/tests.py
-@@ -10,7 +10,7 @@
- """
- import operator
- import re
--from collections import Mapping
-+from collections.abc import Mapping
- from jinja2.runtime import Undefined
- from jinja2._compat import text_type, string_types, integer_types
- import decimal
Copied: electron15/repos/community-x86_64/jinja-python-3.10.patch (from rev 1176686, electron15/trunk/jinja-python-3.10.patch)
===================================================================
--- jinja-python-3.10.patch (rev 0)
+++ jinja-python-3.10.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,33 @@
+--- a/runtime.py
++++ b/runtime.py
+@@ -315,7 +315,7 @@ class Context(with_metaclass(ContextMeta
+
+ # register the context as mapping if possible
+ try:
+- from collections import Mapping
++ from collections.abc import Mapping
+ Mapping.register(Context)
+ except ImportError:
+ pass
+--- a/sandbox.py
++++ b/sandbox.py
+@@ -14,7 +14,7 @@
+ """
+ import types
+ import operator
+-from collections import Mapping
++from collections.abc import Mapping
+ from jinja2.environment import Environment
+ from jinja2.exceptions import SecurityError
+ from jinja2._compat import string_types, PY2
+--- a/tests.py
++++ b/tests.py
+@@ -10,7 +10,7 @@
+ """
+ import operator
+ import re
+-from collections import Mapping
++from collections.abc import Mapping
+ from jinja2.runtime import Undefined
+ from jinja2._compat import text_type, string_types, integer_types
+ import decimal
Deleted: pr-33038.patch
===================================================================
--- pr-33038.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ pr-33038.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,643 +0,0 @@
-diff --git a/patches/chromium/.patches b/patches/chromium/.patches
-index ae0b6f1a147d..683069b716cd 100644
---- a/patches/chromium/.patches
-+++ b/patches/chromium/.patches
-@@ -158,3 +158,5 @@ cherry-pick-e3805f29fed7.patch
- cherry-pick-0081bb347e67.patch
- cherry-pick-1887414c016d.patch
- cherry-pick-6b2643846ae3.patch
-+fixed_terminate_caused_by_binding_to_wrong_version.patch
-+follow_wayland_specification_regarding_xkb_keymap.patch
-diff --git a/patches/chromium/fixed_terminate_caused_by_binding_to_wrong_version.patch b/patches/chromium/fixed_terminate_caused_by_binding_to_wrong_version.patch
-new file mode 100644
-index 000000000000..1a9b9acd2747
---- /dev/null
-+++ b/patches/chromium/fixed_terminate_caused_by_binding_to_wrong_version.patch
-@@ -0,0 +1,553 @@
-+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-+From: Robin Ebert <ebertrobin2002 at gmail.com>
-+Date: Tue, 22 Feb 2022 12:49:55 +0100
-+Subject: Fixed terminate caused by binding to wrong version.
-+
-+The Ozone/Wayland implementation had a few places where the Wayland
-+objects were bound without proper checking for their versions. That was
-+part of the technical debt not addressed before, and ended up causing
-+the issue explained in the linked crbug: the compositor terminates the
-+client that binds to the protocol that it does not actually support.
-+
-+This patch fixes the issue by adding the necessary checks in all places
-+where they were missing. Also a convenience macro for validating the
-+version is proposed.
-+
-+Backport of dd4c3ddadbb9869f59cee201a38e9ca3b9154f4d from chromium
-+
-+diff --git a/ui/ozone/platform/wayland/common/wayland_object.cc b/ui/ozone/platform/wayland/common/wayland_object.cc
-+index 0f21da447e43125c85b15a4254d7e047409e2e57..109fea03294a9bcbcc335d4c7d3250179f13f9bd 100644
-+--- a/ui/ozone/platform/wayland/common/wayland_object.cc
-++++ b/ui/ozone/platform/wayland/common/wayland_object.cc
-+@@ -29,6 +29,8 @@
-+ #include <xdg-shell-client-protocol.h>
-+ #include <xdg-shell-unstable-v6-client-protocol.h>
-+
-++#include "base/logging.h"
-++
-+ namespace wl {
-+ namespace {
-+
-+@@ -71,6 +73,19 @@ void delete_touch(wl_touch* touch) {
-+
-+ } // namespace
-+
-++bool CanBind(uint32_t available_version,
-++ uint32_t min_version,
-++ uint32_t max_version) {
-++ if (available_version < min_version) {
-++ LOG(WARNING) << "Error in binding wayland interface."
-++ << available_version << ". The minimum supported version is "
-++ << min_version << ".";
-++ return false;
-++ }
-++
-++ return true;
-++}
-++
-+ void (*ObjectTraits<wl_cursor_theme>::deleter)(wl_cursor_theme*) =
-+ &wl_cursor_theme_destroy;
-+
-+diff --git a/ui/ozone/platform/wayland/common/wayland_object.h b/ui/ozone/platform/wayland/common/wayland_object.h
-+index 88a5c0551402131357168c788787a0fddb24d747..465ac9633841b297ecdfe31df4b569773fdf2918 100644
-+--- a/ui/ozone/platform/wayland/common/wayland_object.h
-++++ b/ui/ozone/platform/wayland/common/wayland_object.h
-+@@ -86,6 +86,16 @@ struct ObjectTraits<wl_proxy> {
-+ static void (*deleter)(void*);
-+ };
-+
-++// Checks the given |available_version| exposed by the server against
-++// |min_version| and |max_version| supported by the client.
-++// Returns false (with rendering a warning) if |available_version| is less than
-++// the minimum supported version.
-++// Returns true otherwise, renders an info message if |available_version| is
-++// greater than the maximum supported one.
-++bool CanBind(uint32_t available_version,
-++ uint32_t min_version,
-++ uint32_t max_version);
-++
-+ } // namespace wl
-+
-+ // Puts the forward declaration for struct TYPE and declares the template
-+diff --git a/ui/ozone/platform/wayland/host/gtk_primary_selection_device_manager.cc b/ui/ozone/platform/wayland/host/gtk_primary_selection_device_manager.cc
-+index 8822c0a57ebd5cdc5044c3746e6b17abd6898621..3dcb157031df12e36109bda1048cd0c57de23a41 100644
-+--- a/ui/ozone/platform/wayland/host/gtk_primary_selection_device_manager.cc
-++++ b/ui/ozone/platform/wayland/host/gtk_primary_selection_device_manager.cc
-+@@ -16,7 +16,7 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMaxGtkPrimarySelectionDeviceManagerVersion = 1;
-++constexpr uint32_t kMinVersion = 1;
-+ }
-+
-+ // static
-+@@ -32,12 +32,13 @@ void GtkPrimarySelectionDeviceManager::Instantiate(
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->gtk_primary_selection_device_manager())
-+- return;
-++ if (connection->gtk_primary_selection_device_manager() ||
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-++ return;
-++ }
-+
-+- auto manager = wl::Bind<gtk_primary_selection_device_manager>(
-+- registry, name,
-+- std::min(version, kMaxGtkPrimarySelectionDeviceManagerVersion));
-++ auto manager = wl::Bind<gtk_primary_selection_device_manager>(registry, name,
-++ kMinVersion);
-+ if (!manager) {
-+ LOG(ERROR) << "Failed to bind gtk_primary_selection_device_manager";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/gtk_shell1.cc b/ui/ozone/platform/wayland/host/gtk_shell1.cc
-+index 88126d9dd6e6770747059b77fb68f96b051176a7..20afad639e26d63c1e4c039f25a833deb9595425 100644
-+--- a/ui/ozone/platform/wayland/host/gtk_shell1.cc
-++++ b/ui/ozone/platform/wayland/host/gtk_shell1.cc
-+@@ -17,8 +17,8 @@ namespace {
-+ // gtk_shell1 exposes request_focus() since version 3. Below that, it is not
-+ // interesting for us, although it provides some shell integration that might be
-+ // useful.
-+-constexpr uint32_t kMinGtkShell1Version = 3;
-+-constexpr uint32_t kMaxGtkShell1Version = 4;
-++constexpr uint32_t kMinVersion = 3;
-++constexpr uint32_t kMaxVersion = 4;
-+ } // namespace
-+
-+ // static
-+@@ -32,11 +32,13 @@ void GtkShell1::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->gtk_shell1_ || version < kMinGtkShell1Version)
-+- return;
-++ if (connection->gtk_shell1_ ||
-++ !wl::CanBind(version, kMinVersion, kMaxVersion)) {
-++ return;
-++ }
-+
-+ auto gtk_shell1 = wl::Bind<::gtk_shell1>(
-+- registry, name, std::min(version, kMaxGtkShell1Version));
-++ registry, name, std::min(version, kMaxVersion));
-+ if (!gtk_shell1) {
-+ LOG(ERROR) << "Failed to bind gtk_shell1";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/org_kde_kwin_idle.cc b/ui/ozone/platform/wayland/host/org_kde_kwin_idle.cc
-+index d990c810be430462cfe1a66460350fe1c548fbb8..ec225d49ecfbf0c349f15663d5acd3bc0620584f 100644
-+--- a/ui/ozone/platform/wayland/host/org_kde_kwin_idle.cc
-++++ b/ui/ozone/platform/wayland/host/org_kde_kwin_idle.cc
-+@@ -13,7 +13,7 @@ namespace ui {
-+
-+ namespace {
-+
-+-constexpr uint32_t kMaxOrgKdeKwinIdleVersion = 1;
-++constexpr uint32_t kMinVersion = 1;
-+
-+ // After the system has gone idle, it will wait for this time before notifying
-+ // us. This reduces "jitter" of the idle/active state, but also adds some lag
-+@@ -58,11 +58,13 @@ void OrgKdeKwinIdle::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->org_kde_kwin_idle_)
-+- return;
-++ if (connection->org_kde_kwin_idle_ ||
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-++ return;
-++ }
-+
-+ auto idle = wl::Bind<struct org_kde_kwin_idle>(
-+- registry, name, std::min(version, kMaxOrgKdeKwinIdleVersion));
-++ registry, name, kMinVersion);
-+ if (!idle) {
-+ LOG(ERROR) << "Failed to bind to org_kde_kwin_idle global";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/wayland_data_device_manager.cc b/ui/ozone/platform/wayland/host/wayland_data_device_manager.cc
-+index 036512a39fa776d3c76c8dc6e29163224838c30b..6acc02f8348e5aaf1b20c1064bb10d31c32da26d 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_data_device_manager.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_data_device_manager.cc
-+@@ -14,7 +14,8 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMaxDeviceManagerVersion = 3;
-++constexpr uint32_t kMinVersion = 1;
-++constexpr uint32_t kMaxVersion = 3;
-+ }
-+
-+ // static
-+@@ -28,11 +29,13 @@ void WaylandDataDeviceManager::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->data_device_manager_)
-+- return;
-++ if (connection->data_device_manager_ ||
-++ !wl::CanBind(version, kMinVersion, kMaxVersion)) {
-++ return;
-++ }
-+
-+ auto data_device_manager = wl::Bind<wl_data_device_manager>(
-+- registry, name, std::min(version, kMaxDeviceManagerVersion));
-++ registry, name, std::min(version, kMaxVersion));
-+ if (!data_device_manager) {
-+ LOG(ERROR) << "Failed to bind to wl_data_device_manager global";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/wayland_drm.cc b/ui/ozone/platform/wayland/host/wayland_drm.cc
-+index cb1062d47d035672e1b730fc7011185daaa162c2..852b516e1b8f86ef4e741d1a70f67541cba7def3 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_drm.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_drm.cc
-+@@ -17,7 +17,7 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMinWlDrmVersion = 2;
-++constexpr uint32_t kMinVersion = 2;
-+ }
-+
-+ // static
-+@@ -30,10 +30,12 @@ void WaylandDrm::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->drm_ || version < kMinWlDrmVersion)
-+- return;
-++ if (connection->drm_ ||
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-++ return;
-++ }
-+
-+- auto wl_drm = wl::Bind<struct wl_drm>(registry, name, version);
-++ auto wl_drm = wl::Bind<struct wl_drm>(registry, name, kMinVersion);
-+ if (!wl_drm) {
-+ LOG(ERROR) << "Failed to bind wl_drm";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/wayland_output.cc b/ui/ozone/platform/wayland/host/wayland_output.cc
-+index 0316abe49f9f6c289cfbac2ed94e47b93a7b1f1f..344974d33af6b97120e8143b1931ee59a08111f5 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_output.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_output.cc
-+@@ -13,7 +13,8 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMinWlOutputVersion = 2;
-++// TODO(crbug.com/1279681): support newer versions.
-++constexpr uint32_t kMinVersion = 2;
-+ }
-+
-+ // static
-+@@ -27,14 +28,11 @@ void WaylandOutput::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (version < kMinWlOutputVersion) {
-+- LOG(ERROR)
-+- << "Unable to bind to the unsupported wl_output object with version= "
-+- << version << ". Minimum supported version is " << kMinWlOutputVersion;
-++ if (!wl::CanBind(version, kMinVersion, kMinVersion)) {
-+ return;
-+ }
-+
-+- auto output = wl::Bind<wl_output>(registry, name, version);
-++ auto output = wl::Bind<wl_output>(registry, name, kMinVersion);
-+ if (!output) {
-+ LOG(ERROR) << "Failed to bind to wl_output global";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/wayland_shm.cc b/ui/ozone/platform/wayland/host/wayland_shm.cc
-+index 27afbcfb25d9c73d4d832bd4ac9e57629451e35a..8f05786d7beb6a8f7458bf37cf0417d6a76b682a 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_shm.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_shm.cc
-+@@ -10,7 +10,7 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMaxShmVersion = 1;
-++constexpr uint32_t kMinVersion = 1;
-+ constexpr uint32_t kShmFormat = WL_SHM_FORMAT_ARGB8888;
-+ } // namespace
-+
-+@@ -24,11 +24,13 @@ void WaylandShm::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->shm_)
-++ if (connection->shm_ ||
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-+ return;
-++ }
-+
-+ auto shm =
-+- wl::Bind<wl_shm>(registry, name, std::min(version, kMaxShmVersion));
-++ wl::Bind<wl_shm>(registry, name, kMinVersion);
-+ if (!shm) {
-+ LOG(ERROR) << "Failed to bind to wl_shm global";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/wayland_zaura_shell.cc b/ui/ozone/platform/wayland/host/wayland_zaura_shell.cc
-+index 9bc924f6baaf41288bfd616bb4f3eb4d37492c5f..29e32ed739233a91d57838e33f2fe3a7f5ecdaed 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_zaura_shell.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_zaura_shell.cc
-+@@ -18,7 +18,8 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMaxAuraShellVersion = 22;
-++constexpr uint32_t kMinVersion = 1;
-++constexpr uint32_t kMaxVersion = 22;
-+ }
-+
-+ // static
-+@@ -32,11 +33,13 @@ void WaylandZAuraShell::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->zaura_shell_)
-+- return;
-++ if (connection->zaura_shell_ ||
-++ !wl::CanBind(version, kMinVersion, kMaxVersion)) {
-++ return;
-++ }
-+
-+ auto zaura_shell = wl::Bind<struct zaura_shell>(
-+- registry, name, std::min(version, kMaxAuraShellVersion));
-++ registry, name, std::min(version, kMaxVersion));
-+ if (!zaura_shell) {
-+ LOG(ERROR) << "Failed to bind zaura_shell";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/wayland_zcr_cursor_shapes.cc b/ui/ozone/platform/wayland/host/wayland_zcr_cursor_shapes.cc
-+index 651e4f8154e47aeaac8860bf8ec58583cdb64862..28c43f2fc43be89b92496c5a5d084455c80c0cbd 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_zcr_cursor_shapes.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_zcr_cursor_shapes.cc
-+@@ -16,7 +16,7 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMaxCursorShapesVersion = 1;
-++constexpr uint32_t kMinVersion = 1;
-+ }
-+
-+ using mojom::CursorType;
-+@@ -32,11 +32,13 @@ void WaylandZcrCursorShapes::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->zcr_cursor_shapes_)
-+- return;
-++ if (connection->zcr_cursor_shapes_ ||
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-++ return;
-++ }
-+
-+ auto zcr_cursor_shapes = wl::Bind<zcr_cursor_shapes_v1>(
-+- registry, name, std::min(version, kMaxCursorShapesVersion));
-++ registry, name, kMinVersion);
-+ if (!zcr_cursor_shapes) {
-+ LOG(ERROR) << "Failed to bind zcr_cursor_shapes_v1";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/wayland_zwp_linux_dmabuf.cc b/ui/ozone/platform/wayland/host/wayland_zwp_linux_dmabuf.cc
-+index edc00fc587f1c6011171460e0c055191e642befb..34f93335267ba082a013e694e870bfe03e698fc1 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_zwp_linux_dmabuf.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_zwp_linux_dmabuf.cc
-+@@ -14,7 +14,8 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMaxLinuxDmabufVersion = 3;
-++constexpr uint32_t kMinVersion = 1;
-++constexpr uint32_t kMaxVersion = 3;
-+ }
-+
-+ // static
-+@@ -28,11 +29,13 @@ void WaylandZwpLinuxDmabuf::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->zwp_dmabuf())
-+- return;
-++ if (connection->zwp_dmabuf() ||
-++ !wl::CanBind(version, kMinVersion, kMaxVersion)) {
-++ return;
-++ }
-+
-+ auto zwp_linux_dmabuf = wl::Bind<zwp_linux_dmabuf_v1>(
-+- registry, name, std::min(version, kMaxLinuxDmabufVersion));
-++ registry, name, std::min(version, kMaxVersion));
-+ if (!zwp_linux_dmabuf) {
-+ LOG(ERROR) << "Failed to bind zwp_linux_dmabuf_v1";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/wayland_zwp_pointer_constraints.cc b/ui/ozone/platform/wayland/host/wayland_zwp_pointer_constraints.cc
-+index b0c35447917eea2c9031e24e7e03efd0999afba7..25f497db50fe1161e8bb7d162b711f583e6c482e 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_zwp_pointer_constraints.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_zwp_pointer_constraints.cc
-+@@ -15,7 +15,7 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMinZwpPointerConstraintsVersion = 1;
-++constexpr uint32_t kMinVersion = 1;
-+ }
-+
-+ // static
-+@@ -30,12 +30,12 @@ void WaylandZwpPointerConstraints::Instantiate(WaylandConnection* connection,
-+ uint32_t name,
-+ uint32_t version) {
-+ if (connection->wayland_zwp_pointer_constraints_ ||
-+- version < kMinZwpPointerConstraintsVersion) {
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-+ return;
-+ }
-+
-+ auto zwp_pointer_constraints_v1 =
-+- wl::Bind<struct zwp_pointer_constraints_v1>(registry, name, version);
-++ wl::Bind<struct zwp_pointer_constraints_v1>(registry, name, kMinVersion);
-+ if (!zwp_pointer_constraints_v1) {
-+ LOG(ERROR) << "Failed to bind wp_pointer_constraints_v1";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/wayland_zwp_pointer_gestures.cc b/ui/ozone/platform/wayland/host/wayland_zwp_pointer_gestures.cc
-+index 86a0d3aabdf23f43463c5cc2c72b31fc31da8f04..ceac0b99d4534b64a67eff04c2ab10611656a0e8 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_zwp_pointer_gestures.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_zwp_pointer_gestures.cc
-+@@ -19,7 +19,7 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMinZwpPointerGesturesVersion = 1;
-++constexpr uint32_t kMinVersion = 1;
-+ }
-+
-+ // static
-+@@ -34,11 +34,12 @@ void WaylandZwpPointerGestures::Instantiate(WaylandConnection* connection,
-+ uint32_t name,
-+ uint32_t version) {
-+ if (connection->wayland_zwp_pointer_gestures_ ||
-+- version < kMinZwpPointerGesturesVersion)
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-+ return;
-++ }
-+
-+ auto zwp_pointer_gestures_v1 =
-+- wl::Bind<struct zwp_pointer_gestures_v1>(registry, name, version);
-++ wl::Bind<struct zwp_pointer_gestures_v1>(registry, name, kMinVersion);
-+ if (!zwp_pointer_gestures_v1) {
-+ LOG(ERROR) << "Failed to bind wp_pointer_gestures_v1";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/wayland_zwp_relative_pointer_manager.cc b/ui/ozone/platform/wayland/host/wayland_zwp_relative_pointer_manager.cc
-+index 26c9cc387ae085d1bee35baab7a53e82be499799..0283b3630866fc4f32e16dc47a16fee5ac93e5a7 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_zwp_relative_pointer_manager.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_zwp_relative_pointer_manager.cc
-+@@ -14,7 +14,7 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMinZwpRelativePointerManagerVersion = 1;
-++constexpr uint32_t kMinVersion = 1;
-+ }
-+
-+ // static
-+@@ -31,11 +31,13 @@ void WaylandZwpRelativePointerManager::Instantiate(
-+ uint32_t name,
-+ uint32_t version) {
-+ if (connection->wayland_zwp_relative_pointer_manager_ ||
-+- version < kMinZwpRelativePointerManagerVersion)
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-+ return;
-++ }
-+
-+ auto zwp_relative_pointer_manager_v1 =
-+- wl::Bind<struct zwp_relative_pointer_manager_v1>(registry, name, version);
-++ wl::Bind<struct zwp_relative_pointer_manager_v1>(registry, name,
-++ kMinVersion);
-+ if (!zwp_relative_pointer_manager_v1) {
-+ LOG(ERROR) << "Failed to bind zwp_relative_pointer_manager_v1";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/xdg_foreign_wrapper.cc b/ui/ozone/platform/wayland/host/xdg_foreign_wrapper.cc
-+index 43a419c125f13a749bd5769eba66fa052a5b300c..188ff4a61685a53705b2da2773cd583a1127fe22 100644
-+--- a/ui/ozone/platform/wayland/host/xdg_foreign_wrapper.cc
-++++ b/ui/ozone/platform/wayland/host/xdg_foreign_wrapper.cc
-+@@ -11,6 +11,8 @@
-+ #include "ui/ozone/platform/wayland/host/wayland_window.h"
-+ #include "ui/platform_window/platform_window_init_properties.h"
-+
-++constexpr uint32_t kMinVersion = 1;
-++
-+ namespace ui {
-+
-+ // static
-+@@ -24,10 +26,12 @@ void XdgForeignWrapper::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->xdg_foreign_)
-+- return;
-++ if (connection->xdg_foreign_ ||
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-++ return;
-++ }
-+
-+- auto zxdg_exporter = wl::Bind<zxdg_exporter_v1>(registry, name, version);
-++ auto zxdg_exporter = wl::Bind<zxdg_exporter_v1>(registry, name, kMinVersion);
-+ if (!zxdg_exporter) {
-+ LOG(ERROR) << "Failed to bind zxdg_exporter";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/zwp_idle_inhibit_manager.cc b/ui/ozone/platform/wayland/host/zwp_idle_inhibit_manager.cc
-+index ef9cf6fd6934ffd20c7d8f80bcb3f08c9e2e43d9..678f08e63d29b2388292729c6b77dbf163a6d007 100644
-+--- a/ui/ozone/platform/wayland/host/zwp_idle_inhibit_manager.cc
-++++ b/ui/ozone/platform/wayland/host/zwp_idle_inhibit_manager.cc
-+@@ -12,7 +12,7 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMaxZwpIdleInhibitManagerVersion = 1;
-++constexpr uint32_t kMinVersion = 1;
-+ }
-+
-+ // static
-+@@ -26,11 +26,13 @@ void ZwpIdleInhibitManager::Instantiate(WaylandConnection* connection,
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->zwp_idle_inhibit_manager_)
-+- return;
-++ if (connection->zwp_idle_inhibit_manager_ ||
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-++ return;
-++ }
-+
-+- auto manager = wl::Bind<zwp_idle_inhibit_manager_v1>(
-+- registry, name, std::min(version, kMaxZwpIdleInhibitManagerVersion));
-++ auto manager =
-++ wl::Bind<zwp_idle_inhibit_manager_v1>(registry, name, kMinVersion);
-+ if (!manager) {
-+ LOG(ERROR) << "Failed to bind zwp_idle_inhibit_manager_v1";
-+ return;
-+diff --git a/ui/ozone/platform/wayland/host/zwp_primary_selection_device_manager.cc b/ui/ozone/platform/wayland/host/zwp_primary_selection_device_manager.cc
-+index 0bae8670c33bc2998e29613e7647c167b4a3b957..e7a138942c955ce432e75d155b6a80b455d3243e 100644
-+--- a/ui/ozone/platform/wayland/host/zwp_primary_selection_device_manager.cc
-++++ b/ui/ozone/platform/wayland/host/zwp_primary_selection_device_manager.cc
-+@@ -16,7 +16,7 @@
-+ namespace ui {
-+
-+ namespace {
-+-constexpr uint32_t kMaxGtkPrimarySelectionDeviceManagerVersion = 1;
-++constexpr uint32_t kMinVersion = 1;
-+ } // namespace
-+
-+ // static
-+@@ -32,12 +32,12 @@ void ZwpPrimarySelectionDeviceManager::Instantiate(
-+ wl_registry* registry,
-+ uint32_t name,
-+ uint32_t version) {
-+- if (connection->zwp_primary_selection_device_manager_)
-+- return;
-+-
-++ if (connection->zwp_primary_selection_device_manager_ ||
-++ !wl::CanBind(version, kMinVersion, kMinVersion)) {
-++ return;
-++ }
-+ auto manager = wl::Bind<zwp_primary_selection_device_manager_v1>(
-+- registry, name,
-+- std::min(version, kMaxGtkPrimarySelectionDeviceManagerVersion));
-++ registry, name, kMinVersion);
-+ if (!manager) {
-+ LOG(ERROR) << "Failed to bind zwp_primary_selection_device_manager_v1";
-+ return;
-diff --git a/patches/chromium/follow_wayland_specification_regarding_xkb_keymap.patch b/patches/chromium/follow_wayland_specification_regarding_xkb_keymap.patch
-new file mode 100644
-index 000000000000..b0df91cf2427
---- /dev/null
-+++ b/patches/chromium/follow_wayland_specification_regarding_xkb_keymap.patch
-@@ -0,0 +1,68 @@
-+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-+From: Robin Ebert <ebertrobin2002 at gmail.com>
-+Date: Tue, 22 Feb 2022 18:12:22 +0100
-+Subject: Follow wayland specification regarding xkb keymap.
-+
-+The wayland specification expects client to mmap the xkb keymap file descriptor with MAP_PRIVATE.
-+This fixes mapping issues regarding file descriptor permissions.
-+
-+diff --git a/ui/ozone/platform/wayland/host/wayland_keyboard.cc b/ui/ozone/platform/wayland/host/wayland_keyboard.cc
-+index 272322210b59228e5faa606101957c48c6371249..1c661e1ed92428f7c810fe4c041e91a08a0901e5 100644
-+--- a/ui/ozone/platform/wayland/host/wayland_keyboard.cc
-++++ b/ui/ozone/platform/wayland/host/wayland_keyboard.cc
-+@@ -4,11 +4,12 @@
-+
-+ #include "ui/ozone/platform/wayland/host/wayland_keyboard.h"
-+
-++#include <sys/mman.h>
-++
-+ #include <utility>
-+
-+ #include "base/files/scoped_file.h"
-+ #include "base/logging.h"
-+-#include "base/memory/unsafe_shared_memory_region.h"
-+ #include "base/unguessable_token.h"
-+ #include "ui/base/buildflags.h"
-+ #include "ui/events/base_event_utils.h"
-+@@ -111,26 +112,28 @@ WaylandKeyboard::~WaylandKeyboard() {
-+ void WaylandKeyboard::Keymap(void* data,
-+ wl_keyboard* obj,
-+ uint32_t format,
-+- int32_t keymap_fd,
-++ int32_t fd,
-+ uint32_t size) {
-+ WaylandKeyboard* keyboard = static_cast<WaylandKeyboard*>(data);
-+ DCHECK(keyboard);
-+
-+- base::ScopedFD fd(keymap_fd);
-+- auto length = size - 1;
-+- auto shmen = base::subtle::PlatformSharedMemoryRegion::Take(
-+- std::move(fd), base::subtle::PlatformSharedMemoryRegion::Mode::kUnsafe,
-+- length, base::UnguessableToken::Create());
-+- auto mapped_memory =
-+- base::UnsafeSharedMemoryRegion::Deserialize(std::move(shmen)).Map();
-+- const char* keymap = mapped_memory.GetMemoryAs<char>();
-++ if (!data || format != WL_KEYBOARD_KEYMAP_FORMAT_XKB_V1) {
-++ return;
-++ }
-+
-+- if (!keymap || format != WL_KEYBOARD_KEYMAP_FORMAT_XKB_V1)
-++ void* keymap = mmap(nullptr, size, PROT_READ, MAP_PRIVATE, fd, 0);
-++ if (keymap == MAP_FAILED) {
-++ DPLOG(ERROR) << "Failed to map XKB keymap.";
-+ return;
-++ }
-+
-+- bool success = keyboard->layout_engine_->SetCurrentLayoutFromBuffer(
-+- keymap, mapped_memory.size());
-+- DCHECK(success) << "Failed to set the XKB keyboard mapping.";
-++ const char* keymap_string = static_cast<const char*>(keymap);
-++ if (!keyboard->layout_engine_->SetCurrentLayoutFromBuffer(
-++ keymap_string, strnlen(keymap_string, size))) {
-++ DLOG(ERROR) << "Failed to set XKB keymap.";
-++ }
-++ munmap(keymap, size);
-++ close(fd);
-+ }
-+
-+ void WaylandKeyboard::Enter(void* data,
Deleted: replace-blacklist-with-ignorelist.patch
===================================================================
--- replace-blacklist-with-ignorelist.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ replace-blacklist-with-ignorelist.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,196 +0,0 @@
-From 9d080c0934b848ee4a05013c78641e612fcc1e03 Mon Sep 17 00:00:00 2001
-From: Dylan Cutler <dylancutler at google.com>
-Date: Wed, 26 May 2021 16:39:52 +0000
-Subject: [PATCH] Reland "Replace 'blacklist' with 'ignorelist' in
- ./tools/msan/."
-
-This is a reland of 3b6263f2eece1264b052dfdcbc03b851d5abfb48
-
-Relanding now that https://chromium-review.googlesource.com/c/chromiumos/overlays/chromiumos-overlay/+/2897974 is merged
-
-Original change's description:
-> Replace 'blacklist' with 'ignorelist' in ./tools/msan/.
->
-> Bug: 1097272, 1097268
-> Change-Id: Id5c8227a5bfb1ffaec82d3168b609085b10c8297
-> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2867730
-> Commit-Queue: Dylan Cutler <dylancutler at google.com>
-> Reviewed-by: Nico Weber <thakis at chromium.org>
-> Reviewed-by: Jonathan Metzman <metzman at chromium.org>
-> Cr-Commit-Position: refs/heads/master@{#883035}
-
-Bug: 1097272
-Bug: 1097268
-Change-Id: I11a5bc8972680c95fb1dab95ed3b707ed76f4667
-Cq-Include-Trybots: luci.chromium.try:chromeos-amd64-generic-cfi-thin-lto-rel
-Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2911096
-Commit-Queue: Dylan Cutler <dylancutler at google.com>
-Reviewed-by: Nico Weber <thakis at chromium.org>
-Cr-Commit-Position: refs/heads/master@{#886773}
----
- build/config/sanitizers/BUILD.gn | 44 ++++++++++----------
- build_overrides/build.gni | 14 +++----
- tools/msan/{blacklist.txt => ignorelist.txt} | 0
- 3 files changed, 29 insertions(+), 29 deletions(-)
- rename tools/msan/{blacklist.txt => ignorelist.txt} (100%)
-
-diff --git a/build/config/sanitizers/BUILD.gn b/build/config/sanitizers/BUILD.gn
-index aaaad023474d..55b388a43743 100644
---- a/build/config/sanitizers/BUILD.gn
-+++ b/build/config/sanitizers/BUILD.gn
-@@ -272,11 +272,11 @@ config("asan_flags") {
- if (is_asan) {
- cflags += [ "-fsanitize=address" ]
- if (is_win) {
-- if (!defined(asan_win_blacklist_path)) {
-- asan_win_blacklist_path =
-+ if (!defined(asan_win_blocklist_path)) {
-+ asan_win_blocklist_path =
- rebase_path("//tools/memory/asan/blocklist_win.txt", root_build_dir)
- }
-- cflags += [ "-fsanitize-blacklist=$asan_win_blacklist_path" ]
-+ cflags += [ "-fsanitize-ignorelist=$asan_win_blocklist_path" ]
- }
- }
- }
-@@ -306,13 +306,13 @@ config("link_shared_library") {
- config("cfi_flags") {
- cflags = []
- if (is_cfi && current_toolchain == default_toolchain) {
-- if (!defined(cfi_blacklist_path)) {
-- cfi_blacklist_path =
-+ if (!defined(cfi_ignorelist_path)) {
-+ cfi_ignorelist_path =
- rebase_path("//tools/cfi/ignores.txt", root_build_dir)
- }
- cflags += [
- "-fsanitize=cfi-vcall",
-- "-fsanitize-blacklist=$cfi_blacklist_path",
-+ "-fsanitize-ignorelist=$cfi_ignorelist_path",
- ]
-
- if (use_cfi_cast) {
-@@ -409,14 +409,14 @@ config("msan_flags") {
- if (is_msan) {
- assert(is_linux || is_chromeos,
- "msan only supported on linux x86_64/ChromeOS")
-- if (!defined(msan_blacklist_path)) {
-- msan_blacklist_path =
-- rebase_path("//tools/msan/blacklist.txt", root_build_dir)
-+ if (!defined(msan_ignorelist_path)) {
-+ msan_ignorelist_path =
-+ rebase_path("//tools/msan/ignorelist.txt", root_build_dir)
- }
- cflags = [
- "-fsanitize=memory",
- "-fsanitize-memory-track-origins=$msan_track_origins",
-- "-fsanitize-blacklist=$msan_blacklist_path",
-+ "-fsanitize-ignorelist=$msan_ignorelist_path",
- ]
- }
- }
-@@ -424,13 +424,13 @@ config("msan_flags") {
- config("tsan_flags") {
- if (is_tsan) {
- assert(is_linux || is_chromeos, "tsan only supported on linux x86_64")
-- if (!defined(tsan_blacklist_path)) {
-- tsan_blacklist_path =
-+ if (!defined(tsan_ignorelist_path)) {
-+ tsan_ignorelist_path =
- rebase_path("//tools/memory/tsan_v2/ignores.txt", root_build_dir)
- }
- cflags = [
- "-fsanitize=thread",
-- "-fsanitize-blacklist=$tsan_blacklist_path",
-+ "-fsanitize-ignorelist=$tsan_ignorelist_path",
- ]
- }
- }
-@@ -438,8 +438,8 @@ config("tsan_flags") {
- config("ubsan_flags") {
- cflags = []
- if (is_ubsan) {
-- if (!defined(ubsan_blacklist_path)) {
-- ubsan_blacklist_path =
-+ if (!defined(ubsan_ignorelist_path)) {
-+ ubsan_ignorelist_path =
- rebase_path("//tools/ubsan/ignorelist.txt", root_build_dir)
- }
- cflags += [
-@@ -456,7 +456,7 @@ config("ubsan_flags") {
- "-fsanitize=signed-integer-overflow",
- "-fsanitize=unreachable",
- "-fsanitize=vla-bound",
-- "-fsanitize-blacklist=$ubsan_blacklist_path",
-+ "-fsanitize-ignorelist=$ubsan_ignorelist_path",
- ]
-
- # Chromecast ubsan builds fail to compile with these
-@@ -486,8 +486,8 @@ config("ubsan_no_recover") {
-
- config("ubsan_security_flags") {
- if (is_ubsan_security) {
-- if (!defined(ubsan_security_blacklist_path)) {
-- ubsan_security_blacklist_path =
-+ if (!defined(ubsan_security_ignorelist_path)) {
-+ ubsan_security_ignorelist_path =
- rebase_path("//tools/ubsan/security_ignorelist.txt", root_build_dir)
- }
- cflags = [
-@@ -495,7 +495,7 @@ config("ubsan_security_flags") {
- "-fsanitize=shift",
- "-fsanitize=signed-integer-overflow",
- "-fsanitize=vla-bound",
-- "-fsanitize-blacklist=$ubsan_security_blacklist_path",
-+ "-fsanitize-ignorelist=$ubsan_security_ignorelist_path",
- ]
- }
- }
-@@ -508,13 +508,13 @@ config("ubsan_null_flags") {
-
- config("ubsan_vptr_flags") {
- if (is_ubsan_vptr) {
-- if (!defined(ubsan_vptr_blacklist_path)) {
-- ubsan_vptr_blacklist_path =
-+ if (!defined(ubsan_vptr_ignorelist_path)) {
-+ ubsan_vptr_ignorelist_path =
- rebase_path("//tools/ubsan/vptr_ignorelist.txt", root_build_dir)
- }
- cflags = [
- "-fsanitize=vptr",
-- "-fsanitize-blacklist=$ubsan_vptr_blacklist_path",
-+ "-fsanitize-ignorelist=$ubsan_vptr_ignorelist_path",
- ]
- }
- }
-diff --git a/build_overrides/build.gni b/build_overrides/build.gni
-index 82627b03653f..f3e563ab701b 100644
---- a/build_overrides/build.gni
-+++ b/build_overrides/build.gni
-@@ -42,15 +42,15 @@ declare_args() {
- # Allows different projects to specify their own suppression/ignore lists for
- # sanitizer tools.
- # asan_suppressions_file = "path/to/asan_suppressions.cc"
--# asan_win_blacklist_path = "path/to/asan/blocklist_win.txt"
-+# asan_win_ignorelist_path = "path/to/asan/blocklist_win.txt"
- # lsan_suppressions_file = "path/to/lsan_suppressions.cc"
- # tsan_suppressions_file = "path/to/tsan_suppressions.cc"
--# tsan_blacklist_path = "path/to/tsan/ignores.txt"
--# msan_blacklist_path = "path/to/msan/blacklist.txt"
--# ubsan_blacklist_path = "path/to/ubsan/blacklist.txt"
--# ubsan_vptr_blacklist_path = "path/to/ubsan/vptr_blacklist.txt"
--# ubsan_security_blacklist_path = "path/to/ubsan/security_blacklist.txt"
--# cfi_blacklist_path = "path/to/cfi/ignores.txt"
-+# tsan_ignorelist_path = "path/to/tsan/ignores.txt"
-+# msan_ignorelist_path = "path/to/msan/ignorelist.txt"
-+# ubsan_ignorelist_path = "path/to/ubsan/ignorelist.txt"
-+# ubsan_vptr_ignorelist_path = "path/to/ubsan/vptr_ignorelist.txt"
-+# ubsan_security_ignorelist_path = "path/to/ubsan/security_ignorelist.txt"
-+# cfi_ignorelist_path = "path/to/cfi/ignores.txt"
-
- declare_args() {
- # Android 32-bit non-component, non-clang builds cannot have symbol_level=2
-diff --git a/tools/msan/blacklist.txt b/tools/msan/ignorelist.txt
-similarity index 100%
-rename from tools/msan/blacklist.txt
-rename to tools/msan/ignorelist.txt
Copied: electron15/repos/community-x86_64/replace-blacklist-with-ignorelist.patch (from rev 1176686, electron15/trunk/replace-blacklist-with-ignorelist.patch)
===================================================================
--- replace-blacklist-with-ignorelist.patch (rev 0)
+++ replace-blacklist-with-ignorelist.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,196 @@
+From 9d080c0934b848ee4a05013c78641e612fcc1e03 Mon Sep 17 00:00:00 2001
+From: Dylan Cutler <dylancutler at google.com>
+Date: Wed, 26 May 2021 16:39:52 +0000
+Subject: [PATCH] Reland "Replace 'blacklist' with 'ignorelist' in
+ ./tools/msan/."
+
+This is a reland of 3b6263f2eece1264b052dfdcbc03b851d5abfb48
+
+Relanding now that https://chromium-review.googlesource.com/c/chromiumos/overlays/chromiumos-overlay/+/2897974 is merged
+
+Original change's description:
+> Replace 'blacklist' with 'ignorelist' in ./tools/msan/.
+>
+> Bug: 1097272, 1097268
+> Change-Id: Id5c8227a5bfb1ffaec82d3168b609085b10c8297
+> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2867730
+> Commit-Queue: Dylan Cutler <dylancutler at google.com>
+> Reviewed-by: Nico Weber <thakis at chromium.org>
+> Reviewed-by: Jonathan Metzman <metzman at chromium.org>
+> Cr-Commit-Position: refs/heads/master@{#883035}
+
+Bug: 1097272
+Bug: 1097268
+Change-Id: I11a5bc8972680c95fb1dab95ed3b707ed76f4667
+Cq-Include-Trybots: luci.chromium.try:chromeos-amd64-generic-cfi-thin-lto-rel
+Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2911096
+Commit-Queue: Dylan Cutler <dylancutler at google.com>
+Reviewed-by: Nico Weber <thakis at chromium.org>
+Cr-Commit-Position: refs/heads/master@{#886773}
+---
+ build/config/sanitizers/BUILD.gn | 44 ++++++++++----------
+ build_overrides/build.gni | 14 +++----
+ tools/msan/{blacklist.txt => ignorelist.txt} | 0
+ 3 files changed, 29 insertions(+), 29 deletions(-)
+ rename tools/msan/{blacklist.txt => ignorelist.txt} (100%)
+
+diff --git a/build/config/sanitizers/BUILD.gn b/build/config/sanitizers/BUILD.gn
+index aaaad023474d..55b388a43743 100644
+--- a/build/config/sanitizers/BUILD.gn
++++ b/build/config/sanitizers/BUILD.gn
+@@ -272,11 +272,11 @@ config("asan_flags") {
+ if (is_asan) {
+ cflags += [ "-fsanitize=address" ]
+ if (is_win) {
+- if (!defined(asan_win_blacklist_path)) {
+- asan_win_blacklist_path =
++ if (!defined(asan_win_blocklist_path)) {
++ asan_win_blocklist_path =
+ rebase_path("//tools/memory/asan/blocklist_win.txt", root_build_dir)
+ }
+- cflags += [ "-fsanitize-blacklist=$asan_win_blacklist_path" ]
++ cflags += [ "-fsanitize-ignorelist=$asan_win_blocklist_path" ]
+ }
+ }
+ }
+@@ -306,13 +306,13 @@ config("link_shared_library") {
+ config("cfi_flags") {
+ cflags = []
+ if (is_cfi && current_toolchain == default_toolchain) {
+- if (!defined(cfi_blacklist_path)) {
+- cfi_blacklist_path =
++ if (!defined(cfi_ignorelist_path)) {
++ cfi_ignorelist_path =
+ rebase_path("//tools/cfi/ignores.txt", root_build_dir)
+ }
+ cflags += [
+ "-fsanitize=cfi-vcall",
+- "-fsanitize-blacklist=$cfi_blacklist_path",
++ "-fsanitize-ignorelist=$cfi_ignorelist_path",
+ ]
+
+ if (use_cfi_cast) {
+@@ -409,14 +409,14 @@ config("msan_flags") {
+ if (is_msan) {
+ assert(is_linux || is_chromeos,
+ "msan only supported on linux x86_64/ChromeOS")
+- if (!defined(msan_blacklist_path)) {
+- msan_blacklist_path =
+- rebase_path("//tools/msan/blacklist.txt", root_build_dir)
++ if (!defined(msan_ignorelist_path)) {
++ msan_ignorelist_path =
++ rebase_path("//tools/msan/ignorelist.txt", root_build_dir)
+ }
+ cflags = [
+ "-fsanitize=memory",
+ "-fsanitize-memory-track-origins=$msan_track_origins",
+- "-fsanitize-blacklist=$msan_blacklist_path",
++ "-fsanitize-ignorelist=$msan_ignorelist_path",
+ ]
+ }
+ }
+@@ -424,13 +424,13 @@ config("msan_flags") {
+ config("tsan_flags") {
+ if (is_tsan) {
+ assert(is_linux || is_chromeos, "tsan only supported on linux x86_64")
+- if (!defined(tsan_blacklist_path)) {
+- tsan_blacklist_path =
++ if (!defined(tsan_ignorelist_path)) {
++ tsan_ignorelist_path =
+ rebase_path("//tools/memory/tsan_v2/ignores.txt", root_build_dir)
+ }
+ cflags = [
+ "-fsanitize=thread",
+- "-fsanitize-blacklist=$tsan_blacklist_path",
++ "-fsanitize-ignorelist=$tsan_ignorelist_path",
+ ]
+ }
+ }
+@@ -438,8 +438,8 @@ config("tsan_flags") {
+ config("ubsan_flags") {
+ cflags = []
+ if (is_ubsan) {
+- if (!defined(ubsan_blacklist_path)) {
+- ubsan_blacklist_path =
++ if (!defined(ubsan_ignorelist_path)) {
++ ubsan_ignorelist_path =
+ rebase_path("//tools/ubsan/ignorelist.txt", root_build_dir)
+ }
+ cflags += [
+@@ -456,7 +456,7 @@ config("ubsan_flags") {
+ "-fsanitize=signed-integer-overflow",
+ "-fsanitize=unreachable",
+ "-fsanitize=vla-bound",
+- "-fsanitize-blacklist=$ubsan_blacklist_path",
++ "-fsanitize-ignorelist=$ubsan_ignorelist_path",
+ ]
+
+ # Chromecast ubsan builds fail to compile with these
+@@ -486,8 +486,8 @@ config("ubsan_no_recover") {
+
+ config("ubsan_security_flags") {
+ if (is_ubsan_security) {
+- if (!defined(ubsan_security_blacklist_path)) {
+- ubsan_security_blacklist_path =
++ if (!defined(ubsan_security_ignorelist_path)) {
++ ubsan_security_ignorelist_path =
+ rebase_path("//tools/ubsan/security_ignorelist.txt", root_build_dir)
+ }
+ cflags = [
+@@ -495,7 +495,7 @@ config("ubsan_security_flags") {
+ "-fsanitize=shift",
+ "-fsanitize=signed-integer-overflow",
+ "-fsanitize=vla-bound",
+- "-fsanitize-blacklist=$ubsan_security_blacklist_path",
++ "-fsanitize-ignorelist=$ubsan_security_ignorelist_path",
+ ]
+ }
+ }
+@@ -508,13 +508,13 @@ config("ubsan_null_flags") {
+
+ config("ubsan_vptr_flags") {
+ if (is_ubsan_vptr) {
+- if (!defined(ubsan_vptr_blacklist_path)) {
+- ubsan_vptr_blacklist_path =
++ if (!defined(ubsan_vptr_ignorelist_path)) {
++ ubsan_vptr_ignorelist_path =
+ rebase_path("//tools/ubsan/vptr_ignorelist.txt", root_build_dir)
+ }
+ cflags = [
+ "-fsanitize=vptr",
+- "-fsanitize-blacklist=$ubsan_vptr_blacklist_path",
++ "-fsanitize-ignorelist=$ubsan_vptr_ignorelist_path",
+ ]
+ }
+ }
+diff --git a/build_overrides/build.gni b/build_overrides/build.gni
+index 82627b03653f..f3e563ab701b 100644
+--- a/build_overrides/build.gni
++++ b/build_overrides/build.gni
+@@ -42,15 +42,15 @@ declare_args() {
+ # Allows different projects to specify their own suppression/ignore lists for
+ # sanitizer tools.
+ # asan_suppressions_file = "path/to/asan_suppressions.cc"
+-# asan_win_blacklist_path = "path/to/asan/blocklist_win.txt"
++# asan_win_ignorelist_path = "path/to/asan/blocklist_win.txt"
+ # lsan_suppressions_file = "path/to/lsan_suppressions.cc"
+ # tsan_suppressions_file = "path/to/tsan_suppressions.cc"
+-# tsan_blacklist_path = "path/to/tsan/ignores.txt"
+-# msan_blacklist_path = "path/to/msan/blacklist.txt"
+-# ubsan_blacklist_path = "path/to/ubsan/blacklist.txt"
+-# ubsan_vptr_blacklist_path = "path/to/ubsan/vptr_blacklist.txt"
+-# ubsan_security_blacklist_path = "path/to/ubsan/security_blacklist.txt"
+-# cfi_blacklist_path = "path/to/cfi/ignores.txt"
++# tsan_ignorelist_path = "path/to/tsan/ignores.txt"
++# msan_ignorelist_path = "path/to/msan/ignorelist.txt"
++# ubsan_ignorelist_path = "path/to/ubsan/ignorelist.txt"
++# ubsan_vptr_ignorelist_path = "path/to/ubsan/vptr_ignorelist.txt"
++# ubsan_security_ignorelist_path = "path/to/ubsan/security_ignorelist.txt"
++# cfi_ignorelist_path = "path/to/cfi/ignores.txt"
+
+ declare_args() {
+ # Android 32-bit non-component, non-clang builds cannot have symbol_level=2
+diff --git a/tools/msan/blacklist.txt b/tools/msan/ignorelist.txt
+similarity index 100%
+rename from tools/msan/blacklist.txt
+rename to tools/msan/ignorelist.txt
Deleted: sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch
===================================================================
--- sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,39 +0,0 @@
-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
-
Copied: electron15/repos/community-x86_64/sandbox-build-if-glibc-2.34-dynamic-stack-size-is-en.patch (from rev 1176686, electron15/trunk/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-03-25 21:02:30 UTC (rev 1176687)
@@ -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
+
Deleted: sql-make-VirtualCursor-standard-layout-type.patch
===================================================================
--- sql-make-VirtualCursor-standard-layout-type.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ sql-make-VirtualCursor-standard-layout-type.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,238 +0,0 @@
-From 80368f8ba7a8bab13440463a254888311efe3986 Mon Sep 17 00:00:00 2001
-From: Stephan Hartmann <stha09 at googlemail.com>
-Date: Tue, 4 May 2021 15:00:19 +0000
-Subject: [PATCH] sql: make VirtualCursor standard layout type
-
-sql::recover::VirtualCursor needs to be a standard layout type, but
-has members of type std::unique_ptr. However, std::unique_ptr is not
-guaranteed to be standard layout. Compiling with clang combined with
-gcc-11 libstdc++ fails because of this. Replace std::unique_ptr with
-raw pointers.
-
-Bug: 1189788
-Change-Id: Ia6dc388cc5ef1c0f2afc75f8ca45b9f12687ca9c
----
- sql/recover_module/btree.cc | 21 +++++++++++++++------
- sql/recover_module/btree.h | 17 +++++++++++++----
- sql/recover_module/cursor.cc | 24 ++++++++++++------------
- sql/recover_module/cursor.h | 2 +-
- sql/recover_module/pager.cc | 7 +++----
- sql/recover_module/pager.h | 5 +++--
- 6 files changed, 47 insertions(+), 29 deletions(-)
-
-diff --git a/sql/recover_module/btree.cc b/sql/recover_module/btree.cc
-index 9ecaafe8a3..839318abf9 100644
---- a/sql/recover_module/btree.cc
-+++ b/sql/recover_module/btree.cc
-@@ -135,16 +135,25 @@ static_assert(std::is_trivially_destructible<LeafPageDecoder>::value,
- "Move the destructor to the .cc file if it's non-trival");
- #endif // !DCHECK_IS_ON()
-
--LeafPageDecoder::LeafPageDecoder(DatabasePageReader* db_reader) noexcept
-- : page_id_(db_reader->page_id()),
-- db_reader_(db_reader),
-- cell_count_(ComputeCellCount(db_reader)),
-- next_read_index_(0),
-- last_record_size_(0) {
-+void LeafPageDecoder::Initialize(DatabasePageReader* db_reader) {
-+ DCHECK(db_reader);
- DCHECK(IsOnValidPage(db_reader));
-+ page_id_ = db_reader->page_id();
-+ db_reader_ = db_reader;
-+ cell_count_ = ComputeCellCount(db_reader);
-+ next_read_index_ = 0;
-+ last_record_size_ = 0;
- DCHECK(DatabasePageReader::IsValidPageId(page_id_));
- }
-
-+void LeafPageDecoder::Reset() {
-+ db_reader_ = nullptr;
-+ page_id_ = 0;
-+ cell_count_ = 0;
-+ next_read_index_ = 0;
-+ last_record_size_ = 0;
-+}
-+
- bool LeafPageDecoder::TryAdvance() {
- DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
- DCHECK(CanAdvance());
-diff --git a/sql/recover_module/btree.h b/sql/recover_module/btree.h
-index d76d076bf6..33114b01fa 100644
---- a/sql/recover_module/btree.h
-+++ b/sql/recover_module/btree.h
-@@ -102,7 +102,7 @@ class LeafPageDecoder {
- //
- // |db_reader| must have been used to read an inner page of a table B-tree.
- // |db_reader| must outlive this instance.
-- explicit LeafPageDecoder(DatabasePageReader* db_reader) noexcept;
-+ explicit LeafPageDecoder() noexcept = default;
- ~LeafPageDecoder() noexcept = default;
-
- LeafPageDecoder(const LeafPageDecoder&) = delete;
-@@ -150,6 +150,15 @@ class LeafPageDecoder {
- // read as long as CanAdvance() returns true.
- bool TryAdvance();
-
-+ // Initialize with DatabasePageReader
-+ void Initialize(DatabasePageReader* db_reader);
-+
-+ // Reset internal DatabasePageReader
-+ void Reset();
-+
-+ // True if DatabasePageReader is valid
-+ bool IsValid() { return (db_reader_ != nullptr); }
-+
- // True if the given reader may point to an inner page in a table B-tree.
- //
- // The last ReadPage() call on |db_reader| must have succeeded.
-@@ -163,14 +172,14 @@ class LeafPageDecoder {
- static int ComputeCellCount(DatabasePageReader* db_reader);
-
- // The number of the B-tree page this reader is reading.
-- const int64_t page_id_;
-+ int64_t page_id_;
- // Used to read the tree page.
- //
- // Raw pointer usage is acceptable because this instance's owner is expected
- // to ensure that the DatabasePageReader outlives this.
-- DatabasePageReader* const db_reader_;
-+ DatabasePageReader* db_reader_;
- // Caches the ComputeCellCount() value for this reader's page.
-- const int cell_count_ = ComputeCellCount(db_reader_);
-+ int cell_count_;
-
- // The reader's cursor state.
- //
-diff --git a/sql/recover_module/cursor.cc b/sql/recover_module/cursor.cc
-index 0029ff9295..42548bc4b5 100644
---- a/sql/recover_module/cursor.cc
-+++ b/sql/recover_module/cursor.cc
-@@ -26,7 +26,7 @@ VirtualCursor::~VirtualCursor() {
- int VirtualCursor::First() {
- DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
- inner_decoders_.clear();
-- leaf_decoder_ = nullptr;
-+ leaf_decoder_.Reset();
-
- AppendPageDecoder(table_->root_page_id());
- return Next();
-@@ -36,18 +36,18 @@ int VirtualCursor::Next() {
- DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
- record_reader_.Reset();
-
-- while (!inner_decoders_.empty() || leaf_decoder_.get()) {
-- if (leaf_decoder_.get()) {
-- if (!leaf_decoder_->CanAdvance()) {
-+ while (!inner_decoders_.empty() || leaf_decoder_.IsValid()) {
-+ if (leaf_decoder_.IsValid()) {
-+ if (!leaf_decoder_.CanAdvance()) {
- // The leaf has been exhausted. Remove it from the DFS stack.
-- leaf_decoder_ = nullptr;
-+ leaf_decoder_.Reset();
- continue;
- }
-- if (!leaf_decoder_->TryAdvance())
-+ if (!leaf_decoder_.TryAdvance())
- continue;
-
-- if (!payload_reader_.Initialize(leaf_decoder_->last_record_size(),
-- leaf_decoder_->last_record_offset())) {
-+ if (!payload_reader_.Initialize(leaf_decoder_.last_record_size(),
-+ leaf_decoder_.last_record_offset())) {
- continue;
- }
- if (!record_reader_.Initialize())
-@@ -99,13 +99,13 @@ int VirtualCursor::ReadColumn(int column_index,
- int64_t VirtualCursor::RowId() {
- DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
- DCHECK(record_reader_.IsInitialized());
-- DCHECK(leaf_decoder_.get());
-- return leaf_decoder_->last_record_rowid();
-+ DCHECK(leaf_decoder_.IsValid());
-+ return leaf_decoder_.last_record_rowid();
- }
-
- void VirtualCursor::AppendPageDecoder(int page_id) {
- DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
-- DCHECK(leaf_decoder_.get() == nullptr)
-+ DCHECK(!leaf_decoder_.IsValid())
- << __func__
- << " must only be called when the current path has no leaf decoder";
-
-@@ -113,7 +113,7 @@ void VirtualCursor::AppendPageDecoder(int page_id) {
- return;
-
- if (LeafPageDecoder::IsOnValidPage(&db_reader_)) {
-- leaf_decoder_ = std::make_unique<LeafPageDecoder>(&db_reader_);
-+ leaf_decoder_.Initialize(&db_reader_);
- return;
- }
-
-diff --git a/sql/recover_module/cursor.h b/sql/recover_module/cursor.h
-index afcd6900e1..b15c31d425 100644
---- a/sql/recover_module/cursor.h
-+++ b/sql/recover_module/cursor.h
-@@ -129,7 +129,7 @@ class VirtualCursor {
- std::vector<std::unique_ptr<InnerPageDecoder>> inner_decoders_;
-
- // Decodes the leaf page containing records.
-- std::unique_ptr<LeafPageDecoder> leaf_decoder_;
-+ LeafPageDecoder leaf_decoder_;
-
- SEQUENCE_CHECKER(sequence_checker_);
- };
-diff --git a/sql/recover_module/pager.cc b/sql/recover_module/pager.cc
-index 58e75de270..5fe96204e5 100644
---- a/sql/recover_module/pager.cc
-+++ b/sql/recover_module/pager.cc
-@@ -23,8 +23,7 @@ static_assert(DatabasePageReader::kMaxPageId <= std::numeric_limits<int>::max(),
- "ints are not appropriate for representing page IDs");
-
- DatabasePageReader::DatabasePageReader(VirtualTable* table)
-- : page_data_(std::make_unique<uint8_t[]>(table->page_size())),
-- table_(table) {
-+ : page_data_(), table_(table) {
- DCHECK(table != nullptr);
- DCHECK(IsValidPageSize(table->page_size()));
- }
-@@ -57,8 +56,8 @@ int DatabasePageReader::ReadPage(int page_id) {
- std::numeric_limits<int64_t>::max(),
- "The |read_offset| computation above may overflow");
-
-- int sqlite_status =
-- RawRead(sqlite_file, read_size, read_offset, page_data_.get());
-+ int sqlite_status = RawRead(sqlite_file, read_size, read_offset,
-+ const_cast<uint8_t*>(page_data_.data()));
-
- // |page_id_| needs to be set to kInvalidPageId if the read failed.
- // Otherwise, future ReadPage() calls with the previous |page_id_| value
-diff --git a/sql/recover_module/pager.h b/sql/recover_module/pager.h
-index 0e388ddc3b..99314e30ff 100644
---- a/sql/recover_module/pager.h
-+++ b/sql/recover_module/pager.h
-@@ -5,6 +5,7 @@
- #ifndef SQL_RECOVER_MODULE_PAGER_H_
- #define SQL_RECOVER_MODULE_PAGER_H_
-
-+#include <array>
- #include <cstdint>
- #include <memory>
-
-@@ -70,7 +71,7 @@ class DatabasePageReader {
- DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
- DCHECK_NE(page_id_, kInvalidPageId)
- << "Successful ReadPage() required before accessing pager state";
-- return page_data_.get();
-+ return page_data_.data();
- }
-
- // The number of bytes in the page read by the last ReadPage() call.
-@@ -137,7 +138,7 @@ class DatabasePageReader {
- int page_id_ = kInvalidPageId;
- // Stores the bytes of the last page successfully read by ReadPage().
- // The content is undefined if the last call to ReadPage() did not succeed.
-- const std::unique_ptr<uint8_t[]> page_data_;
-+ const std::array<uint8_t, kMaxPageSize> page_data_;
- // Raw pointer usage is acceptable because this instance's owner is expected
- // to ensure that the VirtualTable outlives this.
- VirtualTable* const table_;
Copied: electron15/repos/community-x86_64/sql-make-VirtualCursor-standard-layout-type.patch (from rev 1176686, electron15/trunk/sql-make-VirtualCursor-standard-layout-type.patch)
===================================================================
--- sql-make-VirtualCursor-standard-layout-type.patch (rev 0)
+++ sql-make-VirtualCursor-standard-layout-type.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,238 @@
+From 80368f8ba7a8bab13440463a254888311efe3986 Mon Sep 17 00:00:00 2001
+From: Stephan Hartmann <stha09 at googlemail.com>
+Date: Tue, 4 May 2021 15:00:19 +0000
+Subject: [PATCH] sql: make VirtualCursor standard layout type
+
+sql::recover::VirtualCursor needs to be a standard layout type, but
+has members of type std::unique_ptr. However, std::unique_ptr is not
+guaranteed to be standard layout. Compiling with clang combined with
+gcc-11 libstdc++ fails because of this. Replace std::unique_ptr with
+raw pointers.
+
+Bug: 1189788
+Change-Id: Ia6dc388cc5ef1c0f2afc75f8ca45b9f12687ca9c
+---
+ sql/recover_module/btree.cc | 21 +++++++++++++++------
+ sql/recover_module/btree.h | 17 +++++++++++++----
+ sql/recover_module/cursor.cc | 24 ++++++++++++------------
+ sql/recover_module/cursor.h | 2 +-
+ sql/recover_module/pager.cc | 7 +++----
+ sql/recover_module/pager.h | 5 +++--
+ 6 files changed, 47 insertions(+), 29 deletions(-)
+
+diff --git a/sql/recover_module/btree.cc b/sql/recover_module/btree.cc
+index 9ecaafe8a3..839318abf9 100644
+--- a/sql/recover_module/btree.cc
++++ b/sql/recover_module/btree.cc
+@@ -135,16 +135,25 @@ static_assert(std::is_trivially_destructible<LeafPageDecoder>::value,
+ "Move the destructor to the .cc file if it's non-trival");
+ #endif // !DCHECK_IS_ON()
+
+-LeafPageDecoder::LeafPageDecoder(DatabasePageReader* db_reader) noexcept
+- : page_id_(db_reader->page_id()),
+- db_reader_(db_reader),
+- cell_count_(ComputeCellCount(db_reader)),
+- next_read_index_(0),
+- last_record_size_(0) {
++void LeafPageDecoder::Initialize(DatabasePageReader* db_reader) {
++ DCHECK(db_reader);
+ DCHECK(IsOnValidPage(db_reader));
++ page_id_ = db_reader->page_id();
++ db_reader_ = db_reader;
++ cell_count_ = ComputeCellCount(db_reader);
++ next_read_index_ = 0;
++ last_record_size_ = 0;
+ DCHECK(DatabasePageReader::IsValidPageId(page_id_));
+ }
+
++void LeafPageDecoder::Reset() {
++ db_reader_ = nullptr;
++ page_id_ = 0;
++ cell_count_ = 0;
++ next_read_index_ = 0;
++ last_record_size_ = 0;
++}
++
+ bool LeafPageDecoder::TryAdvance() {
+ DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
+ DCHECK(CanAdvance());
+diff --git a/sql/recover_module/btree.h b/sql/recover_module/btree.h
+index d76d076bf6..33114b01fa 100644
+--- a/sql/recover_module/btree.h
++++ b/sql/recover_module/btree.h
+@@ -102,7 +102,7 @@ class LeafPageDecoder {
+ //
+ // |db_reader| must have been used to read an inner page of a table B-tree.
+ // |db_reader| must outlive this instance.
+- explicit LeafPageDecoder(DatabasePageReader* db_reader) noexcept;
++ explicit LeafPageDecoder() noexcept = default;
+ ~LeafPageDecoder() noexcept = default;
+
+ LeafPageDecoder(const LeafPageDecoder&) = delete;
+@@ -150,6 +150,15 @@ class LeafPageDecoder {
+ // read as long as CanAdvance() returns true.
+ bool TryAdvance();
+
++ // Initialize with DatabasePageReader
++ void Initialize(DatabasePageReader* db_reader);
++
++ // Reset internal DatabasePageReader
++ void Reset();
++
++ // True if DatabasePageReader is valid
++ bool IsValid() { return (db_reader_ != nullptr); }
++
+ // True if the given reader may point to an inner page in a table B-tree.
+ //
+ // The last ReadPage() call on |db_reader| must have succeeded.
+@@ -163,14 +172,14 @@ class LeafPageDecoder {
+ static int ComputeCellCount(DatabasePageReader* db_reader);
+
+ // The number of the B-tree page this reader is reading.
+- const int64_t page_id_;
++ int64_t page_id_;
+ // Used to read the tree page.
+ //
+ // Raw pointer usage is acceptable because this instance's owner is expected
+ // to ensure that the DatabasePageReader outlives this.
+- DatabasePageReader* const db_reader_;
++ DatabasePageReader* db_reader_;
+ // Caches the ComputeCellCount() value for this reader's page.
+- const int cell_count_ = ComputeCellCount(db_reader_);
++ int cell_count_;
+
+ // The reader's cursor state.
+ //
+diff --git a/sql/recover_module/cursor.cc b/sql/recover_module/cursor.cc
+index 0029ff9295..42548bc4b5 100644
+--- a/sql/recover_module/cursor.cc
++++ b/sql/recover_module/cursor.cc
+@@ -26,7 +26,7 @@ VirtualCursor::~VirtualCursor() {
+ int VirtualCursor::First() {
+ DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
+ inner_decoders_.clear();
+- leaf_decoder_ = nullptr;
++ leaf_decoder_.Reset();
+
+ AppendPageDecoder(table_->root_page_id());
+ return Next();
+@@ -36,18 +36,18 @@ int VirtualCursor::Next() {
+ DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
+ record_reader_.Reset();
+
+- while (!inner_decoders_.empty() || leaf_decoder_.get()) {
+- if (leaf_decoder_.get()) {
+- if (!leaf_decoder_->CanAdvance()) {
++ while (!inner_decoders_.empty() || leaf_decoder_.IsValid()) {
++ if (leaf_decoder_.IsValid()) {
++ if (!leaf_decoder_.CanAdvance()) {
+ // The leaf has been exhausted. Remove it from the DFS stack.
+- leaf_decoder_ = nullptr;
++ leaf_decoder_.Reset();
+ continue;
+ }
+- if (!leaf_decoder_->TryAdvance())
++ if (!leaf_decoder_.TryAdvance())
+ continue;
+
+- if (!payload_reader_.Initialize(leaf_decoder_->last_record_size(),
+- leaf_decoder_->last_record_offset())) {
++ if (!payload_reader_.Initialize(leaf_decoder_.last_record_size(),
++ leaf_decoder_.last_record_offset())) {
+ continue;
+ }
+ if (!record_reader_.Initialize())
+@@ -99,13 +99,13 @@ int VirtualCursor::ReadColumn(int column_index,
+ int64_t VirtualCursor::RowId() {
+ DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
+ DCHECK(record_reader_.IsInitialized());
+- DCHECK(leaf_decoder_.get());
+- return leaf_decoder_->last_record_rowid();
++ DCHECK(leaf_decoder_.IsValid());
++ return leaf_decoder_.last_record_rowid();
+ }
+
+ void VirtualCursor::AppendPageDecoder(int page_id) {
+ DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
+- DCHECK(leaf_decoder_.get() == nullptr)
++ DCHECK(!leaf_decoder_.IsValid())
+ << __func__
+ << " must only be called when the current path has no leaf decoder";
+
+@@ -113,7 +113,7 @@ void VirtualCursor::AppendPageDecoder(int page_id) {
+ return;
+
+ if (LeafPageDecoder::IsOnValidPage(&db_reader_)) {
+- leaf_decoder_ = std::make_unique<LeafPageDecoder>(&db_reader_);
++ leaf_decoder_.Initialize(&db_reader_);
+ return;
+ }
+
+diff --git a/sql/recover_module/cursor.h b/sql/recover_module/cursor.h
+index afcd6900e1..b15c31d425 100644
+--- a/sql/recover_module/cursor.h
++++ b/sql/recover_module/cursor.h
+@@ -129,7 +129,7 @@ class VirtualCursor {
+ std::vector<std::unique_ptr<InnerPageDecoder>> inner_decoders_;
+
+ // Decodes the leaf page containing records.
+- std::unique_ptr<LeafPageDecoder> leaf_decoder_;
++ LeafPageDecoder leaf_decoder_;
+
+ SEQUENCE_CHECKER(sequence_checker_);
+ };
+diff --git a/sql/recover_module/pager.cc b/sql/recover_module/pager.cc
+index 58e75de270..5fe96204e5 100644
+--- a/sql/recover_module/pager.cc
++++ b/sql/recover_module/pager.cc
+@@ -23,8 +23,7 @@ static_assert(DatabasePageReader::kMaxPageId <= std::numeric_limits<int>::max(),
+ "ints are not appropriate for representing page IDs");
+
+ DatabasePageReader::DatabasePageReader(VirtualTable* table)
+- : page_data_(std::make_unique<uint8_t[]>(table->page_size())),
+- table_(table) {
++ : page_data_(), table_(table) {
+ DCHECK(table != nullptr);
+ DCHECK(IsValidPageSize(table->page_size()));
+ }
+@@ -57,8 +56,8 @@ int DatabasePageReader::ReadPage(int page_id) {
+ std::numeric_limits<int64_t>::max(),
+ "The |read_offset| computation above may overflow");
+
+- int sqlite_status =
+- RawRead(sqlite_file, read_size, read_offset, page_data_.get());
++ int sqlite_status = RawRead(sqlite_file, read_size, read_offset,
++ const_cast<uint8_t*>(page_data_.data()));
+
+ // |page_id_| needs to be set to kInvalidPageId if the read failed.
+ // Otherwise, future ReadPage() calls with the previous |page_id_| value
+diff --git a/sql/recover_module/pager.h b/sql/recover_module/pager.h
+index 0e388ddc3b..99314e30ff 100644
+--- a/sql/recover_module/pager.h
++++ b/sql/recover_module/pager.h
+@@ -5,6 +5,7 @@
+ #ifndef SQL_RECOVER_MODULE_PAGER_H_
+ #define SQL_RECOVER_MODULE_PAGER_H_
+
++#include <array>
+ #include <cstdint>
+ #include <memory>
+
+@@ -70,7 +71,7 @@ class DatabasePageReader {
+ DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
+ DCHECK_NE(page_id_, kInvalidPageId)
+ << "Successful ReadPage() required before accessing pager state";
+- return page_data_.get();
++ return page_data_.data();
+ }
+
+ // The number of bytes in the page read by the last ReadPage() call.
+@@ -137,7 +138,7 @@ class DatabasePageReader {
+ int page_id_ = kInvalidPageId;
+ // Stores the bytes of the last page successfully read by ReadPage().
+ // The content is undefined if the last call to ReadPage() did not succeed.
+- const std::unique_ptr<uint8_t[]> page_data_;
++ const std::array<uint8_t, kMaxPageSize> page_data_;
+ // Raw pointer usage is acceptable because this instance's owner is expected
+ // to ensure that the VirtualTable outlives this.
+ VirtualTable* const table_;
Deleted: unbundle-fix-visibility-of-build-config-freetype.patch
===================================================================
--- unbundle-fix-visibility-of-build-config-freetype.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ unbundle-fix-visibility-of-build-config-freetype.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,31 +0,0 @@
-From 271e45339b7b969e98ccef7837cb1b15480b07fc Mon Sep 17 00:00:00 2001
-From: Stephan Hartmann <stha09 at googlemail.com>
-Date: Thu, 4 Nov 2021 18:58:34 +0000
-Subject: [PATCH] unbundle: fix visibility of //build/config/freetype
-
-For system freetype //build/linux:freetype_from_pkgconfig is restricted
-to //third_party:freetype_harfbuzz and //third_party/harfbuzz-ng:harfbuzz_source.
-However //build/config/freetype:freetype is accessing it too.
-
-Bug: None
-Change-Id: Ic4a37b01e4ae221372a9220cbad04c598b844c21
-Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3259304
-Commit-Queue: Thomas Anderson <thomasanderson at chromium.org>
-Reviewed-by: Thomas Anderson <thomasanderson at chromium.org>
-Cr-Commit-Position: refs/heads/main@{#938388}
----
- build/linux/BUILD.gn | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/build/linux/BUILD.gn b/build/linux/BUILD.gn
-index 54314c7687..cd49e3d524 100644
---- a/build/linux/BUILD.gn
-+++ b/build/linux/BUILD.gn
-@@ -23,6 +23,7 @@ if (use_system_freetype) {
- # the system, use with caution,for details see build/config/freetype/BUILD.gn.
- pkg_config("freetype_from_pkgconfig") {
- visibility = [
-+ "//build/config/freetype:freetype",
- "//third_party:freetype_harfbuzz",
- "//third_party/harfbuzz-ng:harfbuzz_source",
- ]
Copied: electron15/repos/community-x86_64/unbundle-fix-visibility-of-build-config-freetype.patch (from rev 1176686, electron15/trunk/unbundle-fix-visibility-of-build-config-freetype.patch)
===================================================================
--- unbundle-fix-visibility-of-build-config-freetype.patch (rev 0)
+++ unbundle-fix-visibility-of-build-config-freetype.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,31 @@
+From 271e45339b7b969e98ccef7837cb1b15480b07fc Mon Sep 17 00:00:00 2001
+From: Stephan Hartmann <stha09 at googlemail.com>
+Date: Thu, 4 Nov 2021 18:58:34 +0000
+Subject: [PATCH] unbundle: fix visibility of //build/config/freetype
+
+For system freetype //build/linux:freetype_from_pkgconfig is restricted
+to //third_party:freetype_harfbuzz and //third_party/harfbuzz-ng:harfbuzz_source.
+However //build/config/freetype:freetype is accessing it too.
+
+Bug: None
+Change-Id: Ic4a37b01e4ae221372a9220cbad04c598b844c21
+Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3259304
+Commit-Queue: Thomas Anderson <thomasanderson at chromium.org>
+Reviewed-by: Thomas Anderson <thomasanderson at chromium.org>
+Cr-Commit-Position: refs/heads/main@{#938388}
+---
+ build/linux/BUILD.gn | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/build/linux/BUILD.gn b/build/linux/BUILD.gn
+index 54314c7687..cd49e3d524 100644
+--- a/build/linux/BUILD.gn
++++ b/build/linux/BUILD.gn
+@@ -23,6 +23,7 @@ if (use_system_freetype) {
+ # the system, use with caution,for details see build/config/freetype/BUILD.gn.
+ pkg_config("freetype_from_pkgconfig") {
+ visibility = [
++ "//build/config/freetype:freetype",
+ "//third_party:freetype_harfbuzz",
+ "//third_party/harfbuzz-ng:harfbuzz_source",
+ ]
Deleted: unexpire-accelerated-video-decode-flag.patch
===================================================================
--- unexpire-accelerated-video-decode-flag.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ unexpire-accelerated-video-decode-flag.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,11 +0,0 @@
---- chrome/browser/flag-metadata.json.orig 2021-09-21 18:34:38.740426608 +0000
-+++ chrome/browser/flag-metadata.json 2021-09-21 18:35:09.392000797 +0000
-@@ -1285,7 +1285,7 @@
- {
- "name": "enable-accelerated-video-decode",
- "owners": [ "media-dev at chromium.org" ],
-- "expiry_milestone": 93
-+ "expiry_milestone": 99
- },
- {
- "name": "enable-accessibility-live-caption",
Copied: electron15/repos/community-x86_64/unexpire-accelerated-video-decode-flag.patch (from rev 1176686, electron15/trunk/unexpire-accelerated-video-decode-flag.patch)
===================================================================
--- unexpire-accelerated-video-decode-flag.patch (rev 0)
+++ unexpire-accelerated-video-decode-flag.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,11 @@
+--- chrome/browser/flag-metadata.json.orig 2021-09-21 18:34:38.740426608 +0000
++++ chrome/browser/flag-metadata.json 2021-09-21 18:35:09.392000797 +0000
+@@ -1285,7 +1285,7 @@
+ {
+ "name": "enable-accelerated-video-decode",
+ "owners": [ "media-dev at chromium.org" ],
+- "expiry_milestone": 93
++ "expiry_milestone": 99
+ },
+ {
+ "name": "enable-accessibility-live-caption",
Deleted: use-ffile-compilation-dir.patch
===================================================================
--- use-ffile-compilation-dir.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ use-ffile-compilation-dir.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,65 +0,0 @@
-From 34a955823630096f5b01c2b01d51c1ea59d22763 Mon Sep 17 00:00:00 2001
-From: Zequan Wu <zequanwu at google.com>
-Date: Tue, 20 Jul 2021 14:13:50 +0000
-Subject: [PATCH] Use -ffile-compilation-dir= instead of
- -fdebug-compilation-dir=
-
-Bug: 1010267
-Change-Id: If2b4ead8535a76490eb466a38e3d8fed6ea91079
-Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2770738
-Auto-Submit: Zequan Wu <zequanwu at google.com>
-Commit-Queue: Nico Weber <thakis at chromium.org>
-Reviewed-by: Nico Weber <thakis at chromium.org>
-Cr-Commit-Position: refs/heads/master@{#903456}
----
- build/config/compiler/BUILD.gn | 18 ++++++++++++------
- build/config/compiler/compiler.gni | 7 ++-----
- 2 files changed, 14 insertions(+), 11 deletions(-)
-
-diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
-index ede07d111c..6db16c1cdd 100644
---- a/build/config/compiler/BUILD.gn
-+++ b/build/config/compiler/BUILD.gn
-@@ -1216,12 +1216,18 @@ config("compiler_deterministic") {
- # different build directory like "out/feature_a" and "out/feature_b" if
- # we build same files with same compile flag.
- # Other paths are already given in relative, no need to normalize them.
-- cflags += [
-- "-Xclang",
-- "-fdebug-compilation-dir",
-- "-Xclang",
-- ".",
-- ]
-+ if (is_nacl) {
-+ cflags += [
-+ "-Xclang",
-+ "-fdebug-compilation-dir",
-+ "-Xclang",
-+ ".",
-+ ]
-+ } else {
-+ # -ffile-compilation-dir is an alias for both -fdebug-compilation-dir=
-+ # and -fcoverage-compilation-dir=.
-+ cflags += [ "-ffile-compilation-dir=." ]
-+ }
- if (!is_win) {
- # We don't use clang -cc1as on Windows (yet? https://crbug.com/762167)
- asmflags = [ "-Wa,-fdebug-compilation-dir,." ]
-diff --git a/build/config/compiler/compiler.gni b/build/config/compiler/compiler.gni
-index 8c259c360a..642319b4f4 100644
---- a/build/config/compiler/compiler.gni
-+++ b/build/config/compiler/compiler.gni
-@@ -225,11 +225,8 @@ declare_args() {
- # deterministic builds to reduce compile times, so this is less relevant for
- # official builders.
- strip_absolute_paths_from_debug_symbols_default =
-- # TODO(crbug.com/1010267): remove '!use_clang_coverage', coverage build has
-- # dependency to absolute path of source files.
-- !use_clang_coverage &&
-- (is_android || is_fuchsia || is_nacl || (is_win && use_lld) || is_linux ||
-- is_chromeos || (is_apple && !enable_dsyms))
-+ is_android || is_fuchsia || is_nacl || (is_win && use_lld) || is_linux ||
-+ is_chromeos || (is_apple && !enable_dsyms)
-
- # If the platform uses stripped absolute paths by default, then we don't expose
- # it as a configuration option. If this is causing problems, please file a bug.
Copied: electron15/repos/community-x86_64/use-ffile-compilation-dir.patch (from rev 1176686, electron15/trunk/use-ffile-compilation-dir.patch)
===================================================================
--- use-ffile-compilation-dir.patch (rev 0)
+++ use-ffile-compilation-dir.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,65 @@
+From 34a955823630096f5b01c2b01d51c1ea59d22763 Mon Sep 17 00:00:00 2001
+From: Zequan Wu <zequanwu at google.com>
+Date: Tue, 20 Jul 2021 14:13:50 +0000
+Subject: [PATCH] Use -ffile-compilation-dir= instead of
+ -fdebug-compilation-dir=
+
+Bug: 1010267
+Change-Id: If2b4ead8535a76490eb466a38e3d8fed6ea91079
+Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2770738
+Auto-Submit: Zequan Wu <zequanwu at google.com>
+Commit-Queue: Nico Weber <thakis at chromium.org>
+Reviewed-by: Nico Weber <thakis at chromium.org>
+Cr-Commit-Position: refs/heads/master@{#903456}
+---
+ build/config/compiler/BUILD.gn | 18 ++++++++++++------
+ build/config/compiler/compiler.gni | 7 ++-----
+ 2 files changed, 14 insertions(+), 11 deletions(-)
+
+diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
+index ede07d111c..6db16c1cdd 100644
+--- a/build/config/compiler/BUILD.gn
++++ b/build/config/compiler/BUILD.gn
+@@ -1216,12 +1216,18 @@ config("compiler_deterministic") {
+ # different build directory like "out/feature_a" and "out/feature_b" if
+ # we build same files with same compile flag.
+ # Other paths are already given in relative, no need to normalize them.
+- cflags += [
+- "-Xclang",
+- "-fdebug-compilation-dir",
+- "-Xclang",
+- ".",
+- ]
++ if (is_nacl) {
++ cflags += [
++ "-Xclang",
++ "-fdebug-compilation-dir",
++ "-Xclang",
++ ".",
++ ]
++ } else {
++ # -ffile-compilation-dir is an alias for both -fdebug-compilation-dir=
++ # and -fcoverage-compilation-dir=.
++ cflags += [ "-ffile-compilation-dir=." ]
++ }
+ if (!is_win) {
+ # We don't use clang -cc1as on Windows (yet? https://crbug.com/762167)
+ asmflags = [ "-Wa,-fdebug-compilation-dir,." ]
+diff --git a/build/config/compiler/compiler.gni b/build/config/compiler/compiler.gni
+index 8c259c360a..642319b4f4 100644
+--- a/build/config/compiler/compiler.gni
++++ b/build/config/compiler/compiler.gni
+@@ -225,11 +225,8 @@ declare_args() {
+ # deterministic builds to reduce compile times, so this is less relevant for
+ # official builders.
+ strip_absolute_paths_from_debug_symbols_default =
+- # TODO(crbug.com/1010267): remove '!use_clang_coverage', coverage build has
+- # dependency to absolute path of source files.
+- !use_clang_coverage &&
+- (is_android || is_fuchsia || is_nacl || (is_win && use_lld) || is_linux ||
+- is_chromeos || (is_apple && !enable_dsyms))
++ is_android || is_fuchsia || is_nacl || (is_win && use_lld) || is_linux ||
++ is_chromeos || (is_apple && !enable_dsyms)
+
+ # If the platform uses stripped absolute paths by default, then we don't expose
+ # it as a configuration option. If this is causing problems, please file a bug.
Deleted: use-system-libraries-in-node.patch
===================================================================
--- use-system-libraries-in-node.patch 2022-03-25 21:02:02 UTC (rev 1176686)
+++ use-system-libraries-in-node.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -1,52 +0,0 @@
---- a/third_party/electron_node/BUILD.gn
-+++ b/third_party/electron_node/BUILD.gn
-@@ -42,6 +42,18 @@
- node_module_version = ""
- }
-
-+if (is_linux) {
-+ import("//build/config/linux/pkg_config.gni")
-+
-+ pkg_config("cares") {
-+ packages = [ "libcares" ]
-+ }
-+
-+ pkg_config("nghttp2") {
-+ packages = [ "libnghttp2" ]
-+ }
-+}
-+
- assert(!node_use_dtrace, "node_use_dtrace not supported in GN")
- assert(!node_use_etw, "node_use_etw not supported in GN")
-
-@@ -182,10 +194,8 @@
- component("node_lib") {
- deps = [
- ":node_js2c",
-- "deps/cares",
- "deps/histogram",
- "deps/llhttp",
-- "deps/nghttp2",
- "deps/uvwasi",
- "//third_party/zlib",
- "//third_party/brotli:dec",
-@@ -201,6 +211,19 @@
- public_configs = [ ":node_lib_config" ]
- include_dirs = [ "src" ]
- libs = []
-+ if (is_linux) {
-+ configs += [
-+ ":cares",
-+ ":nghttp2",
-+ ]
-+ libs += [ "http_parser" ]
-+ } else {
-+ deps += [
-+ "deps/cares",
-+ "deps/http_parser",
-+ "deps/nghttp2",
-+ ]
-+ }
- frameworks = []
- cflags_cc = [
- "-Wno-deprecated-declarations",
Copied: electron15/repos/community-x86_64/use-system-libraries-in-node.patch (from rev 1176686, electron15/trunk/use-system-libraries-in-node.patch)
===================================================================
--- use-system-libraries-in-node.patch (rev 0)
+++ use-system-libraries-in-node.patch 2022-03-25 21:02:30 UTC (rev 1176687)
@@ -0,0 +1,52 @@
+--- a/third_party/electron_node/BUILD.gn
++++ b/third_party/electron_node/BUILD.gn
+@@ -42,6 +42,18 @@
+ node_module_version = ""
+ }
+
++if (is_linux) {
++ import("//build/config/linux/pkg_config.gni")
++
++ pkg_config("cares") {
++ packages = [ "libcares" ]
++ }
++
++ pkg_config("nghttp2") {
++ packages = [ "libnghttp2" ]
++ }
++}
++
+ assert(!node_use_dtrace, "node_use_dtrace not supported in GN")
+ assert(!node_use_etw, "node_use_etw not supported in GN")
+
+@@ -182,10 +194,8 @@
+ component("node_lib") {
+ deps = [
+ ":node_js2c",
+- "deps/cares",
+ "deps/histogram",
+ "deps/llhttp",
+- "deps/nghttp2",
+ "deps/uvwasi",
+ "//third_party/zlib",
+ "//third_party/brotli:dec",
+@@ -201,6 +211,19 @@
+ public_configs = [ ":node_lib_config" ]
+ include_dirs = [ "src" ]
+ libs = []
++ if (is_linux) {
++ configs += [
++ ":cares",
++ ":nghttp2",
++ ]
++ libs += [ "http_parser" ]
++ } else {
++ deps += [
++ "deps/cares",
++ "deps/http_parser",
++ "deps/nghttp2",
++ ]
++ }
+ frameworks = []
+ cflags_cc = [
+ "-Wno-deprecated-declarations",
More information about the arch-commits
mailing list