aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorlauren n. liberda <lauren@selfisekai.rocks>2024-04-06 00:39:49 +0200
committeromni <omni+alpine@hack.org>2024-04-19 16:14:08 +0000
commit6b76c18954584b23666e0f829eacd21102a635ef (patch)
tree720183885648030ffd4d59acfd3d5f703e0653a2
parent46b9bbc36c218212a3eb564097369a4a60796a82 (diff)
community/chromium: upgrade to 124.0.6367.60HEADmaster
-rw-r--r--community/chromium/APKBUILD115
-rw-r--r--community/chromium/compiler.patch17
-rw-r--r--community/chromium/no-execinfo.patch25
3 files changed, 115 insertions, 42 deletions
diff --git a/community/chromium/APKBUILD b/community/chromium/APKBUILD
index a375622234f..66d0823a3a5 100644
--- a/community/chromium/APKBUILD
+++ b/community/chromium/APKBUILD
@@ -3,14 +3,16 @@
# Contributor: Elly Fong-Jones <elly@elly.town>
# Maintainer: lauren n. liberda <lauren@selfisekai.rocks>
pkgname=chromium
-pkgver=123.0.6312.122
+pkgver=124.0.6367.60
pkgrel=0
+_copium_tag=124.4
# https://source.chromium.org/chromium/chromium/src/+/main:third_party/test_fonts/test_fonts.tar.gz.sha1
# (for the given version, when it changes)
_testfonts=336e775eec536b2d785cc80eff6ac39051931286
pkgdesc="Chromium web browser"
url="https://www.chromium.org/Home"
-arch="aarch64 armv7 x86_64"
+# armv7: https://github.com/google/ruy/issues/352
+arch="aarch64 x86_64"
license="BSD-3-Clause"
# explicit depends for --headless
# XXX: eudev-libs replaced by so:libudev.so.1 to allow installation with libudev-zero
@@ -46,6 +48,7 @@ makedepends="
ffmpeg-dev
findutils
flac-dev
+ flatbuffers-dev
flex
freetype-dev
gn
@@ -57,6 +60,7 @@ makedepends="
hunspell-dev
hwdata-dev
jpeg-dev
+ jsoncpp-dev
krb5-dev
lcms2-dev
libbsd-dev
@@ -94,10 +98,15 @@ makedepends="
py3-setuptools
python3
qt5-qtbase-dev
+ re2-dev
rust
samurai
+ snappy-dev
speex-dev
+ spirv-tools-dev
sqlite-dev
+ vulkan-headers
+ woff2-dev
xcb-proto
zlib-dev
zstd-dev
@@ -113,12 +122,14 @@ subpackages="
source="https://commondatastorage.googleapis.com/chromium-browser-official/chromium-$pkgver.tar.xz
https://commondatastorage.googleapis.com/chromium-browser-official/chromium-$pkgver-testdata.tar.xz
test_fonts-$_testfonts.tar.gz::https://chromium-fonts.storage.googleapis.com/$_testfonts
+ copium-$_copium_tag.tar.gz::https://codeberg.org/selfisekai/copium/archive/$_copium_tag.tar.gz
chromium-launcher.sh
chromium.conf
google-api.keys
chromium-revert-drop-of-system-java.patch
compiler.patch
+ disable-dns_config_service.patch
disable-failing-tests.patch
fc-cache-version.patch
fix-missing-cstdint-include-musl.patch
@@ -145,10 +156,33 @@ source="https://commondatastorage.googleapis.com/chromium-browser-official/chrom
system-zstd.patch
temp-failure-retry.patch
yes-musl.patch
- disable-dns_config_service.patch
+ "
+_copium_patches="
+ cr124-disable-libstdcpp-assertions.patch
+ cr124-gcc-readablestream.patch
+ cr124-iwyu-atomic-crime.patch
+ cr124-iwyu-bitset-tempora.patch
+ cr124-iwyu-cstdint-in-path_util.patch
+ cr124-iwyu-cstdint-mhtml-gen-result.patch
+ cr124-iwyu-cstdint-webrtc-reorder_optimizer.patch
+ cr124-iwyu-dawncontextprovider.patch
+ cr124-iwyu-include-cstdint-in-autofill.patch
+ cr124-iwyu-memory-in-gpu_init.patch
+ cr124-iwyu-optional-1party-sets.patch
+ cr124-iwyu-optional-base-span_reader.patch
+ cr124-iwyu-optional-gpu-adapter.patch
+ cr124-iwyu-sys-select-dawn-terminal.patch
+ cr124-iwyu-ukm-bitset.patch
+ cr124-libstdc-replace-std-powf-with-std-pow.patch
+ cr124-libvpx-disable-sve-on-gcc.patch
+ cr124-libwebp-shim-sharpyuv.patch
+ cr124-openh264-unbundle-gcc.patch
+ cr124-partition_allocator-xclang.patch
+ cr124-re2-unbundle-googletest-config.patch
+ cr124-stdcpp-blink-fragmentdataiterator.patch
+ cr124-webui-preload-manager-default-constructor.patch
"
# chrome-sandbox can use suid when user namespaces aren't available, but uses only userns and drops privileges normally
-# tests stopped building with 115 with clang16
options="suid"
# backwards compat (merged into primary)
@@ -490,6 +524,22 @@ upstream_version() {
prepare() {
default_prepare
+ for i in $_copium_patches; do
+ case "$i" in
+ *.patch)
+ msg "${i%::*}"
+ patch -p1 -i "$srcdir/copium/$i" || failed="$failed $i"
+ ;;
+ esac
+ done
+ if [ ! -z "$failed" ]; then
+ error "The following patches failed to apply:"
+ for i in $failed; do
+ printf " %s\n" "$i" >&2
+ done
+ exit 1
+ fi
+
mv ../test_fonts/ ./third_party/test_fonts/
# https://groups.google.com/a/chromium.org/d/topic/chromium-packagers/9JX1N2nf4PU/discussion
@@ -502,9 +552,9 @@ prepare() {
ln -s /usr/bin/node third_party/node/linux/node-linux-x64/bin/
# reusable system library settings
- # libavif - https://github.com/AOMediaCodec/libavif/commit/4d2776a3
+ # libavif - https://github.com/AOMediaCodec/libavif/commit/50a541469c98009016af8dcc9f83a1be79f3a7d9
# libaom - https://aomedia.googlesource.com/aom/+/706ee36dcc82%5E%21/
- # jsoncpp, re2, snappy, swiftshader-spirv, woff2 - requires use_custom_libcxx=false
+ # but watch this space: https://aomedia-review.googlesource.com/c/aom/+/188606
local use_system="
brotli
crc32c
@@ -512,11 +562,13 @@ prepare() {
double-conversion
ffmpeg
flac
+ flatbuffers
fontconfig
freetype
harfbuzz-ng
highway
icu
+ jsoncpp
libdrm
libevent
libjpeg
@@ -527,11 +579,16 @@ prepare() {
libxslt
openh264
opus
+ re2
+ snappy
+ swiftshader-SPIRV-Headers
+ swiftshader-SPIRV-Tools
+ woff2
zlib
zstd
"
- for _lib in $use_system libjpeg_turbo; do
+ for _lib in $use_system libc++ libc++abi libjpeg_turbo swiftshader/third_party/SPIRV-Headers swiftshader/third_party/SPIRV-Tools; do
msg "Removing buildscripts for system provided $_lib"
find . -type f -path "*third_party/$_lib/*" \
\! -path "*third_party/$_lib/chromium/*" \
@@ -579,8 +636,8 @@ _configure() {
local _google_api_key _google_default_client_id _google_default_client_secret
eval "$(base64 -d < $srcdir/google-api.keys)"
- export CFLAGS="${CFLAGS/-g/} -O2 -Wno-unknown-warning-option -Wno-builtin-macro-redefined -Wno-deprecated-declarations"
- export CXXFLAGS="${CXXFLAGS/-g/} -O2 -Wno-unknown-warning-option -Wno-builtin-macro-redefined -Wno-deprecated-declarations"
+ export CFLAGS="${CFLAGS/-g/} -O2 -Wno-builtin-macro-redefined -Wno-deprecated-declarations -Wno-shift-count-overflow -Wno-ignored-attributes"
+ export CXXFLAGS="${CXXFLAGS/-g/} -O2 -Wno-builtin-macro-redefined -Wno-deprecated-declarations -Wno-invalid-constexpr"
export CPPFLAGS="${CPPFLAGS/-g/} -D__DATE__= -D__TIME__= -D__TIMESTAMP__="
# breaks chromium
@@ -589,8 +646,8 @@ _configure() {
export CFLAGS="${CFLAGS/-fstack-clash-protection}"
export AR="llvm-ar"
- export CC="clang"
- export CXX="clang++"
+ export CC="gcc"
+ export CXX="g++"
export NM="llvm-nm"
msg "Configuring build"
@@ -652,6 +709,7 @@ _configure() {
host_toolchain=\"//build/toolchain/linux/unbundle:default\"
icu_use_data_file=false
is_cfi=false
+ is_clang=false
is_component_ffmpeg=true
is_debug=false
is_official_build=true
@@ -664,17 +722,12 @@ _configure() {
rust_sysroot_absolute=\"/usr\"
symbol_level=$symbol_level
treat_warnings_as_errors=false
- use_custom_libcxx=true
+ use_custom_libcxx=false
use_lld=true
use_pulseaudio=true
- use_sysroot=false
- use_system_freetype=true
- use_system_harfbuzz=true
- use_system_lcms2=true
- use_system_libdrm=true
+ use_safe_libstdcxx=false
use_system_libffi=true
- use_system_libjpeg=true
- use_system_zlib=true
+ use_sysroot=false
use_thin_lto=false
use_vaapi=$vaapi
v8_enable_maglev=$maglev
@@ -693,8 +746,11 @@ build() {
# moc and friends not in path by default
export PATH="$PATH:/usr/lib/qt5/bin"
+ # ~1 GB per concurrent job is not enough with gcc
+ _njobs="${NJOBS:-"$(python3 -c 'import os; print(max((os.cpu_count() - (10 if os.uname().machine == "aarch64" else 8), 1)))')"}"
+
# shellcheck disable=2046
- ninja -C out/bld \
+ ninja -C out/bld -j$_njobs \
chrome \
chrome_sandbox \
chromedriver.unstripped \
@@ -705,7 +761,15 @@ build() {
check_base_unittests() {
# TODO: fix these tests, hopefully
+ # https://issues.chromium.org/issues/40939315
broken="MessagePumpLibeventTest.NestedNotification*"
+ broken="$broken:AlternateTestParams/PartitionAllocTest.SchedulerLoopQuarantine"
+ broken="$broken:ClampTest.Death"
+ broken="$broken:OptionalTest.DereferencingNoValueCrashes"
+ broken="$broken:RawPtrTest.TrivialRelocability"
+ broken="$broken:SafeNumerics.IntMaxOperations"
+ broken="$broken:StringPieceTest.InvalidLengthDeath"
+ broken="$broken:StringPieceTest.OutOfBoundsDeath"
# test-launcher-bot-mode enables parallelism and uncolored output
./out/bld/base_unittests --test-launcher-bot-mode --gtest_filter="-$broken"
}
@@ -847,14 +911,16 @@ swiftshader() {
}
sha512sums="
-23e13d1d5758aa771f4c66e1a55068438e7c4890456dcb0b7a1fc1839b750e612e29d59e744c8b773935757aad01b78a5fecc3e03057a8acbb7e997dbb98f007 chromium-123.0.6312.122.tar.xz
-51d2eeb54ccaa3e936341cc1b6b8434982ba5f0dbe2f60eff3f5b8a89d59214b2acc19daae10602ff2f4ec8d75a7730e5bf645acdc88143f061c364c89f8f81f chromium-123.0.6312.122-testdata.tar.xz
+3c13cbd65b11d187576dbf40665b4e43397e706fe43516dd280ad238519aa663c490a314ff43a1f2b41c1f757e3d9dbeeefe88e2d0cf312bb149c7737d8713fd chromium-124.0.6367.60.tar.xz
+6837910f964f337cb7d43a4482dcebe707957940f037cbc368133df6ba23207dab0061d28f120cdbc9f9fb992c6256cff8e92638f767c3bc36323fbcbf10aa17 chromium-124.0.6367.60-testdata.tar.xz
bbc928e99ebcd4d953b982688b01526cb754bad018f67be9e777a4f8ac51cdd3e01374e5a63faf55b12e7cee0d52816c88062e012b5bcc4f9bb41f28d8e0b7f7 test_fonts-336e775eec536b2d785cc80eff6ac39051931286.tar.gz
+a6f400da98ee3ae30460fc8d79214a7aee5625b89a02817525e6ed5807956df52ecd5ba2a47e70caf102235266f1ff0be69402cca50799b67a2c3ad9cef1b2a4 copium-124.4.tar.gz
1b16564f85a03f3eb934ec51289dc6159e2454202d40f48354f947d6ceffac8889e9eb4c0f4dfaafb3a15101566d54039f832bc9a8433c3c463e2d1dac2d2acc chromium-launcher.sh
9cfcb41d69c5a515b6f9fe2a629579fa499e1f48eb58a0ce4ec8e5029d450bcafb6d963019aaac9a6838244bee9f9ba7fe5ef6146a0ca6b20fcda4ab7f059476 chromium.conf
2d8237a940ea691bd10b08315429677a587f7ef9692a0cca53bfd066eae82998a6c71f402a8669e9de39f94d7f3280745d1628ea6eac5d76ca7116844d4e0dac google-api.keys
29bb685e03356a77df5fd347cdf55194cc8b3265c421cc76e54d64edefc329dbcb052deb26b22e8f587ce68456876c071de1b7d258dd0fcc6ee66c875ec4a020 chromium-revert-drop-of-system-java.patch
-c116ad6325a79b799b6c56312891d5b3d2f0d0c1c3e2c03f339144b3f93b871db190f83fe5eadc5542303d61849cc362299932a2f93661198e11ba0c1e492e48 compiler.patch
+54eb147c0af2ba096d1df375a289b339ee855ab1a9114e7c747753f0274a6bafb7212c1859b7885454c4529d9a5e3bd9559fc14e8e006f23ccd381895fa68d15 compiler.patch
+4057cc78f10bfd64092bc35a373869abb1d68b880cdbca70422f39ffd78a929c19c7728d4d4c40709aaba25581148a93ae5343e724849fd35323062ed68753fa disable-dns_config_service.patch
111bc22fb704d97759988268a40d6b356c51b0bd7a8119a694e905ffe21850ff64e91566cd0dd0c9d62fcb46dca8acc821436c34eb0ba78be872ee4f7ec88a7b disable-failing-tests.patch
5fc5c012c1db6cf1ba82f38c6f3f4f5ca3a209e47ac708a74de379b018e0649b7694877c9571ef79002dde875ffc07b458a3355425f1c01867f362c66c2bc1bf fc-cache-version.patch
9200f78bad70e95c648a5e8392d50642190600f655c6baa366ff6467ebad52d3b3f305dad58f3610da67136f4b723557653b174ec5c25be8d8737ee04d9ee09f fix-missing-cstdint-include-musl.patch
@@ -869,7 +935,7 @@ e75f57ae34c97ca1caf15fa4b4106c6c1e79c31ed66869cf92ed9ea0c449886c9511e455047c17c1
50c274a420bb8a7f14fcb56e40920dac8f708792a4520789b4987facea459bef88113d5a2b60fa8c57bee6e92bff3617d6b73fa305c8c44614c638971cffd440 musl-sandbox.patch
e7163ac5810ac85366cef2447412287c856e3d67c6b77f219a6e5a418b1965b98e449c409424ad0704a5bded9355dd0aec3dc4585918ce5a2ab36c079707afe2 musl-tid-caching.patch
92eb002718026611f5542362ad69b67f0a398ff71b3fca5c05d55cb5c6f9f29334e5e127bb4860cfaa3fba0f0d4c901e2b98808217e7dc02e254a64a5c9521aa musl-v8-monotonic-pthread-cont_timedwait.patch
-5eb0b83264e2c9213fb871838827eb7875c05131a42d901032d6d1f05eec98609fefac4772385046887a773daf4f1e0ee5a647e82c1c3d73aec3fcf76f887084 no-execinfo.patch
+73bca6c6f9873f2f11cef04f3f41f71e0ae86e7e2d77e14db4298675fec390744c5081f6fdb14052e5ee2b5885be1198c3aa6068eb2b656d1a665c0c3f36e708 no-execinfo.patch
8e17101d69e23b456a9c03dc2fe95bcd56846389707ba6f4720192a9e9168406d20d9168dbebbb3a47d921ec92e478f0e390f46e6b9bb43a34dda217c6e6448b no-mallinfo.patch
e4c4e5bc6f828f9c883dd418c0ba01887949c29c311f76206a1ec29f620b0c0ba0452949dc2778a9c46ea066405857536964a36436a68eecf7da7952736333cf no-res-ninit-nclose.patch
6dc4d8dc92e685dace62265a1ddb3aebc558aed54d20ff6d36b030be0c48d7e84662326c31363612492574d9a03c62653cdc21a60995b97dee1d75cae86a9f9b no-sandbox-settls.patch
@@ -881,5 +947,4 @@ d4ac7f350806b4410ccb1df3b0ad7e90a7b6d724a16919761aa2d47a6f21008c7374da528b05b754
b3beb98b539fe160fbc493ba410ae0f68540cc4b6834f1f8ce9a22c3f4f59ef5d583ad48793e10549fd02a701f833a3969791ef4524322cd1e715ca5bf226bc8 system-zstd.patch
e48693e6b7aeebf69a5acbf80d9a35defe4c23835121dfeb58b051ac7c527e758a41004f4d193274fe1b01c0bfb1dbc77b09cb6a404a3fdee507a2918afb0edb temp-failure-retry.patch
914ccf649d7771f19f209ab97f99c481aebc6f66174d68e8b539f6ad4a70bc8cb0fae2df6dadbf0415958ffb3574c420fe029079dcce45f5e5add4db2e903566 yes-musl.patch
-4057cc78f10bfd64092bc35a373869abb1d68b880cdbca70422f39ffd78a929c19c7728d4d4c40709aaba25581148a93ae5343e724849fd35323062ed68753fa disable-dns_config_service.patch
"
diff --git a/community/chromium/compiler.patch b/community/chromium/compiler.patch
index 2541d19992b..fedc978ae48 100644
--- a/community/chromium/compiler.patch
+++ b/community/chromium/compiler.patch
@@ -1,6 +1,6 @@
--- ./build/config/compiler/BUILD.gn.orig
+++ ./build/config/compiler/BUILD.gn
-@@ -616,24 +618,6 @@
+@@ -613,24 +613,6 @@
}
}
@@ -25,7 +25,7 @@
# TODO(crbug.com/1235145): Investigate why/if this should be needed.
if (is_win) {
cflags += [ "/clang:-ffp-contract=off" ]
-@@ -1011,17 +998,6 @@
+@@ -1005,17 +987,6 @@
# `-nodefaultlibs` from the linker invocation from Rust, which would be used
# to compile dylibs on Android, such as for constructing unit test APKs.
"-Cdefault-linker-libraries",
@@ -43,7 +43,7 @@
]
if (!is_win || force_rustc_color_output) {
-@@ -1175,8 +1151,8 @@
+@@ -1182,8 +1153,8 @@
} else if (current_cpu == "arm") {
if (is_clang && !is_android && !is_nacl &&
!(is_chromeos_lacros && is_chromeos_device)) {
@@ -54,7 +54,7 @@
}
if (!is_nacl) {
cflags += [
-@@ -1190,8 +1166,8 @@
+@@ -1197,8 +1168,8 @@
} else if (current_cpu == "arm64") {
if (is_clang && !is_android && !is_nacl && !is_fuchsia &&
!(is_chromeos_lacros && is_chromeos_device)) {
@@ -65,6 +65,15 @@
}
} else if (current_cpu == "mipsel" && !is_nacl) {
ldflags += [ "-Wl,--hash-style=sysv" ]
+@@ -1983,7 +1954,7 @@
+ defines = [ "_HAS_NODISCARD" ]
+ }
+ } else {
+- cflags = [ "-Wall" ]
++ cflags = []
+ if (is_clang) {
+ # Enable extra warnings for chromium_code when we control the compiler.
+ cflags += [ "-Wextra" ]
--- ./build/config/rust.gni.orig
+++ ./build/config/rust.gni
@@ -186,11 +186,11 @@
diff --git a/community/chromium/no-execinfo.patch b/community/chromium/no-execinfo.patch
index 4b578976a3e..b1705f5d85f 100644
--- a/community/chromium/no-execinfo.patch
+++ b/community/chromium/no-execinfo.patch
@@ -37,25 +37,24 @@ for discussion about this, see https://www.openwall.com/lists/musl/2021/07/16/1
#define HAVE_FCNTL_H 1
--- a/base/debug/stack_trace.cc
+++ b/base/debug/stack_trace.cc
-@@ -251,7 +253,9 @@
+@@ -291,7 +291,7 @@
}
-
- void StackTrace::OutputToStream(std::ostream* os) const {
+ std::string StackTrace::ToStringWithPrefix(const char* prefix_string) const {
+ std::stringstream stream;
+-#if !defined(__UCLIBC__) && !defined(_AIX)
+#if defined(__GLIBC__) && !defined(_AIX)
- OutputToStreamWithPrefix(os, nullptr);
-+#endif
+ if (ShouldSuppressOutput()) {
+ return "Backtrace suppressed.";
+ }
+@@ -301,7 +301,7 @@
}
- std::string StackTrace::ToString() const {
-@@ -281,7 +281,7 @@
- }
- std::string StackTrace::ToStringWithPrefix(const char* prefix_string) const {
- std::stringstream stream;
+ std::ostream& operator<<(std::ostream& os, const StackTrace& s) {
-#if !defined(__UCLIBC__) && !defined(_AIX)
+#if defined(__GLIBC__) && !defined(_AIX)
- OutputToStreamWithPrefix(&stream, prefix_string);
- #endif
- return stream.str();
+ s.OutputToStream(&os);
+ #else
+ os << "StackTrace::OutputToStream not implemented.";
--- a/base/debug/stack_trace_unittest.cc
+++ b/base/debug/stack_trace_unittest.cc
@@ -33,7 +33,7 @@