From 28c7254a0d09b8524c0eb1297d0da617fe409721 Mon Sep 17 00:00:00 2001 From: Duncaen Date: Sun, 30 Aug 2026 16:20:37 +0200 Subject: [PATCH 1/3] gn: update to 0.0.20260830. --- srcpkgs/gn/template | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/srcpkgs/gn/template b/srcpkgs/gn/template index 687e089a311304..19e97c2a195325 100644 --- a/srcpkgs/gn/template +++ b/srcpkgs/gn/template @@ -1,8 +1,8 @@ # Template file for 'gn' pkgname=gn -version=0.0.20260730 +version=0.0.20260830 revision=1 -_commit=666912b6551e692c657569850f1a76e9bde062f6 +_commit=d71c4a70bd2ece461a09cbd6321970b9247fdab2 create_wrksrc=yes hostmakedepends="python3 ninja" short_desc="Meta-build system that generates build files for Ninja" @@ -10,7 +10,7 @@ maintainer="Duncaen " license="BSD-3-Clause" homepage="https://gn.googlesource.com/gn" distfiles="https://gn.googlesource.com/gn/+archive/${_commit}.tar.gz" -checksum=@3d958961e03e2e6a489c7248b8d784894b15adfc75c9fb84df5ca1fce4c95cfa +checksum=@818a09586de72275e9d7c3c29f1b979a3cebca8785c7ed919f57b0fc09ada908 do_configure() { cat <<-EOF >src/gn/last_commit_position.h From e67957c1f6eb928504fc53206383958d8bfd60e6 Mon Sep 17 00:00:00 2001 From: Duncaen Date: Thu, 27 Aug 2026 16:42:03 +0200 Subject: [PATCH 2/3] chromium: update to 152.0.7977.64. --- ...omium-143-revert-libpng_for_testonly.patch | 137 ------------------ ...-143-revert-libpng_for_testonly.patch.args | 1 - ...ograms.xml-if-it-is-not-git-checkout.patch | 39 ----- .../patches/chromium-152-dawn-clang-22.patch | 22 +++ .../patches/chromium-152-rust-cbor.patch | 39 +++++ .../chromium-152-unbundle-opus-devtools.patch | 22 +++ srcpkgs/chromium/template | 9 +- 7 files changed, 88 insertions(+), 181 deletions(-) delete mode 100644 srcpkgs/chromium/patches/chromium-143-revert-libpng_for_testonly.patch delete mode 100644 srcpkgs/chromium/patches/chromium-143-revert-libpng_for_testonly.patch.args delete mode 100644 srcpkgs/chromium/patches/chromium-151-don-t-depends-on-histograms.xml-if-it-is-not-git-checkout.patch create mode 100644 srcpkgs/chromium/patches/chromium-152-dawn-clang-22.patch create mode 100644 srcpkgs/chromium/patches/chromium-152-rust-cbor.patch create mode 100644 srcpkgs/chromium/patches/chromium-152-unbundle-opus-devtools.patch diff --git a/srcpkgs/chromium/patches/chromium-143-revert-libpng_for_testonly.patch b/srcpkgs/chromium/patches/chromium-143-revert-libpng_for_testonly.patch deleted file mode 100644 index 7ece43c88efd5a..00000000000000 --- a/srcpkgs/chromium/patches/chromium-143-revert-libpng_for_testonly.patch +++ /dev/null @@ -1,137 +0,0 @@ -commit 4f7637304eca894adf2e70078a55654a88224a30 -Author: Lukasz Anforowicz -Date: Tue Sep 30 07:08:03 2025 -0700 - - [rust png] Reland: Reinforce `testonly`-ness of some users of `libpng`. - - This reverts commit 7fa4c2d7ab42a48247ce8e0290cbb7e854990f1e and - effectively relands https://crrev.com/c/6976870. The reland is - attempted after using wildcards to cover extra gni-generated targets. - `Cq-Include-Trybots` directives in the CL description should verify - correctness of the reland. Original CL description follows: - - This CL extracts a separate `third_party/libpng:libpng_for_testonly` - target which: - - 1) Is a `group` that proxies/forwards to the `libpng` target by listing - it as its `public_deps` - 2) Has limited visibility (based on the new `libpng_testonly_visibility` - introduced in the refactored `third_party/libpng/visibility.gni`). - The new visibility is almost unchanged, except for explicitly - spelling out some targets instead of using wildcards - 3) Is marked as `testonly` - - Bug: 443128323 - Change-Id: If7ba0d184324a5c662aaf2d52122994ea778d452 - Cq-Include-Trybots: luci.chromium.try:ios-catalyst - Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6991491 - Auto-Submit: Łukasz Anforowicz - Commit-Queue: Łukasz Anforowicz - Reviewed-by: Nico Weber - Cr-Commit-Position: refs/heads/main@{#1522830} - -diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn -index a4703c3692d..2d70f7a5fe9 100644 ---- a/chrome/test/BUILD.gn -+++ b/chrome/test/BUILD.gn -@@ -11152,7 +11152,7 @@ if (!is_android) { - "//testing/gtest", - "//third_party/hunspell", - "//third_party/icu", -- "//third_party/libpng", -+ "//third_party/libpng:libpng_for_testonly", - "//ui/base:test_support", - "//ui/events:test_support", - "//ui/ozone", -@@ -11512,7 +11512,7 @@ if (!is_android && !is_chromeos_device) { - "//testing/gtest", - "//third_party/hunspell", - "//third_party/icu", -- "//third_party/libpng", -+ "//third_party/libpng:libpng_for_testonly", - "//ui/base:base_interactive_ui_tests", - "//ui/base:ozone_buildflags", - "//ui/base:test_support", -@@ -12470,7 +12470,7 @@ if (!is_android) { - "//testing/gtest", - "//third_party/hunspell", - "//third_party/icu", -- "//third_party/libpng", -+ "//third_party/libpng:libpng_for_testonly", - "//ui/base:test_support", - "//ui/resources:ui_test_pak", - "//ui/views", -diff --git a/testing/libfuzzer/fuzzers/BUILD.gn b/testing/libfuzzer/fuzzers/BUILD.gn -index 7d242e177f0..1c67eee1598 100644 ---- a/testing/libfuzzer/fuzzers/BUILD.gn -+++ b/testing/libfuzzer/fuzzers/BUILD.gn -@@ -104,7 +104,7 @@ fuzzer_test("libpng_progressive_read_fuzzer") { - sources = [ "libpng_read_fuzzer.cc" ] - deps = [ - "//base", -- "//third_party/libpng", -+ "//third_party/libpng:libpng_for_testonly", - ] - dict = "dicts/png.dict" - seed_corpuses = libpng_seed_corpuses -diff --git a/third_party/libpng/BUILD.gn b/third_party/libpng/BUILD.gn -index d4bdea1e33c..3e31348b94f 100644 ---- a/third_party/libpng/BUILD.gn -+++ b/third_party/libpng/BUILD.gn -@@ -130,6 +130,14 @@ if (is_win) { - } - } - -+group("libpng_for_testonly") { -+ testonly = true -+ public_deps = [ ":libpng" ] -+ -+ visibility = [] -+ visibility = libpng_testonly_visibility -+} -+ - if (build_with_chromium) { - libpng_ossfuzz_seed_corpuses = [ - "//components/test/data/viz", -diff --git a/tools/imagediff/BUILD.gn b/tools/imagediff/BUILD.gn -index d56651bedc7..2b5f3d38488 100644 ---- a/tools/imagediff/BUILD.gn -+++ b/tools/imagediff/BUILD.gn -@@ -34,6 +34,7 @@ if (target_os == "win" && host_os != "win") { - # If the current toolchain is the test host toolchain, build the tool. - if (current_toolchain == imagediff_toolchain) { - executable("imagediff") { -+ testonly = true - output_name = "image_diff" # Different than dir name for historical - # reasons. - sources = [ -@@ -47,7 +48,7 @@ if (current_toolchain == imagediff_toolchain) { - deps = [ - "//base", - "//build/win:default_exe_manifest", -- "//third_party/libpng", -+ "//third_party/libpng:libpng_for_testonly", - "//third_party/zlib", - ] - } -@@ -60,6 +61,7 @@ if (current_toolchain == imagediff_toolchain) { - } else if (current_toolchain == default_toolchain && - default_toolchain != imagediff_toolchain) { - binary_symlink("imagediff") { -+ testonly = true - binary_label = ":$target_name($imagediff_toolchain)" - binary_output_name = "image_diff" - -diff --git a/ui/gfx/BUILD.gn b/ui/gfx/BUILD.gn -index f6a40abfe99..83d8f55027a 100644 ---- a/ui/gfx/BUILD.gn -+++ b/ui/gfx/BUILD.gn -@@ -906,7 +906,7 @@ test("gfx_unittests") { - "//skia:skcms", - "//testing/gtest", - "//third_party/icu:icuuc", -- "//third_party/libpng", -+ "//third_party/libpng:libpng_for_testonly", - "//third_party/zlib", - "//ui/base", - "//ui/gfx/animation", diff --git a/srcpkgs/chromium/patches/chromium-143-revert-libpng_for_testonly.patch.args b/srcpkgs/chromium/patches/chromium-143-revert-libpng_for_testonly.patch.args deleted file mode 100644 index 492259cdd160e1..00000000000000 --- a/srcpkgs/chromium/patches/chromium-143-revert-libpng_for_testonly.patch.args +++ /dev/null @@ -1 +0,0 @@ --R -Np1 diff --git a/srcpkgs/chromium/patches/chromium-151-don-t-depends-on-histograms.xml-if-it-is-not-git-checkout.patch b/srcpkgs/chromium/patches/chromium-151-don-t-depends-on-histograms.xml-if-it-is-not-git-checkout.patch deleted file mode 100644 index 80b9868e070d46..00000000000000 --- a/srcpkgs/chromium/patches/chromium-151-don-t-depends-on-histograms.xml-if-it-is-not-git-checkout.patch +++ /dev/null @@ -1,39 +0,0 @@ -From 27f8690db999f6e56f0af7a9ea3d28a019ed72ca Mon Sep 17 00:00:00 2001 -From: Fumitoshi Ukai -Date: Tue, 30 Jun 2026 18:32:03 -0700 -Subject: [PATCH] don't depends on histograms.xml if it is not git checkout - -histograms.xml is only generated on git checkout. - -Bug: 329080012 -Change-Id: Iea4484f8af4cf9ef25e25ea1df2c616fbe46ed5c -Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/8019063 -Reviewed-by: Jesse McKenna -Commit-Queue: Fumitoshi Ukai -Auto-Submit: Fumitoshi Ukai -Cr-Commit-Position: refs/heads/main@{#1655184} ---- - tools/metrics/BUILD.gn | 10 +++++----- - 1 file changed, 5 insertions(+), 5 deletions(-) - -diff --git a/tools/metrics/BUILD.gn b/tools/metrics/BUILD.gn -index c826e9708bf6a6..23799c76dd7ef1 100644 ---- a/tools/metrics/BUILD.gn -+++ b/tools/metrics/BUILD.gn -@@ -41,11 +41,11 @@ group("metrics_metadata") { - ] - - # Only include histograms_xml if we have access to dirmd data, which -- # is used to populate ownership information. This is only set to false -- # for non-git checkouts. -- # TODO(crbug.com/329080012): Remove this once dirmd works in non-git -- # checkouts. -- if (generate_location_tags) { -+ # is used to populate ownership information. This is disabled -+ # for non-git checkouts, as dirmd doesn't work on non-git checkout. -+ # TODO(crbug.com/329080012): Remove this condition once dirmd works -+ # in non-git checkouts. -+ if (path_exists("//.git")) { - deps += [ ":histograms_xml" ] - } - } diff --git a/srcpkgs/chromium/patches/chromium-152-dawn-clang-22.patch b/srcpkgs/chromium/patches/chromium-152-dawn-clang-22.patch new file mode 100644 index 00000000000000..ca77f2baeabecf --- /dev/null +++ b/srcpkgs/chromium/patches/chromium-152-dawn-clang-22.patch @@ -0,0 +1,22 @@ +From 7a0d8ee35637aaa73b041e6ba9b381ffe18e88b5 Mon Sep 17 00:00:00 2001 +From: LN Liberda +Date: Sun, 19 Jul 2026 11:19:09 +0200 +Subject: [PATCH] dawn: build with clang 22 + +--- + src/utils/BUILD.gn | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/third_party/dawn/src/utils/BUILD.gn b/third_party/dawn/src/utils/BUILD.gn +index b9f0be693e..ed7ad3b6d3 100644 +--- a/third_party/dawn/src/utils/BUILD.gn ++++ b/third_party/dawn/src/utils/BUILD.gn +@@ -218,8 +218,6 @@ config("dawn_warnings") { + # the analysis pass. + "-Wno-lifetime-safety", + "-Wno-lifetime-safety-all", +- "-Xclang=-fno-lifetime-safety-inference", +- "-Xclang=-fno-experimental-lifetime-safety-tu-analysis", + ] + + # P3. Checks that could be nice but probably don't help with hardening. diff --git a/srcpkgs/chromium/patches/chromium-152-rust-cbor.patch b/srcpkgs/chromium/patches/chromium-152-rust-cbor.patch new file mode 100644 index 00000000000000..3c92d4e6e70812 --- /dev/null +++ b/srcpkgs/chromium/patches/chromium-152-rust-cbor.patch @@ -0,0 +1,39 @@ +Patch-Source: https://salsa.debian.org/chromium-team/chromium/-/blob/96bdb2b923774cf54f3c7598d941df3f769b7897/debian/patches/system/rust-cbor.patch + +ERROR at //build/rust/crubit/BUILD.gn:11:5: Unable to load "/chr-build/chromium-152.0.7977.64/third_party/rust-toolchain/lib/third_party/crubit/support/BUILD.gn". + "$crubit_src_dir/support:support_cpp", + ^------------------------------------ + +Patch taken from https://github.com/ungoogled-software/ungoogled-chromium/pull/3928/changes +(though clearly a more permanent solution is needed, if upstream is +planning to drop USE_CBOR_RUST..) + +--- a/components/cbor/BUILD.gn ++++ b/components/cbor/BUILD.gn +@@ -12,7 +12,7 @@ buildflag_header("buildflags") { + # TODO(crbug.com/535682335): Remove `USE_CBOR_RUST` buildflag entirely, + # unconditionally enable Rust CBOR parser, and drop `is_cronet_build` check + # once Cronet supports Crubit dependencies. +- flags = [ "USE_CBOR_RUST=!$is_cronet_build" ] ++ flags = [ "USE_CBOR_RUST=$enable_cpp_api_from_rust" ] + } + + component("cbor") { +@@ -37,7 +37,7 @@ component("cbor") { + "//base", + ] + +- if (!is_cronet_build) { ++ if (enable_cpp_api_from_rust) { + public_deps = [ + "//build/rust/crubit", + "//components/cbor/rust:cbor_rust_bindings", +@@ -63,7 +63,7 @@ source_set("unit_tests") { + "//testing/gtest", + "//third_party/fuzztest", + ] +- if (!is_cronet_build) { ++ if (enable_cpp_api_from_rust) { + deps += [ "//components/cbor/rust:cbor_rust_unittests" ] + } + diff --git a/srcpkgs/chromium/patches/chromium-152-unbundle-opus-devtools.patch b/srcpkgs/chromium/patches/chromium-152-unbundle-opus-devtools.patch new file mode 100644 index 00000000000000..77e385596e6443 --- /dev/null +++ b/srcpkgs/chromium/patches/chromium-152-unbundle-opus-devtools.patch @@ -0,0 +1,22 @@ +From 47459e81cbfc542aca5a4493dba8457fe11f7108 Mon Sep 17 00:00:00 2001 +From: LN Liberda +Date: Thu, 27 Aug 2026 20:27:03 +0200 +Subject: [PATCH] unbundle/opus: add missing dep on opus in + devtools_media_encoding_service + +--- + content/services/devtools_media_encoding_service/BUILD.gn | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/content/services/devtools_media_encoding_service/BUILD.gn b/content/services/devtools_media_encoding_service/BUILD.gn +index ce2b615256d36..ef222ca3597c2 100644 +--- a/content/services/devtools_media_encoding_service/BUILD.gn ++++ b/content/services/devtools_media_encoding_service/BUILD.gn +@@ -18,6 +18,7 @@ source_set("devtools_media_encoding_service") { + "//media/mojo/common", + "//media/mojo/mojom", + "//mojo/public/cpp/bindings", ++ "//third_party/opus", + "//ui/gfx/geometry", + ] + diff --git a/srcpkgs/chromium/template b/srcpkgs/chromium/template index af3c522a7b8ca0..3349ebf334d749 100644 --- a/srcpkgs/chromium/template +++ b/srcpkgs/chromium/template @@ -1,7 +1,7 @@ # Template file for 'chromium' pkgname=chromium # See https://chromiumdash.appspot.com/releases?platform=Linux for the latest version -version=151.0.7922.108 +version=152.0.7977.64 revision=1 _rollup=4.22.4 archs="i686* x86_64* aarch64* armv7l*" @@ -36,7 +36,7 @@ homepage="https://www.chromium.org/" # distfiles="https://chromium.googlesource.com/chromium/src.git/+archive/refs/tags/${version}.tar.gz" distfiles="https://github.com/chromium-linux-tarballs/chromium-tarballs/releases/download/${version}/chromium-${version}-linux.tar.xz https://registry.npmjs.org/@rollup/wasm-node/-/wasm-node-${_rollup}.tgz" -checksum="69f7abb0b3907245b3239c9e3880789b61144843cbd7669fee18c2f79909572d +checksum="4f96a2d9e87778b2bab2901d88127b00c108060e9d6f424425c715366f14d435 ee49bf67bd9bee869405af78162d028e2af0fcfca80497404f56b1b99f272717" skip_extraction="wasm-node-${_rollup}.tgz" @@ -105,9 +105,10 @@ post_patch() { mkdir -p third_party/node/linux/node-linux-x64/bin rm -f third_party/node/linux/node-linux-x64/bin/node - ln -s /usr/bin/node third_party/node/linux/node-linux-x64/bin/ + ln -s /usr/bin/node third_party/node/linux/node-linux-x64/bin/node mkdir -p third_party/dawn/tools/golang/linux-amd64/bin + rm -f third_party/dawn/tools/golang/linux-amd64/bin/go ln -s /usr/bin/go third_party/dawn/tools/golang/linux-amd64/bin/go rm -rv third_party/devtools-frontend/src/node_modules/rollup @@ -194,13 +195,13 @@ do_configure() { # snappy # ffmpeg: system ffmpeg is too old and makes the ffmpeg update not require # rebuilding chromium + # libpng system=( flac fontconfig freetype libdrm libjpeg - libpng libwebp libxml libxslt From 6ef1319f78acd8e5cf5b528b973c720aeb0dd65d Mon Sep 17 00:00:00 2001 From: Duncaen Date: Wed, 9 Sep 2026 22:32:47 +0200 Subject: [PATCH 3/3] chromium: update to 153.0.8010.36. --- ... => chromium-138-node-version-check.patch} | 0 .../patches/chromium-152-dawn-clang-22.patch | 22 - ...> chromium-153-cross-rust-toolchain.patch} | 36 +- .../chromium-153-no-python-vendoring.patch | 982 ++++++++++++++++++ ...ium-153-typescript-break-definitions.patch | 22 + .../chromium-153-unbundle-opus-iamf.patch | 40 + ...chromium-153-uncrubit-blink-opentype.patch | 276 +++++ srcpkgs/chromium/template | 4 +- 8 files changed, 1341 insertions(+), 41 deletions(-) rename srcpkgs/chromium/patches/{cr138-node-version-check.patch => chromium-138-node-version-check.patch} (100%) delete mode 100644 srcpkgs/chromium/patches/chromium-152-dawn-clang-22.patch rename srcpkgs/chromium/patches/{chromium-150-cross-rust-toolchain.patch => chromium-153-cross-rust-toolchain.patch} (72%) create mode 100644 srcpkgs/chromium/patches/chromium-153-no-python-vendoring.patch create mode 100644 srcpkgs/chromium/patches/chromium-153-typescript-break-definitions.patch create mode 100644 srcpkgs/chromium/patches/chromium-153-unbundle-opus-iamf.patch create mode 100644 srcpkgs/chromium/patches/chromium-153-uncrubit-blink-opentype.patch diff --git a/srcpkgs/chromium/patches/cr138-node-version-check.patch b/srcpkgs/chromium/patches/chromium-138-node-version-check.patch similarity index 100% rename from srcpkgs/chromium/patches/cr138-node-version-check.patch rename to srcpkgs/chromium/patches/chromium-138-node-version-check.patch diff --git a/srcpkgs/chromium/patches/chromium-152-dawn-clang-22.patch b/srcpkgs/chromium/patches/chromium-152-dawn-clang-22.patch deleted file mode 100644 index ca77f2baeabecf..00000000000000 --- a/srcpkgs/chromium/patches/chromium-152-dawn-clang-22.patch +++ /dev/null @@ -1,22 +0,0 @@ -From 7a0d8ee35637aaa73b041e6ba9b381ffe18e88b5 Mon Sep 17 00:00:00 2001 -From: LN Liberda -Date: Sun, 19 Jul 2026 11:19:09 +0200 -Subject: [PATCH] dawn: build with clang 22 - ---- - src/utils/BUILD.gn | 2 -- - 1 file changed, 2 deletions(-) - -diff --git a/third_party/dawn/src/utils/BUILD.gn b/third_party/dawn/src/utils/BUILD.gn -index b9f0be693e..ed7ad3b6d3 100644 ---- a/third_party/dawn/src/utils/BUILD.gn -+++ b/third_party/dawn/src/utils/BUILD.gn -@@ -218,8 +218,6 @@ config("dawn_warnings") { - # the analysis pass. - "-Wno-lifetime-safety", - "-Wno-lifetime-safety-all", -- "-Xclang=-fno-lifetime-safety-inference", -- "-Xclang=-fno-experimental-lifetime-safety-tu-analysis", - ] - - # P3. Checks that could be nice but probably don't help with hardening. diff --git a/srcpkgs/chromium/patches/chromium-150-cross-rust-toolchain.patch b/srcpkgs/chromium/patches/chromium-153-cross-rust-toolchain.patch similarity index 72% rename from srcpkgs/chromium/patches/chromium-150-cross-rust-toolchain.patch rename to srcpkgs/chromium/patches/chromium-153-cross-rust-toolchain.patch index 8727ae25ac3400..4b31c34a46d0d4 100644 --- a/srcpkgs/chromium/patches/chromium-150-cross-rust-toolchain.patch +++ b/srcpkgs/chromium/patches/chromium-153-cross-rust-toolchain.patch @@ -29,23 +29,25 @@ also does not ship the rust stdlib for every target, so add an additional outputs += [ "$target_out_dir/lib$lib.rlib" ] --- a/build/rust/std/find_std_rlibs.py +++ b/build/rust/std/find_std_rlibs.py -@@ -26,6 +26,7 @@ - help="Path to Rust binaries", - required=True), - parser.add_argument("--target", help="Rust target triple", required=False), -+ parser.add_argument("--sysroot", help="Rust sysroot", required=False), - parser.add_argument("--output", - help="Path to rlibs without suffixes", - required=True) -@@ -50,6 +51,8 @@ - rustc_args = [rustc, "--print", "target-libdir"] - if args.target: - rustc_args.extend(["--target", args.target]) -+ if args.sysroot: -+ rustc_args.extend(["--sysroot", args.sysroot]) - rustlib_dir = subprocess.check_output(rustc_args).rstrip().decode() - - # Copy the rlibs to a predictable location. Whilst we're doing so, +@@ -33,6 +33,9 @@ + ), + ) + parser.add_argument( ++ "--sysroot", help="Rust sysroot", required=False ++ ) ++ parser.add_argument( + "--output", help="Path to rlibs without suffixes", required=True + ) + parser.add_argument( +@@ -61,6 +64,8 @@ + rustc_args = [rustc, "--print", "target-libdir"] + if args.target: + rustc_args.extend(["--target", args.target]) ++ if args.sysroot: ++ rustc_args.extend(["--sysroot", args.sysroot]) + rustlib_dir = subprocess.check_output(rustc_args).rstrip().decode() + # crbug.com/467351944 - rustc --print target-libdir loses Windows subst paths + # due to calling GetFinalPathNameByHandle() during canonicalization. This --- a/build/config/compiler/BUILD.gn +++ b/build/config/compiler/BUILD.gn @@ -1158,6 +1158,12 @@ diff --git a/srcpkgs/chromium/patches/chromium-153-no-python-vendoring.patch b/srcpkgs/chromium/patches/chromium-153-no-python-vendoring.patch new file mode 100644 index 00000000000000..b894e64f14d85c --- /dev/null +++ b/srcpkgs/chromium/patches/chromium-153-no-python-vendoring.patch @@ -0,0 +1,982 @@ +From 6e07e9c3dc5f7f5c668059e8fda3a8cbd2c37099 Mon Sep 17 00:00:00 2001 +From: LN Liberda +Date: Fri, 28 Aug 2026 04:08:29 +0200 +Subject: [PATCH] Revert "DEPS: use DEPS provided python instead of a system + one." + +This reverts commit ce8851b40f37e74adcb7813256930792f35b8039. +--- + .gn | 5 ++- + build/config/siso/android.star | 47 ++++++++---------------- + build/config/siso/blink_all.star | 4 +- + build/config/siso/clang_unix.star | 17 ++------- + build/config/siso/clang_windows.star | 7 ++-- + build/config/siso/devtools_frontend.star | 7 +--- + build/config/siso/grit.star | 5 +-- + build/config/siso/linux.star | 28 +++++--------- + build/config/siso/mac.star | 7 ++-- + build/config/siso/main.star | 15 -------- + build/config/siso/mojo.star | 6 +-- + build/config/siso/nasm_linux.star | 4 +- + build/config/siso/platform.star | 4 +- + build/config/siso/proto_linux.star | 4 +- + build/config/siso/rust.star | 24 +++--------- + build/config/siso/typescript_all.star | 10 ++--- + build/config/siso/v8.star | 2 - + build/toolchain/apple/toolchain.gni | 2 +- + build/toolchain/gcc_toolchain.gni | 2 +- + build/toolchain/win/toolchain.gni | 2 +- + 20 files changed, 63 insertions(+), 139 deletions(-) + +diff --git a/.gn b/.gn +index 8d1672b11a008..97a3fa950ca62 100644 +--- a/.gn ++++ b/.gn +@@ -8,8 +8,9 @@ import("//third_party/angle/dotfile_settings.gni") + # The location of the build configuration file. + buildconfig = "//build/config/BUILDCONFIG.gn" + +-# The hermetic Python interpreter to use by default. +-script_executable = "//third_party/cpython3/host/bin/python3" ++# The python interpreter to use by default. On Windows, this will look ++# for python3.exe and python3.bat. ++script_executable = "python3" + + # These arguments override the default values for items in a declare_args + # block. "gn args" in turn can override these. +diff --git a/build/config/siso/android.star b/build/config/siso/android.star +index 3995db1b1fecc..2e463b53941da 100644 +--- a/build/config/siso/android.star ++++ b/build/config/siso/android.star +@@ -10,7 +10,6 @@ load("@builtin//path.star", "path") + load("@builtin//struct.star", "module") + load("./config.star", "config") + load("./gn_logs.star", "gn_logs") +-load("./platform.star", "platform") + + # TODO: crbug.com/323091468 - Propagate target android ABI and + # android SDK version from GN, and remove the hardcoded filegroups. +@@ -61,22 +60,20 @@ def __step_config(ctx, step_config): + # See also https://chromium.googlesource.com/chromium/src/build/+/HEAD/android/docs/java_toolchain.md + { + "name": "android/write_build_config", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/write_build_config.py", ++ "command_prefix": "python3 ../../build/android/gyp/write_build_config.py", + "handler": "android_write_build_config", + "remote": remote_run, + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/ijar", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/ijar.py", ++ "command_prefix": "python3 ../../build/android/gyp/ijar.py", + "remote": remote_run, + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/turbine", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/turbine.py", ++ "command_prefix": "python3 ../../build/android/gyp/turbine.py", + "handler": "android_turbine", + # TODO: crbug.com/396220357 - fix gn to remove unnecessary deps + "exclude_input_patterns": [ +@@ -100,11 +97,10 @@ def __step_config(ctx, step_config): + "remote": remote_run and not config.get(ctx, "no-remote-javac"), + "platform_ref": "large", + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/compile_resources", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/compile_resources.py", ++ "command_prefix": "python3 ../../build/android/gyp/compile_resources.py", + "handler": "android_compile_resources", + "exclude_input_patterns": [ + "*.a", +@@ -118,11 +114,10 @@ def __step_config(ctx, step_config): + ], + "remote": remote_run, + "timeout": "5m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/compile_java", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/compile_java.py", ++ "command_prefix": "python3 ../../build/android/gyp/compile_java.py", + "handler": "android_compile_java", + "exclude_input_patterns": [ + "*.a", +@@ -142,11 +137,10 @@ def __step_config(ctx, step_config): + "remote": remote_run and not config.get(ctx, "no-remote-javac"), + "platform_ref": "large", + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/errorprone", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/errorprone.py", ++ "command_prefix": "python3 ../../build/android/gyp/errorprone.py", + "handler": "android_compile_java", + "exclude_input_patterns": [ + "*.a", +@@ -163,11 +157,10 @@ def __step_config(ctx, step_config): + # obj/chrome/android/chrome_java__errorprone.stamp step takes too + # long. + "timeout": "6m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/compile_kt", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/compile_kt.py", ++ "command_prefix": "python3 ../../build/android/gyp/compile_kt.py", + "handler": "android_compile_java", + "exclude_input_patterns": [ + "*.a", +@@ -187,11 +180,10 @@ def __step_config(ctx, step_config): + "remote": remote_run, + "platform_ref": "large", + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/dex", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/dex.py", ++ "command_prefix": "python3 ../../build/android/gyp/dex.py", + "handler": "android_dex", + "exclude_input_patterns": [ + "*.a", +@@ -210,18 +202,16 @@ def __step_config(ctx, step_config): + "remote": remote_run, + "platform_ref": "large", + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/filter_zip", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/filter_zip.py", ++ "command_prefix": "python3 ../../build/android/gyp/filter_zip.py", + "remote": remote_run, + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/generate_resource_allowlist", +- "command_prefix": platform.python_bin + " ../../tools/resources/generate_resource_allowlist.py", ++ "command_prefix": "python3 ../../tools/resources/generate_resource_allowlist.py", + "indirect_inputs": { + "includes": ["*.o", "*.a"], + }, +@@ -231,16 +221,15 @@ def __step_config(ctx, step_config): + }, + { + "name": "android/trace_event_bytecode_rewriter", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/trace_event_bytecode_rewriter.py", ++ "command_prefix": "python3 ../../build/android/gyp/trace_event_bytecode_rewriter.py", + "handler": "android_trace_event_bytecode_rewriter", + "remote": remote_run, + "platform_ref": "large", + "timeout": "10m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/proguard/local", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/proguard.py", ++ "command_prefix": "python3 ../../build/android/gyp/proguard.py", + "action_outs": [ + # http://crbug.com/396004680#comment15: It slows down CQ build. + # It's better to run it locally. +@@ -250,7 +239,7 @@ def __step_config(ctx, step_config): + }, + { + "name": "android/proguard", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/proguard.py", ++ "command_prefix": "python3 ../../build/android/gyp/proguard.py", + "handler": "android_proguard", + "exclude_input_patterns": [ + "*.a", +@@ -265,11 +254,10 @@ def __step_config(ctx, step_config): + "remote": remote_run, + "platform_ref": "large", + "timeout": "10m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/trace_references", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/tracereferences.py", ++ "command_prefix": "python3 ../../build/android/gyp/tracereferences.py", + "handler": "android_trace_references", + "exclude_input_patterns": [ + "*.a", +@@ -284,11 +272,10 @@ def __step_config(ctx, step_config): + "remote": remote_run_static_analysis, + "platform_ref": "large", + "timeout": "10m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/apkbuilder", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/apkbuilder.py", ++ "command_prefix": "python3 ../../build/android/gyp/apkbuilder.py", + "handler": "android_apkbuilder", + "remote": config.get(ctx, "remote-link") or config.get(ctx, "default-remote") or config.get(ctx, "builder"), + "platform_ref": "large", +@@ -298,11 +285,10 @@ def __step_config(ctx, step_config): + "*.proto", + "*.o", + ], +- "remote_command": platform.remote_python_bin, + }, + { + "name": "android/create_size_info_files", +- "command_prefix": platform.python_bin + " ../../build/android/gyp/create_size_info_files.py", ++ "command_prefix": "python3 ../../build/android/gyp/create_size_info_files.py", + "handler": "android_create_size_info_files", + "remote": remote_run, + "platform_ref": "large", +@@ -314,7 +300,6 @@ def __step_config(ctx, step_config): + "*.inc", + "*.cpp", + ], +- "remote_command": platform.remote_python_bin, + }, + ]) + return step_config +diff --git a/build/config/siso/blink_all.star b/build/config/siso/blink_all.star +index 9dc78bc01b903..a60452927c978 100644 +--- a/build/config/siso/blink_all.star ++++ b/build/config/siso/blink_all.star +@@ -30,7 +30,7 @@ def __step_config(ctx, step_config): + "remote": remote_run, + "timeout": "2m", + "platform_ref": "large", +- "remote_command": platform.remote_python_bin, # only run on Linux worker even for CI Windows. ++ "remote_command": "python3", # only run on Linux worker even for CI Windows. + }, + ]) + +@@ -47,14 +47,12 @@ def __step_config(ctx, step_config): + # needs to read the generated .mojom files. But, the inputs are + # not specified in the build graph correctly. + "output_local": True, +- "remote_command": platform.remote_python_bin, + }, + { + "name": "blink/build_web_idl_database", + "command_prefix": platform.python_bin + " ../../third_party/blink/renderer/bindings/scripts/build_web_idl_database.py", + "remote": remote_run, + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + ]) + return step_config +diff --git a/build/config/siso/clang_unix.star b/build/config/siso/clang_unix.star +index fa182e9d69489..13fe810d93548 100644 +--- a/build/config/siso/clang_unix.star ++++ b/build/config/siso/clang_unix.star +@@ -11,7 +11,6 @@ load("./android.star", "android") + load("./clang_all.star", "clang_all") + load("./config.star", "config") + load("./gn_logs.star", "gn_logs") +-load("./platform.star", "platform") + load("./win_sdk.star", "win_sdk") + + def __clang_link(ctx, cmd): +@@ -295,7 +294,7 @@ def __rules(ctx): + { + "name": "clang-coverage/cxx", + "action": "(.*_)?cxx", +- "command_prefix": platform.python_bin + " ../../build/toolchain/clang_code_coverage_wrapper.py", ++ "command_prefix": "\"python3\" ../../build/toolchain/clang_code_coverage_wrapper.py", + "inputs": [ + "third_party/llvm-build/Release+Asserts/bin/clang++", + ], +@@ -308,7 +307,7 @@ def __rules(ctx): + { + "name": "clang-coverage/cc", + "action": "(.*_)?cc", +- "command_prefix": platform.python_bin + " ../../build/toolchain/clang_code_coverage_wrapper.py", ++ "command_prefix": "\"python3\" ../../build/toolchain/clang_code_coverage_wrapper.py", + "inputs": [ + "third_party/llvm-build/Release+Asserts/bin/clang", + ], +@@ -321,7 +320,7 @@ def __rules(ctx): + { + "name": "clang-coverage/objcxx", + "action": "(.*_)?objcxx", +- "command_prefix": platform.python_bin + " ../../build/toolchain/clang_code_coverage_wrapper.py", ++ "command_prefix": "\"python3\" ../../build/toolchain/clang_code_coverage_wrapper.py", + "inputs": [ + "third_party/llvm-build/Release+Asserts/bin/clang++", + ], +@@ -334,7 +333,7 @@ def __rules(ctx): + { + "name": "clang-coverage/objc", + "action": "(.*_)?objc", +- "command_prefix": platform.python_bin + " ../../build/toolchain/clang_code_coverage_wrapper.py", ++ "command_prefix": "\"python3\" ../../build/toolchain/clang_code_coverage_wrapper.py", + "inputs": [ + "third_party/llvm-build/Release+Asserts/bin/clang", + ], +@@ -365,9 +364,6 @@ def __rules(ctx): + "name": "clang/solink", + "action": "(.*_)?solink", + "handler": "clang_link", +- "inputs": [ +- "third_party/cpython3/linux-amd64:cpython3", +- ], + "exclude_input_patterns": [ + "*.cc", + "*.h", +@@ -376,7 +372,6 @@ def __rules(ctx): + "*.stamp", + ], + "remote": remote_link, +- "remote_command": platform.remote_python_bin, + "restat_content": True, + "platform_ref": "large", + "timeout": remote_link_timeout, +@@ -400,9 +395,6 @@ def __rules(ctx): + "name": "clang/link", + "action": "(.*_)?link", + "handler": "clang_link", +- "inputs": [ +- "third_party/cpython3/linux-amd64:cpython3", +- ], + "exclude_input_patterns": [ + "*.cc", + "*.h", +@@ -412,7 +404,6 @@ def __rules(ctx): + "*.stamp", + ], + "remote": remote_link, +- "remote_command": platform.remote_python_bin, + "platform_ref": "large", + "timeout": remote_link_timeout, + }, +diff --git a/build/config/siso/clang_windows.star b/build/config/siso/clang_windows.star +index 83e974e48b667..26e3d77d2f06e 100644 +--- a/build/config/siso/clang_windows.star ++++ b/build/config/siso/clang_windows.star +@@ -9,7 +9,6 @@ load("./clang_all.star", "clang_all") + load("./clang_exception.star", "clang_exception") + load("./config.star", "config") + load("./gn_logs.star", "gn_logs") +-load("./platform.star", "platform") + load("./reclient.star", "reclient") + load("./rewrapper_cfg.star", "rewrapper_cfg") + load("./win_sdk.star", "win_sdk") +@@ -138,7 +137,7 @@ def __step_config(ctx, step_config): + { + "name": "clang-coverage/cxx", + "action": "(.*_)?cxx", +- "command_prefix": platform.python_bin + " ../../build/toolchain/clang_code_coverage_wrapper.py", ++ "command_prefix": "python3.exe ../../build/toolchain/clang_code_coverage_wrapper.py", + "inputs": rewrapper_config_inputs + [ + "third_party/llvm-build/Release+Asserts/bin/clang++", + ], +@@ -152,7 +151,7 @@ def __step_config(ctx, step_config): + { + "name": "clang-coverage/cxx_module", + "action": "(.*_)?cxx_module", +- "command_prefix": platform.python_bin + " ../../build/toolchain/clang_code_coverage_wrapper.py", ++ "command_prefix": "python3.exe ../../build/toolchain/clang_code_coverage_wrapper.py", + "inputs": rewrapper_config_inputs + [ + "third_party/llvm-build/Release+Asserts/bin/clang++", + ], +@@ -168,7 +167,7 @@ def __step_config(ctx, step_config): + { + "name": "clang-coverage/cc", + "action": "(.*_)?cc", +- "command_prefix": platform.python_bin + " ../../build/toolchain/clang_code_coverage_wrapper.py", ++ "command_prefix": "python3.exe ../../build/toolchain/clang_code_coverage_wrapper.py", + "inputs": rewrapper_config_inputs + [ + "third_party/llvm-build/Release+Asserts/bin/clang", + ], +diff --git a/build/config/siso/devtools_frontend.star b/build/config/siso/devtools_frontend.star +index 7aabb27a06aa6..bd92b7866e89e 100644 +--- a/build/config/siso/devtools_frontend.star ++++ b/build/config/siso/devtools_frontend.star +@@ -41,12 +41,11 @@ def __step_config(ctx, step_config): + step_config["rules"].extend([ + { + "name": "devtools-frontend/typescript/ts_library", +- "command_prefix": platform.python_bin + " ../../third_party/devtools-frontend/src/scripts/build/typescript/ts_library.py", ++ "command_prefix": "python3 ../../third_party/devtools-frontend/src/scripts/build/typescript/ts_library.py", + "remote": config.get(ctx, "default-remote"), + "output_local": True, + "timeout": "2m", + "platform_ref": "large", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "devtools-frontend/esbuild", +@@ -54,15 +53,13 @@ def __step_config(ctx, step_config): + "remote": config.get(ctx, "default-remote"), + "timeout": "2m", + "platform_ref": "large", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "devtools-frontend/build/generate_css_js_files", +- "command_prefix": platform.python_bin + " ../../third_party/node/node.py ../../third_party/devtools-frontend/src/scripts/build/generate_css_js_files.js", ++ "command_prefix": "python3 ../../third_party/node/node.py ../../third_party/devtools-frontend/src/scripts/build/generate_css_js_files.js", + "remote": config.get(ctx, "default-remote"), + "output_local": True, + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + ]) + return step_config +diff --git a/build/config/siso/grit.star b/build/config/siso/grit.star +index c0338ece6b176..4d875876c75ec 100644 +--- a/build/config/siso/grit.star ++++ b/build/config/siso/grit.star +@@ -6,7 +6,6 @@ + + load("@builtin//struct.star", "module") + load("./config.star", "config") +-load("./platform.star", "platform") + + def __step_config(ctx, step_config): + step_config["rules"].extend([ +@@ -18,7 +17,7 @@ def __step_config(ctx, step_config): + "action": "__chrome_app_generated_resources__strings_grit.*", + "remote": config.get(ctx, "googlechrome"), + # Only runs on Linux workers. +- "remote_command": platform.remote_python_bin, ++ "remote_command": "python3", + "platform_ref": "large", + }, + { +@@ -29,7 +28,7 @@ def __step_config(ctx, step_config): + "action": "__components_strings_components_strings__strings_grit.*", + "remote": config.get(ctx, "googlechrome"), + # Only runs on Linux workers. +- "remote_command": platform.remote_python_bin, ++ "remote_command": "python3", + "platform_ref": "large", + }, + ]) +diff --git a/build/config/siso/linux.star b/build/config/siso/linux.star +index 4f1e0bbee3003..8240facdfcde3 100644 +--- a/build/config/siso/linux.star ++++ b/build/config/siso/linux.star +@@ -11,7 +11,6 @@ load("./config.star", "config") + load("./cros.star", "cros") + load("./devtools_frontend.star", "devtools_frontend") + load("./nasm_linux.star", "nasm") +-load("./platform.star", "platform") + load("./proto_linux.star", "proto") + load("./reclient.star", "reclient") + load("./v8.star", "v8") +@@ -71,74 +70,65 @@ def __step_config(ctx, step_config): + step_config["rules"].extend([ + { + "name": "write_buildflag_header", +- "command_prefix": platform.python_bin + " ../../build/write_buildflag_header.py", ++ "command_prefix": "python3 ../../build/write_buildflag_header.py", + "remote": config.get(ctx, "cog") or config.get(ctx, "default-remote"), + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "write_build_date_header", +- "command_prefix": platform.python_bin + " ../../base/write_build_date_header.py", ++ "command_prefix": "python3 ../../base/write_build_date_header.py", + "remote": config.get(ctx, "cog") or config.get(ctx, "default-remote"), + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "version_py", +- "command_prefix": platform.python_bin + " ../../build/util/version.py", ++ "command_prefix": "python3 ../../build/util/version.py", + "remote": config.get(ctx, "cog") or config.get(ctx, "default-remote"), + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "perfetto/touch_file", +- "command_prefix": platform.python_bin + " ../../third_party/perfetto/tools/touch_file.py", ++ "command_prefix": "python3 ../../third_party/perfetto/tools/touch_file.py", + "remote": config.get(ctx, "cog") or config.get(ctx, "default-remote"), + "replace": True, + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "perfetto/write_buildflag_header", +- "command_prefix": platform.python_bin + " ../../third_party/perfetto/gn/write_buildflag_header.py", ++ "command_prefix": "python3 ../../third_party/perfetto/gn/write_buildflag_header.py", + "remote": config.get(ctx, "cog") or config.get(ctx, "default-remote"), + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "perfetto/gen_tp_table_headers", +- "command_prefix": platform.python_bin + " ../../third_party/perfetto/tools/gen_tp_table_headers.py", ++ "command_prefix": "python3 ../../third_party/perfetto/tools/gen_tp_table_headers.py", + "inputs": [ + "third_party/perfetto/python:python", + "third_party/perfetto/src/trace_processor:trace_processor", + ], + "remote": config.get(ctx, "cog") or config.get(ctx, "default-remote"), + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "perfetto/gen_cc_proto_descriptor", +- "command_prefix": platform.python_bin + " ../../third_party/perfetto/tools/gen_cc_proto_descriptor.py", ++ "command_prefix": "python3 ../../third_party/perfetto/tools/gen_cc_proto_descriptor.py", + "remote": config.get(ctx, "cog") or config.get(ctx, "default-remote"), + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + # b/331716896: local fails due to link(2) error. + "name": "generate_fontconfig_cache", +- "command_prefix": platform.python_bin + " ../../build/gn_run_binary.py generate_fontconfig_caches", ++ "command_prefix": "python3 ../../build/gn_run_binary.py generate_fontconfig_caches", + "remote": config.get(ctx, "cog") or config.get(ctx, "default-remote"), + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "dump_app_syms", +- "command_prefix": platform.python_bin + " ../../build/linux/dump_app_syms.py", ++ "command_prefix": "python3 ../../build/linux/dump_app_syms.py", + "handler": "dump_app_syms", + "remote": config.get(ctx, "remote-link") or config.get(ctx, "cog") or config.get(ctx, "default-remote"), + "platform_ref": "large", + "timeout": "30m", +- "remote_command": platform.remote_python_bin, + }, + ]) + +diff --git a/build/config/siso/mac.star b/build/config/siso/mac.star +index 42a8efe9c17fd..3bb6da101849e 100644 +--- a/build/config/siso/mac.star ++++ b/build/config/siso/mac.star +@@ -8,7 +8,6 @@ load("@builtin//path.star", "path") + load("@builtin//struct.star", "module") + load("./clang_mac.star", "clang") + load("./config.star", "config") +-load("./platform.star", "platform") + + def __filegroups(ctx): + fg = {} +@@ -64,17 +63,17 @@ def __step_config(ctx, step_config): + step_config["rules"].extend([ + { + "name": "codesign", +- "command_prefix": platform.python_bin + " ../../build/config/apple/codesign.py", ++ "command_prefix": "python3 ../../build/config/apple/codesign.py ", + "handler": "codesign", + }, + { + "name": "package_framework", +- "command_prefix": platform.python_bin + " ../../build/config/mac/package_framework.py", ++ "command_prefix": "python3 ../../build/config/mac/package_framework.py ", + "handler": "package_framework", + }, + { + "name": "download_from_google_storage", +- "command_prefix": platform.python_bin + " ../../third_party/depot_tools/download_from_google_storage.py", ++ "command_prefix": "python3 ../../third_party/depot_tools/download_from_google_storage.py ", + "handler": "download_from_google_storage", + }, + ]) +diff --git a/build/config/siso/main.star b/build/config/siso/main.star +index b66a7091dad76..ca0bfb9eb0ab9 100644 +--- a/build/config/siso/main.star ++++ b/build/config/siso/main.star +@@ -24,15 +24,6 @@ load("./simple.star", "simple") + load("./typescript_all.star", "typescript_all") + load("./windows.star", chromium_windows = "chromium") + +-def __setup_python(ctx, step_config): +- for rule in step_config["rules"]: +- if rule.get("remote_command") == platform.remote_python_bin: +- inputs = rule.get("inputs", []) +- if "third_party/cpython3/linux-amd64:cpython3" not in inputs: +- inputs.append("third_party/cpython3/linux-amd64:cpython3") +- rule["inputs"] = inputs +- return step_config +- + def __disable_remote(ctx, step_config): + gn_logs_data = gn_logs.read(ctx) + if gn_logs_data.get("use_remoteexec") == "true": +@@ -74,9 +65,6 @@ def init(ctx): + "excludes": [ + "*.json", + "*.proto", +- # Evaluating pyc files causes cache invalidation +- # and potential non determinism with SHA256 generation. +- "*.pyc", + "*.xml", + ], + }, +@@ -87,7 +75,6 @@ def init(ctx): + "executables": [ + "third_party/node/linux/node-linux-x64/bin/node", + "third_party/typescript/linux-amd64/src/lib/tsc", +- "third_party/cpython3/linux-amd64/bin/python3", + ], + } + step_config = blink_all.step_config(ctx, step_config) +@@ -102,14 +89,12 @@ def init(ctx): + + step_config = denylist.step_config(ctx, step_config) + +- step_config = __setup_python(ctx, step_config) + step_config = __disable_remote(ctx, step_config) + step_config = __unset_timeout(ctx, step_config) + + filegroups = {} + filegroups.update(blink_all.filegroups(ctx)) + filegroups.update(host.filegroups(ctx)) +- filegroups.update(platform.filegroups(ctx)) + filegroups.update(rust.filegroups(ctx)) + filegroups.update(simple.filegroups(ctx)) + filegroups.update(typescript_all.filegroups(ctx)) +diff --git a/build/config/siso/mojo.star b/build/config/siso/mojo.star +index 4d23d674a6a3e..40287daa0b997 100644 +--- a/build/config/siso/mojo.star ++++ b/build/config/siso/mojo.star +@@ -27,7 +27,7 @@ def __step_config(ctx, step_config): + "timeout": "2m", + "output_local": True, + "platform_ref": platform_ref, +- "remote_command": platform.remote_python_bin, # only run on Linux worker even for CI Windows. ++ "remote_command": "python3", # only run on Linux worker even for CI Windows. + }, + { + "name": "mojo/mojom_parser", +@@ -36,7 +36,7 @@ def __step_config(ctx, step_config): + "timeout": "2m", + "output_local": True, + "platform_ref": platform_ref, +- "remote_command": platform.remote_python_bin, # only run on Linux worker even for CI Windows. ++ "remote_command": "python3", # only run on Linux worker even for CI Windows. + }, + { + "name": "mojo/generate_type_mappings", +@@ -45,7 +45,7 @@ def __step_config(ctx, step_config): + "timeout": "2m", + "output_local": True, + "platform_ref": platform_ref, +- "remote_command": platform.remote_python_bin, # only run on Linux worker even for CI Windows. ++ "remote_command": "python3", # only run on Linux worker even for CI Windows. + }, + ]) + return step_config +diff --git a/build/config/siso/nasm_linux.star b/build/config/siso/nasm_linux.star +index ffd3cd527c58e..8574927a7a524 100644 +--- a/build/config/siso/nasm_linux.star ++++ b/build/config/siso/nasm_linux.star +@@ -7,7 +7,6 @@ + load("@builtin//path.star", "path") + load("@builtin//struct.star", "module") + load("./config.star", "config") +-load("./platform.star", "platform") + + def __filegroups(ctx): + return {} +@@ -21,9 +20,8 @@ def __step_config(ctx, step_config): + nasm_path = path.join(toolchain, "nasm") + rules.append({ + "name": path.join("nasm", toolchain), +- "command_prefix": platform.python_bin + " ../../build/gn_run_binary.py " + nasm_path, ++ "command_prefix": "python3 ../../build/gn_run_binary.py " + nasm_path, + "remote": remote_run, +- "remote_command": platform.remote_python_bin, + # chromeos generates default.profraw? + "ignore_extra_output_pattern": ".*default.profraw", + "timeout": "2m", +diff --git a/build/config/siso/platform.star b/build/config/siso/platform.star +index 0959e678b692e..3e1726e648e9c 100644 +--- a/build/config/siso/platform.star ++++ b/build/config/siso/platform.star +@@ -8,7 +8,7 @@ load("@builtin//runtime.star", "runtime") + load("@builtin//struct.star", "module") + + # Python binary name for host actions. +-__python_bin = "../../third_party/cpython3/host/bin/python3" ++__python_bin = "python3" + + # Python binary name for remote Linux worker actions (cross-compilation from Windows/macOS). + __remote_python_bin = "../../third_party/cpython3/linux-amd64/bin/python3" +@@ -29,7 +29,5 @@ def __filegroups(ctx): + + platform = module( + "platform", +- filegroups = __filegroups, + python_bin = __python_bin, +- remote_python_bin = __remote_python_bin, + ) +diff --git a/build/config/siso/proto_linux.star b/build/config/siso/proto_linux.star +index 87d90a16a2fa1..06f47db07e7fd 100644 +--- a/build/config/siso/proto_linux.star ++++ b/build/config/siso/proto_linux.star +@@ -6,7 +6,6 @@ + + load("@builtin//struct.star", "module") + load("./config.star", "config") +-load("./platform.star", "platform") + + def __filegroups(ctx): + return {} +@@ -16,7 +15,7 @@ def __step_config(ctx, step_config): + step_config["rules"].extend([ + { + "name": "proto/protoc_wrapper", +- "command_prefix": platform.python_bin + " ../../tools/protoc_wrapper/protoc_wrapper.py", ++ "command_prefix": "python3 ../../tools/protoc_wrapper/protoc_wrapper.py", + "exclude_input_patterns": [ + "*.o", + "*.a", +@@ -25,7 +24,6 @@ def __step_config(ctx, step_config): + # "*_pb2.py", + ], + "remote": remote_run, +- "remote_command": platform.remote_python_bin, + # chromeos generates default.profraw? + "ignore_extra_output_pattern": ".*default.profraw", + # "deps": "depfile", +diff --git a/build/config/siso/rust.star b/build/config/siso/rust.star +index c7e3f96acbc7e..b42418b2599ed 100644 +--- a/build/config/siso/rust.star ++++ b/build/config/siso/rust.star +@@ -12,7 +12,6 @@ load("./ar.star", "ar") + load("./config.star", "config") + load("./fuchsia.star", "fuchsia") + load("./gn_logs.star", "gn_logs") +-load("./platform.star", "platform") + load("./win_sdk.star", "win_sdk") + + def __filegroups(ctx): +@@ -192,7 +191,6 @@ def __step_config(ctx, step_config): + rust_toolchain = [ + # TODO(b/285225184): use precomputed subtree + "third_party/rust-toolchain:toolchain", +- "third_party/cpython3/linux-amd64:cpython3", + ] + rust_link_indirect_inputs = { + "includes": [ +@@ -242,7 +240,6 @@ def __step_config(ctx, step_config): + "handler": "rust_link_handler", + "deps": "none", # disable gcc scandeps + "remote": remote_link, +- "remote_command": platform.remote_python_bin, + "timeout": "2m", + "platform_ref": platform_ref, + }, +@@ -254,7 +251,6 @@ def __step_config(ctx, step_config): + "handler": "rust_link_handler", + "deps": "none", # disable gcc scandeps + "remote": remote_link, +- "remote_command": platform.remote_python_bin, + "timeout": "2m", + "platform_ref": platform_ref, + }, +@@ -266,7 +262,6 @@ def __step_config(ctx, step_config): + "handler": "rust_link_handler", + "deps": "none", # disable gcc scandeps + "remote": remote_link, +- "remote_command": platform.remote_python_bin, + "timeout": "2m", + "platform_ref": platform_ref, + }, +@@ -277,7 +272,6 @@ def __step_config(ctx, step_config): + "indirect_inputs": rust_compile_indirect_inputs, + "deps": "none", # disable gcc scandeps + "remote": remote, +- "remote_command": platform.remote_python_bin, + "timeout": "2m", + "platform_ref": platform_ref, + }, +@@ -288,68 +282,62 @@ def __step_config(ctx, step_config): + "indirect_inputs": rust_compile_indirect_inputs, + "deps": "none", # disable gcc scandeps + "remote": remote, +- "remote_command": platform.remote_python_bin, + "timeout": "2m", + "platform_ref": platform_ref, + }, + { + "name": "rust/run_build_script", +- "command_prefix": platform.python_bin + " ../../build/rust/gni_impl/run_build_script.py", ++ "command_prefix": "python3 ../../build/rust/gni_impl/run_build_script.py", + "inputs": [ + "third_party/rust-toolchain:toolchain", + ], + "handler": "rust_build_handler", + "remote": (remote and config.get(ctx, "cog")) or config.get(ctx, "default-remote"), + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "rust/find_std_rlibs", +- "command_prefix": platform.python_bin + " ../../build/rust/std/find_std_rlibs.py", ++ "command_prefix": "python3 ../../build/rust/std/find_std_rlibs.py", + "inputs": [ + "third_party/rust-toolchain:toolchain", + ], + "remote": (remote and config.get(ctx, "cog")) or config.get(ctx, "default-remote"), + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "rust/clippy", +- "command_prefix": platform.python_bin + " ../../build/rust/gni_impl/clippy_wrapper.py", ++ "command_prefix": "python3 ../../build/rust/gni_impl/clippy_wrapper.py", + "inputs": rust_toolchain, + "indirect_inputs": rust_link_indirect_inputs, + "remote": remote, + "timeout": "2m", + "platform_ref": platform_ref, +- "remote_command": platform.remote_python_bin, + }, + { + # rust/bindgen fails remotely when *.d does not exist. + # TODO(b/356496947): need to run scandeps? + "name": "rust/bindgen", +- "command_prefix": platform.python_bin + " ../../build/rust/gni_impl/run_bindgen.py", ++ "command_prefix": "python3 ../../build/rust/gni_impl/run_bindgen.py", + "inputs": rust_toolchain + clang_inputs, + "remote": False, + "timeout": "2m", + }, + { + "name": "rust/rustc_print_cfg", +- "command_prefix": platform.python_bin + " ../../build/rust/gni_impl/rustc_print_cfg.py", ++ "command_prefix": "python3 ../../build/rust/gni_impl/rustc_print_cfg.py", + "inputs": [ + "third_party/rust-toolchain:toolchain", + ], + "remote": remote, + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "rust/cpp_api_from_rust", +- "command_prefix": platform.python_bin + " ../../build/rust/gni_impl/cpp_api_from_rust_wrapper.py", ++ "command_prefix": "python3 ../../build/rust/gni_impl/cpp_api_from_rust_wrapper.py", + "inputs": rust_toolchain + clang_inputs, + "indirect_inputs": rust_compile_indirect_inputs, + "remote": remote, + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + ]) + return step_config +diff --git a/build/config/siso/typescript_all.star b/build/config/siso/typescript_all.star +index 265607d03751a..cd66dfca051d7 100644 +--- a/build/config/siso/typescript_all.star ++++ b/build/config/siso/typescript_all.star +@@ -80,7 +80,7 @@ def __step_config(ctx, step_config): + "output_local": True, + "input_root_absolute_path": use_input_root_absolute_path, + # Only runs on Linux workers. +- "remote_command": platform.remote_python_bin, ++ "remote_command": "python3", + }, + { + "name": "typescript/ts_definitions", +@@ -97,7 +97,7 @@ def __step_config(ctx, step_config): + "handler": "typescript_ts_definitions" if remote_run else None, + "input_root_absolute_path": use_input_root_absolute_path, + # Only runs on Linux workers. +- "remote_command": platform.remote_python_bin, ++ "remote_command": "python3", + }, + { + "name": "webui/minify_js", +@@ -105,7 +105,7 @@ def __step_config(ctx, step_config): + "remote": remote_run, + "timeout": "2m", + # Only runs on Linux workers. +- "remote_command": platform.remote_python_bin, ++ "remote_command": "python3", + }, + { + "name": "webui/stylelint", +@@ -113,7 +113,7 @@ def __step_config(ctx, step_config): + "remote": remote_run, + "timeout": "2m", + # Only runs on Linux workers. +- "remote_command": platform.remote_python_bin, ++ "remote_command": "python3", + }, + { + "name": "webui/eslint_ts", +@@ -127,7 +127,7 @@ def __step_config(ctx, step_config): + "timeout": "2m", + "handler": "webui_eslint_ts" if remote_run else None, + # Only runs on Linux workers. +- "remote_command": platform.remote_python_bin, ++ "remote_command": "python3", + }, + ]) + return step_config +diff --git a/build/config/siso/v8.star b/build/config/siso/v8.star +index 605e86ca833d8..1a70f90282057 100644 +--- a/build/config/siso/v8.star ++++ b/build/config/siso/v8.star +@@ -23,7 +23,6 @@ def __step_config(ctx, step_config): + "command_prefix": platform.python_bin + " ../../v8/tools/run.py ./torque", + "remote": remote_run, + "timeout": "2m", +- "remote_command": platform.remote_python_bin, + }, + { + "name": "v8/mksnapshot", +@@ -36,7 +35,6 @@ def __step_config(ctx, step_config): + # The outputs of mksnapshot are often required for running the + # following steps. + "output_local": True, +- "remote_command": platform.remote_python_bin, + }, + ]) + return step_config +diff --git a/build/toolchain/apple/toolchain.gni b/build/toolchain/apple/toolchain.gni +index 7b00996ea8dfc..c97882722e985 100644 +--- a/build/toolchain/apple/toolchain.gni ++++ b/build/toolchain/apple/toolchain.gni +@@ -208,7 +208,7 @@ template("single_apple_toolchain") { + root_build_dir) + " --files-to-instrument=" + + rebase_path(toolchain_coverage_instrumentation_input_file, + root_build_dir) + " --target-os=" + target_os +- coverage_wrapper = "$python_path ${_coverage_wrapper} " ++ coverage_wrapper = "\"$python_path\" ${_coverage_wrapper} " + } + + linker_driver_env = "TOOL_VERSION=${tool_versions.linker_driver}" +diff --git a/build/toolchain/gcc_toolchain.gni b/build/toolchain/gcc_toolchain.gni +index 9108d65b7dd25..eb1d2a4ec1a1c 100644 +--- a/build/toolchain/gcc_toolchain.gni ++++ b/build/toolchain/gcc_toolchain.gni +@@ -246,7 +246,7 @@ template("single_gcc_toolchain") { + rebase_path(toolchain_coverage_instrumentation_input_file, + root_build_dir) + } +- coverage_wrapper = "$python_path ${_coverage_wrapper} " ++ coverage_wrapper = "\"$python_path\" ${_coverage_wrapper} " + } + + cc = compiler_prefix + invoker.cc +diff --git a/build/toolchain/win/toolchain.gni b/build/toolchain/win/toolchain.gni +index a0772fc1c1013..4737d5c3654bd 100644 +--- a/build/toolchain/win/toolchain.gni ++++ b/build/toolchain/win/toolchain.gni +@@ -196,7 +196,7 @@ template("msvc_toolchain") { + rebase_path(toolchain_coverage_instrumentation_input_file, + root_build_dir) + } +- coverage_wrapper = "$python_path " + coverage_wrapper + " " ++ coverage_wrapper = "\"$python_path\" " + coverage_wrapper + " " + } else { + coverage_wrapper = "" + } diff --git a/srcpkgs/chromium/patches/chromium-153-typescript-break-definitions.patch b/srcpkgs/chromium/patches/chromium-153-typescript-break-definitions.patch new file mode 100644 index 00000000000000..2752f249dbb58f --- /dev/null +++ b/srcpkgs/chromium/patches/chromium-153-typescript-break-definitions.patch @@ -0,0 +1,22 @@ +From 53b2ebddbd2464b1265541fcaa4f1b7fa751c0e6 Mon Sep 17 00:00:00 2001 +From: LN Liberda +Date: Thu, 3 Sep 2026 18:44:59 +0200 +Subject: [PATCH] Break a typescript check that breaks build + +--- + tools/typescript/validate_tsconfig.py | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/tools/typescript/validate_tsconfig.py b/tools/typescript/validate_tsconfig.py +index 16ba0268ffdf2..de93d3badafd9 100644 +--- a/tools/typescript/validate_tsconfig.py ++++ b/tools/typescript/validate_tsconfig.py +@@ -286,6 +286,8 @@ def validateRootDir(root_dir, gen_dir, root_gen_dir, is_ios): + def validateDefinitionDeps( + definitions_files, target_path, gen_dir, root_gen_dir, definitions + ): ++ # These checks don't work and break build ++ return True, None + # Root gen dir relative to the current working directory (essentially 'gen') + gen_dir_from_build = os.path.normpath( + os.path.join(gen_dir, root_gen_dir) diff --git a/srcpkgs/chromium/patches/chromium-153-unbundle-opus-iamf.patch b/srcpkgs/chromium/patches/chromium-153-unbundle-opus-iamf.patch new file mode 100644 index 00000000000000..5e7fd5348d9320 --- /dev/null +++ b/srcpkgs/chromium/patches/chromium-153-unbundle-opus-iamf.patch @@ -0,0 +1,40 @@ +From efc4c82a6a44b1230ff20878c0a75a23f30c1246 Mon Sep 17 00:00:00 2001 +From: LN Liberda +Date: Fri, 28 Aug 2026 14:39:24 +0200 +Subject: [PATCH] unbundle/opus: add a deeper include path + +--- + build/linux/unbundle/opus.gn | 3 +++ + build/shim_headers.gni | 5 +++++ + 2 files changed, 8 insertions(+) + +diff --git a/build/linux/unbundle/opus.gn b/build/linux/unbundle/opus.gn +index b1a199a532405..26e4aac01d3b3 100644 +--- a/build/linux/unbundle/opus.gn ++++ b/build/linux/unbundle/opus.gn +@@ -17,6 +17,9 @@ shim_headers("opus_shim") { + "opus_multistream.h", + "opus_types.h", + ] ++ ++ # for //third_party/iamf_tools ++ extra_includes = [ "third_party/opus/src" ] + } + + source_set("opus") { +diff --git a/build/shim_headers.gni b/build/shim_headers.gni +index 7c30a007248ca..19cb1f80966f9 100644 +--- a/build/shim_headers.gni ++++ b/build/shim_headers.gni +@@ -9,6 +9,11 @@ template("shim_headers") { + + config(config_name) { + include_dirs = [ shim_headers_path ] ++ if (defined(invoker.extra_includes)) { ++ foreach(xi, invoker.extra_includes) { ++ include_dirs += [ "${shim_headers_path}/${xi}" ] ++ } ++ } + } + + action(action_name) { diff --git a/srcpkgs/chromium/patches/chromium-153-uncrubit-blink-opentype.patch b/srcpkgs/chromium/patches/chromium-153-uncrubit-blink-opentype.patch new file mode 100644 index 00000000000000..477080d7c90cfb --- /dev/null +++ b/srcpkgs/chromium/patches/chromium-153-uncrubit-blink-opentype.patch @@ -0,0 +1,276 @@ +From f55ec0ffc222c3a6865086c8585f789c19231d75 Mon Sep 17 00:00:00 2001 +From: LN Liberda +Date: Fri, 28 Aug 2026 04:38:15 +0200 +Subject: [PATCH] Revert "Migrate OpenType format check bindings to Crubit" + +https://www.youtube.com/watch?v=ac4E_UsmB1g + +This reverts commit 493e6c3911e33cc356856bafbffc6cf95521266b. +--- + third_party/blink/renderer/platform/BUILD.gn | 15 ++++++- + .../blink/renderer/platform/fonts/BUILD.gn | 19 --------- + .../fonts/opentype/font_format_check.cc | 21 +++++----- + .../fonts/opentype/font_format_check.h | 6 +-- + .../platform/fonts/opentype/format_check.rs | 41 +++++++++++++------ + 5 files changed, 55 insertions(+), 47 deletions(-) + delete mode 100644 third_party/blink/renderer/platform/fonts/BUILD.gn + +diff --git a/third_party/blink/renderer/platform/BUILD.gn b/third_party/blink/renderer/platform/BUILD.gn +index 9bfa9565f03f1..6eed09d66d173 100644 +--- a/third_party/blink/renderer/platform/BUILD.gn ++++ b/third_party/blink/renderer/platform/BUILD.gn +@@ -186,6 +186,18 @@ group("make_platform_generated") { + ] + } + ++rust_static_library("font_format_check") { ++ allow_unsafe = true # Needed for FFI that underpins the `cxx` crate. ++ crate_root = "fonts/opentype/format_check.rs" ++ sources = [ crate_root ] ++ cxx_bindings = [ crate_root ] ++ deps = [ ++ "//third_party/rust/font_types/v0_12:lib", ++ "//third_party/rust/read_fonts/v0_41:lib", ++ "//third_party/rust/skrifa/v0_44:lib", ++ ] ++} ++ + rust_static_library("rustfft_ffi") { + allow_unsafe = true # Needed for FFI that underpins the `cxx` crate. + crate_root = "audio/rustfft_ffi.rs" +@@ -1794,7 +1806,6 @@ component("platform") { + ":allow_discouraged_type", + ":blink_platform_public_deps", + ":platform_export", +- "//build/rust/crubit", + "//gpu/command_buffer/client:raster_interface", + "//media/capture:capture_lib", + "//mojo/public/cpp/base", +@@ -1821,8 +1832,8 @@ component("platform") { + "//ui/native_theme/features", + ] + deps = [ ++ ":font_format_check", + ":rustfft_ffi", +- "fonts:font_format_bindings", + "//base:base_static", + "//base/allocator:buildflags", + "//build:chromecast_buildflags", +diff --git a/third_party/blink/renderer/platform/fonts/BUILD.gn b/third_party/blink/renderer/platform/fonts/BUILD.gn +deleted file mode 100644 +index 51b9b03ba7c85..0000000000000 +--- a/third_party/blink/renderer/platform/fonts/BUILD.gn ++++ /dev/null +@@ -1,19 +0,0 @@ +-# Copyright 2026 The Chromium Authors +-# Use of this source code is governed by a BSD-style license that can be +-# found in the LICENSE file. +- +-import("//build/rust/rust_static_library.gni") +- +-rust_static_library("font_format") { +- crate_root = "opentype/format_check.rs" +- sources = [ crate_root ] +- cpp_api_from_rust = { +- target_name = "font_format_bindings" +- cpp_namespace = "font_format" +- } +- deps = [ +- "//third_party/rust/font_types/v0_12:lib", +- "//third_party/rust/read_fonts/v0_41:lib", +- "//third_party/rust/skrifa/v0_44:lib", +- ] +-} +diff --git a/third_party/blink/renderer/platform/fonts/opentype/font_format_check.cc b/third_party/blink/renderer/platform/fonts/opentype/font_format_check.cc +index f58e9433d39f4..b9d2639822bc0 100644 +--- a/third_party/blink/renderer/platform/fonts/opentype/font_format_check.cc ++++ b/third_party/blink/renderer/platform/fonts/opentype/font_format_check.cc +@@ -7,6 +7,7 @@ + #include "base/containers/span.h" + #include "base/containers/span_rust.h" + #include "base/numerics/byte_conversions.h" ++#include "third_party/blink/renderer/platform/fonts/opentype/format_check.rs.h" + #include "third_party/blink/renderer/platform/runtime_enabled_features.h" + #include "third_party/blink/renderer/platform/wtf/vector.h" + #include "third_party/skia/include/core/SkTypeface.h" +@@ -14,37 +15,35 @@ + namespace blink { + + FontFormatCheck::FontFormatCheck(sk_sp sk_data) +- : format_info_(font_format::get_font_format_info( ++ : format_info_(font_format_check::get_font_format_info( + base::SpanToRustSlice(sk_data->byteSpan()))) {} + +-FontFormatCheck::~FontFormatCheck() = default; +- + bool FontFormatCheck::IsVariableFont() const { +- return font_format::is_variable(format_info_); ++ return font_format_check::is_variable(*format_info_); + } + + bool FontFormatCheck::IsCbdtCblcColorFont() const { +- return font_format::is_cbdt_cblc(format_info_); ++ return font_format_check::is_cbdt_cblc(*format_info_); + } + + bool FontFormatCheck::IsEbdtEblcMonochromeFont() const { +- return font_format::is_ebdt_eblc(format_info_); ++ return font_format_check::is_ebdt_eblc(*format_info_); + } + + bool FontFormatCheck::IsColrCpalColorFontV0() const { +- return font_format::is_colrv0(format_info_); ++ return font_format_check::is_colrv0(*format_info_); + } + + bool FontFormatCheck::IsColrCpalColorFontV1() const { +- return font_format::is_colrv1(format_info_); ++ return font_format_check::is_colrv1(*format_info_); + } + + bool FontFormatCheck::IsSbixColorFont() const { +- return font_format::is_sbix(format_info_); ++ return font_format_check::is_sbix(*format_info_); + } + + bool FontFormatCheck::IsCff2OutlineFont() const { +- return font_format::is_cff2(format_info_); ++ return font_format_check::is_cff2(*format_info_); + } + + bool FontFormatCheck::IsVariableColrV0Font() const { +@@ -58,7 +57,7 @@ bool FontFormatCheck::IsColorFont() const { + + bool FontFormatCheck::IsAvar2Font() const { + return RuntimeEnabledFeatures::FontFormatAvar2Enabled() && +- font_format::is_avar2(format_info_); ++ font_format_check::is_avar2(*format_info_); + } + + FontFormatCheck::VariableFontSubType FontFormatCheck::ProbeVariableFont( +diff --git a/third_party/blink/renderer/platform/fonts/opentype/font_format_check.h b/third_party/blink/renderer/platform/fonts/opentype/font_format_check.h +index af50dbdf74d00..19d2639233b07 100644 +--- a/third_party/blink/renderer/platform/fonts/opentype/font_format_check.h ++++ b/third_party/blink/renderer/platform/fonts/opentype/font_format_check.h +@@ -5,7 +5,7 @@ + #ifndef THIRD_PARTY_BLINK_RENDERER_PLATFORM_FONTS_OPENTYPE_FONT_FORMAT_CHECK_H_ + #define THIRD_PARTY_BLINK_RENDERER_PLATFORM_FONTS_OPENTYPE_FONT_FORMAT_CHECK_H_ + +-#include "third_party/blink/renderer/platform/fonts/font_format.h" ++#include "third_party/blink/renderer/platform/fonts/opentype/format_check.rs.h" + #include "third_party/blink/renderer/platform/platform_export.h" + #include "third_party/blink/renderer/platform/wtf/allocator/allocator.h" + #include "third_party/skia/include/core/SkData.h" +@@ -19,7 +19,7 @@ class PLATFORM_EXPORT FontFormatCheck { + + public: + explicit FontFormatCheck(sk_sp); +- virtual ~FontFormatCheck(); ++ virtual ~FontFormatCheck() = default; + virtual bool IsVariableFont() const; + virtual bool IsCbdtCblcColorFont() const; + virtual bool IsEbdtEblcMonochromeFont() const; +@@ -46,7 +46,7 @@ class PLATFORM_EXPORT FontFormatCheck { + enum class COLRVersion { kCOLRV0, kCOLRV1, kNoCOLR }; + + private: +- font_format::FontFormatInfo format_info_; ++ rust::Box format_info_; + }; + + } // namespace blink +diff --git a/third_party/blink/renderer/platform/fonts/opentype/format_check.rs b/third_party/blink/renderer/platform/fonts/opentype/format_check.rs +index b99f0ec8655e6..eda8e6b2b8188 100644 +--- a/third_party/blink/renderer/platform/fonts/opentype/format_check.rs ++++ b/third_party/blink/renderer/platform/fonts/opentype/format_check.rs +@@ -23,7 +23,7 @@ pub struct FontFormatInfo { + format_flags: Option, + } + +-pub fn get_font_format_info(font_bytes: &[u8]) -> FontFormatInfo { ++pub fn get_font_format_info(font_bytes: &[u8]) -> Box { + let file_ref = make_font_ref_internal(font_bytes, 0); + + match file_ref { +@@ -32,11 +32,11 @@ pub fn get_font_format_info(font_bytes: &[u8]) -> FontFormatInfo { + font.table_directory().table_records().iter().map(|e| e.tag()).collect(); + let color_version = get_colr_version(&font); + let avar_version = get_avar_version(&font); +- FontFormatInfo { ++ Box::new(FontFormatInfo { + format_flags: Some(FontFormatFlags { table_tags, color_version, avar_version }), +- } ++ }) + } +- _ => FontFormatInfo::default(), ++ _ => Box::new(FontFormatInfo::default()), + } + } + +@@ -44,10 +44,10 @@ fn get_colr_version(font_ref: &FontRef) -> Option { + Some(font_ref.colr().ok()?.version()) + } + +-pub fn is_colrv1(format_info: &FontFormatInfo) -> bool { ++fn is_colrv1(format_info: &FontFormatInfo) -> bool { + matches!(&format_info.format_flags, Some(FontFormatFlags { color_version: Some(1), .. }),) + } +-pub fn is_colrv0(format_info: &FontFormatInfo) -> bool { ++fn is_colrv0(format_info: &FontFormatInfo) -> bool { + matches!(&format_info.format_flags, Some(FontFormatFlags { color_version: Some(0), .. }),) + } + +@@ -56,7 +56,7 @@ fn get_avar_version(font_ref: &FontRef) -> Option<(u16, u16)> { + Some((version.major, version.minor)) + } + +-pub fn is_avar2(format_info: &FontFormatInfo) -> bool { ++fn is_avar2(format_info: &FontFormatInfo) -> bool { + matches!(&format_info.format_flags, Some(FontFormatFlags { avar_version: Some((2, _)), .. }),) + } + +@@ -69,22 +69,39 @@ fn has_tags(format_info: &FontFormatInfo, query: &[Tag]) -> bool { + } + } + +-pub fn is_variable(format_info: &FontFormatInfo) -> bool { ++fn is_variable(format_info: &FontFormatInfo) -> bool { + has_tags(format_info, &[Tag::new(b"fvar")]) + } + +-pub fn is_sbix(format_info: &FontFormatInfo) -> bool { ++fn is_sbix(format_info: &FontFormatInfo) -> bool { + has_tags(format_info, &[Tag::new(b"sbix")]) + } + +-pub fn is_cbdt_cblc(format_info: &FontFormatInfo) -> bool { ++fn is_cbdt_cblc(format_info: &FontFormatInfo) -> bool { + has_tags(format_info, &[Tag::new(b"CBDT"), Tag::new(b"CBLC")]) + } + +-pub fn is_ebdt_eblc(format_info: &FontFormatInfo) -> bool { ++fn is_ebdt_eblc(format_info: &FontFormatInfo) -> bool { + has_tags(format_info, &[Tag::new(b"EBDT"), Tag::new(b"EBLC")]) + } + +-pub fn is_cff2(format_info: &FontFormatInfo) -> bool { ++fn is_cff2(format_info: &FontFormatInfo) -> bool { + has_tags(format_info, &[Tag::new(b"CFF2")]) + } ++ ++#[cxx::bridge(namespace = "font_format_check")] ++pub mod ffi { ++ extern "Rust" { ++ type FontFormatInfo; ++ ++ fn get_font_format_info(font_bytes: &[u8]) -> Box; ++ fn is_colrv1(format_info: &FontFormatInfo) -> bool; ++ fn is_colrv0(format_info: &FontFormatInfo) -> bool; ++ fn is_cbdt_cblc(format_info: &FontFormatInfo) -> bool; ++ fn is_ebdt_eblc(format_info: &FontFormatInfo) -> bool; ++ fn is_variable(format_info: &FontFormatInfo) -> bool; ++ fn is_sbix(format_info: &FontFormatInfo) -> bool; ++ fn is_cff2(format_info: &FontFormatInfo) -> bool; ++ fn is_avar2(format_info: &FontFormatInfo) -> bool; ++ } ++} diff --git a/srcpkgs/chromium/template b/srcpkgs/chromium/template index 3349ebf334d749..b50e1d0e32e998 100644 --- a/srcpkgs/chromium/template +++ b/srcpkgs/chromium/template @@ -1,7 +1,7 @@ # Template file for 'chromium' pkgname=chromium # See https://chromiumdash.appspot.com/releases?platform=Linux for the latest version -version=152.0.7977.64 +version=153.0.8010.36 revision=1 _rollup=4.22.4 archs="i686* x86_64* aarch64* armv7l*" @@ -36,7 +36,7 @@ homepage="https://www.chromium.org/" # distfiles="https://chromium.googlesource.com/chromium/src.git/+archive/refs/tags/${version}.tar.gz" distfiles="https://github.com/chromium-linux-tarballs/chromium-tarballs/releases/download/${version}/chromium-${version}-linux.tar.xz https://registry.npmjs.org/@rollup/wasm-node/-/wasm-node-${_rollup}.tgz" -checksum="4f96a2d9e87778b2bab2901d88127b00c108060e9d6f424425c715366f14d435 +checksum="5e2e8fe8c990e591b26237ed0fb9747a76f9da3eac439d7a726000879c468735 ee49bf67bd9bee869405af78162d028e2af0fcfca80497404f56b1b99f272717" skip_extraction="wasm-node-${_rollup}.tgz"